MCPcopy Create free account
hub / github.com/codecombat/codecombat / schemaCompileTest

Function schemaCompileTest

test/app/models/InteractiveSession.spec.js:7–14  ·  view source on GitHub ↗
(schemaObject)

Source from the content-addressed store, hash-verified

5import { getAjvOptions } from 'ozaria/site/common/ozariaUtils'
6
7function schemaCompileTest (schemaObject) {
8 it('compiles successfully', () => {
9 const ajv = new Ajv(getAjvOptions())
10 const validate = ajv.compile(schemaObject)
11 expect(typeof validate).toBe('function')
12 expect(ajv.errors).toBe(null)
13 })
14}
15
16function schemaValidateObjectTest (schemaObject, testObject) {
17 it('validates a correct object', () => {

Callers 1

Calls 2

getAjvOptionsFunction · 0.90
compileMethod · 0.45

Tested by

no test coverage detected