File tree Expand file tree Collapse file tree 5 files changed +38
-4
lines changed Expand file tree Collapse file tree 5 files changed +38
-4
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ import { getMappedType } from './getMappedType';
2
2
3
3
describe ( 'getMappedType' , ( ) => {
4
4
it ( 'should map types to the basics' , ( ) => {
5
- expect ( getMappedType ( 'File' ) ) . toEqual ( 'binary' ) ;
6
5
expect ( getMappedType ( 'file' ) ) . toEqual ( 'binary' ) ;
7
6
expect ( getMappedType ( 'string' ) ) . toEqual ( 'string' ) ;
8
7
expect ( getMappedType ( 'date' ) ) . toEqual ( 'string' ) ;
Original file line number Diff line number Diff line change 1
1
const TYPE_MAPPINGS = new Map < string , string > ( [
2
- [ 'File' , 'binary' ] ,
3
2
[ 'file' , 'binary' ] ,
4
3
[ 'any' , 'any' ] ,
5
4
[ 'object' , 'any' ] ,
Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ import { getMappedType } from './getMappedType';
2
2
3
3
describe ( 'getMappedType' , ( ) => {
4
4
it ( 'should map types to the basics' , ( ) => {
5
- expect ( getMappedType ( 'File' ) ) . toEqual ( 'binary' ) ;
6
5
expect ( getMappedType ( 'file' ) ) . toEqual ( 'binary' ) ;
7
6
expect ( getMappedType ( 'string' ) ) . toEqual ( 'string' ) ;
8
7
expect ( getMappedType ( 'date' ) ) . toEqual ( 'string' ) ;
Original file line number Diff line number Diff line change 1
1
const TYPE_MAPPINGS = new Map < string , string > ( [
2
- [ 'File' , 'binary' ] ,
3
2
[ 'file' , 'binary' ] ,
4
3
[ 'any' , 'any' ] ,
5
4
[ 'object' , 'any' ] ,
Original file line number Diff line number Diff line change 2241
2241
"pattern" : " ^\\ w+$"
2242
2242
}
2243
2243
}
2244
+ },
2245
+ "File" : {
2246
+ "required" : [
2247
+ " mime"
2248
+ ],
2249
+ "type" : " object" ,
2250
+ "properties" : {
2251
+ "id" : {
2252
+ "title" : " Id" ,
2253
+ "type" : " string" ,
2254
+ "readOnly" : true ,
2255
+ "minLength" : 1
2256
+ },
2257
+ "updated_at" : {
2258
+ "title" : " Updated at" ,
2259
+ "type" : " string" ,
2260
+ "format" : " date-time" ,
2261
+ "readOnly" : true
2262
+ },
2263
+ "created_at" : {
2264
+ "title" : " Created at" ,
2265
+ "type" : " string" ,
2266
+ "format" : " date-time" ,
2267
+ "readOnly" : true
2268
+ },
2269
+ "mime" : {
2270
+ "title" : " Mime" ,
2271
+ "type" : " string" ,
2272
+ "maxLength" : 24 ,
2273
+ "minLength" : 1
2274
+ },
2275
+ "file" : {
2276
+ "title" : " File" ,
2277
+ "type" : " string" ,
2278
+ "readOnly" : true ,
2279
+ "format" : " uri"
2280
+ }
2281
+ }
2244
2282
}
2245
2283
}
2246
2284
}
You can’t perform that action at this time.
0 commit comments