| 1381 | expect(Object.prototype.hasOwnProperty.call(schema, 'classLevelPermissions')).toBe(true); |
| 1382 | } |
| 1383 | function validateSchemaDataStructure(schemaData) { |
| 1384 | Object.keys(schemaData).forEach(className => { |
| 1385 | const schema = schemaData[className]; |
| 1386 | // Hooks has className... |
| 1387 | if (className != '_Hooks') { |
| 1388 | expect(Object.prototype.hasOwnProperty.call(schema, 'className')).toBe(false); |
| 1389 | } |
| 1390 | expect(Object.prototype.hasOwnProperty.call(schema, 'fields')).toBe(false); |
| 1391 | expect(Object.prototype.hasOwnProperty.call(schema, 'classLevelPermissions')).toBe(false); |
| 1392 | }); |
| 1393 | } |
| 1394 | let schema; |
| 1395 | config.database |
| 1396 | .loadSchema() |