コード例 #1
0
        public void AreCompatible_VerifyCircularCompat()
        {
            var graph = new RuntimeGraph(new[]
            {
                new RuntimeDescription("win7", new[] { "win8" }),
                new RuntimeDescription("win8", new[] { "win7" })
            });

            graph.AreCompatible("win8", "win7").Should().BeTrue();
            graph.AreCompatible("win7", "win8").Should().BeTrue();
        }
コード例 #2
0
        public void AreCompatible_VerifyBasicOneWayCompat()
        {
            var graph = new RuntimeGraph(new[]
            {
                new RuntimeDescription("win7"),
                new RuntimeDescription("win8", new[] { "win7" })
            });

            graph.AreCompatible("win8", "win7").Should().BeTrue();
            graph.AreCompatible("win7", "win8").Should().BeFalse();
        }
コード例 #3
0
        public void AreCompatible_VerifyCompatThroughChain()
        {
            var graph = new RuntimeGraph(new[]
            {
                new RuntimeDescription("a"),
                new RuntimeDescription("b", new[] { "a" }),
                new RuntimeDescription("c", new[] { "b" }),
                new RuntimeDescription("d", new[] { "c" })
            });

            graph.AreCompatible("d", "a").Should().BeTrue();
        }
コード例 #4
0
        public void ExpandRuntimes_UnknownRuntimeVerifyCompat()
        {
            var graph = new RuntimeGraph();

            graph.AreCompatible("x", "x").Should().BeTrue();
        }