rok commented on code in PR #47139:
URL: https://github.com/apache/arrow/pull/47139#discussion_r2217450345


##########
python/pyarrow/tests/test_types.py:
##########
@@ -1445,3 +1445,22 @@ def __arrow_c_schema__(self):
     assert pa.field(wrapped_field, nullable=False).nullable is False
     result = pa.field(wrapped_field, metadata={"other": "meta"})
     assert result.metadata == {b"other": b"meta"}
+
+
+def test__combine_enums():
+    from enum import Enum
+
+    class Enum1(Enum):
+        VAL0 = 0
+        VAL1 = 1
+
+    class Enum2(Enum):
+        VAL2 = 2
+        VAL3 = 3
+
+    Enum3 = types._combine_enums("Enum3", Enum1, Enum2)
+
+    for i in range(4):
+        assert i in [val.value for val in Enum3.__members__.values()]
+        assert Enum3(i).name == f"VAL{i}"
+

Review Comment:
   ```suggestion
   ```
   
   Odd, but it seems linter wants to remove the last line?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to