homebridge-config-ui-x
Version:
A web based management, configuration and control platform for Homebridge
32 lines (25 loc) • 463 B
JavaScript
const test = require('tap').test
const build = require('..')
test('object with custom format field', (t) => {
t.plan(1)
const schema = {
title: 'object with custom format field',
type: 'object',
properties: {
str: {
type: 'string',
format: 'test-format'
}
}
}
const stringify = build(schema)
try {
stringify({
str: 'string'
})
t.pass()
} catch (e) {
t.fail()
}
})