Skip to content

Commit 3012c58

Browse files
unknownunknown
authored andcommitted
lots more assertions and tests. restructured project. build and nuget package working
1 parent f8dc82a commit 3012c58

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+464
-876
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,6 @@
55
test-results
66
*.pidb
77
*.userprefs
8+
*.pfx
9+
cmd.exe
10+
[Pp]ackage

Build.cmd

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
@echo off
2+
pushd %~dp0
3+
4+
if exist bin goto build
5+
mkdir bin
6+
7+
:Build
8+
if "%1" == "" goto BuildDefaults
9+
10+
%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\msbuild FluentAssertionsMvc.msbuild /m /nr:false /t:%* /v:M /fl /flp:LogFile=bin\msbuild.log;Verbosity=Normal
11+
if errorlevel 1 goto BuildFail
12+
goto BuildSuccess
13+
14+
:BuildDefaults
15+
%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\msbuild FluentAssertionsMvc.msbuild /m /nr:false /v:M /fl /flp:LogFile=bin\msbuild.log;Verbosity=Normal
16+
if errorlevel 1 goto BuildFail
17+
goto BuildSuccess
18+
19+
:BuildFail
20+
echo.
21+
echo *** BUILD FAILED ***
22+
goto End
23+
24+
:BuildSuccess
25+
echo.
26+
echo **** BUILD SUCCESSFUL ***
27+
goto end
28+
29+
:End
30+
popd
31+
32+
echo.
33+
pause

FluentAssertionsMvc.msbuild

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
<Project DefaultTargets="UnitTest" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
2+
<PropertyGroup>
3+
<Configuration Condition=" '$(Configuration)' == '' ">Release</Configuration>
4+
5+
<CodeAnalysis Condition=" '$(CodeAnalysis)' == ''">true</CodeAnalysis>
6+
<StyleCopEnabled Condition=" '$(StyleCopEnabled)' == '' ">true</StyleCopEnabled>
7+
8+
</PropertyGroup>
9+
10+
<Target Name="Clean">
11+
<MSBuild
12+
Projects="FluentAssertionsMvc.sln"
13+
Targets="Clean"
14+
Properties="Configuration=$(Configuration)" />
15+
<RemoveDir Directories="bin\$(Configuration)" />
16+
</Target>
17+
18+
<Target Name="Build" DependsOnTargets="Prereq">
19+
<MakeDir Directories="bin\$(Configuration)" />
20+
<MSBuild
21+
Projects="FluentAssertionsMvc.sln"
22+
BuildInParallel="$(BuildInParallel)"
23+
Targets="Build"
24+
Properties="Configuration=$(Configuration);CodeAnalysis=$(CodeAnalysis);StyleCopEnabled=$(StyleCopEnabled)" />
25+
</Target>
26+
27+
<Target Name="Prereq">
28+
</Target>
29+
30+
<Target Name="UnitTest" DependsOnTargets="Clean;Build">
31+
</Target>
32+
33+
</Project>
Lines changed: 13 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11

22
Microsoft Visual Studio Solution File, Format Version 11.00
3-
# Visual C# Express 2010
4-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FluentAssertions.Mvc3.Tests", "FluentAssertions.Mvc.Tests\FluentAssertions.Mvc3.Tests.csproj", "{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}"
3+
# Visual Web Developer Express 2010
4+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FluentAssertions.Mvc3", "src\FluentAssertions.Mvc3\FluentAssertions.Mvc3.csproj", "{53589F79-0908-409A-8366-3E18DC637600}"
55
EndProject
6-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FluentAssertions.Mvc3", "FluentAssertions.Mvc3\FluentAssertions.Mvc3.csproj", "{53589F79-0908-409A-8366-3E18DC637600}"
6+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FluentAssertions.Mvc3.Tests", "tests\FluentAssertions.Mvc3.Tests\FluentAssertions.Mvc3.Tests.csproj", "{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}"
77
EndProject
8-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "test", "test\test.csproj", "{D29AE253-FEE8-4A54-BFBD-323CAD27F549}"
8+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "test", "tests\test\test.csproj", "{D29AE253-FEE8-4A54-BFBD-323CAD27F549}"
99
EndProject
10-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FluentAssertions.Mvc3.Samples", "FluentAssertions.Mvc3.Samples\FluentAssertions.Mvc3.Samples.csproj", "{7B9B969E-C3E1-47DD-89B1-AD17232D4A23}"
10+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FluentAssertions.Mvc3.Samples", "samples\FluentAssertions.Mvc3.Samples\FluentAssertions.Mvc3.Samples.csproj", "{7B9B969E-C3E1-47DD-89B1-AD17232D4A23}"
1111
EndProject
1212
Global
1313
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -19,16 +19,6 @@ Global
1919
Release|x86 = Release|x86
2020
EndGlobalSection
2121
GlobalSection(ProjectConfigurationPlatforms) = postSolution
22-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
23-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Debug|Any CPU.Build.0 = Debug|Any CPU
24-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
25-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
26-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Debug|x86.ActiveCfg = Debug|Any CPU
27-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Release|Any CPU.ActiveCfg = Release|Any CPU
28-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Release|Any CPU.Build.0 = Release|Any CPU
29-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
30-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Release|Mixed Platforms.Build.0 = Release|Any CPU
31-
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Release|x86.ActiveCfg = Release|Any CPU
3222
{53589F79-0908-409A-8366-3E18DC637600}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
3323
{53589F79-0908-409A-8366-3E18DC637600}.Debug|Any CPU.Build.0 = Debug|Any CPU
3424
{53589F79-0908-409A-8366-3E18DC637600}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
@@ -39,14 +29,21 @@ Global
3929
{53589F79-0908-409A-8366-3E18DC637600}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
4030
{53589F79-0908-409A-8366-3E18DC637600}.Release|Mixed Platforms.Build.0 = Release|Any CPU
4131
{53589F79-0908-409A-8366-3E18DC637600}.Release|x86.ActiveCfg = Release|Any CPU
32+
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
33+
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
34+
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
35+
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Debug|x86.ActiveCfg = Debug|Any CPU
36+
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Release|Any CPU.ActiveCfg = Release|Any CPU
37+
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
38+
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Release|Mixed Platforms.Build.0 = Release|Any CPU
39+
{3CB00FF9-3DC2-460F-82E8-EBFB6339247D}.Release|x86.ActiveCfg = Release|Any CPU
4240
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Debug|Any CPU.ActiveCfg = Debug|x86
4341
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Debug|Mixed Platforms.ActiveCfg = Debug|x86
4442
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Debug|Mixed Platforms.Build.0 = Debug|x86
4543
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Debug|x86.ActiveCfg = Debug|x86
4644
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Debug|x86.Build.0 = Debug|x86
4745
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Release|Any CPU.ActiveCfg = Release|x86
4846
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Release|Mixed Platforms.ActiveCfg = Release|x86
49-
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Release|Mixed Platforms.Build.0 = Release|x86
5047
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Release|x86.ActiveCfg = Release|x86
5148
{D29AE253-FEE8-4A54-BFBD-323CAD27F549}.Release|x86.Build.0 = Release|x86
5249
{7B9B969E-C3E1-47DD-89B1-AD17232D4A23}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
@@ -57,13 +54,9 @@ Global
5754
{7B9B969E-C3E1-47DD-89B1-AD17232D4A23}.Release|Any CPU.ActiveCfg = Release|Any CPU
5855
{7B9B969E-C3E1-47DD-89B1-AD17232D4A23}.Release|Any CPU.Build.0 = Release|Any CPU
5956
{7B9B969E-C3E1-47DD-89B1-AD17232D4A23}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
60-
{7B9B969E-C3E1-47DD-89B1-AD17232D4A23}.Release|Mixed Platforms.Build.0 = Release|Any CPU
6157
{7B9B969E-C3E1-47DD-89B1-AD17232D4A23}.Release|x86.ActiveCfg = Release|Any CPU
6258
EndGlobalSection
6359
GlobalSection(SolutionProperties) = preSolution
6460
HideSolutionNode = FALSE
6561
EndGlobalSection
66-
GlobalSection(MonoDevelopProperties) = preSolution
67-
StartupItem = FluentAssertions.Mvc3\FluentAssertions.Mvc3.csproj
68-
EndGlobalSection
6962
EndGlobal

Package.cmd

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
@ECHO OFF
2+
pushd %~dp0
3+
4+
%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\msbuild FluentAssertionsMvc.msbuild /m /nr:false /v:M /fl /flp:LogFile=bin\msbuild.log;Verbosity=Normal
5+
if errorlevel 1 goto BuildFail
6+
7+
echo.
8+
echo *** BUILD SUCCESSFUL ***
9+
echo.
10+
11+
cd package
12+
nuget pack
13+
if errorlevel 1 goto PackageFail
14+
15+
echo.
16+
echo *** PACKAGE SUCCESSFUL ***
17+
echo.
18+
goto End
19+
20+
:BuildFail
21+
echo.
22+
echo *** BUILD FAILED ***
23+
goto End
24+
25+
:BuildFail
26+
echo.
27+
echo *** PACKAGE FAILED ***
28+
goto End
29+
30+
31+
:End
32+
popd
33+
34+
echo.
35+
pause

_todo_.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[ ] Check for ActionResult types that derive from basic types
2+
[ ] Change lib folder to use restorable nuget packages

src/FluentAssertions.Mvc3.Samples/FluentAssertions.Mvc3.Samples.csproj renamed to samples/FluentAssertions.Mvc3.Samples/FluentAssertions.Mvc3.Samples.csproj

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory),FluentAssertionsMvc.sln))\tools\FluentAssertionsMvc.settings.targets" />
34
<PropertyGroup>
45
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
56
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
@@ -49,9 +50,6 @@
4950
<Reference Include="System.Xml" />
5051
</ItemGroup>
5152
<ItemGroup>
52-
<Compile Include="..\SolutionInfo.cs">
53-
<Link>Properties\SolutionInfo.cs</Link>
54-
</Compile>
5553
<Compile Include="ActionResult_Samples.cs" />
5654
<Compile Include="Controllers\HomeController.cs" />
5755
<Compile Include="IncomingUrl_Samples.cs" />
@@ -61,7 +59,7 @@
6159
<Compile Include="Properties\AssemblyInfo.cs" />
6260
</ItemGroup>
6361
<ItemGroup>
64-
<ProjectReference Include="..\FluentAssertions.Mvc3\FluentAssertions.Mvc3.csproj">
62+
<ProjectReference Include="..\..\src\FluentAssertions.Mvc3\FluentAssertions.Mvc3.csproj">
6563
<Project>{53589F79-0908-409A-8366-3E18DC637600}</Project>
6664
<Name>FluentAssertions.Mvc3</Name>
6765
</ProjectReference>

0 commit comments

Comments
 (0)