Skip to content

Commit

Permalink
test: add test to check that the PG.OID param type is correct
Browse files Browse the repository at this point in the history
  • Loading branch information
larkee committed Nov 13, 2023
1 parent c8a5b65 commit 4f09a0b
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions tests/unit/test_param_types.py
Expand Up @@ -71,3 +71,20 @@ def test_it(self):
found = param_types.PG_JSONB

self.assertEqual(found, expected)


class Test_OidParamType(unittest.TestCase):
def test_it(self):
from google.cloud.spanner_v1 import Type
from google.cloud.spanner_v1 import TypeCode
from google.cloud.spanner_v1 import TypeAnnotationCode
from google.cloud.spanner_v1 import param_types

expected = Type(
code=TypeCode.INT64,
type_annotation=TypeAnnotationCode.PG_OID,
)

found = param_types.PG_OID

self.assertEqual(found, expected)

0 comments on commit 4f09a0b

Please sign in to comment.