Package org.sonar.java.checks.verifier
Class TestUtils
java.lang.Object
org.sonar.java.checks.verifier.TestUtils
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic org.sonar.api.batch.fs.InputFileemptyInputFile(String filename) static org.sonar.api.batch.fs.InputFileemptyInputFile(String filename, org.sonar.api.batch.fs.InputFile.Type type) static org.sonar.api.batch.fs.InputFilestatic org.sonar.api.batch.fs.InputFilestatic org.sonar.api.batch.fs.InputFilestatic StringmainCodeSourcesPath(String path) To be used when testing rules targeting MAIN code.static StringmainCodeSourcesPathInModule(String module, String path) To be used when testing rules targeting MAIN code from a non-default module.static StringTo be used when testing rules behavior when bytecode is missing, partial, or code does not compile.static StringnonCompilingTestSourcesPathInModule(String module, String path) To be used when testing rules behavior when bytecode is missing, partial, or code does not compile.static StringtestCodeSourcesPath(String path) To be used when testing rules targeting TEST code.static StringtestCodeSourcesPathInModule(String module, String path) To be used when testing rules targeting TEST code from a non-default module.
-
Field Details
-
DEFAULT_MODULE
- See Also:
-
-
Method Details
-
mainCodeSourcesPath
To be used when testing rules targeting MAIN code. -
mainCodeSourcesPathInModule
To be used when testing rules targeting MAIN code from a non-default module. -
testCodeSourcesPath
To be used when testing rules targeting TEST code. -
testCodeSourcesPathInModule
To be used when testing rules targeting TEST code from a non-default module. -
nonCompilingTestSourcesPath
To be used when testing rules behavior when bytecode is missing, partial, or code does not compile. -
nonCompilingTestSourcesPathInModule
To be used when testing rules behavior when bytecode is missing, partial, or code does not compile. And the file is in a non-default module. -
emptyInputFile
-
emptyInputFile
public static org.sonar.api.batch.fs.InputFile emptyInputFile(String filename, org.sonar.api.batch.fs.InputFile.Type type) -
inputFile
-
inputFile
-
inputFile
-