tighten / takeout

Docker-based development-only dependency manager. macOS, Linux, and WSL2-only and installs via PHP's Composer... for now.
MIT License
1.6k stars 84 forks source link

Properly sort versions (closes #207 & #213) #216

Closed edalzell closed 3 years ago

edalzell commented 3 years ago

Closes #207 Closes #213

Added a failing test as well.

mattstauffer commented 3 years ago

Thanks @edalzell!

mattstauffer commented 3 years ago

@edalzell Sorry, but either something has changed or I didn't understand this when I was merging. The test you added is failing, as you mentioned, but... I guess what I assumed you meant was "I added a test that failed but now succeeds."

But.. you definitely left a test that just fails. What was your intention with that?

edalzell commented 3 years ago

@edalzell Sorry, but either something has changed or I didn't understand this when I was merging. The test you added is failing, as you mentioned, but... I guess what I assumed you meant was "I added a test that failed but now succeeds."

But.. you definitely left a test that just fails. What was your intention with that?

Ya that's what I meant, it passed after my update. It breaks now? I can take a look.

edalzell commented 3 years ago

Ya if you look at my test and it_lists_10_newest_available_tags_for_service they are practically the same. The first one (mysql) passes and mine, postgres fails.

Perhaps the postgres stuff changed?

edalzell commented 3 years ago

Looks like latest is NOT in the most recent ten tags, as seen here. Very different than mysql as seen here.

Not sure how to get the latest postgres anymore...I'll have to experiment

edalzell commented 3 years ago

Ok I have a fix @mattstauffer, let's discuss?

The issue is that the latest is not in the first 10. It turns out you can set ?page_size=20 and get more results (from here).

Once you do that, the tags come back sorted properly again, and the tests pass (once you change the 10 test to 20, of course).

Sound good?

edalzell commented 3 years ago

Once you do that, the tags come back sorted properly again, and the tests pass (once you change the 10 test to 20, of course).

Note that ALL tests continue to pass after getting 20 tags back, instead of ten.