Exemplo n.º 1
0
        public void Topping2()
        {
#if !DEBUG
        Assert.Multiple(() => {
#endif
            var expected = new Dictionary<string, string> { { "yogurt", "cherry" }, { "ice cream", "cherry" } };
            var actual = _object.Topping2(new Dictionary<string, string> { { "ice cream", "cherry" } });
            CollectionAssert.AreEquivalent(expected, actual);

            expected = new Dictionary<string, string> { { "yogurt", "cherry" }, { "spinach", "nuts" }, { "ice cream", "cherry" } };
            actual = _object.Topping2(new Dictionary<string, string> { { "spinach", "dirt" }, { "ice cream", "cherry" } });
            CollectionAssert.AreEquivalent(expected, actual);

            expected = new Dictionary<string, string> { { "yogurt", "salt" } };
            actual = _object.Topping2(new Dictionary<string, string> { { "yogurt", "salt" } });
            CollectionAssert.AreEquivalent(expected, actual);

            expected = new Dictionary<string, string> { { "yogurt", "salt" }, { "bread", "butter" } };
            actual = _object.Topping2(new Dictionary<string, string> { { "yogurt", "salt" }, { "bread", "butter" } });
            CollectionAssert.AreEquivalent(expected, actual);

            expected = new Dictionary<string, string>();
            actual = _object.Topping2(new Dictionary<string, string>());
            CollectionAssert.AreEquivalent(expected, actual);

            expected = new Dictionary<string, string> { { "yogurt", "air" }, { "ice cream", "air" }, { "salad", "oil" } };
            actual = _object.Topping2(new Dictionary<string, string> { { "ice cream", "air" }, { "salad", "oil" } });
            CollectionAssert.AreEquivalent(expected, actual);
#if !DEBUG
});
#endif
        }