Skip to content

Commit c582227

Browse files
committed
Bug 1088131 - Adding new raptor performance tests
1 parent 6ef93c4 commit c582227

6 files changed

+43
-2
lines changed

.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ manifest.appcache
4141
/profile-test/
4242
/profile-gaia-test-b2g/
4343
/profile-gaia-test-firefox/
44+
/profile-raptor/
4445
/profile.tar.gz
4546
/b2g_sdk/
4647
/tools/test-agent/node_modules
@@ -52,6 +53,7 @@ manifest.appcache
5253
/build_stage/
5354
/coverage/
5455
/local.mk
56+
/raptor.log
5557

5658
/tools/xpcwindow/vendor/
5759

@@ -61,6 +63,7 @@ manifest.appcache
6163
/node_modules/
6264
/.modules.tar
6365
ENV/
66+
.env
6467
modules.tar
6568
mozilla-b2g-gaia-node-modules-*
6669
/git-gaia-node-modules/

Makefile

+5-1
Original file line numberDiff line numberDiff line change
@@ -782,6 +782,10 @@ test-perf:
782782
REPORTER=$(REPORTER) \
783783
./bin/gaia-perf-marionette
784784

785+
.PHONY: raptor
786+
raptor: node_modules
787+
NO_LOCK_SCREEN=1 NOFTU=1 SCREEN_TIMEOUT=0 GAIA_DISTRIBUTION_DIR=node_modules/gaia-raptor/dist PROFILE_FOLDER=profile-raptor make reset-gaia
788+
785789
.PHONY: tests
786790
tests: app offline
787791
echo "Checking if the mozilla build has tests enabled..."
@@ -1023,7 +1027,7 @@ endif
10231027

10241028
# clean out build products
10251029
clean:
1026-
rm -rf profile profile-debug profile-test profile-gaia-test-b2g profile-gaia-test-firefox $(PROFILE_FOLDER) $(STAGE_DIR) docs minidumps
1030+
rm -rf profile profile-debug profile-test profile-gaia-test-b2g profile-gaia-test-firefox profile-raptor $(PROFILE_FOLDER) $(STAGE_DIR) docs minidumps
10271031

10281032
# clean out build products and tools
10291033
really-clean: clean

gaia_node_modules.revision

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
5d3091a0c3bb50ea51c753806cff7edcc184ab6e
1+
580c7090140eca853def29bf96b1067fe6a6dddc

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
"empty-port": "~0.0.1",
1818
"fe.js": "~0.1.4",
1919
"ffi-prebuilt": "~1.2.6",
20+
"gaia-raptor": "0.1.2",
2021
"grunt": "0.4.2",
2122
"grunt-contrib-clean": "0.5.0",
2223
"grunt-jsdoc": "0.5.1",

tests/raptor/boot_test.js

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
'use strict';
2+
3+
var raptor = require('gaia-raptor');
4+
5+
var options = {
6+
phase: 'reboot',
7+
runs: 1
8+
};
9+
10+
raptor(options, function(runner) {
11+
12+
runner.on('run', function(next) {
13+
next();
14+
});
15+
16+
});

tests/raptor/launch_test.js

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
'use strict';
2+
3+
var raptor = require('gaia-raptor');
4+
5+
var options = {
6+
phase: 'cold',
7+
runs: 1,
8+
apps: []
9+
};
10+
11+
raptor(options, function(runner) {
12+
13+
runner.on('run', function(next) {
14+
runner.closeApp().then(next);
15+
});
16+
17+
});

0 commit comments

Comments
 (0)