`unit-test-is-not-verb` incorrectly rejects valid verb test names in `Vocabulary.isVerb`

Open Beginner friendly
#1,533 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

@Thayorns is already working on this.

Since Oct 12, 2026.

  • #1551 by @Thayorns — open

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
76/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
java
Domain
tooling

Research direction

Start in src/main/java/org/eolang/lints/Vocabulary.java at line 95 and inspect how Vocabulary.isVerb interprets the word after “It can”. Review the skipped lint puzzle in eo-runtime/pom.xml for the affected examples. Done means valid verb-only names such as can-format-the-error-message-of-negative-places pass, while names like can-and-two-negatives and can-upper-case-text remain rejected.

Written by the indexing model from the issue text.

Description

bug good-title

Vocabulary.isVerb in src/main/java/org/eolang/lints/Vocabulary.java:95 tags "It" followed by the words of a test name, and after a modal it accepts the name only when the next tag is exactly VB. The perceptron model does not always give that tag to a word that can only be a verb in that position, so unit-test-is-not-verb rejects names like can-format-the-error-message-of-negative-places, can-print-a-single-character, can-scan-a-complex-integer, can-floor-a-negative-fraction or can-round-to-the-last-place.

After It can, English allows nothing but a verb, so the test name is right and the tag is wrong. eo-runtime/pom.xml in objectionary/eo keeps the lint skipped for this reason, with a puzzle naming format, print, scan and floor among the words it trips on. Renaming those tests to synonyms the model happens to like would not make them read better.

After a modal, an NN or NNS tag on the next word could be taken as a verb too, while CC, IN, DT and JJ stay rejected, so names with no verb at all, like can-and-two-negatives or can-upper-case-text, are still caught.

@yegor256

Dominant language
Java
Stars
14
Forks
40
Avg merge
3d 12h
Merged PRs (30d)
67

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from objectionary/lints

All issues in objectionary/lints

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.