Skip to content

Enable tests to run in parallel - #3809

Merged
vonzshik merged 7 commits into
npgsql:mainfrom
vonzshik:npgsql-tests-parallel
Feb 22, 2022
Merged

vonzshik merged 7 commits into
npgsql:mainfrom
vonzshik:npgsql-tests-parallel

Conversation

@vonzshik

@vonzshik vonzshik commented Jun 4, 2021 •

Copy link
Copy Markdown
Contributor

Let's see how it goes...

Closes #4094

@vonzshik
vonzshik requested a review from roji as a code owner June 4, 2021 10:54
@vonzshik
vonzshik force-pushed the npgsql-tests-parallel branch 18 times, most recently from 6113bac to 28590a7 Compare November 5, 2021 09:50

@roji roji left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Am very happy to see this @vonzshik, thanks! Hopefully we'll see a few stable runs...

@vonzshik
vonzshik force-pushed the npgsql-tests-parallel branch 2 times, most recently from b7be6dd to f8753d7 Compare November 6, 2021 12:00
@vonzshik
vonzshik force-pushed the npgsql-tests-parallel branch from 397607b to f0eb732 Compare November 20, 2021 09:52
@vonzshik
vonzshik requested a review from roji November 20, 2021 10:03
@vonzshik

Copy link
Copy Markdown
Contributor Author

@roji one final check...

@roji roji left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vonzshik looks good, thanks.

Just to confirm - some tests/classes are marked as [NonParallelizable], though they could probably easily be made parallelizable - this is just because we're leaving them for later, right? If so, that's a good thing - better to do this work in phases and get confidence via successful builds that all is good before doing more...

Comment thread test/Npgsql.Tests/ConnectionTests.cs Resolved
Comment thread test/Npgsql.Tests/CopyTests.cs Resolved
Comment thread test/Npgsql.Tests/NotificationTests.cs Outdated

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't mind this being NonParallelizable, but is there a specific problem with this test suite? Or are we leaving this for later?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are multiple calls LISTEN notifytest and NOTIFY notifytest from different tests. Definitely not impossible to fix, but probably better to do it a bit later.

Comment thread test/Npgsql.Tests/ReaderTests.cs Resolved
Comment thread test/Npgsql.Tests/SchemaTests.cs Outdated

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most of this should parallelizable right? Just leaving for later?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, exactly.

Comment thread test/Npgsql.Tests/TestUtil.cs Outdated

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is all this needed? We're guaranteed to have a unique tableName via _tempTableCounter no?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I remember having an issue whenever multiple tables were created concurrently (something with the types). I can change it back just to test whether the issue is back...

@vonzshik
vonzshik force-pushed the npgsql-tests-parallel branch from cf57dd2 to d7bc792 Compare February 21, 2022 10:27
@vonzshik
vonzshik requested a review from roji February 21, 2022 11:36
@vonzshik

Copy link
Copy Markdown
Contributor Author

@roji seems to be relatively stable. I propose to merge it and start removing NonParallelizable in the next few weeks.

@roji roji left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍 Let's get it in and work incrementally from there.

There's that failing test which I'm guessing you're looking at...

Comment thread test/Npgsql.Tests/ConnectionTests.cs Resolved
Comment thread test/Npgsql.Tests/ConnectionTests.cs Resolved
@vonzshik
vonzshik enabled auto-merge (squash) February 22, 2022 14:03
@vonzshik
vonzshik disabled auto-merge February 22, 2022 14:11
@vonzshik
vonzshik merged commit 0ead407 into npgsql:main Feb 22, 2022
@vonzshik
vonzshik deleted the npgsql-tests-parallel branch February 22, 2022 14:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Run tests in parallel again

2 participants