Skip to content

Distinguish ambiguous column value of None #86

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

Closed
wants to merge 20 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
refactor: get none_sources as variable
  • Loading branch information
heehehe committed Sep 22, 2023
commit 6a506ebaa3c5e4a3788dcbc8b34c983ca7336996
5 changes: 3 additions & 2 deletions pymysqlreplication/tests/test_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -621,8 +621,9 @@ def test_get_none(self):
write_rows_event = self.stream.fetchone()
self.assertIsInstance(write_rows_event, WriteRowsEvent)

if write_rows_event.rows[0].get("none_sources"):
self.assertEqual(write_rows_event.rows[0]["none_sources"]["col1"], "null")
none_sources = write_rows_event.rows[0].get("none_sources")
if none_sources:
self.assertEqual(none_sources["col1"], "null")

def test_get_none_invalid(self):
self.execute("SET SESSION SQL_MODE='ALLOW_INVALID_DATES'")
Expand Down