Skip to content

Tests: Improve resource sorting assertions - #155

Merged
n7studios merged 4 commits into
mainfrom
tests-resource-order-assertion
Nov 3, 2026
Merged

n7studios merged 4 commits into
mainfrom
tests-resource-order-assertion

Conversation

@n7studios

Copy link
Copy Markdown
Contributor

Summary

Resource tests asserted the first and last resource names, which break whenever a sequence, tag, form or custom field is added to the test Kit account. Replaces these with assertions that don't depend on which resources exist, ported from the main Kit Plugin (#1264):

  • assertResourcesSorted(): checks resources are sorted by the resource class' order_by and order properties, using the same strcmp comparison as the resource class.
  • assertResourcesInOriginalOrder(): checks resources are returned unsorted when order_by is invalid.

Testing

  • Updated Integration tests for Custom Fields, Forms, Sequences and Tags resources.

Checklist

dependabot Bot and others added 2 commits October 30, 2026 22:23
Updates the requirements on convertkit/convertkit-wordpress-libraries to permit the latest version.

---
updated-dependencies:
- dependency-name: convertkit/convertkit-wordpress-libraries
  dependency-version: 2.8.1
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
@n7studios n7studios self-assigned this Nov 2, 2026
…into dependabot/composer/convertkit/convertkit-wordpress-libraries-2.8.1
@n7studios
n7studios marked this pull request as ready for review November 2, 2026 10:40
@n7studios
n7studios requested review from a team, ciccio-kit and noelherrick and removed request for a team November 2, 2026 10:40
…rtkit-wordpress-libraries-2.8.1

Update convertkit/convertkit-wordpress-libraries requirement from 2.8.0 to 2.8.1
@n7studios
n7studios merged commit 1185baf into main Nov 3, 2026
35 of 39 checks passed
@n7studios
n7studios deleted the tests-resource-order-assertion branch November 3, 2026 03:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant