You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
test: consolidate slug field integration tests - #19625
Moves the existing slug field integration tests from test/fields/int.spec.ts into test/fields/collections/SlugField/int.spec.ts, alongside the existing slug-specific tests.
No actionable comments were generated in the recent review.
Walkthrough
The slug test suite was moved from test/fields/int.spec.ts to test/fields/collections/SlugField/int.spec.ts. The dedicated suite groups slug scenarios under shared setup and cleanup and includes coverage for localized fields, drafts, access, and fallback behavior.
Changes: Slug field tests
Layer / File(s)
Summary
Core slug and locale coverage test/fields/collections/SlugField/int.spec.ts, test/fields/int.spec.ts
The dedicated suite covers source-derived and explicit slugs, fallback generation, localized values and uniqueness, collisions, and direct slugifyHandler cases. The prior slug suite and its import were removed from the general field test file.
Draft and autosave coverage test/fields/collections/SlugField/int.spec.ts
The suite covers draft slug generation, collisions, duplication, autosave behavior, and slug persistence through publish and later updates.
Access and required localized fields test/fields/collections/SlugField/int.spec.ts
The suite covers slug probes during REST and elevated Local API creates. It also covers required localized fields, including nested group and tab fields.
payloadcms/payload#19349: This PR defines the localized slug regression scope that the moved test suite covers.
Suggested reviewers:danribbens
Merge Risk: Minimal · up to 34fc2
This is a test-only reorganization that moves slug integration tests into a dedicated file. It does not change runtime behavior and no actionable merge-blocking issue remains.
Pre-merge checks: 4
Check name
Status
Explanation
Title check
The title 'test: consolidate slug field integration tests' matches the main change. The PR moves slug field integration tests from test/fields/int.spec.ts into test/fields/collections/SlugField/int.sp…
Description check
The description states that the PR moves the existing slug field integration tests from test/fields/int.spec.ts into test/fields/collections/SlugField/int.spec.ts, next to the existing slug-specific t…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title 'test: consolidate slug field integration tests' matches the main change. The PR moves slug field integration tests from test/fields/int.spec.ts into test/fields/collections/SlugField/int.spec.ts, and the raw summary confirms the removal of the slug suite from the root file and its consolidation into the SlugField suite.
Full details: Description check
Explanation
The description states that the PR moves the existing slug field integration tests from test/fields/int.spec.ts into test/fields/collections/SlugField/int.spec.ts, next to the existing slug-specific tests. It also notes a dependency on #19349. This directly describes the changeset.
Finishing Touches
Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Reviewing files that changed from the base of the PR and between 1f703e3 and 34fc225.
Files selected for processing: 2
test/fields/collections/SlugField/int.spec.ts
test/fields/int.spec.ts
Files with no reviewable changes: 1
test/fields/int.spec.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requires #19349
Moves the existing slug field integration tests from
test/fields/int.spec.tsintotest/fields/collections/SlugField/int.spec.ts, alongside the existing slug-specific tests.