@@ -637,6 +637,31 @@ def test_utility_methods(self, sea_client):
637
637
sea_client ._extract_description_from_manifest (no_columns_manifest ) is None
638
638
)
639
639
640
+ def test_results_message_to_execute_response_is_staging_operation (self , sea_client ):
641
+ """Test that is_staging_operation is correctly set from manifest.is_volume_operation."""
642
+ # Test when is_volume_operation is True
643
+ response = MagicMock ()
644
+ response .statement_id = "test-statement-123"
645
+ response .status .state = CommandState .SUCCEEDED
646
+ response .manifest .is_volume_operation = True
647
+ response .manifest .result_compression = "NONE"
648
+ response .manifest .format = "JSON_ARRAY"
649
+
650
+ # Mock the _extract_description_from_manifest method to return None
651
+ with patch .object (
652
+ sea_client , "_extract_description_from_manifest" , return_value = None
653
+ ):
654
+ result = sea_client ._results_message_to_execute_response (response )
655
+ assert result .is_staging_operation is True
656
+
657
+ # Test when is_volume_operation is False
658
+ response .manifest .is_volume_operation = False
659
+ with patch .object (
660
+ sea_client , "_extract_description_from_manifest" , return_value = None
661
+ ):
662
+ result = sea_client ._results_message_to_execute_response (response )
663
+ assert result .is_staging_operation is False
664
+
640
665
def test_get_catalogs (self , sea_client , sea_session_id , mock_cursor ):
641
666
"""Test the get_catalogs method."""
642
667
# Mock the execute_command method
0 commit comments