Removes the redundant contract and enumeration tests

This commit is contained in:
BinaryAlley committed 2026-09-26 17:56:57 +03:00
1 parent 4dce426b38
commit dc2692e208
127 files changed
-6721

No files matched your search

@@ -48,50 +48,4 @@ public class PluginSettingDescriptorDtoTests
Assert.Null(result.DefaultValue);
Assert.Null(result.AllowedValues);
}
[Fact]
public void Equality_WhenTwoDescriptorsHaveTheSameValues_ShouldBeEqual()
{
// Arrange
IReadOnlyList<string> allowedValues = ["A"];
// Act
PluginSettingDescriptorDto first = _pluginSettingDescriptorDtoFixture.Create(key: "Key", label: "Label", type: PluginSettingType.Text, defaultValue: "value", allowedValues: allowedValues);
PluginSettingDescriptorDto second = _pluginSettingDescriptorDtoFixture.Create(key: "Key", label: "Label", type: PluginSettingType.Text, defaultValue: "value", allowedValues: allowedValues);
bool result = first == second;
// Assert
Assert.True(result);
Assert.Equal(first, second);
Assert.Equal(first.GetHashCode(), second.GetHashCode());
}
[Fact]
public void Equality_WhenDescriptorsHaveDifferentAllowedValueInstances_ShouldNotBeEqual()
{
// Arrange
PluginSettingDescriptorDto first = _pluginSettingDescriptorDtoFixture.Create(key: "Key", label: "Label", type: PluginSettingType.Text, defaultValue: "value", allowedValues: ["A"]);
PluginSettingDescriptorDto second = _pluginSettingDescriptorDtoFixture.Create(key: "Key", label: "Label", type: PluginSettingType.Text, defaultValue: "value", allowedValues: ["A"]);
// Act
bool result = first == second;
// Assert
Assert.False(result);
}
[Fact]
public void Equality_WhenTwoDescriptorsHaveDifferentKeys_ShouldNotBeEqual()
{
// Arrange
PluginSettingDescriptorDto first = _pluginSettingDescriptorDtoFixture.Create(key: "KeyOne", label: "Label", type: PluginSettingType.Text);
PluginSettingDescriptorDto second = _pluginSettingDescriptorDtoFixture.Create(key: "KeyTwo", label: "Label", type: PluginSettingType.Text);
// Act
bool result = first == second;
// Assert
Assert.False(result);
Assert.NotEqual(first, second);
}
}