Is the file not analyzed, or simply no issues are reported (you can check SonarLint console in verbose mode to see if something is triggered when saving a change to the file).
My guess is that you are using a recent version of Eclipse, that has built-in support for test source folders. And most rules of SonarJava are not applied to test sources.
SonarLint analysis of project tutorial1 (19 files processed)…
File ‘src/test/java/net/serenity/tutorial/ui/SearchBox.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/model/Category.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/tasks/OpenTheApplication.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/steps/NavigatingUser.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/ui/CurrentPage.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/features/navigation/WhenBrowsingProductCategories.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/features/search/SearchByKeywordStory.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/test.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/ui/CategoryNavigationBar.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/tasks/Search.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/ui/EbayHomePage.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
File ‘src/test/java/net/serenity/tutorial/ui/GoogleSearchPage.java’ qualified as test by ‘JavaProjectConfiguratorExtension’
Standalone mode (project not bound)
Starting analysis with configuration: