Skip to content

Commit 1860103

Browse files
committed
Very simple test
1 parent 5603cbe commit 1860103

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

test/services/schema-form-test.js

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,30 @@ describe('schemaForm', function() {
257257
});
258258
});
259259

260+
it.only('should handle x-schema-form defaults',function(){
261+
inject(function(schemaForm){
262+
263+
var schema = {
264+
"type": "object",
265+
"properties": {
266+
"name": {
267+
"title": "Name",
268+
"description": "Gimme yea name lad",
269+
"type": "string",
270+
"x-schema-form": {
271+
"type": "textarea"
272+
}
273+
}
274+
}
275+
};
276+
277+
278+
279+
var f = schemaForm.defaults(schema,{});
280+
f.form[0].type.should.be.eq('textarea');
281+
});
282+
});
283+
260284
it('should ignore parts of schema in ignore list',function(){
261285
inject(function(schemaForm){
262286

0 commit comments

Comments
 (0)