|
9 | 9 | from diffpy.utils.tools import ( |
10 | 10 | _extend_z_and_convolve, |
11 | 11 | check_and_build_global_config, |
12 | | - compute_mu_using_xraydb, |
13 | 12 | compute_mud, |
14 | 13 | get_package_info, |
15 | 14 | get_user_info, |
@@ -270,40 +269,6 @@ def test_get_package_info(monkeypatch, inputs, expected): |
270 | 269 | assert actual_metadata == expected |
271 | 270 |
|
272 | 271 |
|
273 | | -@pytest.mark.parametrize( |
274 | | - "inputs", |
275 | | - [ |
276 | | - # Test when the function has invalid inputs |
277 | | - ( # C1: Both mass density and packing fraction are provided, |
278 | | - # expect ValueError exception |
279 | | - { |
280 | | - "sample_composition": "SiO2", |
281 | | - "energy": 10, |
282 | | - "sample_mass_density": 2.65, |
283 | | - "packing_fraction": 1, |
284 | | - } |
285 | | - ), |
286 | | - ( # C2: None of mass density or packing fraction are provided, |
287 | | - # expect ValueError exception |
288 | | - { |
289 | | - "sample_composition": "SiO2", |
290 | | - "energy": 10, |
291 | | - } |
292 | | - ), |
293 | | - ], |
294 | | -) |
295 | | -def test_compute_mu_using_xraydb_bad(inputs): |
296 | | - with pytest.raises( |
297 | | - ValueError, |
298 | | - match=( |
299 | | - "You must specify either sample_mass_density or " |
300 | | - "packing_fraction, but not both. " |
301 | | - "Please rerun specifying only one." |
302 | | - ), |
303 | | - ): |
304 | | - compute_mu_using_xraydb(**inputs) |
305 | | - |
306 | | - |
307 | 272 | def test_compute_mud(tmp_path): |
308 | 273 | diameter, slit_width, z0, I0, mud, slope = 1, 0.1, 0, 1e5, 3, 0 |
309 | 274 | z_data = np.linspace(-1, 1, 50) |
|
0 commit comments