CYCAMORE
Functions | Variables
helper Namespace Reference

Functions

def check_cmd (args, cwd, holdsrtn)
 
def exit_times (agent_id, exit_table)
 
def find_ids (data, data_table, id_table)
 
def hasher (x)
 
def idx (h)
 
def run_cyclus (cyclus, cwd, in_path, out_path)
 
def table_exist (db, tables)
 

Variables

 sha1array = lambdax:np.array(idx(hasher(x)), np.uint32)
 
tuple str_types = (bytes, str)
 

Detailed Description

A set of tools for use in integration tests.

Function Documentation

def helper.check_cmd (   args,
  cwd,
  holdsrtn 
)
Runs a command in a subprocess and verifies that it executed properly.

Definition at line 68 of file helper.py.

Referenced by run_cyclus().

def helper.exit_times (   agent_id,
  exit_table 
)
Finds exit times of the specified agent from the exit table.

Definition at line 48 of file helper.py.

def helper.find_ids (   data,
  data_table,
  id_table 
)
Finds ids of the specified data located in the specified data_table,
and extracts the corresponding id from the specified id_table.

Definition at line 32 of file helper.py.

References sha1array.

Referenced by test_regression.TestRegression.find_ids().

def helper.hasher (   x)

Definition at line 16 of file helper.py.

References cycamore.int.

def helper.idx (   h)

Definition at line 19 of file helper.py.

def helper.run_cyclus (   cyclus,
  cwd,
  in_path,
  out_path 
)
Runs cyclus with various inputs and creates output databases

Definition at line 60 of file helper.py.

References check_cmd().

Referenced by test_regression.TestRegression.setUp().

def helper.table_exist (   db,
  tables 
)
Checks if hdf5 database contains the specified tables.

Definition at line 27 of file helper.py.

Variable Documentation

helper.sha1array = lambdax:np.array(idx(hasher(x)), np.uint32)

Definition at line 25 of file helper.py.

Referenced by find_ids().

tuple helper.str_types = (bytes, str)

Definition at line 12 of file helper.py.