Example #1
0
        public CheckJsonGrammar(JsonComparisonFixture fixture, string path, string key)
        {
            _fixture = fixture;
            _path    = path;
            _key     = key;

            _format = $"{path} should be {{{key}}}";
        }
Example #2
0
            public void Store(JsonComparisonFixture fixture, StepValues values, JToken element)
            {
                var token = element.SelectToken(_path);

                if (token == null)
                {
                    values.Store(_key, null);
                }
                else
                {
                    var value = fixture.deserialize <T>(token);
                    values.Store(_key, value);
                }
            }
Example #3
0
 public JsonValueChecks(string path, string title, JsonComparisonFixture parent)
 {
     _path   = path;
     _title  = title;
     _parent = parent;
 }
Example #4
0
 public JsonValueCheckExpression(string path, JsonComparisonFixture parent)
 {
     _path   = path;
     _parent = parent;
 }