Commit e7261a24 authored by An Ionescu's avatar An Ionescu

NUnit.FixtureDependent update.

parent cdc22119
......@@ -28,20 +28,20 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void Add_ExistingKeyThrows(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.KeysInitial))]
TK key,
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.ValuesInitial))]
TV value)
=> Assert.Throws<ArgumentException>(() => bimap.Add(key, value));
[Test, SequentialDependent]
public void Add_NonExistingKey(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.KeysToAdd))]
TK key,
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.ValuesToAdd))]
TV value)
{
......@@ -74,10 +74,10 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void Indexer_Set_ExistingKey(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.KeysInitial))]
TK key,
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.ValuesInitial))]
TV value)
{
......@@ -87,10 +87,10 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void Indexer_Set_NonExistingKey(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.KeysToAdd))]
TK key,
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.ValuesToAdd))]
TV value)
{
......@@ -112,7 +112,7 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void Remove_Key_Existing(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.KeysInitial))]
TK key)
{
......@@ -137,7 +137,7 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void Remove_Key_NonExisting(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.KeysExcluded))]
TK key)
{
......@@ -171,10 +171,10 @@ namespace Anvoker.Maps.Tests.Common
[Test]
[SequentialDependent]
public void Replace_ExistingKey(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.KeysInitial))]
TK key,
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TBiMap>.ValuesToAdd))]
TV newValue)
{
......
......@@ -35,21 +35,21 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void ContainsValue_Excluded(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TROBiMap>.ValuesExcluded))]
TV value)
=> Assert.False(bimap.ContainsValue(value));
[Test, SequentialDependent]
public void ContainsValue_Initial(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TROBiMap>.ValuesInitial))]
TV value)
=> Assert.True(bimap.ContainsValue(value));
[Test, SequentialDependent]
public void GetKeysWithValue_Existing(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TROBiMap>.ValuesInitial))]
TV value)
{
......@@ -62,7 +62,7 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void GetKeysWithValue_NonExisting(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TROBiMap>.ValuesExcluded))]
TV value)
=> CollectionAssert.IsEmpty(bimap.GetKeysWithValue(value));
......
......@@ -29,14 +29,14 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void ContainsKey_ExcludedKeys(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TRODictionary>.KeysExcluded))]
TK key)
=> Assert.IsFalse(dictionary.ContainsKey(key));
[Test, SequentialDependent]
public void ContainsKey_InitialKeys(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TRODictionary>.KeysInitial))]
TK key)
=> Assert.IsTrue(dictionary.ContainsKey(key));
......@@ -69,17 +69,17 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void Indexer_Get_ExistingKey(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TRODictionary>.KeysInitial))]
TK key,
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TRODictionary>.ValuesInitial))]
TV expectedValue)
=> Assert.AreEqual(expectedValue, dictionary[key]);
[Test, SequentialDependent]
public void Indexer_Get_NonExistingKey(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TRODictionary>.KeysExcluded))]
TK key)
=> Assert.Throws<KeyNotFoundException>(()
......@@ -92,10 +92,10 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void TryGetValue_ExistingKey(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TRODictionary>.KeysInitial))]
TK key,
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TRODictionary>.ValuesInitial))]
TV expectedValue)
{
......@@ -110,7 +110,7 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void TryGetValue_NonExistingKey(
[ValueDependentSource(typeof(IKeyValueData<,,>),
[FixtureValueSource(typeof(IKeyValueData<,,>),
nameof(IKeyValueData<TK, TV, TRODictionary>.KeysExcluded))]
TK key)
{
......
......@@ -73,7 +73,7 @@ namespace Anvoker.Maps.Tests.Common
public void GetKeysWith_Excluded(
[ValueSource(nameof(SelectorCases))]
string selectorKey,
[ValueDependentSource(typeof(IKeyValuesData<,,,>),
[FixtureValueSource(typeof(IKeyValuesData<,,,>),
nameof(IKeyValuesData<TK, TV, TROMBiMap, TVCol>.KVPsExcluded))]
KeyValuePair<TK, TVCol> kvp)
{
......@@ -90,7 +90,7 @@ namespace Anvoker.Maps.Tests.Common
public void GetKeysWith_Initial(
[ValueSource(nameof(SelectorCases))]
string selectorKey,
[ValueDependentSource(typeof(IKeyValuesData<,,,>),
[FixtureValueSource(typeof(IKeyValuesData<,,,>),
nameof(IKeyValuesData<TK, TV, TROMBiMap, TVCol>.KVPsInitial))]
KeyValuePair<TK, TVCol> kvp)
{
......@@ -105,7 +105,7 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void GetKeysWithValue_Excluded(
[ValueDependentSource(typeof(IKeyValuesData<,,,>),
[FixtureValueSource(typeof(IKeyValuesData<,,,>),
nameof(IKeyValuesData<TK, TV, TROMBiMap, TVCol>.KVPsExcluded))]
KeyValuePair<TK, TVCol> kvp)
{
......@@ -124,7 +124,7 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void GetKeysWithValue_Initial(
[ValueDependentSource(typeof(IKeyValuesData<,,,>),
[FixtureValueSource(typeof(IKeyValuesData<,,,>),
nameof(IKeyValuesData<TK, TV, TROMBiMap, TVCol>.KVPsInitial))]
KeyValuePair<TK, TVCol> kvp)
{
......
......@@ -37,14 +37,14 @@ namespace Anvoker.Maps.Tests.Common
[Test, SequentialDependent]
public void ContainsValue_Excluded(
[ValueDependentSource(typeof(IKeyValuesData<,,,>),
[FixtureValueSource(typeof(IKeyValuesData<,,,>),
nameof(IKeyValuesData<TK, TV, TROMMap, TVCol>.ValuesExcludedFlat))]
TV value)
=> Assert.False(map.ContainsValue(value));
[Test, SequentialDependent]
public void ContainsValue_Initial(
[ValueDependentSource(typeof(IKeyValuesData<,,,>),
[FixtureValueSource(typeof(IKeyValuesData<,,,>),
nameof(IKeyValuesData<TK, TV, TROMMap, TVCol>.ValuesInitialFlat))]
TV value)
=> Assert.True(map.ContainsValue(value));
......
......@@ -46,7 +46,7 @@
</PropertyGroup>
<ItemGroup>
<Reference Include="NUnit.FixtureDependent, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\..\..\packages\NUnit.FixtureDependent.1.0.0\lib\net461\NUnit.FixtureDependent.dll</HintPath>
<HintPath>..\..\packages\NUnit.FixtureDependent.2.0.0\lib\net461\NUnit.FixtureDependent.dll</HintPath>
</Reference>
<Reference Include="nunit.framework, Version=3.11.0.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
<HintPath>..\..\..\Assets\NuGetPackages\NUnit.3.11.0\lib\net45\nunit.framework.dll</HintPath>
......
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="NUnit" version="3.11.0" targetFramework="net461" />
<package id="NUnit.FixtureDependent" version="1.0.0" targetFramework="net461" />
<package id="NUnit.FixtureDependent" version="2.0.0" targetFramework="net461" />
</packages>
\ No newline at end of file
......@@ -6,10 +6,10 @@ using System.Runtime.InteropServices;
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Anvoker.Maps")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyDescription("Provides map collections with compatibility with standard collection interfaces, including multimaps and bimaps.")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("Anvoker.Maps.Properties")]
[assembly: AssemblyCompany("Andrei Ionescu")]
[assembly: AssemblyProduct("Anvoker.Maps")]
[assembly: AssemblyCopyright("Copyright © 2019")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment