From f89bf493ca545a7e53b0ef9b5208c5e1670ae740 Mon Sep 17 00:00:00 2001 From: "HOT-ROD\\craig" Date: Wed, 20 Jun 2018 16:49:25 +0100 Subject: [PATCH] Fixed NuGet package cache problems. Added more unit tests. --- TestCentre/TestCentre.fsproj | 3 +-- TestCentre/UnitTests.fs | 27 ++++++++++++++++++++++++--- WetPancake/WetPancake.fsproj | 2 +- WetPancake/packages.config | 2 +- WetPancakeCLI/WetPancakeCLI.csproj | 3 +++ WetPancakeCLI/packages.config | 1 + 6 files changed, 31 insertions(+), 7 deletions(-) diff --git a/TestCentre/TestCentre.fsproj b/TestCentre/TestCentre.fsproj index dce0da2..a9e97f5 100644 --- a/TestCentre/TestCentre.fsproj +++ b/TestCentre/TestCentre.fsproj @@ -56,9 +56,8 @@ - - + diff --git a/TestCentre/UnitTests.fs b/TestCentre/UnitTests.fs index 2a09ef5..ba7dc04 100644 --- a/TestCentre/UnitTests.fs +++ b/TestCentre/UnitTests.fs @@ -5,6 +5,27 @@ open Xunit open WetPancake open TestingConstants + open System.IO + + (*These tests check to see if the .txt files exists in the Test Centre project. + The Wet Pancake library does not expose the file access functions so the .txt + files are mirrored here (in Text Centre) + The mirroring, also, doubles up as sample files to pass into Wet Pancake.*) + [] + let ``desktop-clock-info-txt can be found`` () = + let result = File.Exists DesktopClock + Assert.Equal(true, result); + + [] + let ``console-waterworks-announcements-txt can be found`` () = + let result = File.Exists ConsoleWaterworks + Assert.Equal(true, result); + + [] + let ``word-generator-txt can be found`` () = + let result = File.Exists WordGenerator + Assert.Equal(true, result); + [] let ``Request Random Text does not generate a null`` () = @@ -17,16 +38,16 @@ Assert.NotNull result [] - let ``Request Text From File does not generate a null for desktop-clock-info.txt`` () = + let ``Request Text From File does not generate a null for desktop-clock-info-txt`` () = let result = Pancake.RequestTextFromFile 5 5 DesktopClock Assert.NotNull result [] - let ``Request Text From File does not generate a null for console-waterworks-announcement.txt`` () = + let ``Request Text From File does not generate a null for console-waterworks-announcement-txt`` () = let result = Pancake.RequestTextFromFile 5 5 ConsoleWaterworks Assert.NotNull result [] - let ``Request Text From File does not generate a null for word-generator.txt`` () = + let ``Request Text From File does not generate a null for word-generator-txt`` () = let result = Pancake.RequestTextFromFile 5 5 WordGenerator Assert.NotNull result \ No newline at end of file diff --git a/WetPancake/WetPancake.fsproj b/WetPancake/WetPancake.fsproj index 9e59902..ed2bcf8 100644 --- a/WetPancake/WetPancake.fsproj +++ b/WetPancake/WetPancake.fsproj @@ -54,7 +54,6 @@ - @@ -64,6 +63,7 @@ + diff --git a/WetPancake/packages.config b/WetPancake/packages.config index b4aca10..949fd55 100644 --- a/WetPancake/packages.config +++ b/WetPancake/packages.config @@ -1,4 +1,4 @@  - + \ No newline at end of file diff --git a/WetPancakeCLI/WetPancakeCLI.csproj b/WetPancakeCLI/WetPancakeCLI.csproj index 5bb7aa7..870e136 100644 --- a/WetPancakeCLI/WetPancakeCLI.csproj +++ b/WetPancakeCLI/WetPancakeCLI.csproj @@ -40,6 +40,9 @@ + + ..\packages\System.ValueTuple.4.5.0\lib\net47\System.ValueTuple.dll + diff --git a/WetPancakeCLI/packages.config b/WetPancakeCLI/packages.config index 464c85b..43ce362 100644 --- a/WetPancakeCLI/packages.config +++ b/WetPancakeCLI/packages.config @@ -1,4 +1,5 @@  + \ No newline at end of file