|
95 | 95 |
|
96 | 96 | <article> |
97 | 97 | <header><h1>Order Agnostic Match</h1></header> |
98 | | -<p>Use *key column(s) if list order is not guaranteed package scenarios.rest.springboot import static org.testingisdocumenting.webtau.WebTauGroovyDsl.* scenario("list Customers and assert with a Table Data using key column") { def id1 = createCustomer firstName: "FN1", lastName: "LN1" def id2 = createCustomer firstName: "FN2", lastName: "LN2" def id3 = createCustomer firstName: "FN3", lastName: "LN3" http.get("/customers") { body.should == ['*id' | 'firstName' | 'lastName'] { _________________________________ id2 | 'FN2' | 'LN2' id1 | 'FN1' | 'LN1' id3 | 'FN3' | 'LN3'} } } def createCustomer(Map payload) { def id = http.post("/customers", payload) { id } http.doc.capture('create-customer') return id }</p> |
| 98 | +<p>Use *key column(s) if list order is not guaranteed package scenarios.rest.springboot import static org.testingisdocumenting.webtau.WebTauGroovyDsl.* scenario("list Customers and assert with a Table Data using key column") { def id1 = createCustomer firstName: "FN1", lastName: "LN1" def id2 = createCustomer firstName: "FN2", lastName: "LN2" def id3 = createCustomer firstName: "FN3", lastName: "LN3" http.get("/customers") { body.should == ['*id' | 'firstName' | 'lastName'] { _________________________________ id2 | 'FN2' | 'LN2' id1 | 'FN1' | 'LN1' id3 | 'FN3' | 'LN3'} } } def createCustomer(Map payload) { return http.post("/customers", payload) { id } }</p> |
99 | 99 | </article> |
100 | 100 | </section> |
101 | 101 | </div> |
|
108 | 108 | ReactDOM.render(React.createElement(Documentation, { |
109 | 109 | "docMeta" : { |
110 | 110 | "viewOn" : { |
111 | | - "link" : "https://github.com/testingisdocumenting/webtau/tree/master/webtau-docs/webtau", |
| 111 | + "link" : "https://github.com/testingisdocumenting/webtau/tree/master/webtau-docs/znai", |
112 | 112 | "title" : "View On GitHub" |
113 | 113 | }, |
114 | 114 | "id" : "webtau", |
115 | 115 | "title" : "WebTau", |
116 | 116 | "type" : "Guide", |
117 | | - "previewEnabled" : false |
| 117 | + "previewEnabled" : false, |
| 118 | + "allowedGroups" : [ "admin" ] |
118 | 119 | }, |
119 | 120 | "page" : { |
120 | 121 | "type" : "Page", |
|
218 | 219 | } ] |
219 | 220 | }, { |
220 | 221 | "lang" : "groovy", |
221 | | - "snippet" : "package scenarios.rest.springboot\n\nimport static org.testingisdocumenting.webtau.WebTauGroovyDsl.*\n\nscenario(\"list Customers and assert with a Table Data using key column\") {\n def id1 = createCustomer firstName: \"FN1\", lastName: \"LN1\"\n def id2 = createCustomer firstName: \"FN2\", lastName: \"LN2\"\n def id3 = createCustomer firstName: \"FN3\", lastName: \"LN3\"\n\n http.get(\"/customers\") {\n body.should == ['*id' | 'firstName' | 'lastName'] {\n _________________________________\n id2 | 'FN2' | 'LN2'\n id1 | 'FN1' | 'LN1'\n id3 | 'FN3' | 'LN3'}\n }\n}\n\ndef createCustomer(Map payload) {\n def id = http.post(\"/customers\", payload) { id }\n http.doc.capture('create-customer')\n\n return id\n}", |
| 222 | + "snippet" : "package scenarios.rest.springboot\n\nimport static org.testingisdocumenting.webtau.WebTauGroovyDsl.*\n\nscenario(\"list Customers and assert with a Table Data using key column\") {\n def id1 = createCustomer firstName: \"FN1\", lastName: \"LN1\"\n def id2 = createCustomer firstName: \"FN2\", lastName: \"LN2\"\n def id3 = createCustomer firstName: \"FN3\", lastName: \"LN3\"\n\n http.get(\"/customers\") {\n body.should == ['*id' | 'firstName' | 'lastName'] {\n _________________________________\n id2 | 'FN2' | 'LN2'\n id1 | 'FN1' | 'LN1'\n id3 | 'FN3' | 'LN3'}\n }\n}\n\ndef createCustomer(Map payload) {\n return http.post(\"/customers\", payload) { id }\n}", |
222 | 223 | "type" : "Snippet" |
223 | 224 | } ] |
224 | 225 | } ], |
225 | | - "lastModifiedTime" : 1590882383851, |
| 226 | + "lastModifiedTime" : 1597542284759, |
226 | 227 | "tocItem" : { |
227 | 228 | "sectionTitle" : "REST", |
228 | 229 | "pageTitle" : "Complex Types", |
|
0 commit comments