Skip to content
This repository was archived by the owner on Jun 11, 2025. It is now read-only.

Commit 2c74891

Browse files
authored
add demo shell integration test (#322)
* add demo shell integration test * increase timeout * deprecate 2.3.0 extension nodesApi
1 parent 3f1a4ce commit 2c74891

File tree

3 files changed

+67
-4
lines changed

3 files changed

+67
-4
lines changed

.travis.yml

Lines changed: 36 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,45 @@
11
language: node_js
2+
dist: trusty
3+
sudo: required
24
node_js:
3-
- "8.5.0"
4-
before_install: npm install -g grunt-cli
5+
- "8"
6+
7+
addons:
8+
chrome: stable
9+
before_script:
10+
- "sudo chown root /opt/google/chrome/chrome-sandbox"
11+
- "sudo chmod 4755 /opt/google/chrome/chrome-sandbox"
12+
13+
before_install:
14+
- export CHROME_BIN=chromium-browser
15+
- export DISPLAY=:99.0
16+
- sh -e /etc/init.d/xvfb start
17+
- npm install -g grunt-cli
18+
19+
520
install: npm install
6-
sudo: false
21+
722
cache:
823
directories:
924
- node_modules
10-
script: npm run test
25+
26+
env:
27+
matrix:
28+
- MODULE=alfresco-js-api
29+
30+
script:
31+
- if ([ "$MODULE" == "alfresco-js-api" ]); then
32+
npm run test
33+
fi
34+
35+
jobs:
36+
include:
37+
- stage: Check demo shell e2e test
38+
before_install:
39+
- "export DISPLAY=:99.0"
40+
- "sh -e /etc/init.d/xvfb start"
41+
script: travis_wait 30 ./scripts/test-demo-shell-adf.sh
42+
1143
after_success:
1244
- npm run coverage --force
1345
- bash <(curl -s https://codecov.io/bash)

scripts/test-demo-shell-adf.sh

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
#!/usr/bin/env bash
2+
3+
4+
TEMP_ADF_DIR=".tmp-demo-shell";
5+
6+
echo "====== Install JS-API ====="
7+
8+
npm install
9+
10+
echo "====== Link JS-API ====="
11+
12+
npm link
13+
14+
rm -rf $TEMP_ADF_DIR;
15+
16+
echo "====== CLONE ADF ====="
17+
18+
git clone https://$TOKEN@github.com/Alfresco/alfresco-ng2-components.git $TEMP_ADF_DIR
19+
cd $TEMP_ADF_DIR/demo-shell/
20+
git checkout development
21+
22+
echo "====== INSTALL Demo Shell ====="
23+
24+
npm install
25+
npm link alfresco-js-api
26+
27+
echo "====== E2E Demo Shell ====="
28+
npm run e2e || exit 1
29+
30+
rm -rf $TEMP_ADF_DIR;

src/alfrescoNode.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
var AlfrescoCoreRestApi = require('./alfresco-core-rest-api/src/index.js');
44

5+
// @deprecated 2.3.0
56
class AlfrescoNode extends AlfrescoCoreRestApi.NodesApi {
67

78
/**

0 commit comments

Comments
 (0)