forked from Zakaria/RestAssured
fix: xml&jsonValidation
This commit is contained in:
@@ -0,0 +1,124 @@
|
||||
|
||||
|
||||
{
|
||||
"$schema": "http://json-schema.org/draft-04/schema#",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"books": {
|
||||
"type": "array",
|
||||
"items": [
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"Author": {
|
||||
"type": "string"
|
||||
},
|
||||
"Category": {
|
||||
"type": "string"
|
||||
},
|
||||
"SerialNum": {
|
||||
"type": "string"
|
||||
},
|
||||
"Price": {
|
||||
"type": "number"
|
||||
},
|
||||
"Name": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"Author",
|
||||
"Category",
|
||||
"SerialNum",
|
||||
"Price",
|
||||
"Name"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"Author": {
|
||||
"type": "string"
|
||||
},
|
||||
"Category": {
|
||||
"type": "string"
|
||||
},
|
||||
"SerialNum": {
|
||||
"type": "string"
|
||||
},
|
||||
"Price": {
|
||||
"type": "number"
|
||||
},
|
||||
"Name": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"Author",
|
||||
"Category",
|
||||
"SerialNum",
|
||||
"Price",
|
||||
"Name"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"Author": {
|
||||
"type": "string"
|
||||
},
|
||||
"Category": {
|
||||
"type": "string"
|
||||
},
|
||||
"SerialNum": {
|
||||
"type": "string"
|
||||
},
|
||||
"Price": {
|
||||
"type": "number"
|
||||
},
|
||||
"Name": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"Author",
|
||||
"Category",
|
||||
"SerialNum",
|
||||
"Price",
|
||||
"Name"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"Author": {
|
||||
"type": "string"
|
||||
},
|
||||
"Category": {
|
||||
"type": "string"
|
||||
},
|
||||
"SerialNum": {
|
||||
"type": "string"
|
||||
},
|
||||
"Price": {
|
||||
"type": "number"
|
||||
},
|
||||
"Name": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"Author",
|
||||
"Category",
|
||||
"SerialNum",
|
||||
"Price",
|
||||
"Name"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"books"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Created with Liquid Technologies Online Tools 1.0 (https://www.liquid-technologies.com) -->
|
||||
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
|
||||
<xs:element name="root">
|
||||
<xs:complexType>
|
||||
<xs:sequence>
|
||||
<xs:element maxOccurs="unbounded" name="books">
|
||||
<xs:complexType>
|
||||
<xs:sequence>
|
||||
<xs:element name="Author" type="xs:string" />
|
||||
<xs:element name="Category" type="xs:string" />
|
||||
<xs:element name="SerialNum" type="xs:string" />
|
||||
<xs:element name="Price" type="xs:decimal" />
|
||||
<xs:element name="Name" type="xs:string" />
|
||||
</xs:sequence>
|
||||
</xs:complexType>
|
||||
</xs:element>
|
||||
</xs:sequence>
|
||||
</xs:complexType>
|
||||
</xs:element>
|
||||
</xs:schema>
|
||||
Reference in New Issue
Block a user