mirror of
https://github.com/aaronpo97/the-biergarten-app.git
synced 2026-02-16 10:42:08 +00:00
Merge pull request #142 from aaronpo97/fix-test-config
Fix test namespaces and Dockerfile project paths
This commit is contained in:
@@ -1,10 +1,9 @@
|
|||||||
using System.Data;
|
|
||||||
using Apps72.Dev.Data.DbMocker;
|
using Apps72.Dev.Data.DbMocker;
|
||||||
using FluentAssertions;
|
using FluentAssertions;
|
||||||
using Infrastructure.Repository.Auth;
|
using Infrastructure.Repository.Auth;
|
||||||
using Repository.Tests.Database;
|
using Infrastructure.Repository.Tests.Database;
|
||||||
|
|
||||||
namespace Repository.Tests.Auth;
|
namespace Infrastructure.Repository.Tests.Auth;
|
||||||
|
|
||||||
public class AuthRepositoryTest
|
public class AuthRepositoryTest
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
using System.Data.Common;
|
using System.Data.Common;
|
||||||
using Infrastructure.Repository.Sql;
|
using Infrastructure.Repository.Sql;
|
||||||
|
|
||||||
namespace Repository.Tests.Database;
|
namespace Infrastructure.Repository.Tests.Database;
|
||||||
|
|
||||||
internal class TestConnectionFactory(DbConnection conn) : ISqlConnectionFactory
|
internal class TestConnectionFactory(DbConnection conn) : ISqlConnectionFactory
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -3,13 +3,13 @@ ARG BUILD_CONFIGURATION=Release
|
|||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
COPY ["Domain/Domain.csproj", "Domain/"]
|
COPY ["Domain/Domain.csproj", "Domain/"]
|
||||||
COPY ["Infrastructure/Infrastructure.Repository/Infrastructure.Repository.csproj", "Infrastructure/Infrastructure.Repository/"]
|
COPY ["Infrastructure/Infrastructure.Repository/Infrastructure.Repository.csproj", "Infrastructure/Infrastructure.Repository/"]
|
||||||
COPY ["Infrastructure/Infrastructure.Repository.Tests/Repository.Tests.csproj", "Infrastructure/Infrastructure.Repository.Tests/"]
|
COPY ["Infrastructure/Infrastructure.Repository.Tests/Infrastructure.Repository.Tests.csproj", "Infrastructure/Infrastructure.Repository.Tests/"]
|
||||||
RUN dotnet restore "Infrastructure/Infrastructure.Repository.Tests/Repository.Tests.csproj"
|
RUN dotnet restore "Infrastructure/Infrastructure.Repository.Tests/Infrastructure.Repository.Tests.csproj"
|
||||||
COPY . .
|
COPY . .
|
||||||
WORKDIR "/src/Infrastructure/Infrastructure.Repository.Tests"
|
WORKDIR "/src/Infrastructure/Infrastructure.Repository.Tests"
|
||||||
RUN dotnet build "./Repository.Tests.csproj" -c $BUILD_CONFIGURATION -o /app/build
|
RUN dotnet build "./Infrastructure.Repository.Tests.csproj" -c $BUILD_CONFIGURATION -o /app/build
|
||||||
|
|
||||||
FROM build AS final
|
FROM build AS final
|
||||||
RUN mkdir -p /app/test-results
|
RUN mkdir -p /app/test-results
|
||||||
WORKDIR /src/Infrastructure/Infrastructure.Repository.Tests
|
WORKDIR /src/Infrastructure/Infrastructure.Repository.Tests
|
||||||
ENTRYPOINT ["dotnet", "test", "./Repository.Tests.csproj", "-c", "Release", "--logger", "trx;LogFileName=/app/test-results/repository-tests.trx"]
|
ENTRYPOINT ["dotnet", "test", "./Infrastructure.Repository.Tests.csproj", "-c", "Release", "--logger", "trx;LogFileName=/app/test-results/repository-tests.trx"]
|
||||||
|
|||||||
@@ -1,9 +1,9 @@
|
|||||||
using Apps72.Dev.Data.DbMocker;
|
using Apps72.Dev.Data.DbMocker;
|
||||||
using FluentAssertions;
|
using FluentAssertions;
|
||||||
|
using Infrastructure.Repository.Tests.Database;
|
||||||
using Infrastructure.Repository.UserAccount;
|
using Infrastructure.Repository.UserAccount;
|
||||||
using Repository.Tests.Database;
|
|
||||||
|
|
||||||
namespace Repository.Tests.UserAccount;
|
namespace Infrastructure.Repository.Tests.UserAccount;
|
||||||
|
|
||||||
public class UserAccountRepositoryTest
|
public class UserAccountRepositoryTest
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user