Tests: Add commands for openid tests to makefile

This commit is contained in:
theresa 2021-12-13 15:29:36 +01:00
parent d39cc9e1de
commit a68f6c1bef

View file

@ -31,10 +31,12 @@ test-api: reset-testdb run-test-api
test-short: reset-testdb run-test-short
acceptance-private-run-chromium: acceptance-private-restart acceptance-private acceptance-private-stop
acceptance-public-run-chromium: acceptance-restart acceptance acceptance-stop
acceptance-openid-run-chromium: acceptance-openid-restart acceptance-openid acceptance-openid-stop
acceptance-private-run-firefox: acceptance-private-restart acceptance-private-firefox acceptance-private-stop
acceptance-public-run-firefox: acceptance-restart acceptance-firefox acceptance-stop
acceptance-run-chromium: acceptance-private-restart acceptance-private acceptance-private-stop acceptance-restart acceptance acceptance-stop
acceptance-run-firefox: acceptance-private-restart acceptance-private-firefox acceptance-private-stop acceptance-restart acceptance-firefox acceptance-stop
acceptance-openid-run-firefox: acceptance-openid-restart acceptance-openid-firefox acceptance-openid-stop
acceptance-run-chromium: acceptance-private-restart acceptance-private acceptance-private-stop acceptance-restart acceptance acceptance-stop acceptance-openid-restart acceptance-openid acceptance-openid-stop
acceptance-run-firefox: acceptance-private-restart acceptance-private-firefox acceptance-private-stop acceptance-restart acceptance-firefox acceptance-stop acceptance-openid-restart acceptance-openid-firefox acceptance-openid-stop
test-all: test acceptance-run-chromium
fmt: fmt-js fmt-go
upgrade: dep-upgrade-js dep-upgrade
@ -59,15 +61,21 @@ acceptance-restart:
rm -rf storage/acceptance/originals/2011
rm -rf storage/acceptance/originals/2013
rm -rf storage/acceptance/originals/2017
go run cmd/photoprism/photoprism.go --public --upload-nsfw=false --database-driver sqlite --database-dsn ./storage/acceptance/index.db --import-path ./storage/acceptance/import --http-port=2343 --config-path ./storage/acceptance/config --originals-path ./storage/acceptance/originals --storage-path ./storage/acceptance --test --backup-path ./storage/acceptance/backup --disable-backups start -d
go run cmd/photoprism/photoprism.go --public --upload-nsfw=false --database-driver="sqlite" --database-dsn="./storage/acceptance/index.db" --import-path="./storage/acceptance/import" --http-port=2343 --config-path="./storage/acceptance/config" --originals-path="./storage/acceptance/originals" --storage-path="./storage/acceptance" --test --backup-path="./storage/acceptance/backup" --disable-backups start -d
acceptance-stop:
go run cmd/photoprism/photoprism.go --public --upload-nsfw=false --database-driver sqlite --database-dsn ./storage/acceptance/index.db --import-path ./storage/acceptance/import --http-port=2343 --config-path ./storage/acceptance/config --originals-path ./storage/acceptance/originals --storage-path ./storage/acceptance --test --backup-path ./storage/acceptance/backup --disable-backups stop
go run cmd/photoprism/photoprism.go --public --upload-nsfw=false --database-driver="sqlite" --database-dsn="./storage/acceptance/index.db" --import-path="./storage/acceptance/import" --http-port=2343 --config-path="./storage/acceptance/config" --originals-path="./storage/acceptance/originals" --storage-path="./storage/acceptance" --test --backup-path="./storage/acceptance/backup" --disable-backups stop
acceptance-private-restart:
cp -f storage/acceptance/backup.db storage/acceptance/index.db
cp -f storage/acceptance/config/settingsBackup.yml storage/acceptance/config/settings.yml
go run cmd/photoprism/photoprism.go --oidc-issuer-url="" --oidc-client-id="" --oidc-client-secret="" --public=false --upload-nsfw=false --database-driver sqlite --database-dsn ./storage/acceptance/index.db --import-path ./storage/acceptance/import --http-port=2343 --config-path ./storage/acceptance/config --originals-path ./storage/acceptance/originals --storage-path ./storage/acceptance --test --backup-path ./storage/acceptance/backup --disable-backups start -d
go run cmd/photoprism/photoprism.go --oidc-issuer-url="" --oidc-client-id="" --oidc-client-secret="" --public=false --upload-nsfw=false --database-driver="sqlite" --database-dsn="./storage/acceptance/index.db" --import-path="./storage/acceptance/import" --http-port=2343 --config-path="./storage/acceptance/config" --originals-path="./storage/acceptance/originals" --storage-path="./storage/acceptance" --test --backup-path="./storage/acceptance/backup" --disable-backups start -d
acceptance-private-stop:
go run cmd/photoprism/photoprism.go --oidc-issuer-url="" --oidc-client-id="" --oidc-client-secret="" --public=false --upload-nsfw=false --database-driver sqlite --database-dsn ./storage/acceptance/index.db --import-path ./storage/acceptance/import --http-port=2343 --config-path ./storage/acceptance/config --originals-path ./storage/acceptance/originals --storage-path ./storage/acceptance --test --backup-path ./storage/acceptance/backup --disable-backups stop
go run cmd/photoprism/photoprism.go --oidc-issuer-url="" --oidc-client-id="" --oidc-client-secret="" --public=false --upload-nsfw=false --database-driver="sqlite" --database-dsn="./storage/acceptance/index.db" --import-path="./storage/acceptance/import" --http-port=2343 --config-path="./storage/acceptance/config" --originals-path="./storage/acceptance/originals" --storage-path="./storage/acceptance" --test --backup-path="./storage/acceptance/backup" --disable-backups stop
acceptance-openid-restart:
cp -f storage/acceptance/backup.db storage/acceptance/index.db
cp -f storage/acceptance/config/settingsBackup.yml storage/acceptance/config/settings.yml
go run cmd/photoprism/photoprism.go --public=false --upload-nsfw=false --database-driver="sqlite" --database-dsn="./storage/acceptance/index.db" --import-path="./storage/acceptance/import" --http-port=2342 --config-path="./storage/acceptance/config" --originals-path="./storage/acceptance/originals" --storage-path="./storage/acceptance" --test --backup-path="./storage/acceptance/backup" --disable-backups start -d
acceptance-openid-stop:
go run cmd/photoprism/photoprism.go --public=false --upload-nsfw=false --database-driver="sqlite" --database-dsn="./storage/acceptance/index.db" --import-path="./storage/acceptance/import" --http-port=2342 --config-path="./storage/acceptance/config" --originals-path="./storage/acceptance/originals" --storage-path="./storage/acceptance" --test --backup-path="./storage/acceptance/backup" --disable-backups stop
start:
go run cmd/photoprism/photoprism.go start -d
stop:
@ -158,6 +166,12 @@ acceptance-private:
acceptance-private-firefox:
$(info Running JS acceptance-private tests in Firefox...)
(cd frontend && npm run acceptance-private-firefox && cd ..)
acceptance-openid:
$(info Running JS acceptance-private tests in Chrome...)
(cd frontend && npm run acceptance-openid && cd ..)
acceptance-openid-firefox:
$(info Running JS acceptance-private tests in Firefox...)
(cd frontend && npm run acceptance-openid-firefox && cd ..)
reset-mariadb:
$(info Resetting photoprism database...)
mysql < scripts/sql/reset-mariadb.sql