Skip to content
This repository has been archived by the owner on Oct 6, 2020. It is now read-only.

Commit

Permalink
Merge pull request #27 from justaprogrammer/image-management
Browse files Browse the repository at this point in the history
Image Management
  • Loading branch information
StanleyGoldman committed Sep 9, 2019
2 parents d9f0c6f + 3ad96f2 commit 836d477
Show file tree
Hide file tree
Showing 42 changed files with 611 additions and 1,060 deletions.
5 changes: 5 additions & 0 deletions Build.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,10 @@ Target.create "TestData" (fun _ ->
test "SonOfPicasso.Data.Tests" "netcoreapp3.0" "datatest"
)

Target.create "TestIntegration" (fun _ ->
test "SonOfPicasso.Core.IntegrationTests" "netcoreapp3.0" "integration"
)

Target.create "Package" (fun _ ->
let packagePath = (sprintf "build/son-of-picasso-%s.zip" fullSemver)

Expand All @@ -142,6 +146,7 @@ open Fake.Core.TargetOperators
"Build" ==> "TestCore" ==> "Test"
"Build" ==> "TestUI" ==> "Test"
"Build" ==> "TestData" ==> "Test"
"Build" ==> "TestIntegration" ==> "Test"

"Build" ==> "Test" ==> "Default"
"Build" ==> "Package" ==> "Default"
Expand Down
7 changes: 7 additions & 0 deletions SonOfPicasso.sln
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SonOfPicasso.UI", "src\SonO
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SonOfPicasso.UI.Tests", "src\SonOfPicasso.UI.Tests\SonOfPicasso.UI.Tests.csproj", "{9D06ACFE-6ECD-4EC9-9CA9-8D6CCC5C362A}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SonOfPicasso.Core.IntegrationTests", "src\SonOfPicasso.Core.IntegrationTests\SonOfPicasso.Core.IntegrationTests.csproj", "{B86E824C-FAAA-4DBC-B6A9-292D0CEC5797}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -71,6 +73,10 @@ Global
{9D06ACFE-6ECD-4EC9-9CA9-8D6CCC5C362A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{9D06ACFE-6ECD-4EC9-9CA9-8D6CCC5C362A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{9D06ACFE-6ECD-4EC9-9CA9-8D6CCC5C362A}.Release|Any CPU.Build.0 = Release|Any CPU
{B86E824C-FAAA-4DBC-B6A9-292D0CEC5797}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B86E824C-FAAA-4DBC-B6A9-292D0CEC5797}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B86E824C-FAAA-4DBC-B6A9-292D0CEC5797}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B86E824C-FAAA-4DBC-B6A9-292D0CEC5797}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand All @@ -81,6 +87,7 @@ Global
{1D87A79F-C5D4-4EA0-B978-13E942B9CEE9} = {12E2CEF6-EB9D-412F-98E3-ECBBBD00A29A}
{2F6B9B2C-D228-4563-B74C-12C18E753361} = {12E2CEF6-EB9D-412F-98E3-ECBBBD00A29A}
{9D06ACFE-6ECD-4EC9-9CA9-8D6CCC5C362A} = {12E2CEF6-EB9D-412F-98E3-ECBBBD00A29A}
{B86E824C-FAAA-4DBC-B6A9-292D0CEC5797} = {12E2CEF6-EB9D-412F-98E3-ECBBBD00A29A}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {2C01583D-05D7-4F03-A86C-ECF79DA041D0}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
using System;
using Autofac.Extras.NSubstitute;
using SonOfPicasso.Data.Repository;
using SonOfPicasso.Data.Tests;
using SonOfPicasso.Testing.Common;
using Xunit;
using Xunit.Abstractions;

namespace SonOfPicasso.Core.IntegrationTests.Services
{
public class ImageManagementServiceTests : DataTestsBase, IDisposable
{
private readonly AutoSubstitute _autoSubstitute;

public ImageManagementServiceTests(ITestOutputHelper testOutputHelper)
: base(testOutputHelper)
{
_autoSubstitute = new AutoSubstitute();
_autoSubstitute.Provide<Func<UnitOfWork>>(CreateUnitOfWork);
}

[Fact]
public void CanInitialize()
{
var imageManagementService = _autoSubstitute.Resolve<Core.Services.ImageManagementService>();
}

public new void Dispose()
{
_autoSubstitute.Dispose();
base.Dispose();
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netcoreapp3.0</TargetFramework>

<IsPackable>false</IsPackable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="akavache" Version="6.8.1" />
<PackageReference Include="Autofac" Version="4.9.4" />
<PackageReference Include="Autofac.Extras.NSubstitute" Version="1.1.0" />
<PackageReference Include="FluentAssertions" Version="5.9.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.3.0-preview-20190828-03" />
<PackageReference Include="NSubstitute" Version="4.2.1" />
<PackageReference Include="NSubstitute.Analyzers.CSharp" Version="1.0.10" />
<PackageReference Include="Serilog" Version="2.8.0" />
<PackageReference Include="System.IO.Abstractions.TestingHelpers" Version="6.0.27" />
<PackageReference Include="xunit" Version="2.4.1" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.1">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\SonOfPicasso.Data.Tests\SonOfPicasso.Data.Tests.csproj" />
</ItemGroup>

</Project>
Loading

0 comments on commit 836d477

Please sign in to comment.