Skip to content

Commit 9c576cc

Browse files
author
Filipa Lacerda
committed
Merge branch 'ci-favicon-back-in' into 'master'
Added back in the CI status favicon See merge request !10534
2 parents 481f07e + fede01f commit 9c576cc

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

app/assets/javascripts/build.js

+2
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,8 @@ window.Build = (function () {
9090
success: ((log) => {
9191
const $buildContainer = $('.js-build-output');
9292

93+
gl.utils.setCiStatusFavicon(`${this.pageUrl}/status.json`);
94+
9395
if (log.state) {
9496
this.state = log.state;
9597
}

spec/javascripts/build_spec.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,9 @@ describe('Build', () => {
9898

9999
jasmine.clock().tick(4001);
100100

101-
expect($.ajax.calls.count()).toBe(2);
101+
expect($.ajax.calls.count()).toBe(3);
102102

103-
args = $.ajax.calls.argsFor(1)[0];
103+
args = $.ajax.calls.argsFor(2)[0];
104104
expect(args.url).toBe(`${BUILD_URL}/trace.json`);
105105
expect(args.dataType).toBe('json');
106106
expect(args.data.state).toBe('newstate');
@@ -133,7 +133,7 @@ describe('Build', () => {
133133
expect($('#build-trace .js-build-output').text()).toMatch(/Update/);
134134

135135
jasmine.clock().tick(4001);
136-
args = $.ajax.calls.argsFor(1)[0];
136+
args = $.ajax.calls.argsFor(2)[0];
137137
args.success.call($, {
138138
html: '<span>Different</span>',
139139
status: 'running',

0 commit comments

Comments
 (0)