Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F9337519
D8306.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Subscribers
None
D8306.diff
View Options
diff --git a/Makefile.local b/Makefile.local
--- a/Makefile.local
+++ b/Makefile.local
@@ -37,7 +37,7 @@
.PHONY: run-migrations-test
run-migrations-test:
- rm -f swh-web-test.sqlite3
+ rm -f /dev/shm/swh-web-test.sqlite3
django-admin migrate --settings=$(SETTINGS_TEST) -v0
add-users-test: run-migrations-test
diff --git a/cypress/plugins/index.js b/cypress/plugins/index.js
--- a/cypress/plugins/index.js
+++ b/cypress/plugins/index.js
@@ -35,7 +35,7 @@
};
function getDatabase() {
- const db = new sqlite3.Database('./swh-web-test.sqlite3');
+ const db = new sqlite3.Database('/dev/shm/swh-web-test.sqlite3');
// to prevent "database is locked" error when running tests
db.run('PRAGMA journal_mode = WAL;');
return db;
diff --git a/swh/web/settings/tests.py b/swh/web/settings/tests.py
--- a/swh/web/settings/tests.py
+++ b/swh/web/settings/tests.py
@@ -127,7 +127,10 @@
# using sqlite3 for frontend tests
settings.DATABASES["default"].update(
- {"ENGINE": "django.db.backends.sqlite3", "NAME": "swh-web-test.sqlite3"}
+ {
+ "ENGINE": "django.db.backends.sqlite3",
+ "NAME": "/dev/shm/swh-web-test.sqlite3",
+ }
)
# to prevent "database is locked" error when running cypress tests
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Jul 3 2025, 8:08 AM (10 w, 1 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3220158
Attached To
D8306: sqlite: Create swh-web database in /tmp when running cypress tests
Event Timeline
Log In to Comment