Skip to content

Commit

Permalink
Split into testdocker and testwindows profiles
Browse files Browse the repository at this point in the history
  • Loading branch information
theotherp committed Nov 20, 2023
1 parent eb0e9a6 commit ac9af52
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 16 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/system-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ jobs:
matrix:
test: [ { port: 5076, name: core }, { port: 5077, name: v1Migration } ]
env:
spring_profiles_active: build,systemtest,${{ matrix.test.name }}
spring_profiles_active: build,systemtest,testdocker,${{ matrix.test.name }}
nzbhydra_port: ${{ matrix.test.port }}
nzbhydra.port: ${{ matrix.test.port }}
nzbhydra_name: ${{ matrix.test.name }}
Expand Down Expand Up @@ -173,7 +173,7 @@ jobs:
needs: [ waitForNative, buildMockserver ]
runs-on: windows-latest
env:
spring_profiles_active: build,systemtest,core
spring_profiles_active: build,systemtest,core,testwindows
nzbhydra_port: 5076
nzbhydra.port: 5076
nzbhydra_name: windows
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
main.useCsrf=false
nzbhydra.changelogUrl=http://mockserver:5080/changelog
nzbhydra.repositoryBaseUrl=http://mockserver:5080/repos/theotherp/nzbhydra2
nzbhydra.newsUrl=http://mockserver:5080/static/news.json
4 changes: 3 additions & 1 deletion tests/system/src/test/java/org/nzbhydra/NzbHandlingTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,9 @@ public void shouldSaveToBlackhole() throws Exception {
final String guid = searchResultProvider.findOneGuid();
hydraClient.put("/internalapi/saveNzbToBlackhole", guid);
final File[] files = new File(blackholeFolderTestAccess).listFiles();
assertThat(files).isNotEmpty();
assertThat(files)
.as("Expected files to exist in " + blackholeFolderTestAccess)
.isNotNull().isNotEmpty();
assertThat(files[0].getName()).endsWith(".nzb");
}

Expand Down
9 changes: 1 addition & 8 deletions tests/system/src/test/resources/application-build.properties
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
nzbhydra.mockUrl=http://mockserver:5080
sonarr.host=http://sonarr:8989
radarr.host=http://radarr:7878

#Where hydra is supposed to store NZBs
blackholeFolder.nzbhydra=/hydraBlackhole
#The folder under which the test can access the black hole
blackholeFolder.testaccess=/tmp/hydraBlackhole_${nzbhydra.name}

docker.host=unix:///var/run/docker.sock
radarr.host=http://radarr:7878
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#Where hydra is supposed to store NZBs
blackholeFolder.nzbhydra=/hydraBlackhole
#The folder under which the test can access the black hole
blackholeFolder.testaccess=/tmp/hydraBlackhole_${nzbhydra.name}

docker.host=unix:///var/run/docker.sock
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#Where hydra is supposed to store NZBs
blackholeFolder.nzbhydra=/hydraBlackhole
#The folder under which the test can access the black hole
blackholeFolder.testaccess=/hydraBlackhole
4 changes: 0 additions & 4 deletions tests/system/src/test/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,5 @@ nzbhydra.mockUrl=http://127.0.0.1:5080
spring.main.banner-mode=off
sonarr.host=http://127.0.0.1:8989
radarr.host=http://127.0.0.1:7878
#Where hydra is supposed to store NZBs
blackholeFolder.nzbhydra=${java.io.tmpdir}/hydraBlackhole
#The folder under which the test can access the black hole
blackholeFolder.testaccess=${java.io.tmpdir}/hydraBlackhole

docker.host=tcp://127.0.0.1:2376

0 comments on commit ac9af52

Please sign in to comment.