Skip to content

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
danlessa committed Jan 18, 2024
1 parent 196040a commit 2599e2a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
12 changes: 10 additions & 2 deletions testing/test_param_count.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,23 @@ def run_experiment(exp: Experiment, mode: str):
return records


def param_count_test_generator(provided_params):
def param_count_test_suf_generator(provided_params):
def s_test_param_count(params, _2, _3, _4, _5):
assert params.keys() == provided_params.keys(), 'Params are not matching'
return ('varA', None)
return s_test_param_count


def param_count_test_policy_generator(provided_params):
def p_test_param_count(params, _2, _3, _4):
assert params.keys() == provided_params.keys(), 'Params are not matching'
return {'sigA': None}
return p_test_param_count

def create_experiments(N_simulations=3, N_sweeps=3, N_runs=3, N_timesteps=3, N_substeps=3, params={}) -> Experiment:

INITIAL_STATE = {'varA': None}
PSUBs = [{'policies': {}, 'variables': {'varA': param_count_test_generator(params)}}] * N_substeps
PSUBs = [{'policies': {'sigA': param_count_test_policy_generator(params)}, 'variables': {'varA': param_count_test_suf_generator(params)}}] * N_substeps

SIM_CONFIG = config_sim(
{
Expand Down
2 changes: 1 addition & 1 deletion testing/tests/cadCAD_memory_address.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"memory_address": "0x10d841d50"}
{"memory_address": "0x111444900"}

0 comments on commit 2599e2a

Please sign in to comment.