[go: up one dir, main page]

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(spanner): add PG.OID support #1948

Merged
merged 7 commits into from
Feb 14, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Prev Previous commit
fixes to address review feedback
  • Loading branch information
skuruppu committed Feb 14, 2024
commit 92f86e828a1f936772cdb4824df7cd222290b2a7
17 changes: 16 additions & 1 deletion system-test/spanner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -828,7 +828,7 @@ describe('Spanner', () => {
});

describe('oids', () => {
it('POSTGRESQL should read pgOid values', function (done) {
it('POSTGRESQL should read non-null pgOid values', function (done) {
if (IS_EMULATOR_ENABLED) {
this.skip();
}
Expand All @@ -842,6 +842,21 @@ describe('Spanner', () => {
done();
});
});

it('POSTGRESQL should read null pgOid values', function (done) {
if (IS_EMULATOR_ENABLED) {
this.skip();
}
PG_DATABASE.run('SELECT null::oid', (err, rows) => {
assert.ifError(err);
let queriedValue = rows[0][0].value;
if (rows[0][0].value) {
queriedValue = rows[0][0].value.value;
}
assert.strictEqual(queriedValue, null);
done();
});
});
});

describe('float64s', () => {
Expand Down