Skip to content

Commit 83914f8

Browse files
committed
test: add test to check that the PG.OID param type is correct
1 parent 23f41e1 commit 83914f8

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

tests/unit/test_param_types.py

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,3 +70,20 @@ def test_it(self):
7070
found = param_types.PG_JSONB
7171

7272
self.assertEqual(found, expected)
73+
74+
75+
class Test_OidParamType(unittest.TestCase):
76+
def test_it(self):
77+
from google.cloud.spanner_v1 import Type
78+
from google.cloud.spanner_v1 import TypeCode
79+
from google.cloud.spanner_v1 import TypeAnnotationCode
80+
from google.cloud.spanner_v1 import param_types
81+
82+
expected = Type(
83+
code=TypeCode.INT64,
84+
type_annotation=TypeAnnotationCode.PG_OID,
85+
)
86+
87+
found = param_types.PG_OID
88+
89+
self.assertEqual(found, expected)

0 commit comments

Comments
 (0)