aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/test.yml10
-rw-r--r--.gitlab-ci.yml73
-rwxr-xr-xscripts/ci.sh2
3 files changed, 7 insertions, 78 deletions
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 6b9119e2a..9c90e6437 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -21,10 +21,15 @@ jobs:
21 POSTGRES_USER: peertube 21 POSTGRES_USER: peertube
22 POSTGRES_HOST_AUTH_METHOD: trust 22 POSTGRES_HOST_AUTH_METHOD: trust
23 23
24 ldap:
25 image: rroemhild/test-openldap
26 ports:
27 - 389:389
28
24 strategy: 29 strategy:
25 fail-fast: false 30 fail-fast: false
26 matrix: 31 matrix:
27 test_suite: [ misc, api-1, api-2, api-3, api-4, cli, lint ] 32 test_suite: [ misc, api-1, api-2, api-3, api-4, cli, lint, external-plugins ]
28 33
29 env: 34 env:
30 PGUSER: peertube 35 PGUSER: peertube
@@ -63,9 +68,6 @@ jobs:
63 - name: Install dependencies 68 - name: Install dependencies
64 run: yarn install --frozen-lockfile 69 run: yarn install --frozen-lockfile
65 70
66 - name: Test
67 run: echo $PATH
68
69 - name: Run Test 71 - name: Run Test
70 run: NODE_PENDING_JOB_WAIT=2000 npm run ci -- ${{ matrix.test_suite }} 72 run: NODE_PENDING_JOB_WAIT=2000 npm run ci -- ${{ matrix.test_suite }}
71 73
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 8deb07694..3891187e8 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -7,85 +7,12 @@ stages:
7 - docker-nightly 7 - docker-nightly
8 - external-plugins 8 - external-plugins
9 9
10#before_script:
11# - 'sed -i -z "s/database:\n hostname: ''localhost''/database:\n hostname: ''postgres''/" config/test.yaml'
12# - 'sed -i -z "s/redis:\n hostname: ''localhost''/redis:\n hostname: ''redis''/" config/test.yaml'
13# - if [[ $CI_JOB_STAGE == "test" ]]; then psql -c "create user peertube with password 'peertube';"; fi
14# - NOCLIENT=1 yarn install --pure-lockfile --cache-folder .yarn-cache
15
16cache: 10cache:
17 key: yarn 11 key: yarn
18 paths: 12 paths:
19 - .yarn-cache 13 - .yarn-cache
20 - cached-fixtures 14 - cached-fixtures
21 15
22###
23## Jobs templates
24#
25#.build-and-lint: &build-and-lint
26# stage: build-and-lint
27#
28#.tests: &tests
29# stage: test
30# dependencies:
31# - build-server
32# services:
33# - name: postgres:9.6
34# alias: postgres
35# - name: redis:latest
36# alias: redis
37# variables:
38# PGHOST: postgres
39# PGUSER: postgres
40# REDIS_HOST: redis
41# artifacts:
42# expire_in: 1 day
43# paths:
44# - test*/logs
45# when: always
46#
47####
48### Build and lint
49##
50#build-server:
51# <<: *build-and-lint
52# artifacts:
53# expire_in: 5h
54# paths:
55# - dist/
56# script:
57# - npm run build:server
58#
59#lint:
60# <<: *build-and-lint
61# script:
62# - yarn install --pure-lockfile --cache-folder .yarn-cache
63# - npm run ci -- "lint"
64#
65####
66### Tests
67#
68#test-misc:
69# <<: *tests
70# script:
71# - yarn install --pure-lockfile --cache-folder .yarn-cache
72# - npm run ci -- "misc"
73#
74#test-cli:
75# <<: *tests
76# retry:
77# max: 1
78# script:
79# - npm run ci -- "cli"
80#
81#api:
82# <<: *tests
83# parallel: 4
84# retry:
85# max: 1
86# script:
87# - NODE_PENDING_JOB_WAIT=1000 npm run ci -- api-$CI_NODE_INDEX
88
89build-openapi-clients: 16build-openapi-clients:
90 stage: clients 17 stage: clients
91 only: 18 only:
diff --git a/scripts/ci.sh b/scripts/ci.sh
index bf34cd337..df9d6d2b2 100755
--- a/scripts/ci.sh
+++ b/scripts/ci.sh
@@ -1,4 +1,4 @@
1#!/bin/sh 1#!/bin/bash
2 2
3set -eu 3set -eu
4 4