Browse Source

Revert "Break down jenkins file steps"

This reverts commit 7e0c189070.
Shalom Yerushalmy 6 years ago
parent
commit
7942f69bec
1 changed files with 15 additions and 13 deletions
  1. 15
    13
      Jenkinsfile

+ 15
- 13
Jenkinsfile View File

4
     stage('Install npm packages') {
4
     stage('Install npm packages') {
5
       steps {
5
       steps {
6
       ansiColor('xterm') {
6
       ansiColor('xterm') {
7
-        sh 'source ~/.bashrc'
7
+        sh '''#!/bin/bash -ex
8
+        source ~/.bashrc
9
+        npm install
10
+        npm run clean'''
8
         }
11
         }
9
-        sh 'npm install'
10
-        sh 'npm run clean'
11
       }
12
       }
12
     }
13
     }
13
     stage('Run All Tests') {
14
     stage('Run All Tests') {
14
       parallel {
15
       parallel {
15
         stage('Run test-js') {
16
         stage('Run test-js') {
16
           steps {
17
           steps {
17
-            sh 'source ~/.bashrc'
18
-            sh 'npm run test-js'
18
+            sh '''#!/bin/bash
19
+            source ~/.bashrc
20
+            npm run test-js'''
19
           }
21
           }
20
         }
22
         }
21
         stage('Run IOS tests') {
23
         stage('Run IOS tests') {
22
           steps {
24
           steps {
23
-            sh 'source ~/.bashrc'
24
-            ansiColor('xterm') {
25
-              sh 'npm run test-unit-ios -- --release'
26
-            }
27
-            sh 'npm run test-e2e-ios -- --release'
25
+            sh '''#!/bin/bash
26
+            source ~/.bashrc
27
+            npm run test-unit-ios -- --release
28
+            npm run test-e2e-ios -- --release'''
28
           }
29
           }
29
         }
30
         }
30
         stage('Run android tests') {
31
         stage('Run android tests') {
31
           steps {
32
           steps {
32
-            sh 'source ~/.bashrc'
33
-            sh 'npm run test-unit-android -- --release'
34
-            sh 'npm run test-e2e-android -- --release'
33
+            sh '''#!/bin/bash
34
+            source ~/.bashrc
35
+            npm run test-unit-android -- --release
36
+            npm run test-e2e-android -- --release'''
35
           }
37
           }
36
         }
38
         }
37
       }
39
       }