Skip to content

Commit

Permalink
Fix test cases initialization
Browse files Browse the repository at this point in the history
  • Loading branch information
andreise committed Jan 11, 2024
1 parent 43ad5b8 commit 3a9fe98
Showing 1 changed file with 21 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ public void CanCastArray_ValueType_TypeTheSame_ExpectTrue(FlatArray<byte> source
public static TheoryData<FlatArray<byte>> CanCastArray_ValueType_TypeTheSame_ExpectTrue_CaseSource => new()
{
{
default
Array.Empty<byte>().InitializeFlatArray()
},
{
new FlatArray<byte>(1)
new byte[] { 1 }.InitializeFlatArray()
},
{
new FlatArray<byte>(1, 2)
new byte[] { 1, 2 }.InitializeFlatArray()
}
};

Expand All @@ -39,13 +39,13 @@ public void CanCastArray_ValueType_TypeCompatible_ExpectTrue(FlatArray<byte> sou
public static TheoryData<FlatArray<byte>> CanCastArray_ValueType_TypeCompatible_ExpectTrue_CaseSource => new()
{
{
default
Array.Empty<byte>().InitializeFlatArray()
},
{
new FlatArray<byte>(1)
new byte[] { 1 }.InitializeFlatArray()
},
{
new FlatArray<byte>(1, 2)
new byte[] { 1, 2 }.InitializeFlatArray()
}
};

Expand All @@ -60,13 +60,13 @@ public void CanCastArray_ValueType_TypeIncompatible_ExpectFalse(FlatArray<byte>
public static TheoryData<FlatArray<byte>> CanCastArray_ValueType_TypeIncompatible_ExpectFalse_CaseSource => new()
{
{
default
Array.Empty<byte>().InitializeFlatArray()
},
{
new FlatArray<byte>(1)
new byte[] { 1 }.InitializeFlatArray()
},
{
new FlatArray<byte>(1, 2)
new byte[] { 1, 2 }.InitializeFlatArray()
}
};

Expand All @@ -83,16 +83,16 @@ public void CanCastArray_RefType_TypeTheSame_ExpectTrue(FlatArray<string> source
public static TheoryData<FlatArray<string>> CanCastArray_RefType_TypeTheSame_ExpectTrue_CaseSource => new()
{
{
default
Array.Empty<string>().InitializeFlatArray()
},
{
new FlatArray<string>("1")
new[] { "1" }.InitializeFlatArray()
},
{
new FlatArray<string>("1", "2")
new[] { "1", "2" }.InitializeFlatArray()
},
{
new FlatArray<string>(null!, "1", "2")
new[] { null!, "1", "2" }.InitializeFlatArray()
}
};

Expand All @@ -107,16 +107,16 @@ public void CanCastArray_RefType_TypeCompatible_ExpectTrue(FlatArray<string> sou
public static TheoryData<FlatArray<string>> CanCastArray_RefType_TypeCompatible_ExpectTrue_CaseSource => new()
{
{
default
Array.Empty<string>().InitializeFlatArray()
},
{
new FlatArray<string>("1")
new[] { "1" }.InitializeFlatArray()
},
{
new FlatArray<string>("1", "2")
new[] { "1", "2" }.InitializeFlatArray()
},
{
new FlatArray<string>(null!, "1", "2")
new[] { null!, "1", "2" }.InitializeFlatArray()
}
};

Expand All @@ -131,16 +131,16 @@ public void CanCastArray_RefType_TypeIncompatible_ExpectFalse(FlatArray<object>
public static TheoryData<FlatArray<object>> CanCastArray_RefType_TypeIncompatible_ExpectFalse_CaseSource => new()
{
{
default
Array.Empty<object>().InitializeFlatArray()
},
{
new FlatArray<object>(new object())
new[] { new object() }.InitializeFlatArray()
},
{
new FlatArray<object>(new object(), new object())
new[] { new object(), new object() }.InitializeFlatArray()
},
{
new FlatArray<object>(null!, new object(), new object())
new[] { null!, new object(), new object() }.InitializeFlatArray()
}
};
}

0 comments on commit 3a9fe98

Please sign in to comment.