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

Some ActiveRecord Tests Failing #378

Open
keithdoggett opened this issue May 16, 2023 · 5 comments
Open

Some ActiveRecord Tests Failing #378

keithdoggett opened this issue May 16, 2023 · 5 comments

Comments

@keithdoggett
Copy link
Member

Running bundle exec rake test:activerecord yields ~50 test failures, currently. Most of these need to be excluded and re-written in our own test suite. Once I have a standard process for excluding ActiveRecord tests I'll update this issue.

@BuonOmo
Copy link
Member

BuonOmo commented Sep 4, 2024

@keithdoggett I'm back on running this test suite, and excluding tests with minitest-exclude. But as of now something quite weird happens: in CI (not locally) tests are super slow when use_transactional_tests = false, and they seem to get exponentially slower in a given class. Example from one of my latest CI tests:

PostgresqlHstoreTest#test_array_cycle = 0.07 s = .
PostgresqlHstoreTest#test_array_strings_with_array_delimiters = 0.08 s = .
PostgresqlHstoreTest#test_array_strings_with_commas = 0.09 s = .
PostgresqlHstoreTest#test_array_strings_with_null_strings = 0.15 s = .
PostgresqlHstoreTest#test_array_strings_with_quotes = 0.42 s = .
PostgresqlHstoreTest#test_arrow = 1.40 s = .
PostgresqlHstoreTest#test_backslash = 5.20 s = .
PostgresqlHstoreTest#test_cast_value_on_write = 20.81 s = .
PostgresqlHstoreTest#test_change_table_supports_hstore = 82.67 s = .
PostgresqlHstoreTest#test_changes_in_place = 333.01 s = .
PostgresqlHstoreTest#test_changes_with_store_accessors = 1365.47 s = .
PostgresqlHstoreTest#test_clone_hstore_with_serialized_attributes = 5903.55 s = .
... (still running!)

Any hint on this? Seems fun to debug anyway, the only issue is that it is CI specific.

Culprit found: ged/ruby-pg#586

@BuonOmo
Copy link
Member

BuonOmo commented Sep 5, 2024

I've added the test suite and excluded tests failing with the TRIAGE_MESSAGE constant (rg TRIAGE MESSAGE yields them all). Anyone can take some of these once #405 is merged, they are now truly a good first issue.

Note that some skipped tests should not be skipped as well. We should mention them somewhere in our backlog..

@keithdoggett
Copy link
Member Author

@BuonOmo agree about creating a backlog for those tests. Could probably make an issue for each one with some kind of new label.

For the slow tests is there any action we can take? Seems like an upstream issue. Thanks for digging into that.

@BuonOmo
Copy link
Member

BuonOmo commented Sep 9, 2024

Could probably make an issue for each one with some kind of new label.

I wouldn't as it would clutter the backlog a lot.

For the slow tests is there any action we can take? Seems like an upstream issue.

Since PG is no official dependency of this lib, there's no action of upgrading pg for users. Just in tests (which is done in the bump 7.2 pr)

@formigarafa
Copy link
Contributor

I've made a gist with a list of them it may help:
https://gist.github.com/formigarafa/5e5b5687fe5d09535affd2afc7df3c68

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants