-
Notifications
You must be signed in to change notification settings - Fork 57
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
chore: test with postgres #301
Conversation
7bb45d1
to
52e57ca
Compare
pre-commit.ci autofix |
494d919
to
9514d99
Compare
b3600d0
to
ce54e4f
Compare
@zerolab not sure what to do about precommit/prettier complaining about the migrations. There were a few linter changes that just popped up that I'm pretty sure aren't related to my code. bugbear start spitting out B028's where it shouldn't be afaict, we actually want those lines to have the explicit quotes and we want the id as is and we don't actually want |
I will have a look at the linting issue. |
#303 for linting. I am happy with fully ignoring B028 |
ce54e4f
to
355c4ef
Compare
alright. Rebased on main with #303 to hopefully resolve the linting issues. I'll need to hang up my hat here for the time being pending resolution to wagtail/wagtail#9788 vs updating setUpTestData back to setUp. I would really love it if we could get #299 merged in the interim. |
012690b
to
65bd8a2
Compare
32098f6
to
f0297e9
Compare
@zerolab hey I got it all running, but black says everything is good locally for me, so I don't know what exactly pre-commit is complaining about. |
pre-commit.ci autofix let's try to see if this does anything |
@zerolab danke. you've earned the bot whisperer badge. |
🤖 |
f67314b
to
d00eb49
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got a couple of questions, otherwise LGTM
@@ -915,7 +916,6 @@ def test_blog_page_tags(self): | |||
tags = executed["data"]["page"]["tags"] | |||
self.assertEqual(len(tags), 3) | |||
for idx, tag in enumerate(tags, start=1): | |||
self.assertEqual(int(tag["id"]), idx) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
question: why remove it? (I suspect I know the answer, but best not to assume)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is no guarantee that tags are ordered by ID or that a given database's auto incremented will start the ids at 0 and advance by 1. This is simply a frail assertion that doesn't prove anything about the validity of the data returned by the database.
d00eb49
to
5e88da8
Compare
* chore: test with postgres * fix: images tests on postgres
While working on search I discovered that sqllite couldn't support relevance scoring to validate natural ordering and frankly most production sites don't use sqlite. This adds postgres to the test matrix.