public void GetDataFileAsJObject_SimpleString(string filename, string expectedValue) { JObject expected = JObject.Parse(expectedValue); string path = Path.Join("Tools/TestingTools/GetDataFileAsJObject", filename); JObject actual = TestingTools.GetDataFileAsJObject(path); Assert.Equal(expected, actual, new JTokenEqualityComparer()); }
public void GetDataFileAsJObject_NonexistingFile() { Assert.Throws <FileNotFoundException>( () => TestingTools.GetDataFileAsJObject("NonExistingFile.json") ); }
public void GetDataFileAsJObject_Null() { Assert.Throws <ArgumentNullException>( () => TestingTools.GetDataFileAsJObject(null) ); }