diff options
author | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-05-25 07:33:58 +0800 |
---|---|---|
committer | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-05-30 01:09:07 +0800 |
commit | 549e6d57c44abcd7e59699f739027d190d4e3bd7 (patch) | |
tree | f64917762c334a0979c595caff6f0749939183c6 /packages/sol-compiler/src/schemas | |
parent | ed5b9c2b56185fc5d8e83c17d85cc8044fee0872 (diff) | |
download | dexon-sol-tools-549e6d57c44abcd7e59699f739027d190d4e3bd7.tar dexon-sol-tools-549e6d57c44abcd7e59699f739027d190d4e3bd7.tar.gz dexon-sol-tools-549e6d57c44abcd7e59699f739027d190d4e3bd7.tar.bz2 dexon-sol-tools-549e6d57c44abcd7e59699f739027d190d4e3bd7.tar.lz dexon-sol-tools-549e6d57c44abcd7e59699f739027d190d4e3bd7.tar.xz dexon-sol-tools-549e6d57c44abcd7e59699f739027d190d4e3bd7.tar.zst dexon-sol-tools-549e6d57c44abcd7e59699f739027d190d4e3bd7.zip |
Add schema assertions on public methods of @0xproject/sol-compiler
Diffstat (limited to 'packages/sol-compiler/src/schemas')
-rw-r--r-- | packages/sol-compiler/src/schemas/compiler_options_schema.ts | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/packages/sol-compiler/src/schemas/compiler_options_schema.ts b/packages/sol-compiler/src/schemas/compiler_options_schema.ts new file mode 100644 index 000000000..43a9c0879 --- /dev/null +++ b/packages/sol-compiler/src/schemas/compiler_options_schema.ts @@ -0,0 +1,26 @@ +export const compilerOptionsSchema = { + id: '/CompilerOptions', + properties: { + contractsDir: { type: 'string' }, + artifactsDir: { type: 'string' }, + solcVersion: { type: 'string', pattern: '^d+.d+.d+$' }, + compilerSettings: { type: 'object' }, + contracts: { + oneOf: [ + { + type: 'string', + pattern: '^\\*$', + }, + { + type: 'array', + items: { + type: 'string', + }, + }, + ], + }, + }, + type: 'object', + required: [], + additionalProperties: false, +}; |