diff --git a/airbyte-cdk/python/unit_tests/connector_builder/test_message_grouper.py b/airbyte-cdk/python/unit_tests/connector_builder/test_message_grouper.py index cbbf84940207f..e371a4fd3c626 100644 --- a/airbyte-cdk/python/unit_tests/connector_builder/test_message_grouper.py +++ b/airbyte-cdk/python/unit_tests/connector_builder/test_message_grouper.py @@ -543,7 +543,7 @@ def test_read_stream_returns_error_if_stream_does_not_exist() -> None: source=mock_source, config=full_config, configured_catalog=create_configured_catalog("not_in_manifest") ) - assert 1 == len(actual_response.logs) + assert len(actual_response.logs) == 1 assert "Traceback" in actual_response.logs[0].message assert "ERROR" in actual_response.logs[0].level diff --git a/airbyte-cdk/python/unit_tests/destinations/test_destination.py b/airbyte-cdk/python/unit_tests/destinations/test_destination.py index 74e6d995d6bb8..00c4cc478825d 100644 --- a/airbyte-cdk/python/unit_tests/destinations/test_destination.py +++ b/airbyte-cdk/python/unit_tests/destinations/test_destination.py @@ -157,7 +157,7 @@ def test_run_spec(self, mocker, destination: Destination): destination.spec.assert_called_once() # type: ignore # verify the output of spec was returned - assert _wrapped(expected_spec) == spec_message + assert spec_message == _wrapped(expected_spec) def test_run_check(self, mocker, destination: Destination, tmp_path): file_path = tmp_path / "config.json" @@ -183,7 +183,7 @@ def test_run_check(self, mocker, destination: Destination, tmp_path): validate_mock.assert_called_with(dummy_config, spec_msg) # verify output was correct - assert _wrapped(expected_check_result) == returned_check_result + assert returned_check_result == _wrapped(expected_check_result) def test_run_write(self, mocker, destination: Destination, tmp_path, monkeypatch): config_path, dummy_config = tmp_path / "config.json", {"user": "sherif"} @@ -235,7 +235,7 @@ def test_run_write(self, mocker, destination: Destination, tmp_path, monkeypatch validate_mock.assert_called_with(dummy_config, spec_msg) # verify output was correct - assert expected_write_result == returned_write_result + assert returned_write_result == expected_write_result @pytest.mark.parametrize("args", [{}, {"command": "fake"}]) def test_run_cmd_with_incorrect_args_fails(self, args, destination: Destination): diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/datetime/test_datetime_parser.py b/airbyte-cdk/python/unit_tests/sources/declarative/datetime/test_datetime_parser.py index 0e81f99878590..604c339de64f1 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/datetime/test_datetime_parser.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/datetime/test_datetime_parser.py @@ -41,7 +41,7 @@ def test_parse_date(test_name, input_date, date_format, expected_output_date): parser = DatetimeParser() output_date = parser.parse(input_date, date_format) - assert expected_output_date == output_date + assert output_date == expected_output_date @pytest.mark.parametrize( @@ -56,4 +56,4 @@ def test_parse_date(test_name, input_date, date_format, expected_output_date): def test_format_datetime(test_name, input_dt, datetimeformat, expected_output): parser = DatetimeParser() output_date = parser.format(input_dt, datetimeformat) - assert expected_output == output_date + assert output_date == expected_output diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/incremental/test_datetime_based_cursor.py b/airbyte-cdk/python/unit_tests/sources/declarative/incremental/test_datetime_based_cursor.py index 9069145b19563..2f1db84600f19 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/incremental/test_datetime_based_cursor.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/incremental/test_datetime_based_cursor.py @@ -541,10 +541,10 @@ def test_request_option(test_name, inject_into, field_name, expected_req_params, parameters={}, ) stream_slice = {"start_time": "2021-01-01T00:00:00.000000+0000", "end_time": "2021-01-04T00:00:00.000000+0000"} - assert expected_req_params == slicer.get_request_params(stream_slice=stream_slice) - assert expected_headers == slicer.get_request_headers(stream_slice=stream_slice) - assert expected_body_json == slicer.get_request_body_json(stream_slice=stream_slice) - assert expected_body_data == slicer.get_request_body_data(stream_slice=stream_slice) + assert slicer.get_request_params(stream_slice=stream_slice) == expected_req_params + assert slicer.get_request_headers(stream_slice=stream_slice) == expected_headers + assert slicer.get_request_body_json(stream_slice=stream_slice) == expected_body_json + assert slicer.get_request_body_data(stream_slice=stream_slice) == expected_body_data @pytest.mark.parametrize( @@ -607,7 +607,7 @@ def test_parse_date_legacy_merge_datetime_format_in_cursor_datetime_format( parameters={}, ) output_date = slicer.parse_date(input_date) - assert expected_output_date == output_date + assert output_date == expected_output_date @pytest.mark.parametrize( @@ -674,7 +674,7 @@ def test_format_datetime(test_name, input_dt, datetimeformat, datetimeformat_gra ) output_date = slicer._format_datetime(input_dt) - assert expected_output == output_date + assert output_date == expected_output def test_step_but_no_cursor_granularity(): diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/partition_routers/test_list_partition_router.py b/airbyte-cdk/python/unit_tests/sources/declarative/partition_routers/test_list_partition_router.py index b98f8f82d0b7b..67eb064c0e2c8 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/partition_routers/test_list_partition_router.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/partition_routers/test_list_partition_router.py @@ -95,10 +95,10 @@ def test_request_option(request_option, expected_req_params, expected_headers, e ) stream_slice = {cursor_field: "customer"} - assert expected_req_params == partition_router.get_request_params(stream_slice=stream_slice) - assert expected_headers == partition_router.get_request_headers(stream_slice=stream_slice) - assert expected_body_json == partition_router.get_request_body_json(stream_slice=stream_slice) - assert expected_body_data == partition_router.get_request_body_data(stream_slice=stream_slice) + assert partition_router.get_request_params(stream_slice=stream_slice) == expected_req_params + assert partition_router.get_request_headers(stream_slice=stream_slice) == expected_headers + assert partition_router.get_request_body_json(stream_slice=stream_slice) == expected_body_json + assert partition_router.get_request_body_data(stream_slice=stream_slice) == expected_body_data @pytest.mark.parametrize( @@ -139,7 +139,7 @@ def test_request_options_interpolation(field_name_interpolation: str, expected_r ) stream_slice = {cursor_field: "customer"} - assert expected_request_params == partition_router.get_request_params(stream_slice=stream_slice) + assert partition_router.get_request_params(stream_slice=stream_slice) == expected_request_params def test_request_option_before_updating_cursor(): diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/partition_routers/test_substream_partition_router.py b/airbyte-cdk/python/unit_tests/sources/declarative/partition_routers/test_substream_partition_router.py index 664dcaa734213..5daaeb4036722 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/partition_routers/test_substream_partition_router.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/partition_routers/test_substream_partition_router.py @@ -295,10 +295,10 @@ def test_request_option( ) stream_slice = {"first_stream_id": "1234", "second_stream_id": "4567"} - assert expected_req_params == partition_router.get_request_params(stream_slice=stream_slice) - assert expected_headers == partition_router.get_request_headers(stream_slice=stream_slice) - assert expected_body_json == partition_router.get_request_body_json(stream_slice=stream_slice) - assert expected_body_data == partition_router.get_request_body_data(stream_slice=stream_slice) + assert partition_router.get_request_params(stream_slice=stream_slice) == expected_req_params + assert partition_router.get_request_headers(stream_slice=stream_slice) == expected_headers + assert partition_router.get_request_body_json(stream_slice=stream_slice) == expected_body_json + assert partition_router.get_request_body_data(stream_slice=stream_slice) == expected_body_data @pytest.mark.parametrize( @@ -353,7 +353,7 @@ def test_request_params_interpolation_for_parent_stream( ) stream_slice = {"first_stream_id": "1234", "second_stream_id": "4567"} - assert expected_request_params == partition_router.get_request_params(stream_slice=stream_slice) + assert partition_router.get_request_params(stream_slice=stream_slice) == expected_request_params def test_given_record_is_airbyte_message_when_stream_slices_then_use_record_data(): diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_cursor_pagination_strategy.py b/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_cursor_pagination_strategy.py index 1846b6cb4e26f..ea379822b004d 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_cursor_pagination_strategy.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_cursor_pagination_strategy.py @@ -61,7 +61,7 @@ def test_cursor_pagination_strategy(test_name, template_string, stop_condition, last_records = [{"id": 0, "more_records": True}, {"id": 1, "more_records": True}] token = strategy.next_page_token(response, last_records) - assert expected_token == token + assert token == expected_token assert page_size == strategy.get_page_size() diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_offset_increment.py b/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_offset_increment.py index 37f26a2af420c..88e6cda7f15bd 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_offset_increment.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_offset_increment.py @@ -31,8 +31,8 @@ def test_offset_increment_paginator_strategy(page_size, parameters, last_records response._content = json.dumps(response_body).encode("utf-8") next_page_token = paginator_strategy.next_page_token(response, last_records) - assert expected_next_page_token == next_page_token - assert expected_offset == paginator_strategy._offset + assert next_page_token == expected_next_page_token + assert paginator_strategy._offset == expected_offset paginator_strategy.reset() assert 0 == paginator_strategy._offset diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_page_increment.py b/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_page_increment.py index 42d7995388e71..f108dcfe8301f 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_page_increment.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/requesters/paginators/test_page_increment.py @@ -33,8 +33,8 @@ def test_page_increment_paginator_strategy(page_size, start_from, last_records, response._content = json.dumps(response_body).encode("utf-8") next_page_token = paginator_strategy.next_page_token(response, last_records) - assert expected_next_page_token == next_page_token - assert expected_offset == paginator_strategy._page + assert next_page_token == expected_next_page_token + assert paginator_strategy._page == expected_offset paginator_strategy.reset() assert start_from == paginator_strategy._page diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/retrievers/test_simple_retriever.py b/airbyte-cdk/python/unit_tests/sources/declarative/retrievers/test_simple_retriever.py index 11e743bd82320..0a7480194d2be 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/retrievers/test_simple_retriever.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/retrievers/test_simple_retriever.py @@ -219,7 +219,7 @@ def test_get_request_options_from_pagination(test_name, paginator_mapping, strea for _, method in request_option_type_to_method.items(): if expected_mapping is not None: actual_mapping = method(None, None, None) - assert expected_mapping == actual_mapping + assert actual_mapping == expected_mapping else: try: method(None, None, None) @@ -264,7 +264,7 @@ def test_get_request_headers(test_name, paginator_mapping, expected_mapping): for _, method in request_option_type_to_method.items(): if expected_mapping: actual_mapping = method(None, None, None) - assert expected_mapping == actual_mapping + assert actual_mapping == expected_mapping else: try: method(None, None, None) @@ -310,7 +310,7 @@ def test_ignore_stream_slicer_parameters_on_paginated_requests(test_name, pagina for _, method in request_option_type_to_method.items(): actual_mapping = method(None, None, next_page_token={"next_page_token": "1000"}) - assert expected_mapping == actual_mapping + assert actual_mapping == expected_mapping @pytest.mark.parametrize( @@ -345,7 +345,7 @@ def test_request_body_data(test_name, slicer_body_data, paginator_body_data, exp if expected_body_data: actual_body_data = retriever._request_body_data(None, None, None) - assert expected_body_data == actual_body_data + assert actual_body_data == expected_body_data else: try: retriever._request_body_data(None, None, None) @@ -380,7 +380,7 @@ def test_path(test_name, requester_path, paginator_path, expected_path): ) actual_path = retriever._paginator_path() - assert expected_path == actual_path + assert actual_path == expected_path def test_limit_stream_slices(): diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/stream_slicers/test_cartesian_product_stream_slicer.py b/airbyte-cdk/python/unit_tests/sources/declarative/stream_slicers/test_cartesian_product_stream_slicer.py index 74b1cc6ec3135..6f07f20297392 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/stream_slicers/test_cartesian_product_stream_slicer.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/stream_slicers/test_cartesian_product_stream_slicer.py @@ -191,10 +191,10 @@ def test_request_option( ) stream_slice = {"owner_resource": "customer", "repository": "airbyte"} - assert expected_req_params == slicer.get_request_params(stream_slice=stream_slice) - assert expected_headers == slicer.get_request_headers(stream_slice=stream_slice) - assert expected_body_json == slicer.get_request_body_json(stream_slice=stream_slice) - assert expected_body_data == slicer.get_request_body_data(stream_slice=stream_slice) + assert slicer.get_request_params(stream_slice=stream_slice) == expected_req_params + assert slicer.get_request_headers(stream_slice=stream_slice) == expected_headers + assert slicer.get_request_body_json(stream_slice=stream_slice) == expected_body_json + assert slicer.get_request_body_data(stream_slice=stream_slice) == expected_body_data def test_request_option_before_updating_cursor(): diff --git a/airbyte-cdk/python/unit_tests/sources/declarative/test_manifest_declarative_source.py b/airbyte-cdk/python/unit_tests/sources/declarative/test_manifest_declarative_source.py index 8252089b5d4c3..8a1026776fd3c 100644 --- a/airbyte-cdk/python/unit_tests/sources/declarative/test_manifest_declarative_source.py +++ b/airbyte-cdk/python/unit_tests/sources/declarative/test_manifest_declarative_source.py @@ -1123,7 +1123,7 @@ def test_read_manifest_declarative_source(test_name, manifest, pages, expected_r _stream_name = "Rates" with patch.object(SimpleRetriever, "_fetch_next_page", side_effect=pages) as mock_retriever: output_data = [message.record.data for message in _run_read(manifest, _stream_name) if message.record] - assert expected_records == output_data + assert output_data == expected_records mock_retriever.assert_has_calls(expected_calls) diff --git a/airbyte-cdk/python/unit_tests/sources/file_based/stream/concurrent/test_adapters.py b/airbyte-cdk/python/unit_tests/sources/file_based/stream/concurrent/test_adapters.py index 7ff30fb59cc68..95d59fc82ceb1 100644 --- a/airbyte-cdk/python/unit_tests/sources/file_based/stream/concurrent/test_adapters.py +++ b/airbyte-cdk/python/unit_tests/sources/file_based/stream/concurrent/test_adapters.py @@ -329,7 +329,7 @@ def test_get_error_display_message_no_display_message(self): display_message = facade.get_error_display_message(e) - assert expected_display_message == display_message + assert display_message == expected_display_message def test_get_error_display_message_with_display_message(self): self._stream.get_error_display_message.return_value = "display_message" @@ -341,7 +341,7 @@ def test_get_error_display_message_with_display_message(self): display_message = facade.get_error_display_message(e) - assert expected_display_message == display_message + assert display_message == expected_display_message @pytest.mark.parametrize( diff --git a/airbyte-cdk/python/unit_tests/sources/file_based/stream/test_default_file_based_cursor.py b/airbyte-cdk/python/unit_tests/sources/file_based/stream/test_default_file_based_cursor.py index 2088097f7ef48..957ed912aa4bd 100644 --- a/airbyte-cdk/python/unit_tests/sources/file_based/stream/test_default_file_based_cursor.py +++ b/airbyte-cdk/python/unit_tests/sources/file_based/stream/test_default_file_based_cursor.py @@ -111,8 +111,8 @@ def test_add_file(files_to_add: List[RemoteFile], expected_start_time: List[date for index, f in enumerate(files_to_add): cursor.add_file(f) - assert expected_start_time[index] == cursor._compute_start_time() - assert expected_state_dict == cursor.get_state() + assert cursor._compute_start_time() == expected_start_time[index] + assert cursor.get_state() == expected_state_dict @pytest.mark.parametrize( diff --git a/airbyte-cdk/python/unit_tests/sources/file_based/test_scenarios.py b/airbyte-cdk/python/unit_tests/sources/file_based/test_scenarios.py index 6655af928da6c..7d66ec79e5ddf 100644 --- a/airbyte-cdk/python/unit_tests/sources/file_based/test_scenarios.py +++ b/airbyte-cdk/python/unit_tests/sources/file_based/test_scenarios.py @@ -143,7 +143,7 @@ def _verify_state_record_counts(records: List[AirbyteMessage], states: List[Airb ) for stream, actual_count in actual_record_counts.items(): - assert state_record_count_sums.get(stream) == actual_count + assert actual_count == state_record_count_sums.get(stream) # We can have extra keys in state_record_count_sums if we processed a stream and reported 0 records extra_keys = state_record_count_sums.keys() - actual_record_counts.keys() diff --git a/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_adapters.py b/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_adapters.py index 41553bd4622d4..a3990b9c057ba 100644 --- a/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_adapters.py +++ b/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_adapters.py @@ -347,7 +347,7 @@ def test_get_error_display_message_no_display_message(self): display_message = facade.get_error_display_message(e) - assert expected_display_message == display_message + assert display_message == expected_display_message def test_get_error_display_message_with_display_message(self): self._stream.get_error_display_message.return_value = "display_message" @@ -359,7 +359,7 @@ def test_get_error_display_message_with_display_message(self): display_message = facade.get_error_display_message(e) - assert expected_display_message == display_message + assert display_message == expected_display_message @pytest.mark.parametrize( diff --git a/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_concurrent_read_processor.py b/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_concurrent_read_processor.py index 666ff6df3ba2d..95ce1390298ed 100644 --- a/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_concurrent_read_processor.py +++ b/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_concurrent_read_processor.py @@ -108,7 +108,7 @@ def test_handle_partition_done_no_other_streams_to_generate_partitions_for(self) messages = list(handler.on_partition_generation_completed(sentinel)) expected_messages = [] - assert expected_messages == messages + assert messages == expected_messages @freezegun.freeze_time("2020-01-01T00:00:00") def test_handle_last_stream_partition_done(self): @@ -146,7 +146,7 @@ def test_handle_last_stream_partition_done(self): ), ), ] - assert expected_messages == messages + assert messages == expected_messages assert in_order_validation_mock.mock_calls.index( call._another_stream.cursor.ensure_at_least_one_state_emitted ) < in_order_validation_mock.mock_calls.index(call._message_repository.consume_queue) @@ -223,7 +223,7 @@ def test_handle_on_partition_complete_sentinel_with_messages_from_repository(sel expected_messages = [ AirbyteMessage(type=MessageType.LOG, log=AirbyteLogMessage(level=LogLevel.INFO, message="message emitted from the repository")) ] - assert expected_messages == messages + assert messages == expected_messages partition.close.assert_called_once() @@ -267,7 +267,7 @@ def test_handle_on_partition_complete_sentinel_yields_status_message_if_the_stre ), ) ] - assert expected_messages == messages + assert messages == expected_messages self._a_closed_partition.close.assert_called_once() @freezegun.freeze_time("2020-01-01T00:00:00") @@ -294,7 +294,7 @@ def test_handle_on_partition_complete_sentinel_yields_no_status_message_if_the_s messages = list(handler.on_partition_complete_sentinel(sentinel)) expected_messages = [] - assert expected_messages == messages + assert messages == expected_messages partition.close.assert_called_once() @freezegun.freeze_time("2020-01-01T00:00:00") @@ -331,7 +331,7 @@ def test_on_record_no_status_message_no_repository_messge(self): ), ) ] - assert expected_messages == messages + assert messages == expected_messages @freezegun.freeze_time("2020-01-01T00:00:00") def test_on_record_with_repository_messge(self): @@ -381,7 +381,7 @@ def test_on_record_with_repository_messge(self): ), AirbyteMessage(type=MessageType.LOG, log=AirbyteLogMessage(level=LogLevel.INFO, message="message emitted from the repository")), ] - assert expected_messages == messages + assert messages == expected_messages assert handler._record_counter[_STREAM_NAME] == 2 @freezegun.freeze_time("2020-01-01T00:00:00") @@ -423,7 +423,7 @@ def test_on_record_emits_status_message_on_first_record_no_repository_message(se ), ), ] - assert expected_messages == messages + assert messages == expected_messages @freezegun.freeze_time("2020-01-01T00:00:00") def test_on_record_emits_status_message_on_first_record_with_repository_message(self): @@ -477,7 +477,7 @@ def test_on_record_emits_status_message_on_first_record_with_repository_message( ), AirbyteMessage(type=MessageType.LOG, log=AirbyteLogMessage(level=LogLevel.INFO, message="message emitted from the repository")), ] - assert expected_messages == messages + assert messages == expected_messages @freezegun.freeze_time("2020-01-01T00:00:00") def test_on_exception_return_trace_message_and_on_stream_complete_return_stream_status(self): diff --git a/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_default_stream.py b/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_default_stream.py index 7b238e5d5e273..eef8c9fd6bb2a 100644 --- a/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_default_stream.py +++ b/airbyte-cdk/python/unit_tests/sources/streams/concurrent/test_default_stream.py @@ -73,7 +73,7 @@ def test_as_airbyte_stream(self): ) actual_airbyte_stream = self._stream.as_airbyte_stream() - assert expected_airbyte_stream == actual_airbyte_stream + assert actual_airbyte_stream == expected_airbyte_stream def test_as_airbyte_stream_with_primary_key(self): json_schema = { @@ -105,7 +105,7 @@ def test_as_airbyte_stream_with_primary_key(self): ) airbyte_stream = stream.as_airbyte_stream() - assert expected_airbyte_stream == airbyte_stream + assert airbyte_stream == expected_airbyte_stream def test_as_airbyte_stream_with_composite_primary_key(self): json_schema = { @@ -137,7 +137,7 @@ def test_as_airbyte_stream_with_composite_primary_key(self): ) airbyte_stream = stream.as_airbyte_stream() - assert expected_airbyte_stream == airbyte_stream + assert airbyte_stream == expected_airbyte_stream def test_as_airbyte_stream_with_a_cursor(self): json_schema = { @@ -169,7 +169,7 @@ def test_as_airbyte_stream_with_a_cursor(self): ) airbyte_stream = stream.as_airbyte_stream() - assert expected_airbyte_stream == airbyte_stream + assert airbyte_stream == expected_airbyte_stream def test_as_airbyte_stream_with_namespace(self): stream = DefaultStream( @@ -194,4 +194,4 @@ def test_as_airbyte_stream_with_namespace(self): ) actual_airbyte_stream = stream.as_airbyte_stream() - assert expected_airbyte_stream == actual_airbyte_stream + assert actual_airbyte_stream == expected_airbyte_stream diff --git a/airbyte-cdk/python/unit_tests/sources/streams/http/auth/test_auth.py b/airbyte-cdk/python/unit_tests/sources/streams/http/auth/test_auth.py index 444031526a906..a1ada8b0ff63e 100644 --- a/airbyte-cdk/python/unit_tests/sources/streams/http/auth/test_auth.py +++ b/airbyte-cdk/python/unit_tests/sources/streams/http/auth/test_auth.py @@ -170,4 +170,4 @@ def test_refresh_access_authenticator(self): refresh_access_token_authenticator=TestOauth2Authenticator.refresh_access_token_authenticator, ) expected_headers = {"Authorization": "Basic Y2xpZW50X2lkOmNsaWVudF9zZWNyZXQ="} - assert expected_headers == oauth.get_refresh_access_token_headers() + assert oauth.get_refresh_access_token_headers() == expected_headers diff --git a/airbyte-cdk/python/unit_tests/sources/streams/http/test_availability_strategy.py b/airbyte-cdk/python/unit_tests/sources/streams/http/test_availability_strategy.py index b63af79738546..c3a2d8d7f1426 100644 --- a/airbyte-cdk/python/unit_tests/sources/streams/http/test_availability_strategy.py +++ b/airbyte-cdk/python/unit_tests/sources/streams/http/test_availability_strategy.py @@ -113,7 +113,7 @@ def streams(self, config: Mapping[str, Any]) -> List[Stream]: else: actual_is_available, reason = http_stream.check_availability(logger) - assert expected_is_available == actual_is_available + assert actual_is_available == expected_is_available if expected_is_available: assert reason is None else: diff --git a/airbyte-cdk/python/unit_tests/sources/streams/http/test_http.py b/airbyte-cdk/python/unit_tests/sources/streams/http/test_http.py index e826e74a47ee8..c9836e4c28517 100644 --- a/airbyte-cdk/python/unit_tests/sources/streams/http/test_http.py +++ b/airbyte-cdk/python/unit_tests/sources/streams/http/test_http.py @@ -123,7 +123,7 @@ def test_next_page_token_is_input_to_other_methods(mocker): expected = [{"data": 1}, {"data": 2}, {"data": 3}, {"data": 4}, {"data": 5}, {"data": 6}] - assert expected == records + assert records == expected class StubBadUrlHttpStream(StubBasicReadHttpStream): diff --git a/airbyte-cdk/python/unit_tests/sources/streams/test_stream_read.py b/airbyte-cdk/python/unit_tests/sources/streams/test_stream_read.py index 00f7fe78a4d4a..b64b403ebe621 100644 --- a/airbyte-cdk/python/unit_tests/sources/streams/test_stream_read.py +++ b/airbyte-cdk/python/unit_tests/sources/streams/test_stream_read.py @@ -187,7 +187,7 @@ def test_full_refresh_read_a_single_slice_with_debug(constructor): actual_records = _read(stream, configured_stream, logger, slice_logger, message_repository, state_manager, internal_config) - assert expected_records == actual_records + assert actual_records == expected_records @pytest.mark.parametrize( @@ -233,7 +233,7 @@ def test_full_refresh_read_a_single_slice(constructor): actual_records = _read(stream, configured_stream, logger, slice_logger, message_repository, state_manager, internal_config) - assert expected_records == actual_records + assert actual_records == expected_records @pytest.mark.parametrize( @@ -289,7 +289,7 @@ def test_full_refresh_read_two_slices(constructor): for record in expected_records: assert record in actual_records - assert len(expected_records) == len(actual_records) + assert len(actual_records) == len(expected_records) def test_incremental_read_two_slices(): @@ -324,7 +324,7 @@ def test_incremental_read_two_slices(): for record in expected_records: assert record in actual_records - assert len(expected_records) == len(actual_records) + assert len(actual_records) == len(expected_records) def test_concurrent_incremental_read_two_slices(): @@ -361,7 +361,7 @@ def test_concurrent_incremental_read_two_slices(): for record in expected_records: assert record in actual_records - assert len(expected_records) == len(actual_records) + assert len(actual_records) == len(expected_records) # We don't have a real source that reads from the message_repository for state, so we read from the queue directly to verify # the cursor observed records correctly and updated partition states diff --git a/airbyte-cdk/python/unit_tests/sources/test_abstract_source.py b/airbyte-cdk/python/unit_tests/sources/test_abstract_source.py index 3b00adf27d963..4ebfa6a0e771c 100644 --- a/airbyte-cdk/python/unit_tests/sources/test_abstract_source.py +++ b/airbyte-cdk/python/unit_tests/sources/test_abstract_source.py @@ -144,13 +144,13 @@ def message_repository(): def test_successful_check(): """Tests that if a source returns TRUE for the connection check the appropriate connectionStatus success message is returned""" expected = AirbyteConnectionStatus(status=Status.SUCCEEDED) - assert expected == MockSource(check_lambda=lambda: (True, None)).check(logger, {}) + assert MockSource(check_lambda=lambda: (True, None)).check(logger, {}) == expected def test_failed_check(): """Tests that if a source returns FALSE for the connection check the appropriate connectionStatus failure message is returned""" expected = AirbyteConnectionStatus(status=Status.FAILED, message="'womp womp'") - assert expected == MockSource(check_lambda=lambda: (False, "womp womp")).check(logger, {}) + assert MockSource(check_lambda=lambda: (False, "womp womp")).check(logger, {}) == expected def test_raising_check(mocker): @@ -253,7 +253,7 @@ def test_discover(mocker): expected = AirbyteCatalog(streams=[airbyte_stream1, airbyte_stream2]) src = MockSource(check_lambda=lambda: (True, None), streams=[stream1, stream2]) - assert expected == src.discover(logger, {}) + assert src.discover(logger, {}) == expected def test_read_nonexistent_stream_raises_exception(mocker): @@ -441,7 +441,7 @@ def test_valid_full_refresh_read_no_slices(mocker): ) messages = _fix_emitted_at(list(src.read(logger, {}, catalog))) - assert expected == messages + assert messages == expected def test_valid_full_refresh_read_with_slices(mocker): @@ -485,7 +485,7 @@ def test_valid_full_refresh_read_with_slices(mocker): messages = _fix_emitted_at(list(src.read(logger, {}, catalog))) - assert expected == messages + assert messages == expected def test_full_refresh_does_not_use_incoming_state(mocker): @@ -755,7 +755,7 @@ def test_with_checkpoint_interval(self, mocker, use_legacy): ) messages = _fix_emitted_at(list(src.read(logger, {}, catalog, state=input_state))) - assert expected == messages + assert messages == expected @pytest.mark.parametrize( "use_legacy", @@ -812,7 +812,7 @@ def test_with_no_interval(self, mocker, use_legacy): messages = _fix_emitted_at(list(src.read(logger, {}, catalog, state=input_state))) - assert expected == messages + assert messages == expected @pytest.mark.parametrize( "use_legacy", @@ -897,7 +897,7 @@ def test_with_slices(self, mocker, use_legacy): messages = _fix_emitted_at(list(src.read(logger, {}, catalog, state=input_state))) - assert expected == messages + assert messages == expected @pytest.mark.parametrize( "use_legacy", @@ -981,7 +981,7 @@ def test_no_slices(self, mocker, use_legacy, slices): messages = _fix_emitted_at(list(src.read(logger, {}, catalog, state=input_state))) - assert expected == messages + assert messages == expected @pytest.mark.parametrize( "use_legacy", @@ -1288,7 +1288,7 @@ def test_continue_sync_with_failed_streams(mocker, exception_to_raise, expected_ messages = [_remove_stack_trace(message) for message in src.read(logger, {}, catalog)] messages = _fix_emitted_at(messages) - assert expected == messages + assert messages == expected assert "lamentations" in exc.value.message assert exc.value.failure_type == FailureType.config_error @@ -1338,7 +1338,7 @@ def test_continue_sync_source_override_false(mocker): messages = [_remove_stack_trace(message) for message in src.read(logger, {}, catalog)] messages = _fix_emitted_at(messages) - assert expected == messages + assert messages == expected assert "lamentations" in exc.value.message assert exc.value.failure_type == FailureType.config_error @@ -1389,7 +1389,7 @@ def test_sync_error_trace_messages_obfuscate_secrets(mocker): messages = [_remove_stack_trace(message) for message in src.read(logger, {}, catalog)] messages = _fix_emitted_at(messages) - assert expected == messages + assert messages == expected assert "lamentations" in exc.value.message assert exc.value.failure_type == FailureType.config_error @@ -1434,7 +1434,7 @@ def test_continue_sync_with_failed_streams_with_override_false(mocker): messages = [_remove_stack_trace(message) for message in src.read(logger, {}, catalog)] messages = _fix_emitted_at(messages) - assert expected == messages + assert messages == expected assert "lamentations" in exc.value.message assert exc.value.failure_type == FailureType.config_error diff --git a/airbyte-cdk/python/unit_tests/sources/utils/test_catalog_helpers.py b/airbyte-cdk/python/unit_tests/sources/utils/test_catalog_helpers.py index d8ae2bdd802a5..8f4862332ea81 100644 --- a/airbyte-cdk/python/unit_tests/sources/utils/test_catalog_helpers.py +++ b/airbyte-cdk/python/unit_tests/sources/utils/test_catalog_helpers.py @@ -27,4 +27,4 @@ def test_coerce_catalog_as_full_refresh(): ] ) - assert expected == CatalogHelper.coerce_catalog_as_full_refresh(input) + assert CatalogHelper.coerce_catalog_as_full_refresh(input) == expected diff --git a/airbyte-cdk/python/unit_tests/sources/utils/test_record_helper.py b/airbyte-cdk/python/unit_tests/sources/utils/test_record_helper.py index 7f3d535ce05d1..b5476180309bc 100644 --- a/airbyte-cdk/python/unit_tests/sources/utils/test_record_helper.py +++ b/airbyte-cdk/python/unit_tests/sources/utils/test_record_helper.py @@ -45,7 +45,7 @@ def test_data_or_record_to_airbyte_record(test_name, data, expected_message): transformer.transform.assert_called_with(data, schema) else: assert not transformer.transform.called - assert expected_message == message + assert message == expected_message @pytest.mark.parametrize( @@ -69,7 +69,7 @@ def test_log_or_trace_to_message(test_name, data, expected_message): message = stream_data_to_airbyte_message(STREAM_NAME, data, transformer, schema) assert not transformer.transform.called - assert expected_message == message + assert message == expected_message @pytest.mark.parametrize( diff --git a/airbyte-cdk/python/unit_tests/test_connector.py b/airbyte-cdk/python/unit_tests/test_connector.py index c7116c6b25c19..5ebcfb9b86066 100644 --- a/airbyte-cdk/python/unit_tests/test_connector.py +++ b/airbyte-cdk/python/unit_tests/test_connector.py @@ -40,7 +40,7 @@ def test_from_file(self): f.write(json.dumps(self.VALID_SPEC)) f.flush() actual = AirbyteSpec.from_file(f.name) - assert expected == json.loads(actual.spec_string) + assert json.loads(actual.spec_string) == expected def test_from_file_nonexistent(self): with pytest.raises(OSError): @@ -80,7 +80,7 @@ def integration(): def test_read_config(nonempty_file, integration: Connector, mock_config): actual = integration.read_config(nonempty_file.name) - assert mock_config == actual + assert actual == mock_config def test_read_non_json_config(nonjson_file, integration: Connector): @@ -92,7 +92,7 @@ def test_write_config(integration, mock_config): config_path = Path(tempfile.gettempdir()) / "config.json" integration.write_config(mock_config, str(config_path)) with open(config_path, "r") as actual: - assert mock_config == json.loads(actual.read()) + assert json.loads(actual.read()) == mock_config class TestConnectorSpec: diff --git a/airbyte-ci/connectors/common_utils/tests/test_logger.py b/airbyte-ci/connectors/common_utils/tests/test_logger.py index 1d12ad29325c9..23be93de42279 100644 --- a/airbyte-ci/connectors/common_utils/tests/test_logger.py +++ b/airbyte-ci/connectors/common_utils/tests/test_logger.py @@ -19,8 +19,8 @@ def check_output(msg: str, expected_line_number: int, expected_log_level: str): date_time, log_level, line_number, msg = m.groups() assert int(line_number) == expected_line_number - assert expected_log_level == log_level - assert expected_log_level == log_level + assert log_level == expected_log_level + assert log_level == expected_log_level dt = datetime.strptime(date_time, "%d/%m/%Y %H:%M:%S.%f") now = datetime.now() delta = timedelta(seconds=1) diff --git a/airbyte-ci/connectors/metadata_service/orchestrator/tests/test_registry.py b/airbyte-ci/connectors/metadata_service/orchestrator/tests/test_registry.py index 151e49b4ab8a2..4e88c1eb2dc99 100644 --- a/airbyte-ci/connectors/metadata_service/orchestrator/tests/test_registry.py +++ b/airbyte-ci/connectors/metadata_service/orchestrator/tests/test_registry.py @@ -220,7 +220,7 @@ def test_definition_id_conversion(registry_type, connector_type, expected_id_fie result = metadata_to_registry_entry(mock_metadata_entry, registry_type) assert "definitionId" not in result - assert result[expected_id_field] == "test-id" + assert "test-id" == result[expected_id_field] def test_tombstone_custom_public_set(): diff --git a/airbyte-ci/connectors/pipelines/tests/test_helpers/test_utils.py b/airbyte-ci/connectors/pipelines/tests/test_helpers/test_utils.py index aa7e305d809ae..2b9f19a83ed2b 100644 --- a/airbyte-ci/connectors/pipelines/tests/test_helpers/test_utils.py +++ b/airbyte-ci/connectors/pipelines/tests/test_helpers/test_utils.py @@ -183,8 +183,8 @@ async def test_check_path_in_workdir(dagger_client): .with_workdir(str(connector.code_directory)) ) assert await utils.check_path_in_workdir(container, "metadata.yaml") - assert await utils.check_path_in_workdir(container, "setup.py") - assert await utils.check_path_in_workdir(container, "requirements.txt") + assert await utils.check_path_in_workdir(container, "pyproject.toml") + assert await utils.check_path_in_workdir(container, "poetry.lock") assert await utils.check_path_in_workdir(container, "not_existing_file") is False diff --git a/airbyte-ci/connectors/pipelines/tests/test_upgrade_java_cdk.py b/airbyte-ci/connectors/pipelines/tests/test_upgrade_java_cdk.py index cbe91b4df3c1e..72a45978769f4 100644 --- a/airbyte-ci/connectors/pipelines/tests/test_upgrade_java_cdk.py +++ b/airbyte-ci/connectors/pipelines/tests/test_upgrade_java_cdk.py @@ -105,7 +105,7 @@ async def test_run_connector_cdk_upgrade_pipeline( assert files == ["build.gradle"] build_gradle = resulting_directory.file("build.gradle") actual_build_gradle_content = await build_gradle.contents() - assert expected_build_gradle_content == actual_build_gradle_content + assert actual_build_gradle_content == expected_build_gradle_content # Assert that the diff was exported to the repo assert updated_connector_dir.diff.return_value.export.call_count == 1 diff --git a/airbyte-ci/connectors/pipelines/tests/test_upgrade_python_cdk.py b/airbyte-ci/connectors/pipelines/tests/test_upgrade_python_cdk.py index 67d855a1d91e7..70c253241ac21 100644 --- a/airbyte-ci/connectors/pipelines/tests/test_upgrade_python_cdk.py +++ b/airbyte-ci/connectors/pipelines/tests/test_upgrade_python_cdk.py @@ -96,7 +96,7 @@ async def test_run_connector_cdk_upgrade_pipeline( assert files == ["setup.py"] setup_py = resulting_directory.file("setup.py") actual_setup_py_content = await setup_py.contents() - assert expected_setup_py_content == actual_setup_py_content + assert actual_setup_py_content == expected_setup_py_content # Assert that the diff was exported to the repo assert updated_connector_dir.diff.return_value.export.call_count == 1 diff --git a/airbyte-integrations/bases/base-normalization/unit_tests/test_transform_config.py b/airbyte-integrations/bases/base-normalization/unit_tests/test_transform_config.py index 8668d791a719b..2c3fc60f7ea3e 100644 --- a/airbyte-integrations/bases/base-normalization/unit_tests/test_transform_config.py +++ b/airbyte-integrations/bases/base-normalization/unit_tests/test_transform_config.py @@ -154,8 +154,8 @@ def test_transform_bigquery(self): actual_keyfile = actual_output["keyfile_json"] expected_keyfile = {"type": "service_account-json"} - assert expected_output == actual_output - assert expected_keyfile == actual_keyfile + assert actual_output == expected_output + assert actual_keyfile == expected_keyfile assert extract_schema(actual_output) == "my_dataset_id" def test_transform_bigquery_no_credentials(self): @@ -172,7 +172,7 @@ def test_transform_bigquery_no_credentials(self): "threads": 8, } - assert expected_output == actual_output + assert actual_output == expected_output assert extract_schema(actual_output) == "my_dataset_id" def test_transform_bigquery_with_embedded_project_id(self): @@ -189,7 +189,7 @@ def test_transform_bigquery_with_embedded_project_id(self): "threads": 8, } - assert expected_output == actual_output + assert actual_output == expected_output assert extract_schema(actual_output) == "my_dataset_id" def test_transform_bigquery_with_embedded_mismatched_project_id(self): @@ -232,7 +232,7 @@ def test_transform_postgres(self): "user": "a user", } - assert expected == actual + assert actual == expected assert extract_schema(actual) == "public" def test_transform_postgres_ssh(self): @@ -265,7 +265,7 @@ def test_transform_postgres_ssh(self): "user": "a user", } - assert expected == actual + assert actual == expected assert extract_schema(actual) == "public" def test_transform_snowflake(self): @@ -298,7 +298,7 @@ def test_transform_snowflake(self): "warehouse": "AIRBYTE_WAREHOUSE", } - assert expected == actual + assert actual == expected assert extract_schema(actual) == "AIRBYTE_SCHEMA" def test_transform_snowflake_oauth(self): @@ -341,7 +341,7 @@ def test_transform_snowflake_oauth(self): "token": "AIRBYTE_REFRESH_TOKEN", } - assert expected == actual + assert actual == expected assert extract_schema(actual) == "AIRBYTE_SCHEMA" def test_transform_snowflake_key_pair(self): @@ -379,7 +379,7 @@ def test_transform_snowflake_key_pair(self): "private_key_passphrase": "AIRBYTE_PRIVATE_KEY_PASSWORD", } - assert expected == actual + assert actual == expected assert extract_schema(actual) == "AIRBYTE_SCHEMA" def test_transform_mysql(self): @@ -404,7 +404,7 @@ def test_transform_mysql(self): "password": "password1234", } - assert expected == actual + assert actual == expected # DBT schema is equivalent to MySQL database assert extract_schema(actual) == "my_db" @@ -430,7 +430,7 @@ def test_transform_mssql(self): "password": "password1234", } - assert expected == actual + assert actual == expected # DBT schema is equivalent to MySQL database assert extract_schema(actual) == "my_db" @@ -450,7 +450,7 @@ def test_transform_clickhouse(self): "secure": True, } - assert expected == actual + assert actual == expected assert extract_schema(actual) == "default" # test that the full config is produced. this overlaps slightly with the transform_postgres test. @@ -477,7 +477,7 @@ def test_transform(self): } actual = TransformConfig().transform(DestinationType.POSTGRES, input) - assert expected == actual + assert actual == expected assert extract_schema(actual["normalize"]["outputs"]["prod"]) == "public" def test_transform_tidb(self): @@ -502,7 +502,7 @@ def test_transform_tidb(self): "password": "password1234", } - assert expected == actual + assert actual == expected assert extract_schema(actual) == "ti_db" def test_transform_duckdb_schema(self): @@ -519,7 +519,7 @@ def test_transform_duckdb_schema(self): "schema": "quackqauck", } - assert expected == actual + assert actual == expected assert extract_path(actual) == "/local/testing.duckdb" def test_transform_duckdb_no_schema(self): @@ -535,7 +535,7 @@ def test_transform_duckdb_no_schema(self): "schema": "main", } - assert expected == actual + assert actual == expected assert extract_path(actual) == "/local/testing.duckdb" def get_base_config(self): diff --git a/airbyte-integrations/bases/connector-acceptance-test/connector_acceptance_test/tests/test_core.py b/airbyte-integrations/bases/connector-acceptance-test/connector_acceptance_test/tests/test_core.py index 817563b797db8..50e495c322855 100644 --- a/airbyte-integrations/bases/connector-acceptance-test/connector_acceptance_test/tests/test_core.py +++ b/airbyte-integrations/bases/connector-acceptance-test/connector_acceptance_test/tests/test_core.py @@ -868,7 +868,7 @@ def _validate_records_structure(records: List[AirbyteRecordMessage], configured_ therefore any arbitrary object would pass schema validation. This method is here to catch those cases by extracting all the paths from the object and compare it to paths expected from jsonschema. If - there no common pathes then raise an alert. + there no common paths then raise an alert. :param records: List of airbyte record messages gathered from connector instances. :param configured_catalog: Testcase parameters parsed from yaml file @@ -878,15 +878,15 @@ def _validate_records_structure(records: List[AirbyteRecordMessage], configured_ schemas[stream.stream.name] = set(get_expected_schema_structure(stream.stream.json_schema)) for record in records: - schema_pathes = schemas.get(record.stream) - if not schema_pathes: + schema_paths = schemas.get(record.stream) + if not schema_paths: continue record_fields = set(get_object_structure(record.data)) - common_fields = set.intersection(record_fields, schema_pathes) + common_fields = set.intersection(record_fields, schema_paths) assert ( common_fields - ), f" Record {record} from {record.stream} stream with fields {record_fields} should have some fields mentioned by json schema: {schema_pathes}" + ), f" Record {record} from {record.stream} stream with fields {record_fields} should have some fields mentioned by json schema: {schema_paths}" @staticmethod def _validate_schema(records: List[AirbyteRecordMessage], configured_catalog: ConfiguredAirbyteCatalog): diff --git a/airbyte-integrations/bases/connector-acceptance-test/unit_tests/test_json_schema_helper.py b/airbyte-integrations/bases/connector-acceptance-test/unit_tests/test_json_schema_helper.py index a8f2f884d1f34..89536ae245421 100644 --- a/airbyte-integrations/bases/connector-acceptance-test/unit_tests/test_json_schema_helper.py +++ b/airbyte-integrations/bases/connector-acceptance-test/unit_tests/test_json_schema_helper.py @@ -183,7 +183,7 @@ class Root(BaseModel): @pytest.mark.parametrize( - "object, pathes", + "object, paths", [ ({}, []), ({"a": 12}, ["/a"]), @@ -197,12 +197,12 @@ class Root(BaseModel): ({"a": [[[{"b": 12}, {"b": 15}]]]}, ["/a", "/a/[]", "/a/[]/[]", "/a/[]/[]/[]", "/a/[]/[]/[]/b"]), ], ) -def test_get_object_strucutre(object, pathes): - assert get_object_structure(object) == pathes +def test_get_object_strucutre(object, paths): + assert get_object_structure(object) == paths @pytest.mark.parametrize( - "schema, pathes", + "schema, paths", [ ({"type": "object", "properties": {"a": {"type": "string"}}}, ["/a"]), ({"properties": {"a": {"type": "string"}}}, ["/a"]), @@ -229,8 +229,8 @@ def test_get_object_strucutre(object, pathes): ({"type": "array", "items": {"type": "object", "additionalProperties": {"type": "string"}}}, ["/[]"]), ], ) -def test_get_expected_schema_structure(schema, pathes): - assert get_expected_schema_structure(schema) == pathes +def test_get_expected_schema_structure(schema, paths): + assert paths == get_expected_schema_structure(schema) @pytest.mark.parametrize( diff --git a/airbyte-integrations/bases/connector-acceptance-test/unit_tests/test_utils.py b/airbyte-integrations/bases/connector-acceptance-test/unit_tests/test_utils.py index b99ae8389b22c..4316d871ca715 100644 --- a/airbyte-integrations/bases/connector-acceptance-test/unit_tests/test_utils.py +++ b/airbyte-integrations/bases/connector-acceptance-test/unit_tests/test_utils.py @@ -217,14 +217,14 @@ def test_load_json(self): f.write(json.dumps(self.VALID_SPEC)) f.flush() actual = common.load_yaml_or_json_path(Path(f.name)) - assert self.VALID_SPEC == actual + assert actual == self.VALID_SPEC def test_load_yaml(self): with tempfile.NamedTemporaryFile("w", suffix=".yaml") as f: f.write(yaml.dump(self.VALID_SPEC)) f.flush() actual = common.load_yaml_or_json_path(Path(f.name)) - assert self.VALID_SPEC == actual + assert actual == self.VALID_SPEC def test_load_other(self): with tempfile.NamedTemporaryFile("w", suffix=".txt") as f: diff --git a/docusaurus/redirects.yml b/docusaurus/redirects.yml index f1c2bfaa246d7..18304de3117fb 100644 --- a/docusaurus/redirects.yml +++ b/docusaurus/redirects.yml @@ -1,4 +1,4 @@ -# A list of URLs that should be redirected to new pathes +# A list of URLs that should be redirected to new paths - from: /upgrading-airbyte to: /operator-guides/upgrading-airbyte - from: /catalog