예제 #1
0
        public void HasMod_Enabled()
        {
            var listings = new ModListing[]
            {
                new ModListing(TestConstants.LightMasterModKey, true),
                new ModListing(TestConstants.LightMasterModKey2, false),
                new ModListing(TestConstants.LightMasterModKey3, true),
            };

            listings
            .HasMod(TestConstants.LightMasterModKey, enabled: true)
            .Should().BeTrue();
            listings
            .HasMod(TestConstants.LightMasterModKey, enabled: false)
            .Should().BeFalse();
            listings
            .HasMod(TestConstants.LightMasterModKey2, enabled: false)
            .Should().BeTrue();
            listings
            .HasMod(TestConstants.LightMasterModKey2, enabled: true)
            .Should().BeFalse();
            listings
            .HasMod(TestConstants.LightMasterModKey3, enabled: true)
            .Should().BeTrue();
            listings
            .HasMod(TestConstants.LightMasterModKey3, enabled: false)
            .Should().BeFalse();
        }
예제 #2
0
        public void HasMod_Typical()
        {
            var listings = new ModListing[]
            {
                new ModListing(TestConstants.LightMasterModKey, true),
                new ModListing(TestConstants.LightMasterModKey2, false),
                new ModListing(TestConstants.LightMasterModKey3, true),
            };

            listings
            .HasMod(TestConstants.LightMasterModKey)
            .Should().BeTrue();
            listings
            .HasMod(TestConstants.LightMasterModKey2)
            .Should().BeTrue();
            listings
            .HasMod(TestConstants.LightMasterModKey3)
            .Should().BeTrue();
            listings
            .HasMod(TestConstants.LightMasterModKey4)
            .Should().BeFalse();
        }