@@ -27,6 +27,7 @@ def valid_config(self):
2727 "activity_id" : "CMIP" ,
2828 }
2929
30+ @pytest .mark .unit
3031 def test_init_with_minimal_params (self , valid_config , temp_dir ):
3132 """Test initialization with minimal required parameters."""
3233 with patch ("access_mopper.driver.load_cmip6_mappings" ) as mock_load :
@@ -45,6 +46,7 @@ def test_init_with_minimal_params(self, valid_config, temp_dir):
4546 assert cmoriser .experiment_id == "historical"
4647 assert cmoriser .source_id == "ACCESS-ESM1-5"
4748
49+ @pytest .mark .unit
4850 def test_init_with_multiple_input_paths (self , valid_config , temp_dir ):
4951 """Test initialization with multiple input files."""
5052 input_files = ["file1.nc" , "file2.nc" , "file3.nc" ]
@@ -61,6 +63,7 @@ def test_init_with_multiple_input_paths(self, valid_config, temp_dir):
6163
6264 assert cmoriser .input_paths == input_files
6365
66+ @pytest .mark .unit
6467 def test_init_with_parent_info (self , valid_config , temp_dir ):
6568 """Test initialization with parent experiment information."""
6669 parent_info = {
@@ -89,6 +92,7 @@ def test_init_with_parent_info(self, valid_config, temp_dir):
8992 # Should use provided parent info instead of defaults
9093 assert cmoriser .parent_info == parent_info
9194
95+ @pytest .mark .unit
9296 def test_init_with_drs_root (self , valid_config , temp_dir ):
9397 """Test initialization with DRS root specification."""
9498 drs_root = temp_dir / "drs_structure"
@@ -106,6 +110,7 @@ def test_init_with_drs_root(self, valid_config, temp_dir):
106110
107111 assert cmoriser .drs_root == Path (drs_root )
108112
113+ @pytest .mark .unit
109114 def test_compound_name_parsing (self , valid_config , temp_dir ):
110115 """Test that compound names are parsed correctly."""
111116 test_cases = [
@@ -131,6 +136,7 @@ def test_compound_name_parsing(self, valid_config, temp_dir):
131136 # Check that mappings were loaded for the correct compound name
132137 mock_load .assert_called_with (compound_name )
133138
139+ @pytest .mark .unit
134140 def test_output_path_conversion (self , valid_config ):
135141 """Test that output path is properly converted to Path object."""
136142 with patch ("access_mopper.driver.load_cmip6_mappings" ) as mock_load :
@@ -147,6 +153,7 @@ def test_output_path_conversion(self, valid_config):
147153 assert isinstance (cmoriser .output_path , Path )
148154 assert cmoriser .output_path == Path ("/tmp/test_output" )
149155
156+ @pytest .mark .unit
150157 @patch ("access_mopper.driver._default_parent_info" )
151158 def test_default_parent_info_used (
152159 self , mock_default_parent , valid_config , temp_dir
@@ -167,6 +174,7 @@ def test_default_parent_info_used(
167174 # Should call default parent info function
168175 mock_default_parent .assert_called_once ()
169176
177+ @pytest .mark .unit
170178 def test_variable_mapping_loaded (self , valid_config , temp_dir ):
171179 """Test that variable mapping is loaded correctly."""
172180 mock_mapping = {
@@ -190,6 +198,7 @@ def test_variable_mapping_loaded(self, valid_config, temp_dir):
190198 assert cmoriser .variable_mapping == mock_mapping
191199 mock_load .assert_called_once_with ("Amon.tas" )
192200
201+ @pytest .mark .unit
193202 def test_missing_required_params (self , temp_dir ):
194203 """Test that missing required parameters raise appropriate errors."""
195204 with patch ("access_mopper.driver.load_cmip6_mappings" ) as mock_load :
@@ -207,6 +216,7 @@ def test_missing_required_params(self, temp_dir):
207216 # Missing experiment_id
208217 )
209218
219+ @pytest .mark .unit
210220 def test_drs_root_path_conversion (self , valid_config , temp_dir ):
211221 """Test DRS root path conversion from string to Path."""
212222 with patch ("access_mopper.driver.load_cmip6_mappings" ) as mock_load :
0 commit comments