Skip to content

test(#108): cover nested @ with phi-is-not-first - #1245

Open
VasilevNStas wants to merge 1 commit into
objectionary:masterfrom
VasilevNStas:fix/issue-108-phi-nested-at
Open

test(#108): cover nested @ with phi-is-not-first#1245
VasilevNStas wants to merge 1 commit into
objectionary:masterfrom
VasilevNStas:fix/issue-108-phi-nested-at

Conversation

@VasilevNStas

Copy link
Copy Markdown
Contributor

fix #108

What

A regression test for the exact case from the issue: a nested @
attribute (bar > @ inside a child object) is covered by the existing
names/phi-is-not-first lint.

Why

The parser lifts a nested @ up to the top level of its parent, where it
becomes a φ sibling that is never first (the container always precedes
it). The phi-is-not-first lint checks exactly that, so the confusing
code from the issue is already reported. The claim was made in
#108 (comment),
but was not backed by a test. This pack locks the behavior in, so a future
regression in the lint or in the parser would be caught by CI.

Changes

  • src/test/resources/org/eolang/lints/packs/single/phi-is-not-first/catches-nested-at.yaml — the new regression pack

Both mvn test (591 tests) and mvn clean install -Pqulice pass.

@VasilevNStas

Copy link
Copy Markdown
Contributor Author

@volodya-lombrozo plz review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

@ attribute is not at the highest level

1 participant