MushroomObserver / mushroom-observer

A website for sharing observations of mushrooms.
https://mushroomobserver.org
MIT License
77 stars 25 forks source link

Field Slip system test adjustments #2141

Closed nimmolo closed 3 months ago

nimmolo commented 4 months ago

Refactors the field_slips_test as integration tests. Should run faster and be just as effective.

Background:

With system tests, they're slow and we only really need them if we're testing JS.

coveralls commented 4 months ago

Coverage Status

coverage: 94.397%. remained the same when pulling 27ab49d5e2e2b44b96df6f745c7c8adb4290317e on nimmo-system-test-class-selector-adjustments into 977aeb9aea51af9bc1a760fa1b5db7f42dcc6538 on main.

nimmolo commented 4 months ago

Update: This PR does have some things we may want to keep:

nimmolo commented 3 months ago

@mo-nathan — I just converted your original short system tests to equally short integration tests, as we discussed a couple weeks ago. I think keeping the tests separate preserves your original intent.

Note the addition of selector classes to the templates, so we don't have to use XPATH selectors in our tests - much easier.

nimmolo commented 3 months ago

@mo-nathan I am realizing this will affect your #2160 Field Slip Forms PR.

I believe it is an improvement on the form HTML, particularly the selectors, and makes the tests less brittle. If you like, I'll be happy to check #2160 over and reconcile these changes with that PR.

nimmolo commented 3 months ago

Ok thanks, I will merge. Just say the word and I'll either reconcile it with #2160, or offer suggestions - I realize this creates extra work on a long-running PR of yours and that you're probably not wanting any added confusion with it.