@@ -76,6 +76,10 @@ def test_run_paramfile_uvsim(goto_tempdir, paramfile):
7676 assert uvutils ._check_history_version (uv_new .history , pyradiosky .__version__ )
7777 assert uvutils ._check_history_version (uv_new .history , pyuvdata .__version__ )
7878 assert uvutils ._check_history_version (uv_new .history , pyuvsim .__version__ )
79+ assert uvutils ._check_history_version (uv_new .history , paramfile )
80+ assert uvutils ._check_history_version (uv_new .history , 'triangle_bl_layout.csv' )
81+ assert uvutils ._check_history_version (uv_new .history , '28m_triangle_10time_10chan.yaml' )
82+ assert uvutils ._check_history_version (uv_new .history , "Npus =" )
7983
8084 # Reset parts that will deviate
8185 uv_new .history = uv_ref .history
@@ -288,6 +292,16 @@ def test_sim_on_moon(future_shapes):
288292 param_dict = pyuvsim .simsetup ._config_str_to_dict (param_filename )
289293 param_dict ['select' ] = {'redundant_threshold' : 0.1 }
290294 uv_obj , beam_list , beam_dict = pyuvsim .initialize_uvdata_from_params (param_dict )
295+
296+ # set the filename to make sure it ends up in the history,
297+ # remove the parameter file info from extra_keywords
298+ uv_obj .filename = ["moon_sim" ]
299+ uv_obj ._filename .form = (1 ,)
300+ uv_obj .extra_keywords .pop ('obsparam' )
301+ uv_obj .extra_keywords .pop ('telecfg' )
302+ uv_obj .extra_keywords .pop ('layout' )
303+ uv_obj .check ()
304+
291305 uv_obj .select (times = uv_obj .time_array [0 ])
292306 tranquility_base = MoonLocation .from_selenocentric (* uv_obj .telescope_location , 'meter' )
293307
@@ -301,5 +315,11 @@ def test_sim_on_moon(future_shapes):
301315 uv_out = pyuvsim .uvsim .run_uvdata_uvsim (
302316 uv_obj , beam_list , beam_dict , catalog = sources , quiet = True
303317 )
318+ assert uvutils ._check_history_version (uv_out .history , pyradiosky .__version__ )
319+ assert uvutils ._check_history_version (uv_out .history , pyuvdata .__version__ )
320+ assert uvutils ._check_history_version (uv_out .history , pyuvsim .__version__ )
321+ assert uvutils ._check_history_version (uv_out .history , uv_obj .filename [0 ])
322+ assert uvutils ._check_history_version (uv_out .history , "Npus =" )
323+
304324 assert np .allclose (uv_out .data_array [:, :, 0 ], 0.5 )
305325 assert uv_out .extra_keywords ['world' ] == 'moon'
0 commit comments