Skip to content

Commit

Permalink
Exchange wrapper test tool (thrasher-corp#353)
Browse files Browse the repository at this point in the history
* Initial commit which runs through all wrapper funcs for one of each currency pair for each asset type for each exchange and then outputs it all into a JSON file

* Fixes up data holding responses to allow for good json output after completion

* Starting work for reading credentials from a config. Some variable names are more appropriate

* Keys can now be read from keys.json and applied to exchanges. Fixes naming bug for console output

* Cleans up implementation. Uses templating to output some pretty html report

* Changes config to include a bank account to customise for withdrawals. Updates template for warnings for not implemented. Updates template to include jsonified parameters that are sent to the wrapper. Jsonifies the response so you actually understand whats returned.

* Adds bank for withdrawals. Adds wallet address for crypto withdrawals

* Adds ordersubmission configuration to config. Sets command line overrides. Adds lbank to config. Adds okgroup clientid to config.

* Adds missing comma

* Adds config to gitignore

* Removes because thats not how it works...

* Revert go mod changes

* Formatting for prettiness

* Adds asset type override

* Adds verbose, exchangesToExclude, filename CL flags. Removes wg redeclaration. Creates func to check to load exchange before its loaded. Removes double variables and uses flag.Stringvar instead

* Prettifies the JSON output

* Stringifies the []byteified jsonified wrapper response in the template

* Puts types in their own EXCLUSIVE types.go. LOWERCASES COMMAND LINE ARGUMENTS. Wraps vars in var so theres less vars to look at.

* Generates wrapperconfig.json on the fly if not present. Adds missing config fields and exchanges when not present. Saves config file on finish. Fixes some formatting on output when its just a number

* micro format update

* Changes printfs to printlns. Handles config error. Comments on types. Fixes lint issue with shadow err declaration

* Fixes linting issue, removes returns after fatals, evaluates assetType, formats template

* Stringifies byte output when console output is selected. Verbose mode now includes wrapper responses in console output
  • Loading branch information
gloriousCode authored and thrasher- committed Sep 24, 2019
1 parent 4c5b0a4 commit 0493a21
Show file tree
Hide file tree
Showing 5 changed files with 1,282 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cmd/exchange_wrapper_issues/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/data.json
/output.json
/report.html
Loading

0 comments on commit 0493a21

Please sign in to comment.