Class WorkingDirectoryChangesDetector
java.lang.Object
org.springframework.modulith.junit.diff.WorkingDirectoryChangesDetector
- All Implemented Interfaces:
FileModificationDetector
A
FileModificationDetector that filters the ModifiedFile instances returned by a delegate
FileModificationDetector to only contain those nested in the current, repository-relative working directory.- Since:
- 1.3
- Author:
- Oliver Drotbohm
-
Field Summary
Fields inherited from interface org.springframework.modulith.junit.diff.FileModificationDetector
CONFIG_PROPERTY_PREFIX, log -
Constructor Summary
ConstructorsConstructorDescriptionWorkingDirectoryChangesDetector(FileModificationDetector delegate, String workingDirectory) Creates a newWorkingDirectoryChangesDetectorfor the givenFileModificationDetectordelegate and directory; -
Method Summary
Modifier and TypeMethodDescriptionReturns allModifiedFiles detected.of(FileModificationDetector delegate) Creates a newWorkingDirectoryChangesDetectorfor the current Git repository-relative working directory.
-
Constructor Details
-
WorkingDirectoryChangesDetector
WorkingDirectoryChangesDetector(FileModificationDetector delegate, String workingDirectory) Creates a newWorkingDirectoryChangesDetectorfor the givenFileModificationDetectordelegate and directory;- Parameters:
delegate- must not be null.workingDirectory- must not be null.
-
-
Method Details
-
of
Creates a newWorkingDirectoryChangesDetectorfor the current Git repository-relative working directory.- Parameters:
delegate- must not be null.- Returns:
- will never be null.
-
getModifiedFiles
Description copied from interface:FileModificationDetectorReturns allModifiedFiles detected.- Specified by:
getModifiedFilesin interfaceFileModificationDetector- Returns:
- will never be null.
-