MCPcopy Index your code
hub / github.com/ccxt/ccxt / init_inner

Method init_inner

python/ccxt/test/tests_sync.py:52–91  ·  view source on GitHub ↗
(self, exchange_id, symbol_argv, method_argv)

Source from the content-addressed store, hash-verified

50 return True
51
52 def init_inner(self, exchange_id, symbol_argv, method_argv):
53 self.parse_cli_args_and_props()
54 if self.request_tests and self.response_tests:
55 self.run_static_request_tests(exchange_id, symbol_argv)
56 self.run_static_response_tests(exchange_id, symbol_argv)
57 return True
58 if self.response_tests:
59 self.run_static_response_tests(exchange_id, symbol_argv)
60 return True
61 if self.request_tests:
62 self.run_static_request_tests(exchange_id, symbol_argv) # symbol here is the testname
63 return True
64 if self.id_tests:
65 self.run_broker_id_tests()
66 return True
67 new_line = '\n'
68 dump(new_line + '' + new_line + '' + '[INFO] TESTING ', self.ext, {
69 'exchange': exchange_id,
70 'symbol': symbol_argv,
71 'method': method_argv,
72 'isWs': self.ws_tests,
73 'useProxy': get_cli_arg_value('--useProxy'),
74 }, new_line)
75 exchange_args = {
76 'verbose': self.verbose,
77 'debug': self.debug,
78 'enableRateLimit': True,
79 'timeout': 30000,
80 }
81 exchange = init_exchange(exchange_id, exchange_args, self.ws_tests)
82 if exchange.alias:
83 dump(self.add_padding('[INFO] skipping alias', 25))
84 exit_script(0)
85 self.import_files(exchange)
86 # ensure test files are found & filled
87 assert len(list(self.test_files.keys())) > 0, 'Test files were not loaded'
88 self.expand_settings(exchange)
89 self.check_if_specific_test_is_chosen(method_argv)
90 self.start_test(exchange, symbol_argv)
91 exit_script(0) # needed to be explicitly finished for WS tests
92
93 def check_if_specific_test_is_chosen(self, method_argv):
94 if method_argv is not None:

Callers 1

initMethod · 0.95

Calls 13

run_broker_id_testsMethod · 0.95
add_paddingMethod · 0.95
import_filesMethod · 0.95
expand_settingsMethod · 0.95
start_testMethod · 0.95
dumpFunction · 0.90
get_cli_arg_valueFunction · 0.90
init_exchangeFunction · 0.90

Tested by

no test coverage detected