2525from pyspark .sql import SparkSession
2626
2727from pyiceberg .catalog import Catalog
28+ from pyiceberg .environment_context import EnvironmentContext
2829from pyiceberg .exceptions import NoSuchTableError
2930from pyiceberg .partitioning import PartitionField , PartitionSpec
3031from pyiceberg .schema import Schema
@@ -498,6 +499,8 @@ def test_summaries_with_null(spark: SparkSession, session_catalog: Catalog, arro
498499 "total-files-size" : str (file_size ),
499500 "total-position-deletes" : "0" ,
500501 "total-records" : "3" ,
502+ "engine-name" : "pyiceberg" ,
503+ "engine-version" : EnvironmentContext .get ().get ("engine-version" ),
501504 }
502505
503506 assert summaries [1 ] == {
@@ -511,6 +514,8 @@ def test_summaries_with_null(spark: SparkSession, session_catalog: Catalog, arro
511514 "total-files-size" : str (file_size * 2 ),
512515 "total-position-deletes" : "0" ,
513516 "total-records" : "6" ,
517+ "engine-name" : "pyiceberg" ,
518+ "engine-version" : EnvironmentContext .get ().get ("engine-version" ),
514519 }
515520 assert summaries [2 ] == {
516521 "removed-files-size" : str (file_size * 2 ),
@@ -523,6 +528,8 @@ def test_summaries_with_null(spark: SparkSession, session_catalog: Catalog, arro
523528 "total-files-size" : "0" ,
524529 "total-data-files" : "0" ,
525530 "total-records" : "0" ,
531+ "engine-name" : "pyiceberg" ,
532+ "engine-version" : EnvironmentContext .get ().get ("engine-version" ),
526533 }
527534 assert summaries [3 ] == {
528535 "changed-partition-count" : "3" ,
@@ -535,6 +542,8 @@ def test_summaries_with_null(spark: SparkSession, session_catalog: Catalog, arro
535542 "total-files-size" : str (file_size ),
536543 "total-data-files" : "3" ,
537544 "total-records" : "3" ,
545+ "engine-name" : "pyiceberg" ,
546+ "engine-version" : EnvironmentContext .get ().get ("engine-version" ),
538547 }
539548 assert summaries [4 ] == {
540549 "changed-partition-count" : "3" ,
@@ -547,6 +556,8 @@ def test_summaries_with_null(spark: SparkSession, session_catalog: Catalog, arro
547556 "total-files-size" : str (file_size * 2 ),
548557 "total-data-files" : "6" ,
549558 "total-records" : "6" ,
559+ "engine-name" : "pyiceberg" ,
560+ "engine-version" : EnvironmentContext .get ().get ("engine-version" ),
550561 }
551562 assert "removed-files-size" in summaries [5 ]
552563 assert "total-files-size" in summaries [5 ]
@@ -561,6 +572,8 @@ def test_summaries_with_null(spark: SparkSession, session_catalog: Catalog, arro
561572 "total-files-size" : summaries [5 ]["total-files-size" ],
562573 "total-data-files" : "2" ,
563574 "total-records" : "2" ,
575+ "engine-name" : "pyiceberg" ,
576+ "engine-version" : EnvironmentContext .get ().get ("engine-version" ),
564577 }
565578 assert "added-files-size" in summaries [6 ]
566579 assert "total-files-size" in summaries [6 ]
@@ -575,6 +588,8 @@ def test_summaries_with_null(spark: SparkSession, session_catalog: Catalog, arro
575588 "total-files-size" : summaries [6 ]["total-files-size" ],
576589 "total-data-files" : "4" ,
577590 "total-records" : "4" ,
591+ "engine-name" : "pyiceberg" ,
592+ "engine-version" : EnvironmentContext .get ().get ("engine-version" ),
578593 }
579594
580595
0 commit comments