예제 #1
0
        public void EqualsShouldReturnTrueWhenReferencesAreEqual()
        {
            var table      = new SettingsTable <string, string>();
            var otherTable = table;

            Assert.True(table.Equals(otherTable));
        }
예제 #2
0
        public void EqualsShouldReturnTrueWhenAllVersionsAreEqualInTwoTables()
        {
            var version = new SettingsTableVersion <string, string>();

            var table      = new SettingsTable <string, string>();
            var otherTable = new SettingsTable <string, string>();

            table.AddVersion(version);
            otherTable.AddVersion(version);

            Assert.True(table.Equals(otherTable));
        }
예제 #3
0
        public void EqualsShouldReturnFalseWhenTypesAreNotEqual()
        {
            var table = new SettingsTable <string, string>();

            Assert.False(table.Equals(new object()));
        }
예제 #4
0
        public void EqualsShouldReturnFalseWhenComparingToNull()
        {
            var table = new SettingsTable <string, string>();

            Assert.False(table.Equals(null));
        }