Skip to content

feat(analyzer): add MIG-019 rule for .properties config detection - #41

Merged
shossain786 merged 1 commit into
seleniumboot:mainfrom
Contributerr27:mig-019-properties-config
Nov 25, 2026
Merged

shossain786 merged 1 commit into
seleniumboot:mainfrom
Contributerr27:mig-019-properties-config

Conversation

@Contributerr27

Copy link
Copy Markdown
Contributor

What & why

Adds rule MIG-019 (MANUAL) to Analyzer.java: flags Properties.load(...) calls and .properties config loading via new FileInputStream("....properties") / getResourceAsStream("....properties"), with a label in Report.ruleLabel. New fixture src/test/resources/properties-config/Config.java and tests cover the acceptance criteria: the fixture gives a MIG-019 finding, a plain test class gives none. Analysis only; migrate does not touch these.

Closes #38

Type of change

  • New rule (MIG-xxx)

Checklist

  • mvn test passes
  • New behaviour is covered by a test
  • Nothing here modifies the user's original project (read-only by default)
  • Rules are AST-based and deterministic, not AI-generated transformations
  • Any new mapping was checked against the Selenium Boot docs first
  • If a new rule was added, the table in README.md was updated

Notes for reviewers

MIG-019 adds a finding only (MANUAL); no code mapping was added, so no mapping needed checking against the docs. The README rule table is not updated; happy to add it in a follow-up commit if you'd like.

@shossain786

Copy link
Copy Markdown
Contributor

Thanks @Contributerr27. This looks good and mvn clean verify passes locally. Two things before merge:

  • Detect ExtentReports usage in Java source #39 has merged and also adds a case to Report.ruleLabel, so this now conflicts in Report.java. Please rebase on main and keep both labels.
  • Please add a MIG-019 row to the rule table in the README, after MIG-018.

I've assigned #38 to you.

Flag Properties.load(...) calls and FileInputStream/getResourceAsStream literals ending in .properties as MANUAL findings, with a label in Report.ruleLabel. Closes seleniumboot#38.
@Contributerr27
Contributerr27 force-pushed the mig-019-properties-config branch from 53eea4b to cd0c4e6 Compare November 25, 2026 13:02
@Contributerr27

Copy link
Copy Markdown
Contributor Author

Thanks @shossain786. I rebased on main after #39 and kept both labels in Report.java (MIG-018 and MIG-019). I also added a MIG-019 row to the README rule table after MIG-018. mvn clean verify passes locally.

@shossain786
shossain786 merged commit 05acf22 into seleniumboot:main Nov 25, 2026
1 check passed
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.

Detect config loaded from .properties files (MIG-019)

2 participants