Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Framasoft
PeerTube
PeerTube
Commits
18530063
Unverified
Commit
18530063
authored
Oct 31, 2017
by
Chocobozzz
Browse files
Try matrix to speed up travis builds
parent
7a8032bb
Changes
7
Hide whitespace changes
Inline
Side-by-side
.travis.yml
View file @
18530063
...
...
@@ -22,7 +22,6 @@ services:
-
postgresql
before_script
:
-
npm run build
-
wget --no-check-certificate "https://download.cpy.re/ffmpeg/ffmpeg-release-3.0.2-64bit-static.tar.xz"
-
tar xf ffmpeg-release-3.0.2-64bit-static.tar.xz
-
mkdir -p $HOME/bin
...
...
@@ -37,6 +36,16 @@ before_script:
-
psql -c 'create database peertube_test6;' -U postgres
-
psql -c "create user peertube with password 'peertube';" -U postgres
matrix
:
include
:
-
env
:
TEST_SUITE=build_then_client
-
env
:
TEST_SUITE=api
-
env
:
TEST_SUITE=cli
-
env
:
TEST_SUITE=lint
script
:
-
npm run travis -- "$TEST_SUITE"
after_failure
:
-
cat test1/logs/all-logs.log
-
cat test2/logs/all-logs.log
...
...
client/config/webpack.prod.js
View file @
18530063
...
...
@@ -167,7 +167,7 @@ module.exports = function (env) {
beautify
:
false
}
},
warnings
:
tru
e
warnings
Filter
:
()
=>
fals
e
}),
/**
...
...
client/package.json
View file @
18530063
...
...
@@ -13,7 +13,7 @@
"url"
:
"git://github.com/Chocobozzz/PeerTube.git"
},
"scripts"
:
{
"
tes
t"
:
"standard && tslint --type-check --project ./tsconfig.json -c ./tslint.json 'src/app/**/*.ts'"
,
"
lin
t"
:
"standard && tslint --type-check --project ./tsconfig.json -c ./tslint.json 'src/app/**/*.ts'"
,
"webpack"
:
"webpack"
,
"webpack-dev-server"
:
"webpack-dev-server"
,
"postinstall"
:
"npm rebuild node-sass"
...
...
package.json
View file @
18530063
...
...
@@ -44,7 +44,8 @@
"tsc"
:
"tsc"
,
"nodemon"
:
"
nodemon
"
,
"ts-node"
:
"
ts-node
"
,
"tslint"
:
"
tslint
"
"tslint"
:
"
tslint
"
,
"travis"
:
"scripty"
},
"dependencies"
:
{
"
async
"
:
"
^2.0.0
"
,
...
...
scripts/build/client.sh
View file @
18530063
#!/
usr/bin/env
sh
#!/
bin/ba
sh
cd
client
||
exit
-1
rm
-rf
./compiled
rm
-rf
./compiled
./dist
npm run webpack
--
--config
config/webpack.prod.js
--progress
--profile
--bail
scripts/test.sh
View file @
18530063
#!/bin/bash
npm run build:server
npm run build:server
||
exit
-1
cd
client
||
exit
-1
npm
test
||
exit
-1
cd
..
||
exit
-1
npm run tslint
--
--type-check
--project
./tsconfig.json
-c
./tslint.json server.ts
"server/**/*.ts"
||
exit
-1
mocha
--exit
--require
ts-node/register
--bail
server/tests/index.ts
npm run travis
--
client
||
exit
-1
npm run travis
--
api
||
exit
-1
npm run travis
--
cli
||
exit
-1
npm run travis
--
lint
||
exit
-1
scripts/travis.sh
0 → 100755
View file @
18530063
#!/bin/bash
if
[
$#
-eq
0
]
;
then
echo
"Need test suite argument."
exit
-1
fi
if
[
"
$1
"
=
"build_then_client"
]
;
then
npm run build
mocha
--exit
--require
ts-node/register
--bail
server/tests/client.ts
elif
[
"
$1
"
=
"client"
]
;
then
mocha
--exit
--require
ts-node/register
--bail
server/tests/client.ts
elif
[
"
$1
"
=
"api"
]
;
then
mocha
--exit
--require
ts-node/register
--bail
server/tests/api/index.ts
elif
[
"
$1
"
=
"cli"
]
;
then
mocha
--exit
--require
ts-node/register
--bail
server/tests/cli/index.ts
elif
[
"
$1
"
=
"lint"
]
;
then
cd
client
||
exit
-1
npm run lint
||
exit
-1
cd
..
||
exit
-1
npm run tslint
--
--type-check
--project
./tsconfig.json
-c
./tslint.json server.ts
"server/**/*.ts"
||
exit
-1
fi
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment