Skip to content

Commit

Permalink
Updates tests with new table library
Browse files Browse the repository at this point in the history
  • Loading branch information
DrPaulSharp committed Oct 24, 2023
1 parent 9d1678a commit f8c8ce0
Showing 1 changed file with 50 additions and 30 deletions.
80 changes: 50 additions & 30 deletions tests/test_project.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,45 +40,65 @@ def default_project_repr():
'Geometry: ------------------------------------------------------------------------------------------\n\n'
'air/substrate\n\n'
'Parameters: ----------------------------------------------------------------------------------------\n\n'
' name min value max fit prior_type mu sigma\n'
'-- ------------------- ----- ------- ----- ----- ------------ ---- -------\n'
' 0 Substrate Roughness 1 3 5 True uniform 0 inf\n\n'
'+-------+---------------------+-----+-------+-----+------+------------+-----+-------+\n'
'| index | name | min | value | max | fit | prior type | mu | sigma |\n'
'+-------+---------------------+-----+-------+-----+------+------------+-----+-------+\n'
'| 0 | Substrate Roughness | 1.0 | 3.0 | 5.0 | True | uniform | 0.0 | inf |\n'
'+-------+---------------------+-----+-------+-----+------+------------+-----+-------+\n\n'
'Bulk In: -------------------------------------------------------------------------------------------\n\n'
' name min value max fit prior_type mu sigma\n'
'-- ------- ----- ------- ----- ----- ------------ ---- -------\n'
' 0 SLD Air 0 0 0 False uniform 0 inf\n\n'
'+-------+---------+-----+-------+-----+-------+------------+-----+-------+\n'
'| index | name | min | value | max | fit | prior type | mu | sigma |\n'
'+-------+---------+-----+-------+-----+-------+------------+-----+-------+\n'
'| 0 | SLD Air | 0.0 | 0.0 | 0.0 | False | uniform | 0.0 | inf |\n'
'+-------+---------+-----+-------+-----+-------+------------+-----+-------+\n\n'
'Bulk Out: ------------------------------------------------------------------------------------------\n\n'
' name min value max fit prior_type mu sigma\n'
'-- ------- ------- -------- -------- ----- ------------ ---- -------\n'
' 0 SLD D2O 6.2e-06 6.35e-06 6.35e-06 False uniform 0 inf\n\n'
'+-------+---------+---------+----------+----------+-------+------------+-----+-------+\n'
'| index | name | min | value | max | fit | prior type | mu | sigma |\n'
'+-------+---------+---------+----------+----------+-------+------------+-----+-------+\n'
'| 0 | SLD D2O | 6.2e-06 | 6.35e-06 | 6.35e-06 | False | uniform | 0.0 | inf |\n'
'+-------+---------+---------+----------+----------+-------+------------+-----+-------+\n\n'
'Qz Shifts: -----------------------------------------------------------------------------------------\n\n'
' name min value max fit prior_type mu sigma\n'
'-- ---------- ------- ------- ------ ----- ------------ ---- -------\n'
' 0 Qz shift 1 -0.0001 0 0.0001 False uniform 0 inf\n\n'
'+-------+------------+---------+-------+--------+-------+------------+-----+-------+\n'
'| index | name | min | value | max | fit | prior type | mu | sigma |\n'
'+-------+------------+---------+-------+--------+-------+------------+-----+-------+\n'
'| 0 | Qz shift 1 | -0.0001 | 0.0 | 0.0001 | False | uniform | 0.0 | inf |\n'
'+-------+------------+---------+-------+--------+-------+------------+-----+-------+\n\n'
'Scalefactors: --------------------------------------------------------------------------------------\n\n'
' name min value max fit prior_type mu sigma\n'
'-- ------------- ----- ------- ----- ----- ------------ ---- -------\n'
' 0 Scalefactor 1 0.02 0.23 0.25 False uniform 0 inf\n\n'
'+-------+---------------+------+-------+------+-------+------------+-----+-------+\n'
'| index | name | min | value | max | fit | prior type | mu | sigma |\n'
'+-------+---------------+------+-------+------+-------+------------+-----+-------+\n'
'| 0 | Scalefactor 1 | 0.02 | 0.23 | 0.25 | False | uniform | 0.0 | inf |\n'
'+-------+---------------+------+-------+------+-------+------------+-----+-------+\n\n'
'Background Parameters: -----------------------------------------------------------------------------\n\n'
' name min value max fit prior_type mu sigma\n'
'-- ------------------ ----- ------- ----- ----- ------------ ---- -------\n'
' 0 Background Param 1 1e-07 1e-06 1e-05 False uniform 0 inf\n\n'
'+-------+--------------------+-------+-------+-------+-------+------------+-----+-------+\n'
'| index | name | min | value | max | fit | prior type | mu | sigma |\n'
'+-------+--------------------+-------+-------+-------+-------+------------+-----+-------+\n'
'| 0 | Background Param 1 | 1e-07 | 1e-06 | 1e-05 | False | uniform | 0.0 | inf |\n'
'+-------+--------------------+-------+-------+-------+-------+------------+-----+-------+\n\n'
'Backgrounds: ---------------------------------------------------------------------------------------\n\n'
' name type value_1 value_2 value_3 value_4 value_5\n'
'-- ------------ -------- ------------------ --------- --------- --------- ---------\n'
' 0 Background 1 constant Background Param 1\n\n'
'+-------+--------------+----------+--------------------+---------+---------+---------+---------+\n'
'| index | name | type | value 1 | value 2 | value 3 | value 4 | value 5 |\n'
'+-------+--------------+----------+--------------------+---------+---------+---------+---------+\n'
'| 0 | Background 1 | constant | Background Param 1 | | | | |\n'
'+-------+--------------+----------+--------------------+---------+---------+---------+---------+\n\n'
'Resolution Parameters: -----------------------------------------------------------------------------\n\n'
' name min value max fit prior_type mu sigma\n'
'-- ------------------ ----- ------- ----- ----- ------------ ---- -------\n'
' 0 Resolution Param 1 0.01 0.03 0.05 False uniform 0 inf\n\n'
'+-------+--------------------+------+-------+------+-------+------------+-----+-------+\n'
'| index | name | min | value | max | fit | prior type | mu | sigma |\n'
'+-------+--------------------+------+-------+------+-------+------------+-----+-------+\n'
'| 0 | Resolution Param 1 | 0.01 | 0.03 | 0.05 | False | uniform | 0.0 | inf |\n'
'+-------+--------------------+------+-------+------+-------+------------+-----+-------+\n\n'
'Resolutions: ---------------------------------------------------------------------------------------\n\n'
' name type value_1 value_2 value_3 value_4 value_5\n'
'-- ------------ -------- ------------------ --------- --------- --------- ---------\n'
' 0 Resolution 1 constant Resolution Param 1\n\n'
'+-------+--------------+----------+--------------------+---------+---------+---------+---------+\n'
'| index | name | type | value 1 | value 2 | value 3 | value 4 | value 5 |\n'
'+-------+--------------+----------+--------------------+---------+---------+---------+---------+\n'
'| 0 | Resolution 1 | constant | Resolution Param 1 | | | | |\n'
'+-------+--------------+----------+--------------------+---------+---------+---------+---------+\n\n'
'Data: ----------------------------------------------------------------------------------------------\n\n'
' name data data_range simulation_range\n'
'-- ---------- ------ ------------ ------------------\n'
' 0 Simulation [] [] []\n\n')
'+-------+------------+------+------------+------------------+\n'
'| index | name | data | data range | simulation range |\n'
'+-------+------------+------+------------+------------------+\n'
'| 0 | Simulation | [] | [] | [] |\n'
'+-------+------------+------+------------+------------------+\n\n')


@pytest.fixture
Expand Down

0 comments on commit f8c8ce0

Please sign in to comment.