public void TextureInfoTest() { var model = new glTFMaterialBaseColorTextureInfo() { index = 1, }; var json = model.ToJson(); Assert.AreEqual(@"{""index"":1,""texCoord"":0}", json); Debug.Log(json); }
public void TextureInfoTest() { var model = new glTFMaterialBaseColorTextureInfo() { index = 1, }; var json = model.ToJson(); Assert.AreEqual(@"{""index"":1,""texCoord"":0}", json); Debug.Log(json); var c = new JsonSchemaValidationContext("") { EnableDiagnosisForNotRequiredFields = true, }; var json2 = JsonSchema.FromType <glTFMaterialBaseColorTextureInfo>().Serialize(model, c); Assert.AreEqual(json, json2); }