public void Returns_null_when_value_is_null()
        {
            var dict = new Dictionary<string, object>() { ["foo"] = null };

            string foo = null;
            var result = dict.TryGetValueAsString("foo", out foo);

            result.ShouldBeTrue();
            foo.ShouldBeNull();
        }
        public void Returns_value_as_string()
        {
            var dict = new Dictionary<string, object>() { ["foo"] = 123 };

            string foo = null;
            var result = dict.TryGetValueAsString("foo", out foo);

            result.ShouldBeTrue();
            foo.ShouldBe("123");
        }
        public void Returns_null_when_key_does_not_exist()
        {
            var dict = new Dictionary<string, object>() { ["foo"] = "bar" };

            string baz = null;
            var result = dict.TryGetValueAsString("baz", out baz);

            result.ShouldBeFalse();
            baz.ShouldBeNull();
        }