1

NuGetを使用してSpring.Testing.NUnitをインストールしようとしていますが、受け入れ可能なバージョンが既にあるにもかかわらず、依存関係を更新する必要があります。最新バージョンである2.6.0に更新することすらしていません。

でインストールできますが、インストールすると-IgnoreDependencies、次のエラーでテストの実行がエラーになりますCould not load file or assembly 'nunit.framework, Version=2.6.0.12051 。Spring.Testing.NUnitパッケージは、必要なNUnitのバージョンについて間違っていますか?

PM> Install-Package NUnit -Version 2.5.7.10213
'NUnit 2.5.7.10213' already installed.
Successfully added 'NUnit 2.5.7.10213' to Services.Tests.Unit.

PM> Install-Package Spring.Testing.NUnit
Attempting to resolve dependency 'Common.Logging (= 1.2.0)'.
Attempting to resolve dependency 'NUnit (= 2.5.7)'.
Attempting to resolve dependency 'Spring.Core (= 1.3.2)'.
Attempting to resolve dependency 'Spring.Data (= 1.3.2)'.
Attempting to resolve dependency 'Spring.Aop (= 1.3.2)'.
Successfully installed 'NUnit 2.5.10.11092'.
Successfully installed 'Spring.Testing.NUnit 1.3.2'.
Successfully removed 'NUnit 2.5.7.10213' from Services.Tests.Unit.
Successfully added 'NUnit 2.5.10.11092' to Services.Tests.Unit.
Successfully added 'Spring.Testing.NUnit 1.3.2' to Services.Tests.Unit.
4

1 に答える 1

2

Spring.Testing.Packages には NUnit >= 2.5.7 が必要です。NuGet は、バージョン文字列の 3 番目の部分を更新しても安全であると見なします (通常、これはこのパッケージに固有のものではありません)。この場合、NuGet は、バージョンが 2.5.7 以上で 2.6 未満である可能な限り高いケースを選択します。

于 2012-06-13T07:27:52.037 に答える