Skip to content

Commit 4d8d02e

Browse files
authored
Merge pull request #397 from netbox-community/SkipStartupScriptsForUnitTests
Skip Startup Scripts in Unit Tests
2 parents 323e182 + f810d03 commit 4d8d02e

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

docker-compose.test.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ services:
77
- redis
88
- redis-cache
99
env_file: env/netbox.env
10+
environment:
11+
SKIP_STARTUP_SCRIPTS: ${SKIP_STARTUP_SCRIPTS-false}
1012
user: '101'
1113
volumes:
1214
- ./startup_scripts:/opt/netbox/startup_scripts:z,ro

test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ test_setup() {
5656

5757
test_netbox_unit_tests() {
5858
echo "⏱ Running Netbox Unit Tests"
59-
$doco run --rm netbox ./manage.py test
59+
SKIP_STARTUP_SCRIPTS=true $doco run --rm netbox ./manage.py test
6060
}
6161

6262
test_initializers() {

0 commit comments

Comments
 (0)