Conversation
There was a problem hiding this comment.
Pull request overview
This PR tightens NeTEx ID handling around predicates/builders/parsers, adds regression and branch-coverage tests, and introduces a repository skill file for Java development guidance.
Changes:
- Fixes predicate null-handling/exception paths and aligns a few public messages/constants/API signatures.
- Adds builder/parser conveniences such as building from an existing ID and seeding string interning from a broader collection type.
- Expands unit tests across predicates, validators, parsers, and builders; adds a
java-developerskill document.
Reviewed changes
Copilot reviewed 20 out of 20 changed files in this pull request and generated 9 comments.
Show a summary per file
| File | Description |
|---|---|
src/test/java/no/entur/abt/netex/id/predicate/NetexIdPredicateBuilderTest.java |
Adds predicate-builder regression tests for null handling and empty builder state. |
src/test/java/no/entur/abt/netex/id/predicate/NetexIdCodespaceTypePredicateTest.java |
Adds predicate-focused branch/exception tests. |
src/test/java/no/entur/abt/netex/id/NetexIdValidatingParserTest.java |
Adds validating parser coverage for invalid codespace parsing. |
src/test/java/no/entur/abt/netex/id/NetexIdParserBuilderTest.java |
Adds parser-builder coverage for seeded interning with a collection input. |
src/test/java/no/entur/abt/netex/id/NetexIdNonValidatingBuilderTest.java |
Adds happy-path tests for building from an existing ID template. |
src/test/java/no/entur/abt/netex/id/NetexIdBuilderTest.java |
Adds validating-builder tests for null/invalid template IDs. |
src/test/java/no/entur/abt/netex/id/DefaultNetexIdValidatorTest.java |
Expands validator branch coverage for null, casing, digits, offsets, and malformed IDs. |
src/main/java/no/entur/abt/netex/id/predicate/NetexIdTypeValidatingPredicate.java |
Refactors validating type predicate exception flow. |
src/main/java/no/entur/abt/netex/id/predicate/NetexIdTypePredicate.java |
Adds null short-circuiting for non-validating type predicate. |
src/main/java/no/entur/abt/netex/id/predicate/NetexIdPredicateBuilder.java |
Updates type validation error text. |
src/main/java/no/entur/abt/netex/id/predicate/NetexIdCodespaceValidatingPredicate.java |
Refactors validating codespace predicate exception flow. |
src/main/java/no/entur/abt/netex/id/predicate/NetexIdCodespaceTypeValidatingPredicate.java |
Refactors validating codespace+type predicate exception flow. |
src/main/java/no/entur/abt/netex/id/predicate/NetexIdCodespaceTypePredicate.java |
Adds null short-circuiting for non-validating codespace+type predicate. |
src/main/java/no/entur/abt/netex/id/predicate/NetexIdCodespacePredicate.java |
Fixes predicate Javadoc wording. |
src/main/java/no/entur/abt/netex/id/NetexIdValidator.java |
Documents the deprecated offset-based validate overload. |
src/main/java/no/entur/abt/netex/id/NetexIdTypes.java |
Deprecates a typoed constant and adds the corrected alias. |
src/main/java/no/entur/abt/netex/id/NetexIdParserBuilder.java |
Broadens interning-seed API from Set to Collection and updates docs. |
src/main/java/no/entur/abt/netex/id/NetexIdNonValidatingBuilder.java |
Adds template-based builder construction from an existing ID. |
src/main/java/no/entur/abt/netex/id/InterningNetexIdParser.java |
Switches the interning cache to ConcurrentHashMap and simplifies insertion logic. |
.github/skills/java-developer/SKILL.md |
Adds project-specific Java development guidance for the repository skill system. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
… tests Agent-Logs-Url: https://github.com/entur/netex-utils/sessions/04217e4e-fea3-481d-b30f-5c9402e3be45 Co-authored-by: skjolber <1031478+skjolber@users.noreply.github.com>
…add null predicate tests Agent-Logs-Url: https://github.com/entur/netex-utils/sessions/7c46646c-cbdd-4b39-98c9-aebe97c6d474 Co-authored-by: skjolber <1031478+skjolber@users.noreply.github.com>
# Conflicts: # src/main/java/no/entur/abt/netex/id/InterningNetexIdParser.java Co-authored-by: skjolber <1031478+skjolber@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 21 out of 21 changed files in this pull request and generated 5 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 21 out of 21 changed files in this pull request and generated 6 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Should be 100% test coverage for package
no.entur.abt.netex.idandno.entur.abt.netex.id.predicate.Merge this branch last.