@@ -139,11 +139,11 @@ def test_create_strike_key_with_timestamp_value(self):
139139 strike .timestamp .value = 1234567890123456789
140140 strike .x = 12.345678
141141 strike .y = 45.678901
142- strike .amplitude = 100
142+ strike .lateral_error = 100
143143
144144 key = imprt2 .create_strike_key (strike )
145145
146- assert_that (key ).is_equal_to ((1234567890123456789 , 12.345678 , 45.678901 , 100 ))
146+ assert_that (key ).is_equal_to ((1234567890123456789 , 12.3457 , 45.6789 , 100 ))
147147
148148 def test_create_strike_key_rounds_location (self ):
149149 """Test that location is rounded to 6 decimal places."""
@@ -152,13 +152,13 @@ def test_create_strike_key_rounds_location(self):
152152 strike .timestamp .value = 1000000000000000000
153153 strike .x = 12.34567890123 # More than 6 decimals
154154 strike .y = 45.67890123456
155- strike .amplitude = 50
155+ strike .lateral_error = 50
156156
157157 key = imprt2 .create_strike_key (strike )
158158
159159 # Should be rounded to 6 decimals
160- assert_that (key [1 ]).is_equal_to (12.345679 )
161- assert_that (key [2 ]).is_equal_to (45.678901 )
160+ assert_that (key [1 ]).is_equal_to (12.3457 )
161+ assert_that (key [2 ]).is_equal_to (45.6789 )
162162
163163
164164class TestGetExistingStrikeKeys :
@@ -185,14 +185,14 @@ def test_get_existing_strikes_with_results(self, mock_strike_db):
185185 strike1 .timestamp .value = 1000000000000000001
186186 strike1 .x = 10.5
187187 strike1 .y = 20.5
188- strike1 .amplitude = 100
188+ strike1 .lateral_error = 100
189189
190190 strike2 = Mock (spec = Strike )
191191 strike2 .timestamp = Mock ()
192192 strike2 .timestamp .value = 1000000000000000002
193193 strike2 .x = 11.5
194194 strike2 .y = 21.5
195- strike2 .amplitude = 200
195+ strike2 .lateral_error = 200
196196
197197 mock_strike_db .select .return_value = [strike1 , strike2 ]
198198
@@ -275,7 +275,7 @@ def test_update_strikes_skips_duplicates(self, mock_config, mock_fetch, mock_db_
275275 existing_strike .timestamp .value = timestamp_value
276276 existing_strike .x = 10.5
277277 existing_strike .y = 20.5
278- existing_strike .amplitude = 100
278+ existing_strike .lateral_error = 100
279279
280280 mock_strike_db .select .return_value = [existing_strike ]
281281 mock_strike_db .insert = Mock ()
@@ -291,7 +291,7 @@ def test_update_strikes_skips_duplicates(self, mock_config, mock_fetch, mock_db_
291291 strike_from_url .timestamp .__ge__ = Mock (return_value = True )
292292 strike_from_url .x = 10.5
293293 strike_from_url .y = 20.5
294- strike_from_url .amplitude = 100
294+ strike_from_url .lateral_error = 100
295295
296296 mock_fetch .return_value = [strike_from_url ]
297297
0 commit comments