Skip to content

Commit

Permalink
Create more regression tests for #1178
Browse files Browse the repository at this point in the history
  • Loading branch information
forki committed Oct 30, 2015
1 parent 49e10ee commit 6a5641a
Show file tree
Hide file tree
Showing 5 changed files with 36 additions and 17 deletions.
21 changes: 20 additions & 1 deletion integrationtests/Paket.IntegrationTests/UpdatePackageSpecs.fs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,17 @@ open System.Diagnostics
open Paket
open Paket.Domain

[<Test>]
let ``#1178 update specific package``() =
paket "update nuget NUnit" "i001178-update-with-regex" |> ignore
let lockFile = LockFile.LoadFrom(Path.Combine(scenarioTempPath "i001178-update-with-regex","paket.lock"))
lockFile.Groups.[Constants.MainDependencyGroup].Resolution.[PackageName "Castle.Windsor"].Version
|> shouldEqual (SemVer.Parse "2.5.1")
lockFile.Groups.[Constants.MainDependencyGroup].Resolution.[PackageName "NUnit"].Version
|> shouldBeGreaterThan (SemVer.Parse "2.6.1")
lockFile.Groups.[Constants.MainDependencyGroup].Resolution.[PackageName "Microsoft.AspNet.WebApi.SelfHost"].Version
|> shouldEqual (SemVer.Parse "5.0.1")

[<Test>]
let ``#1178 update with Mircosoft.* filter``() =
paket "update nuget Microsoft.* --filter" "i001178-update-with-regex" |> ignore
Expand All @@ -30,4 +41,12 @@ let ``#1178 update with [MN].* --filter``() =
lockFile.Groups.[Constants.MainDependencyGroup].Resolution.[PackageName "NUnit"].Version
|> shouldBeGreaterThan (SemVer.Parse "2.6.1")
lockFile.Groups.[Constants.MainDependencyGroup].Resolution.[PackageName "Microsoft.AspNet.WebApi.SelfHost"].Version
|> shouldBeGreaterThan (SemVer.Parse "5.0.1")
|> shouldBeGreaterThan (SemVer.Parse "5.0.1")

[<Test>]
let ``#1178 update with [MN].* and without filter should fail``() =
try
paket "update nuget [MN].*" "i001178-update-with-regex" |> ignore
failwithf "Paket command expected to fail"
with
| exn when exn.Message.Contains "Package [MN].* was not found in paket.dependencies in group Main" -> ()
8 changes: 4 additions & 4 deletions src/Paket.Bootstrapper/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
[assembly: AssemblyTitleAttribute("Paket.Bootstrapper")]
[assembly: AssemblyProductAttribute("Paket")]
[assembly: AssemblyDescriptionAttribute("A package dependency manager for .NET with support for NuGet packages and GitHub repositories.")]
[assembly: AssemblyVersionAttribute("2.19.0")]
[assembly: AssemblyFileVersionAttribute("2.19.0")]
[assembly: AssemblyInformationalVersionAttribute("2.19.0")]
[assembly: AssemblyVersionAttribute("2.20.0")]
[assembly: AssemblyFileVersionAttribute("2.20.0")]
[assembly: AssemblyInformationalVersionAttribute("2.20.0")]
namespace System {
internal static class AssemblyVersionInformation {
internal const string Version = "2.19.0";
internal const string Version = "2.20.0";
}
}
8 changes: 4 additions & 4 deletions src/Paket.Core/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ open System.Reflection
[<assembly: AssemblyProductAttribute("Paket")>]
[<assembly: AssemblyCompanyAttribute("Paket team")>]
[<assembly: AssemblyDescriptionAttribute("A package dependency manager for .NET with support for NuGet packages and GitHub repositories.")>]
[<assembly: AssemblyVersionAttribute("2.19.0")>]
[<assembly: AssemblyFileVersionAttribute("2.19.0")>]
[<assembly: AssemblyInformationalVersionAttribute("2.19.0")>]
[<assembly: AssemblyVersionAttribute("2.20.0")>]
[<assembly: AssemblyFileVersionAttribute("2.20.0")>]
[<assembly: AssemblyInformationalVersionAttribute("2.20.0")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] Version = "2.19.0"
let [<Literal>] Version = "2.20.0"
8 changes: 4 additions & 4 deletions src/Paket.PowerShell/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ open System.Reflection
[<assembly: AssemblyProductAttribute("Paket")>]
[<assembly: AssemblyCompanyAttribute("Paket team")>]
[<assembly: AssemblyDescriptionAttribute("A package dependency manager for .NET with support for NuGet packages and GitHub repositories.")>]
[<assembly: AssemblyVersionAttribute("2.19.0")>]
[<assembly: AssemblyFileVersionAttribute("2.19.0")>]
[<assembly: AssemblyInformationalVersionAttribute("2.19.0")>]
[<assembly: AssemblyVersionAttribute("2.20.0")>]
[<assembly: AssemblyFileVersionAttribute("2.20.0")>]
[<assembly: AssemblyInformationalVersionAttribute("2.20.0")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] Version = "2.19.0"
let [<Literal>] Version = "2.20.0"
8 changes: 4 additions & 4 deletions src/Paket/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ open System.Reflection
[<assembly: AssemblyProductAttribute("Paket")>]
[<assembly: AssemblyCompanyAttribute("Paket team")>]
[<assembly: AssemblyDescriptionAttribute("A package dependency manager for .NET with support for NuGet packages and GitHub repositories.")>]
[<assembly: AssemblyVersionAttribute("2.19.0")>]
[<assembly: AssemblyFileVersionAttribute("2.19.0")>]
[<assembly: AssemblyInformationalVersionAttribute("2.19.0")>]
[<assembly: AssemblyVersionAttribute("2.20.0")>]
[<assembly: AssemblyFileVersionAttribute("2.20.0")>]
[<assembly: AssemblyInformationalVersionAttribute("2.20.0")>]
do ()

module internal AssemblyVersionInformation =
let [<Literal>] Version = "2.19.0"
let [<Literal>] Version = "2.20.0"

0 comments on commit 6a5641a

Please sign in to comment.