test: guard apps against build-only modules
This commit is contained in:
@@ -10,6 +10,7 @@ import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.stream.Stream;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
@@ -43,6 +44,16 @@ class MavenModuleProfileTest {
|
||||
"modules/apps/xinda-push-app");
|
||||
}
|
||||
|
||||
@Test
|
||||
void appsDirectoryContainsOnlyRealMavenModules() throws Exception {
|
||||
try (Stream<Path> apps = Files.list(repositoryRoot().resolve("modules/apps"))) {
|
||||
assertThat(apps.filter(Files::isDirectory)
|
||||
.filter(path -> !Files.exists(path.resolve("pom.xml")))
|
||||
.map(path -> path.getFileName().toString()))
|
||||
.isEmpty();
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
void readmeMatchesCurrentRuntimeVersionsAndSplitAppResponsibilities() throws Exception {
|
||||
Document pom = rootPom();
|
||||
|
||||
Reference in New Issue
Block a user