Skip to content

Commit dee7e8c

Browse files
greenkeeper[bot]maxbeatty
authored andcommitted
Update dependencies to enable Greenkeeper 🌴 (#405)
* chore(package): update dependencies * docs(readme): add Greenkeeper badge * add greenkeeper-lockfile-update, fix lint * fix umzug breaking change * fix test errors * fix umzug tests
1 parent 1e1e086 commit dee7e8c

File tree

33 files changed

+1752
-1636
lines changed

33 files changed

+1752
-1636
lines changed

.travis.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,12 @@ language: node_js
1212
# env:
1313
# - NODE_ENV=test PORT=3000 MYSQL_USER=jsuser MYSQL_PASSWORD=jspass MYSQL_DATABASE=jsperf GITHUB_CALLBACK=http://localhost:3000 BELL_COOKIE_PASS=password-should-be-32-characters COOKIE_PASS=password-should-be-32-characters
1414

15+
before_install:
16+
- npm install -g greenkeeper-lockfile@1
17+
18+
before_script:
19+
- greenkeeper-lockfile-update
20+
1521
script:
1622
- npm test
1723
# - npm start &
@@ -20,5 +26,6 @@ script:
2026
# - npm run test-e2e
2127

2228
after_script:
29+
- greenkeeper-lockfile-upload
2330
- npm install -g codeclimate-test-reporter
2431
- codeclimate-test-reporter < lcov.info || echo "Could not upload code coverage to CodeClimate"

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# jsperf.com
22

3+
[![Greenkeeper badge](https://badges.greenkeeper.io/jsperf/jsperf.com.svg)](https://greenkeeper.io/)
4+
35
[![Build Status](https://travis-ci.org/jsperf/jsperf.com.svg?branch=master)](https://travis-ci.org/jsperf/jsperf.com) [![Test Coverage](https://codeclimate.com/github/jsperf/jsperf.com/badges/coverage.svg)](https://codeclimate.com/github/jsperf/jsperf.com) [![Code Climate](https://codeclimate.com/github/jsperf/jsperf.com/badges/gpa.svg)](https://codeclimate.com/github/jsperf/jsperf.com)
46

57
[Chat on `irc.freenode.net` in the `#jsperf` channel](https://webchat.freenode.net/?channels=jsperf).

client/ui.js

Lines changed: 42 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@
147147
while (target && !(id = target.id)) {
148148
target = target.parentNode;
149149
}
150-
index = id && --id.split('-')[1] || 0;
150+
index = (id && --id.split('-')[1]) || 0;
151151
ui.push(ui.benchmarks[index].reset());
152152
ui.running ? ui.render(index) : ui.run(runOptions);
153153
},
@@ -514,51 +514,51 @@
514514
ui.render(index);
515515
}
516516
})
517-
.on('start cycle', function () {
518-
ui.render();
519-
setHTML('run', texts.run.running);
520-
})
521-
.on('complete', function () {
522-
var benches = filter(ui.benchmarks, 'successful');
523-
var fastest = filter(benches, 'fastest');
524-
var slowest = filter(benches, 'slowest');
525-
526-
ui.render();
527-
setHTML('run', texts.run.again);
528-
setStatus(texts.status.again);
529-
530-
// highlight result cells
531-
_.each(benches, function (bench) {
532-
var cell = $(prefix + (_.indexOf(ui.benchmarks, bench) + 1));
533-
var fastestHz = getHz(fastest[0]);
534-
var hz = getHz(bench);
535-
var percent = (1 - (hz / fastestHz)) * 100;
536-
var span = cell.getElementsByTagName('span')[0];
537-
var text = 'fastest';
538-
539-
if (_.indexOf(fastest, bench) > -1) {
517+
.on('start cycle', function () {
518+
ui.render();
519+
setHTML('run', texts.run.running);
520+
})
521+
.on('complete', function () {
522+
var benches = filter(ui.benchmarks, 'successful');
523+
var fastest = filter(benches, 'fastest');
524+
var slowest = filter(benches, 'slowest');
525+
526+
ui.render();
527+
setHTML('run', texts.run.again);
528+
setStatus(texts.status.again);
529+
530+
// highlight result cells
531+
_.each(benches, function (bench) {
532+
var cell = $(prefix + (_.indexOf(ui.benchmarks, bench) + 1));
533+
var fastestHz = getHz(fastest[0]);
534+
var hz = getHz(bench);
535+
var percent = (1 - (hz / fastestHz)) * 100;
536+
var span = cell.getElementsByTagName('span')[0];
537+
var text = 'fastest';
538+
539+
if (_.indexOf(fastest, bench) > -1) {
540540
// mark fastest
541-
addClass(cell, text);
542-
} else {
543-
text = isFinite(hz)
544-
? formatNumber(percent < 1 ? percent.toFixed(2) : Math.round(percent)) + '% slower'
545-
: '';
541+
addClass(cell, text);
542+
} else {
543+
text = isFinite(hz)
544+
? formatNumber(percent < 1 ? percent.toFixed(2) : Math.round(percent)) + '% slower'
545+
: '';
546546

547-
// mark slowest
548-
if (_.indexOf(slowest, bench) > -1) {
549-
addClass(cell, 'slowest');
547+
// mark slowest
548+
if (_.indexOf(slowest, bench) > -1) {
549+
addClass(cell, 'slowest');
550+
}
550551
}
551-
}
552-
// write ranking
553-
if (span) {
554-
setHTML(span, text);
555-
} else {
556-
appendHTML(cell, '<span>' + text + '</span>');
557-
}
558-
});
552+
// write ranking
553+
if (span) {
554+
setHTML(span, text);
555+
} else {
556+
appendHTML(cell, '<span>' + text + '</span>');
557+
}
558+
});
559559

560-
ui.browserscope.post();
561-
});
560+
ui.browserscope.post();
561+
});
562562

563563
/* ------------------------------------------------------------------------ */
564564

gulpfile.js

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -36,45 +36,45 @@ gulp.task('js', function () {
3636

3737
// list in reverse order since prepending
3838
// use `require.resolve` so you get file path and not file contents
39-
.pipe(addSrc.prepend('client/ui.js'))
40-
.pipe(addSrc.prepend(require.resolve('benchmark')))
41-
.pipe(addSrc.prepend(require.resolve('platform')))
42-
.pipe(addSrc.prepend(require.resolve('lodash')))
39+
.pipe(addSrc.prepend('client/ui.js'))
40+
.pipe(addSrc.prepend(require.resolve('benchmark')))
41+
.pipe(addSrc.prepend(require.resolve('platform')))
42+
.pipe(addSrc.prepend(require.resolve('lodash')))
4343

44-
.pipe(concat('test.js'))
44+
.pipe(concat('test.js'))
4545
// jsPerf is browser-only. Ensure we’re detected as a browser environment,
4646
// even if this is an AMD test, for example.
47-
.pipe(replace(/freeDefine = (?:[^;]+)/, 'freeDefine = false'))
48-
.pipe(replace(/freeExports = (?:[^;]+)/, 'freeExports = false'))
49-
.pipe(replace(/freeModule = (?:[^;]+)/, 'freeModule = false'))
50-
.pipe(replace(/freeRequire = (?:[^;]+)/, 'freeRequire = false'))
51-
.pipe(replace(/(if\s*\()(typeof define|freeDefine)\b/, '$1false'))
47+
.pipe(replace(/freeDefine = (?:[^;]+)/, 'freeDefine = false'))
48+
.pipe(replace(/freeExports = (?:[^;]+)/, 'freeExports = false'))
49+
.pipe(replace(/freeModule = (?:[^;]+)/, 'freeModule = false'))
50+
.pipe(replace(/freeRequire = (?:[^;]+)/, 'freeRequire = false'))
51+
.pipe(replace(/(if\s*\()(typeof define|freeDefine)\b/, '$1false'))
5252

5353
// Specify the correct path to our CSS file.
54-
.pipe(replace(`href = 'main.css'`, `href = '/public/_css/main.src.css'`))
54+
.pipe(replace(`href = 'main.css'`, `href = '/public/_css/main.src.css'`))
5555

5656
// Set the CSS selector for the Browserscope results.
57-
.pipe(replace(`'selector': ''`, `'selector': '#bs-results'`))
57+
.pipe(replace(`'selector': ''`, `'selector': '#bs-results'`))
5858

5959
// Avoid exposing `_` and `platform` as global variables.
60-
.pipe(insert.wrap(
61-
'(function(){var _,platform;',
62-
'}.call(this))'
63-
))
64-
.pipe(replace('root.platform = parse()', 'platform = parse()'))
65-
.pipe(replace('var _ = runInContext()', '_ = runInContext()'))
66-
.pipe(replace(`var _ = context && context._ || require('lodash') || root._;`, ''))
67-
.pipe(replace('(freeWindow || freeSelf || {})._ = _', ''))
68-
.pipe(replace('root._ = _', ''))
60+
.pipe(insert.wrap(
61+
'(function(){var _,platform;',
62+
'}.call(this))'
63+
))
64+
.pipe(replace('root.platform = parse()', 'platform = parse()'))
65+
.pipe(replace('var _ = runInContext()', '_ = runInContext()'))
66+
.pipe(replace(`var _ = context && context._ || require('lodash') || root._;`, ''))
67+
.pipe(replace('(freeWindow || freeSelf || {})._ = _', ''))
68+
.pipe(replace('root._ = _', ''))
6969

7070
// Ensure that Benchmark.js uses the local copies of lodash and Platform.js.
71-
.pipe(replace(`var _ = context && context._ || req('lodash') || root._;`, ''))
72-
.pipe(replace(`'platform': context.platform`, `'platform': platform`))
71+
.pipe(replace(`var _ = context && context._ || req('lodash') || root._;`, ''))
72+
.pipe(replace(`'platform': context.platform`, `'platform': platform`))
7373

7474
// Minify the result.
7575
// .pipe(uglify())
7676

77-
.pipe(gulp.dest('./public/_js/'));
77+
.pipe(gulp.dest('./public/_js/'));
7878
});
7979

8080
gulp.task('css', function () {

0 commit comments

Comments
 (0)