]> Untitled Git - lemmy.git/commitdiff
Fixing travis, adding a test.sh script.
authorDessalines <tyhou13@gmx.com>
Fri, 10 Jul 2020 18:16:42 +0000 (14:16 -0400)
committerDessalines <tyhou13@gmx.com>
Fri, 10 Jul 2020 18:16:42 +0000 (14:16 -0400)
.travis.yml
docs/src/contributing_tests.md
server/test.sh [new file with mode: 0755]

index 602a8613dc62ce4e27f38ed5bbf0221ad94057ef..71fbac3ff415a4292146f48adba358bc03351242 100644 (file)
@@ -24,7 +24,7 @@ script:
   - cargo clippy -- -D clippy::style -D clippy::correctness -D clippy::complexity -D clippy::perf
   - cargo install diesel_cli --no-default-features --features postgres --force
   - diesel migration run
-  - cargo test
+  - cargo test --workspace
 env:
   global:
     - DATABASE_URL=postgres://lemmy:password@localhost:5432/lemmy
index ccce67250d7cedfef4398c45fd51d95c84e85a2f..d4168e190608039732b28414ab03ccaa8f8ba85a 100644 (file)
@@ -7,9 +7,7 @@ following commands in the `server` subfolder:
 
 ```bash
 psql -U lemmy -c "DROP SCHEMA public CASCADE; CREATE SCHEMA public;"
-export DATABASE_URL=postgres://lemmy:password@localhost:5432/lemmy
-diesel migration run
-RUST_TEST_THREADS=1 cargo test --workspace
+./test.sh
 ```
 
 ### Federation
diff --git a/server/test.sh b/server/test.sh
new file mode 100755 (executable)
index 0000000..9a8e445
--- /dev/null
@@ -0,0 +1,5 @@
+#!/bin/sh
+export DATABASE_URL=postgres://lemmy:password@localhost:5432/lemmy
+diesel migration run
+export LEMMY_DATABASE_URL=postgres://lemmy:password@localhost:5432/lemmy
+RUST_TEST_THREADS=1 cargo test --workspace