diff --git a/.github/actions/close-bot/helpers.js b/.github/actions/close-bot/helpers.js index aa0854846f85c0e78cfa722dbafdd57a519a71dc..2f29e7750616a9a941bf720e2f70ff1739670473 100644 --- a/.github/actions/close-bot/helpers.js +++ b/.github/actions/close-bot/helpers.js @@ -28,7 +28,7 @@ function allChangelogLinesAreVersionBump(changelogLines) { changelogLines.length > 0 && changelogLines.length === changelogLines.filter(line => - line.includes('Version bump only for package') + line.includes('Version bump only for package'), ).length ) } @@ -52,14 +52,15 @@ function isPointlessVersionBump(body) { .filter(line => !line.startsWith('<h')) .filter(line => !line.startsWith('<p>All notable changes')) .filter( - line => !line.startsWith('See <a href="https://conventionalcommits.org">') + line => + !line.startsWith('See <a href="https://conventionalcommits.org">'), ) .filter(line => !line.startsWith('<!--')) .filter( line => !line.startsWith( - '<p><a href="https://www.gatsbyjs.com/docs/reference/release-notes/' - ) + '<p><a href="https://www.gatsbyjs.com/docs/reference/release-notes/', + ), ) return allChangelogLinesAreVersionBump(changelogLines) } diff --git a/badge-maker/CHANGELOG.md b/badge-maker/CHANGELOG.md index 619785c2300c267bc2af6fe551d93e52dd470d96..1c18294416a6c76bce5eacaf23f122435b539d4e 100644 --- a/badge-maker/CHANGELOG.md +++ b/badge-maker/CHANGELOG.md @@ -275,7 +275,7 @@ badge.loadFont('/path/to/Verdana.ttf', err => { { text: ['build', 'passed'], colorscheme: 'green', template: 'flat' }, (svg, err) => { // svg is a string containing your badge - } + }, ) }) ``` diff --git a/badge-maker/index.test-d.ts b/badge-maker/index.test-d.ts index 9897e0798188ad6119949ae9c8bf07026a03d7ef..7e9246cd975b361d77d911ea58d3dcf36b1a31fd 100644 --- a/badge-maker/index.test-d.ts +++ b/badge-maker/index.test-d.ts @@ -7,19 +7,19 @@ expectError( makeBadge({ message: 'passed', style: 'invalid style', - }) + }), ) expectType<string>( makeBadge({ message: 'passed', - }) + }), ) expectType<string>( makeBadge({ label: 'build', message: 'passed', - }) + }), ) expectType<string>( makeBadge({ @@ -28,7 +28,7 @@ expectType<string>( labelColor: 'green', color: 'red', style: 'flat', - }) + }), ) const error = new ValidationError() diff --git a/badge-maker/lib/badge-renderers.js b/badge-maker/lib/badge-renderers.js index 56e3792b8b6fb1b78f9c4a5823d0cdbe72a50587..af726101e08190f8bdf8564f03da271289b56de9 100644 --- a/badge-maker/lib/badge-renderers.js +++ b/badge-maker/lib/badge-renderers.js @@ -69,7 +69,7 @@ function getLogoElement({ logo, horizPadding, badgeHeight, logoWidth }) { function renderBadge( { links, leftWidth, rightWidth, height, accessibleText }, - content + content, ) { const width = leftWidth + rightWidth const leftLink = links[0] @@ -397,7 +397,7 @@ class Plastic extends Badge { accessibleText: this.accessibleText, height: this.constructor.height, }, - [gradient, clipPath, backgroundGroup, this.foregroundGroupElement] + [gradient, clipPath, backgroundGroup, this.foregroundGroupElement], ) } } @@ -446,7 +446,7 @@ class Flat extends Badge { accessibleText: this.accessibleText, height: this.constructor.height, }, - [gradient, clipPath, backgroundGroup, this.foregroundGroupElement] + [gradient, clipPath, backgroundGroup, this.foregroundGroupElement], ) } } @@ -478,7 +478,7 @@ class FlatSquare extends Badge { accessibleText: this.accessibleText, height: this.constructor.height, }, - [backgroundGroup, this.foregroundGroupElement] + [backgroundGroup, this.foregroundGroupElement], ) } } @@ -748,7 +748,7 @@ function social({ accessibleText, height: externalHeight, }, - [style, gradients, backgroundGroup, logoElement, foregroundGroup] + [style, gradients, backgroundGroup, logoElement, foregroundGroup], ) } @@ -978,7 +978,7 @@ function forTheBadge({ accessibleText: createAccessibleText({ label, message }), height: BADGE_HEIGHT, }, - [backgroundGroup, foregroundGroup] + [backgroundGroup, foregroundGroup], ) } diff --git a/badge-maker/lib/color.spec.js b/badge-maker/lib/color.spec.js index 65326f9d56854c63a3eeee0507046d58069ffd37..3adabee5e6b44f48669a8331ef6fb85cea40a31c 100644 --- a/badge-maker/lib/color.spec.js +++ b/badge-maker/lib/color.spec.js @@ -75,7 +75,7 @@ test(toSvgColor, () => { given('papayawhip').expect('papayawhip') given('purple').expect('purple') forCases([given(''), given(undefined), given('not-a-color')]).expect( - undefined + undefined, ) given('lightgray').expect('#9f9f9f') given('informational').expect('#007ec6') diff --git a/badge-maker/lib/index.js b/badge-maker/lib/index.js index f4eed2c5806cd8deca710870140609d27e895aa9..051c3d84e9c7b4afc9a8ffde24a30bebd41550de 100644 --- a/badge-maker/lib/index.js +++ b/badge-maker/lib/index.js @@ -32,7 +32,7 @@ function _validate(format) { ] if ('style' in format && !styleValues.includes(format.style)) { throw new ValidationError( - `Field \`style\` must be one of (${styleValues.toString()})` + `Field \`style\` must be one of (${styleValues.toString()})`, ) } } @@ -46,7 +46,7 @@ function _clean(format) { cleaned[key] = format[key] } else { throw new ValidationError( - `Unexpected field '${key}'. Allowed values are (${expectedKeys.toString()})` + `Unexpected field '${key}'. Allowed values are (${expectedKeys.toString()})`, ) } }) diff --git a/badge-maker/lib/index.spec.js b/badge-maker/lib/index.spec.js index 5242bc36ecb88ad7f20f3e10eb582bf0e39b34df..839aa061e4ff19298a2322ed519676973987bfa9 100644 --- a/badge-maker/lib/index.spec.js +++ b/badge-maker/lib/index.spec.js @@ -10,12 +10,12 @@ describe('makeBadge function', function () { makeBadge({ label: 'build', message: 'passed', - }) + }), ).to.satisfy(isSvg) expect( makeBadge({ message: 'passed', - }) + }), ).to.satisfy(isSvg) expect( makeBadge({ @@ -23,7 +23,7 @@ describe('makeBadge function', function () { message: 'passed', color: 'green', style: 'flat', - }) + }), ).to.satisfy(isSvg) }) @@ -32,44 +32,44 @@ describe('makeBadge function', function () { console.log(x) expect(() => makeBadge(x)).to.throw( ValidationError, - 'makeBadge takes an argument of type object' + 'makeBadge takes an argument of type object', ) }) expect(() => makeBadge({})).to.throw( ValidationError, - 'Field `message` is required' + 'Field `message` is required', ) expect(() => makeBadge({ label: 'build' })).to.throw( ValidationError, - 'Field `message` is required' + 'Field `message` is required', ) expect(() => - makeBadge({ label: 'build', message: 'passed', labelColor: 7 }) + makeBadge({ label: 'build', message: 'passed', labelColor: 7 }), ).to.throw(ValidationError, 'Field `labelColor` must be of type string') expect(() => - makeBadge({ label: 'build', message: 'passed', format: 'png' }) + makeBadge({ label: 'build', message: 'passed', format: 'png' }), ).to.throw(ValidationError, "Unexpected field 'format'") expect(() => - makeBadge({ label: 'build', message: 'passed', template: 'flat' }) + makeBadge({ label: 'build', message: 'passed', template: 'flat' }), ).to.throw(ValidationError, "Unexpected field 'template'") expect(() => - makeBadge({ label: 'build', message: 'passed', foo: 'bar' }) + makeBadge({ label: 'build', message: 'passed', foo: 'bar' }), ).to.throw(ValidationError, "Unexpected field 'foo'") expect(() => makeBadge({ label: 'build', message: 'passed', style: 'something else', - }) + }), ).to.throw( ValidationError, - 'Field `style` must be one of (plastic,flat,flat-square,for-the-badge,social)' + 'Field `style` must be one of (plastic,flat,flat-square,for-the-badge,social)', ) expect(() => - makeBadge({ label: 'build', message: 'passed', style: 'popout' }) + makeBadge({ label: 'build', message: 'passed', style: 'popout' }), ).to.throw( ValidationError, - 'Field `style` must be one of (plastic,flat,flat-square,for-the-badge,social)' + 'Field `style` must be one of (plastic,flat,flat-square,for-the-badge,social)', ) }) }) diff --git a/badge-maker/lib/make-badge.js b/badge-maker/lib/make-badge.js index 495dd4ecbef48b1e72c77707ccdc35121095e4e3..fd68199e64be98e5fc6d6f0c826cf3934556c6b1 100644 --- a/badge-maker/lib/make-badge.js +++ b/badge-maker/lib/make-badge.js @@ -58,6 +58,6 @@ module.exports = function makeBadge({ logoPadding: logo && label.length ? 3 : 0, color: toSvgColor(color), labelColor: toSvgColor(labelColor), - }) + }), ) } diff --git a/badge-maker/lib/make-badge.spec.js b/badge-maker/lib/make-badge.spec.js index 2492af9edaedc5b8a09e009d924137ad7081bf12..9170a3d37bc70887e1060315ce7afccbebcef1f1 100644 --- a/badge-maker/lib/make-badge.spec.js +++ b/badge-maker/lib/make-badge.spec.js @@ -6,8 +6,8 @@ const snapshot = require('snap-shot-it') const prettier = require('prettier') const makeBadge = require('./make-badge') -function expectBadgeToMatchSnapshot(format) { - snapshot(prettier.format(makeBadge(format), { parser: 'html' })) +async function expectBadgeToMatchSnapshot(format) { + snapshot(await prettier.format(makeBadge(format), { parser: 'html' })) } function testColor(color = '', colorAttr = 'color') { @@ -17,7 +17,7 @@ function testColor(color = '', colorAttr = 'color') { message: 'Bob', [colorAttr]: color, format: 'json', - }) + }), ).color } @@ -67,7 +67,7 @@ describe('The badge generator', function () { given('bluish'), given('almostred'), given('brightmaroon'), - given('cactus') + given('cactus'), ).expect(undefined) }) }) @@ -87,8 +87,8 @@ describe('The badge generator', function () { .and.to.include('grown') }) - it('should match snapshot', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshot', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -138,14 +138,14 @@ describe('The badge generator', function () { message: 'Bob', format: 'svg', style: 'unknown_style', - }) + }), ).to.throw(Error, "Unknown badge style: 'unknown_style'") }) }) describe('"flat" template badge generation', function () { - it('should match snapshots: message/label, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -155,8 +155,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -167,8 +167,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -177,8 +177,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -188,8 +188,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo and labelColor', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo and labelColor', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -200,8 +200,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with links', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with links', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -212,8 +212,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: black text when the label color is light', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: black text when the label color is light', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -223,8 +223,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: black text when the message color is light', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: black text when the message color is light', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -236,8 +236,8 @@ describe('The badge generator', function () { }) describe('"flat-square" template badge generation', function () { - it('should match snapshots: message/label, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -247,8 +247,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -259,8 +259,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -269,8 +269,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -280,8 +280,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo and labelColor', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo and labelColor', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -292,8 +292,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with links', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with links', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -304,8 +304,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: black text when the label color is light', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: black text when the label color is light', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -315,8 +315,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: black text when the message color is light', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: black text when the message color is light', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -328,8 +328,8 @@ describe('The badge generator', function () { }) describe('"plastic" template badge generation', function () { - it('should match snapshots: message/label, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -339,8 +339,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -351,8 +351,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -361,8 +361,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -372,8 +372,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo and labelColor', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo and labelColor', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -384,8 +384,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with links', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with links', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -396,8 +396,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: black text when the label color is light', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: black text when the label color is light', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -407,8 +407,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: black text when the message color is light', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: black text when the message color is light', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -428,7 +428,7 @@ describe('The badge generator', function () { message: 1999, format: 'svg', style: 'for-the-badge', - }) + }), ) .to.include('1998') .and.to.include('1999') @@ -441,14 +441,14 @@ describe('The badge generator', function () { message: '1 string', format: 'svg', style: 'for-the-badge', - }) + }), ) .to.include('LABEL') .and.to.include('1 STRING') }) - it('should match snapshots: message/label, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -458,8 +458,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -470,8 +470,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -480,8 +480,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -491,8 +491,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo and labelColor', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo and labelColor', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -503,8 +503,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with links', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with links', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -515,8 +515,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: black text when the label color is light', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: black text when the label color is light', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -526,8 +526,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: black text when the message color is light', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: black text when the message color is light', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -546,7 +546,7 @@ describe('The badge generator', function () { message: 'some-value', format: 'svg', style: 'social', - }) + }), ) .to.include('Some-key') .and.to.include('some-value') @@ -560,14 +560,14 @@ describe('The badge generator', function () { message: 'some-value', format: 'json', style: 'social', - }) + }), ) .to.include('""') .and.to.include('some-value') }) - it('should match snapshots: message/label, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -577,8 +577,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -589,8 +589,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, no logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, no logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -599,8 +599,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -610,8 +610,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message only, with logo and labelColor', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message only, with logo and labelColor', async function () { + await expectBadgeToMatchSnapshot({ label: '', message: 'grown', format: 'svg', @@ -622,8 +622,8 @@ describe('The badge generator', function () { }) }) - it('should match snapshots: message/label, with links', function () { - expectBadgeToMatchSnapshot({ + it('should match snapshots: message/label, with links', async function () { + await expectBadgeToMatchSnapshot({ label: 'cactus', message: 'grown', format: 'svg', @@ -636,8 +636,8 @@ describe('The badge generator', function () { }) describe('badges with logos should always produce the same badge', function () { - it('badge with logo', function () { - expectBadgeToMatchSnapshot({ + it('badge with logo', async function () { + await expectBadgeToMatchSnapshot({ label: 'label', message: 'message', format: 'svg', diff --git a/badge-maker/lib/xml.js b/badge-maker/lib/xml.js index 6d20c90ff5e1fc1d395ab049c9a5a47e3c2e3dd2..3e0ead1c56591f053362b85d663e1e67fbf9fe22 100644 --- a/badge-maker/lib/xml.js +++ b/badge-maker/lib/xml.js @@ -66,7 +66,7 @@ class XmlElement { }) .join(' ') return stripXmlWhitespace( - `<${this.name}${attrsStr}>${content}</${this.name}>` + `<${this.name}${attrsStr}>${content}</${this.name}>`, ) } return stripXmlWhitespace(`<${this.name}${attrsStr}/>`) @@ -88,7 +88,7 @@ class ElementList { typeof el.render === 'function' ? acc + el.render() : acc + escapeXml(el), - '' + '', ) } } diff --git a/core/badge-urls/path-helpers.spec.js b/core/badge-urls/path-helpers.spec.js index 88de5a4869ebdd106c0d617fc68c26f0724189b2..904660d1e517dea5953dafe70232c25229414fbe 100644 --- a/core/badge-urls/path-helpers.spec.js +++ b/core/badge-urls/path-helpers.spec.js @@ -7,7 +7,7 @@ describe('Badge URL helper functions', function () { given('single trailing underscore_').expect('single trailing underscore ') given('__double leading underscores').expect('_double leading underscores') given('double trailing underscores__').expect( - 'double trailing underscores_' + 'double trailing underscores_', ) given('treble___underscores').expect('treble_ underscores') given('fourfold____underscores').expect('fourfold__underscores') diff --git a/core/base-service/auth-helper.js b/core/base-service/auth-helper.js index 857bae76a06bf3f930fc764e1f6cd9a2579f42a9..ccfe2722a032e950bdc49d21c3da8a7fee523dc3 100644 --- a/core/base-service/auth-helper.js +++ b/core/base-service/auth-helper.js @@ -11,7 +11,7 @@ class AuthHelper { isRequired = false, defaultToEmptyStringForUser = false, }, - config + config, ) { if (!userKey && !passKey) { throw Error('Expected userKey or passKey to be set') @@ -142,7 +142,7 @@ class AuthHelper { withBasicAuth(requestParams) { return this._withAnyAuth(requestParams, requestParams => - this.constructor._mergeAuth(requestParams, this._basicAuth) + this.constructor._mergeAuth(requestParams, this._basicAuth), ) } @@ -172,13 +172,13 @@ class AuthHelper { withBearerAuthHeader( requestParams, - bearerKey = 'Bearer' // lgtm [js/hardcoded-credentials] + bearerKey = 'Bearer', // lgtm [js/hardcoded-credentials] ) { return this._withAnyAuth(requestParams, requestParams => this.constructor._mergeHeaders( requestParams, - this._bearerAuthHeader(bearerKey) - ) + this._bearerAuthHeader(bearerKey), + ), ) } @@ -204,7 +204,7 @@ class AuthHelper { this.constructor._mergeQueryParams(requestParams, { ...(userKey ? { [userKey]: this._user } : undefined), ...(passKey ? { [passKey]: this._pass } : undefined), - }) + }), ) } } diff --git a/core/base-service/auth-helper.spec.js b/core/base-service/auth-helper.spec.js index d9ada221e88903326d82547339d8d020a11cece3..4ea06374ec8c91ceb25b803df53974f0f4a5e7f7 100644 --- a/core/base-service/auth-helper.spec.js +++ b/core/base-service/auth-helper.spec.js @@ -8,12 +8,13 @@ describe('AuthHelper', function () { it('throws without userKey or passKey', function () { expect(() => new AuthHelper({}, {})).to.throw( Error, - 'Expected userKey or passKey to be set' + 'Expected userKey or passKey to be set', ) }) it('throws without serviceKey or authorizedOrigins', function () { expect( - () => new AuthHelper({ userKey: 'myci_user', passKey: 'myci_pass' }, {}) + () => + new AuthHelper({ userKey: 'myci_user', passKey: 'myci_pass' }, {}), ).to.throw(Error, 'Expected authorizedOrigins or serviceKey to be set') }) it('throws when authorizedOrigins is not an array', function () { @@ -25,8 +26,8 @@ describe('AuthHelper', function () { passKey: 'myci_pass', authorizedOrigins: true, }, - { private: {} } - ) + { private: {} }, + ), ).to.throw(Error, 'Expected authorizedOrigins to be an array of origins') }) }) @@ -35,7 +36,7 @@ describe('AuthHelper', function () { function validate(config, privateConfig) { return new AuthHelper( { authorizedOrigins: ['https://example.test'], ...config }, - { private: privateConfig } + { private: privateConfig }, ).isValid } test(validate, () => { @@ -43,20 +44,20 @@ describe('AuthHelper', function () { // Fully configured user + pass. given( { userKey: 'myci_user', passKey: 'myci_pass', isRequired: true }, - { myci_user: 'admin', myci_pass: 'abc123' } + { myci_user: 'admin', myci_pass: 'abc123' }, ), given( { userKey: 'myci_user', passKey: 'myci_pass' }, - { myci_user: 'admin', myci_pass: 'abc123' } + { myci_user: 'admin', myci_pass: 'abc123' }, ), // Fully configured user or pass. given( { userKey: 'myci_user', isRequired: true }, - { myci_user: 'admin' } + { myci_user: 'admin' }, ), given( { passKey: 'myci_pass', isRequired: true }, - { myci_pass: 'abc123' } + { myci_pass: 'abc123' }, ), given({ userKey: 'myci_user' }, { myci_user: 'admin' }), given({ passKey: 'myci_pass' }, { myci_pass: 'abc123' }), @@ -70,16 +71,16 @@ describe('AuthHelper', function () { // Partly configured. given( { userKey: 'myci_user', passKey: 'myci_pass', isRequired: true }, - { myci_user: 'admin' } + { myci_user: 'admin' }, ), given( { userKey: 'myci_user', passKey: 'myci_pass' }, - { myci_user: 'admin' } + { myci_user: 'admin' }, ), // Missing required config. given( { userKey: 'myci_user', passKey: 'myci_pass', isRequired: true }, - {} + {}, ), given({ userKey: 'myci_user', isRequired: true }, {}), given({ passKey: 'myci_pass', isRequired: true }, {}), @@ -91,18 +92,18 @@ describe('AuthHelper', function () { function validate(config, privateConfig) { return new AuthHelper( { authorizedOrigins: ['https://example.test'], ...config }, - { private: privateConfig } + { private: privateConfig }, )._basicAuth } test(validate, () => { forCases([ given( { userKey: 'myci_user', passKey: 'myci_pass', isRequired: true }, - { myci_user: 'admin', myci_pass: 'abc123' } + { myci_user: 'admin', myci_pass: 'abc123' }, ), given( { userKey: 'myci_user', passKey: 'myci_pass' }, - { myci_user: 'admin', myci_pass: 'abc123' } + { myci_user: 'admin', myci_pass: 'abc123' }, ), ]).expect({ username: 'admin', password: 'abc123' }) given({ userKey: 'myci_user' }, { myci_user: 'admin' }).expect({ @@ -114,11 +115,11 @@ describe('AuthHelper', function () { password: 'abc123', }) given({ userKey: 'myci_user', passKey: 'myci_pass' }, {}).expect( - undefined + undefined, ) given( { passKey: 'myci_pass', defaultToEmptyStringForUser: true }, - { myci_pass: 'abc123' } + { myci_pass: 'abc123' }, ).expect({ username: '', password: 'abc123', @@ -168,7 +169,7 @@ describe('AuthHelper', function () { expect(() => authHelper.enforceStrictSsl({ options: { https: { rejectUnauthorized: false } }, - }) + }), ).to.throw(InvalidParameter) }) }) @@ -192,7 +193,7 @@ describe('AuthHelper', function () { expect(() => authHelper.enforceStrictSsl({ options: { https: { rejectUnauthorized: false } }, - }) + }), ).not.to.throw() }) }) @@ -318,7 +319,7 @@ describe('AuthHelper', function () { }, }, private: { myci_user: 'admin', myci_pass: 'abc123' }, - } + }, ) const withBasicAuth = requestOptions => authHelper.withBasicAuth(requestOptions) @@ -376,7 +377,7 @@ describe('AuthHelper', function () { withBasicAuth({ url: 'https://myci.test/api', options: { https: { rejectUnauthorized: false } }, - }) + }), ).to.throw(InvalidParameter) }) }) diff --git a/core/base-service/base-graphql.js b/core/base-service/base-graphql.js index a81bac29f9c9fde874750260b7fd591edbd18886..c63ac6ac36252058f2cb7f48065cd169427488dd 100644 --- a/core/base-service/base-graphql.js +++ b/core/base-service/base-graphql.js @@ -91,7 +91,7 @@ class BaseGraphqlService extends BaseService { throw exception } else { throw Error( - `transformErrors() must return a ShieldsRuntimeError; got ${exception}` + `transformErrors() must return a ShieldsRuntimeError; got ${exception}`, ) } } diff --git a/core/base-service/base-graphql.spec.js b/core/base-service/base-graphql.spec.js index 7cfbef8da2c9bb3ae5a7b617a66b52666bf6dc39..b22f96ce12ebc0e2b2fbfe1417836a596c2b68f7 100644 --- a/core/base-service/base-graphql.spec.js +++ b/core/base-service/base-graphql.spec.js @@ -35,14 +35,14 @@ describe('BaseGraphqlService', function () { Promise.resolve({ buffer: '{"some": "json"}', res: { statusCode: 200 }, - }) + }), ) }) it('invokes _requestFetcher', async function () { await DummyGraphqlService.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( @@ -51,7 +51,7 @@ describe('BaseGraphqlService', function () { body: '{"query":"{\\n requiredString\\n}","variables":{}}', headers: { Accept: 'application/json' }, method: 'POST', - } + }, ) }) @@ -74,7 +74,7 @@ describe('BaseGraphqlService', function () { await WithOptions.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( @@ -84,7 +84,7 @@ describe('BaseGraphqlService', function () { headers: { Accept: 'application/json' }, method: 'POST', searchParams: { queryParam: 123 }, - } + }, ) }) }) @@ -98,8 +98,8 @@ describe('BaseGraphqlService', function () { expect( await DummyGraphqlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ message: 'some-string', }) @@ -113,8 +113,8 @@ describe('BaseGraphqlService', function () { expect( await DummyGraphqlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -130,8 +130,8 @@ describe('BaseGraphqlService', function () { expect( await DummyGraphqlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -149,8 +149,8 @@ describe('BaseGraphqlService', function () { expect( await DummyGraphqlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -188,8 +188,8 @@ describe('BaseGraphqlService', function () { expect( await WithErrorHandler.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', diff --git a/core/base-service/base-json.spec.js b/core/base-service/base-json.spec.js index 5618c43922478bbcc88ed650fc21351f1cc38831..fc894d7a89fd96d06de72620b7ef639eabd3ba6c 100644 --- a/core/base-service/base-json.spec.js +++ b/core/base-service/base-json.spec.js @@ -28,21 +28,21 @@ describe('BaseJsonService', function () { Promise.resolve({ buffer: '{"some": "json"}', res: { statusCode: 200 }, - }) + }), ) }) it('invokes _requestFetcher', async function () { await DummyJsonService.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( 'http://example.com/foo.json', { headers: { Accept: 'application/json' }, - } + }, ) }) @@ -60,7 +60,7 @@ describe('BaseJsonService', function () { await WithOptions.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( @@ -69,7 +69,7 @@ describe('BaseJsonService', function () { headers: { Accept: 'application/json' }, method: 'POST', searchParams: { queryParam: 123 }, - } + }, ) }) }) @@ -83,8 +83,8 @@ describe('BaseJsonService', function () { expect( await DummyJsonService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ message: 'some-string', }) @@ -98,8 +98,8 @@ describe('BaseJsonService', function () { expect( await DummyJsonService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -115,8 +115,8 @@ describe('BaseJsonService', function () { expect( await DummyJsonService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', diff --git a/core/base-service/base-static.js b/core/base-service/base-static.js index df9eae5efb953105f05da6d555cc3fcfa1f65c4f..d2523cce547a2d5030a8c13b4bd82ab36dacd6d5 100644 --- a/core/base-service/base-static.js +++ b/core/base-service/base-static.js @@ -33,14 +33,14 @@ export default class BaseStaticService extends BaseService { {}, serviceConfig, namedParams, - queryParams + queryParams, ) const badgeData = coalesceBadge( queryParams, serviceData, this.defaultBadgeData, - this + this, ) // The final capture group is the extension. diff --git a/core/base-service/base-svg-scraping.spec.js b/core/base-service/base-svg-scraping.spec.js index 9f03b546c2ed0557b9fbdb7a67b2a54b8fbf50bc..24502a8584203859b5a8e92bc394a0b9cec97d74 100644 --- a/core/base-service/base-svg-scraping.spec.js +++ b/core/base-service/base-svg-scraping.spec.js @@ -28,7 +28,7 @@ describe('BaseSvgScrapingService', function () { describe('valueFromSvgBadge', function () { it('should find the correct value', function () { expect(BaseSvgScrapingService.valueFromSvgBadge(exampleSvg)).to.equal( - exampleMessage + exampleMessage, ) }) }) @@ -40,21 +40,21 @@ describe('BaseSvgScrapingService', function () { Promise.resolve({ buffer: exampleSvg, res: { statusCode: 200 }, - }) + }), ) }) it('invokes _requestFetcher with the expected header', async function () { await DummySvgScrapingService.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( 'http://example.com/foo.svg', { headers: { Accept: 'image/svg+xml' }, - } + }, ) }) @@ -75,7 +75,7 @@ describe('BaseSvgScrapingService', function () { await WithCustomOptions.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( @@ -84,7 +84,7 @@ describe('BaseSvgScrapingService', function () { method: 'POST', headers: { Accept: 'image/svg+xml' }, searchParams: { queryParam: 123 }, - } + }, ) }) }) @@ -98,8 +98,8 @@ describe('BaseSvgScrapingService', function () { expect( await DummySvgScrapingService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ message: exampleMessage, }) @@ -124,8 +124,8 @@ describe('BaseSvgScrapingService', function () { expect( await WithValueMatcher.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ message: 'a different message', }) @@ -139,8 +139,8 @@ describe('BaseSvgScrapingService', function () { expect( await DummySvgScrapingService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', diff --git a/core/base-service/base-xml.spec.js b/core/base-service/base-xml.spec.js index de61d2ee95f6efd70c9f751493c54f4ec524d7d0..cf22f02deac44e46f27bca783b7b1892d6eddfd4 100644 --- a/core/base-service/base-xml.spec.js +++ b/core/base-service/base-xml.spec.js @@ -28,21 +28,21 @@ describe('BaseXmlService', function () { Promise.resolve({ buffer: '<requiredString>some-string</requiredString>', res: { statusCode: 200 }, - }) + }), ) }) it('invokes _requestFetcher', async function () { await DummyXmlService.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( 'http://example.com/foo.xml', { headers: { Accept: 'application/xml, text/xml' }, - } + }, ) }) @@ -62,7 +62,7 @@ describe('BaseXmlService', function () { await WithCustomOptions.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( @@ -71,7 +71,7 @@ describe('BaseXmlService', function () { headers: { Accept: 'application/xml, text/xml' }, method: 'POST', searchParams: { queryParam: 123 }, - } + }, ) }) }) @@ -85,8 +85,8 @@ describe('BaseXmlService', function () { expect( await DummyXmlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ message: 'some-string', }) @@ -112,8 +112,8 @@ describe('BaseXmlService', function () { expect( await DummyXmlServiceWithParserOption.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ message: 'some-string with trailing whitespace ', }) @@ -127,8 +127,8 @@ describe('BaseXmlService', function () { expect( await DummyXmlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -144,8 +144,8 @@ describe('BaseXmlService', function () { expect( await DummyXmlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', diff --git a/core/base-service/base-yaml.spec.js b/core/base-service/base-yaml.spec.js index 570c34cf729347ba7c5b304fb1309b78bb68bef4..1f8ebef65f3800487b01c92167e8911872d6d52d 100644 --- a/core/base-service/base-yaml.spec.js +++ b/core/base-service/base-yaml.spec.js @@ -44,14 +44,14 @@ describe('BaseYamlService', function () { Promise.resolve({ buffer: expectedYaml, res: { statusCode: 200 }, - }) + }), ) }) it('invokes _requestFetcher', async function () { await DummyYamlService.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( @@ -61,7 +61,7 @@ describe('BaseYamlService', function () { Accept: 'text/x-yaml, text/yaml, application/x-yaml, application/yaml, text/plain', }, - } + }, ) }) @@ -79,7 +79,7 @@ describe('BaseYamlService', function () { await WithOptions.invoke( { requestFetcher }, - { handleInternalErrors: false } + { handleInternalErrors: false }, ) expect(requestFetcher).to.have.been.calledOnceWith( @@ -91,7 +91,7 @@ describe('BaseYamlService', function () { }, method: 'POST', searchParams: { queryParam: 123 }, - } + }, ) }) }) @@ -105,8 +105,8 @@ describe('BaseYamlService', function () { expect( await DummyYamlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ message: 'some-string', }) @@ -120,8 +120,8 @@ describe('BaseYamlService', function () { expect( await DummyYamlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -137,8 +137,8 @@ describe('BaseYamlService', function () { expect( await DummyYamlService.invoke( { requestFetcher }, - { handleInternalErrors: false } - ) + { handleInternalErrors: false }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', diff --git a/core/base-service/base.js b/core/base-service/base.js index cf077c562fec962e706a6bd9eeae1d31559b4a45..270c3e20867b7d68f5bc86bc8cb40bd019a8b16d 100644 --- a/core/base-service/base.js +++ b/core/base-service/base.js @@ -44,7 +44,7 @@ const optionalStringWhenNamedLogoPresent = Joi.alternatives().conditional( { is: Joi.string().required(), then: Joi.string(), - } + }, ) const optionalNumberWhenAnyLogoPresent = Joi.alternatives() @@ -183,11 +183,11 @@ class BaseService { Joi.assert( this.defaultBadgeData, defaultBadgeDataSchema, - `Default badge data for ${this.name}` + `Default badge data for ${this.name}`, ) this.examples.forEach((example, index) => - validateExample(example, index, this) + validateExample(example, index, this), ) } @@ -197,7 +197,7 @@ class BaseService { const queryParams = getQueryParamNames(this.route) const examples = this.examples.map((example, index) => - transformExample(example, index, this) + transformExample(example, index, this), ) let route @@ -218,7 +218,7 @@ class BaseService { constructor( { requestFetcher, authHelper, metricHelper }, - { handleInternalErrors } + { handleInternalErrors }, ) { this._requestFetcher = requestFetcher this.authHelper = authHelper @@ -234,9 +234,9 @@ class BaseService { const params = new URLSearchParams( Object.fromEntries( Object.entries(options.searchParams).filter( - ([k, v]) => v !== undefined - ) - ) + ([k, v]) => v !== undefined, + ), + ), ) logUrl = `${url}?${params.toString()}` delete logOptions.searchParams @@ -244,12 +244,12 @@ class BaseService { logTrace( emojic.bowAndArrow, 'Request', - `${logUrl}\n${JSON.stringify(logOptions, null, 2)}` + `${logUrl}\n${JSON.stringify(logOptions, null, 2)}`, ) const { res, buffer } = await this._requestFetcher( url, options, - systemErrors + systemErrors, ) await this._meterResponse(res, buffer) logTrace(emojic.dart, 'Response status code', res.statusCode) @@ -279,7 +279,7 @@ class BaseService { prettyErrorMessage = 'invalid response data', includeKeys = false, allowAndStripUnknownKeys = true, - } = {} + } = {}, ) { return validate( { @@ -291,7 +291,7 @@ class BaseService { allowAndStripUnknownKeys, }, data, - schema + schema, ) } @@ -347,7 +347,7 @@ class BaseService { 'unhandledError', emojic.boom, 'Unhandled internal error', - error + error, ) ) { // This is where we end up if an unhandled exception is thrown in @@ -365,7 +365,7 @@ class BaseService { 'unhandledError', emojic.boom, 'Unhandled internal error', - error + error, ) throw error } @@ -375,7 +375,7 @@ class BaseService { context = {}, config = {}, namedParams = {}, - queryParams = {} + queryParams = {}, ) { trace.logTrace('inbound', emojic.womanCook, 'Service class', this.name) trace.logTrace('inbound', emojic.ticket, 'Named params', namedParams) @@ -409,13 +409,13 @@ class BaseService { traceSuccessMessage: 'Query params after validation', }, queryParams, - queryParamSchema + queryParamSchema, ) trace.logTrace( 'inbound', emojic.crayon, 'Query params after validation', - queryParams + queryParams, ) } catch (error) { serviceError = error @@ -429,7 +429,7 @@ class BaseService { try { serviceData = await serviceInstance.handle( namedParams, - transformedQueryParams + transformedQueryParams, ) serviceInstance._validateServiceData(serviceData) } catch (error) { @@ -454,7 +454,7 @@ class BaseService { librariesIoApiProvider, metricInstance, }, - serviceConfig + serviceConfig, ) { const { cacheHeaders: cacheHeaderConfig } = serviceConfig const { regex, captureNames } = prepareRoute(this.route) @@ -482,14 +482,14 @@ class BaseService { }, serviceConfig, namedParams, - queryParams + queryParams, ) const badgeData = coalesceBadge( queryParams, serviceData, this.defaultBadgeData, - this + this, ) // The final capture group is the extension. const format = (match.slice(-1)[0] || '.svg').replace(/^\./, '') @@ -498,7 +498,7 @@ class BaseService { metricHandle.noteResponseSent() }, cacheLength: this._cacheLength, - }) + }), ) } } diff --git a/core/base-service/base.spec.js b/core/base-service/base.spec.js index 0eb3fcd16295350076702ba07c3466ed9f8f52ca..8f63654679bec8c00a3b7f5be45d28e650a929b8 100644 --- a/core/base-service/base.spec.js +++ b/core/base-service/base.spec.js @@ -72,8 +72,8 @@ describe('BaseService', function () { {}, defaultConfig, { namedParamA: 'bar.bar.bar' }, - { queryParamA: '!' } - ) + { queryParamA: '!' }, + ), ).to.deep.equal({ message: 'Hello namedParamA: bar.bar.bar with queryParamA: !', }) @@ -85,8 +85,8 @@ describe('BaseService', function () { {}, defaultConfig, { namedParamA: 'bar.bar.bar' }, - { queryParamA: ['foo', 'bar'] } - ) + { queryParamA: ['foo', 'bar'] }, + ), ).to.deep.equal({ color: 'red', isError: true, @@ -97,13 +97,13 @@ describe('BaseService', function () { describe('Required overrides', function () { it('Should throw if render() is not overridden', function () { expect(() => BaseService.render()).to.throw( - /^render\(\) function not implemented for BaseService$/ + /^render\(\) function not implemented for BaseService$/, ) }) it('Should throw if route is not overridden', function () { return expect(BaseService.invoke({}, {}, {})).to.be.rejectedWith( - /^Route not defined for BaseService$/ + /^Route not defined for BaseService$/, ) }) @@ -112,13 +112,13 @@ describe('BaseService', function () { } it('Should throw if handle() is not overridden', function () { return expect(WithRoute.invoke({}, {}, {})).to.be.rejectedWith( - /^Handler not implemented for WithRoute$/ + /^Handler not implemented for WithRoute$/, ) }) it('Should throw if category is not overridden', function () { expect(() => BaseService.category).to.throw( - /^Category not set for BaseService$/ + /^Category not set for BaseService$/, ) }) }) @@ -135,25 +135,25 @@ describe('BaseService', function () { {}, defaultConfig, { namedParamA: 'bar.bar.bar' }, - { queryParamA: '!' } + { queryParamA: '!' }, ) expect(trace.logTrace).to.be.calledWithMatch( 'inbound', sinon.match.string, 'Service class', - 'DummyService' + 'DummyService', ) expect(trace.logTrace).to.be.calledWith( 'inbound', sinon.match.string, 'Named params', - { namedParamA: 'bar.bar.bar' } + { namedParamA: 'bar.bar.bar' }, ) expect(trace.logTrace).to.be.calledWith( 'inbound', sinon.match.string, 'Query params after validation', - { queryParamA: '!' } + { queryParamA: '!' }, ) }) }) @@ -171,7 +171,7 @@ describe('BaseService', function () { const serviceData = await LinkService.invoke( {}, { handleInternalErrors: false }, - { namedParamA: 'bar.bar.bar' } + { namedParamA: 'bar.bar.bar' }, ) expect(serviceData).to.deep.equal({ @@ -194,7 +194,7 @@ describe('BaseService', function () { await ThrowingService.invoke( {}, { handleInternalErrors: false }, - { namedParamA: 'bar.bar.bar' } + { namedParamA: 'bar.bar.bar' }, ) expect.fail('Expected to throw') } catch (e) { @@ -212,7 +212,7 @@ describe('BaseService', function () { await ThrowingService.invoke( {}, { handleInternalErrors: false }, - { namedParamA: 'bar.bar.bar' } + { namedParamA: 'bar.bar.bar' }, ) expect.fail('Expected to throw') } catch (e) { @@ -233,8 +233,8 @@ describe('BaseService', function () { await ThrowingService.invoke( {}, { handleInternalErrors: true }, - { namedParamA: 'bar.bar.bar' } - ) + { namedParamA: 'bar.bar.bar' }, + ), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -251,7 +251,7 @@ describe('BaseService', function () { } } expect( - await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }) + await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }), ).to.deep.equal({ isError: true, color: 'red', @@ -266,7 +266,7 @@ describe('BaseService', function () { } } expect( - await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }) + await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -281,7 +281,7 @@ describe('BaseService', function () { } } expect( - await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }) + await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -296,7 +296,7 @@ describe('BaseService', function () { } } expect( - await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }) + await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }), ).to.deep.equal({ isError: true, color: 'lightgray', @@ -311,7 +311,7 @@ describe('BaseService', function () { } } expect( - await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }) + await ThrowingService.invoke({}, {}, { namedParamA: 'bar.bar.bar' }), ).to.deep.equal({ isError: true, color: 'red', @@ -336,7 +336,7 @@ describe('BaseService', function () { mockHandleRequest = sinon.spy() DummyService.register( { camp: mockCamp, handleRequest: mockHandleRequest }, - defaultConfig + defaultConfig, ) }) @@ -413,8 +413,8 @@ describe('BaseService', function () { expect(() => DummyService._validate( { requiredString: ['this', "shouldn't", 'work'] }, - dummySchema - ) + dummySchema, + ), ) .to.throw() .instanceof(InvalidResponse) @@ -436,7 +436,7 @@ describe('BaseService', function () { }) const serviceInstance = new DummyService( { requestFetcher }, - defaultConfig + defaultConfig, ) const url = 'some-url' @@ -453,14 +453,14 @@ describe('BaseService', function () { `${url}?param1=foobar\n${JSON.stringify( { headers: options.headers }, null, - 2 - )}` + 2, + )}`, ) expect(trace.logTrace).to.be.calledWithMatch( 'fetch', sinon.match.string, 'Response status code', - 200 + 200, ) }) @@ -471,7 +471,7 @@ describe('BaseService', function () { }) const serviceInstance = new DummyService( { requestFetcher }, - defaultConfig + defaultConfig, ) try { @@ -504,17 +504,17 @@ describe('BaseService', function () { const serviceInstance = new DummyServiceWithServiceResponseSizeMetricEnabled( { requestFetcher, metricHelper }, - defaultConfig + defaultConfig, ) await serviceInstance._request({ url }) expect(await register.getSingleMetricAsString('service_response_bytes')) .to.contain( - 'service_response_bytes_bucket{le="65536",category="other",family="undefined",service="dummy_service_with_service_response_size_metric_enabled"} 0\n' + 'service_response_bytes_bucket{le="65536",category="other",family="undefined",service="dummy_service_with_service_response_size_metric_enabled"} 0\n', ) .and.to.contain( - 'service_response_bytes_bucket{le="131072",category="other",family="undefined",service="dummy_service_with_service_response_size_metric_enabled"} 1\n' + 'service_response_bytes_bucket{le="131072",category="other",family="undefined",service="dummy_service_with_service_response_size_metric_enabled"} 1\n', ) }) @@ -529,13 +529,13 @@ describe('BaseService', function () { }) const serviceInstance = new DummyService( { requestFetcher, metricHelper }, - defaultConfig + defaultConfig, ) await serviceInstance._request({ url }) expect( - await register.getSingleMetricAsString('service_response_bytes') + await register.getSingleMetricAsString('service_response_bytes'), ).to.not.contain('service_response_bytes_bucket') }) }) @@ -565,8 +565,8 @@ describe('BaseService', function () { }, private: { myci_pass: 'abc123' }, }, - { namedParamA: 'bar.bar.bar' } - ) + { namedParamA: 'bar.bar.bar' }, + ), ).to.deep.equal({ message: 'The CI password is abc123' }) }) @@ -583,8 +583,8 @@ describe('BaseService', function () { }, { namedParamA: 'bar.bar.bar', - } - ) + }, + ), ).to.deep.equal({ color: 'lightgray', isError: true, diff --git a/core/base-service/cache-headers.js b/core/base-service/cache-headers.js index 2bd02e2f161e44c2890fc52481dbab2a707a511d..881af81d0426d9045304f253b331c16909512bd7 100644 --- a/core/base-service/cache-headers.js +++ b/core/base-service/cache-headers.js @@ -41,7 +41,7 @@ function coalesceCacheLength({ const cacheLength = coalesce( serviceOverrideCacheLengthSeconds, serviceDefaultCacheLengthSeconds, - defaultCacheLengthSeconds + defaultCacheLengthSeconds, ) // Overrides can apply _more_ caching, but not less. Query param overriding diff --git a/core/base-service/cache-headers.spec.js b/core/base-service/cache-headers.spec.js index fcf82ee749fd7de32b25c69d5691f03b36d7ae9a..0e1f508e32bd5aa99afd7653135f8fe781c083d0 100644 --- a/core/base-service/cache-headers.spec.js +++ b/core/base-service/cache-headers.spec.js @@ -125,7 +125,7 @@ describe('Cache header functions', function () { it('should set the expected Cache-Control header', function () { expect(res._headers['cache-control']).to.equal( - 'no-cache, no-store, must-revalidate' + 'no-cache, no-store, must-revalidate', ) }) @@ -141,7 +141,7 @@ describe('Cache header functions', function () { it('should set the expected Cache-Control header', function () { expect(res._headers['cache-control']).to.equal( - 'max-age=123, s-maxage=123' + 'max-age=123, s-maxage=123', ) }) @@ -156,7 +156,7 @@ describe('Cache header functions', function () { it('sets the expected fields', function () { const expectedFields = ['date', 'cache-control', 'expires'] expectedFields.forEach(field => - expect(res._headers[field]).to.equal(undefined) + expect(res._headers[field]).to.equal(undefined), ) setCacheHeaders({ @@ -169,7 +169,7 @@ describe('Cache header functions', function () { expectedFields.forEach(field => expect(res._headers[field]) .to.be.a('string') - .and.have.lengthOf.at.least(1) + .and.have.lengthOf.at.least(1), ) }) }) @@ -181,7 +181,7 @@ describe('Cache header functions', function () { it('should set the expected Cache-Control header', function () { expect(res._headers['cache-control']).to.equal( - `max-age=${24 * 3600}, s-maxage=${24 * 3600}` + `max-age=${24 * 3600}, s-maxage=${24 * 3600}`, ) }) @@ -190,7 +190,7 @@ describe('Cache header functions', function () { expect(new Date(lastModified)).to.be.withinTime( // Within the last 60 seconds. new Date(Date.now() - 60 * 1000), - new Date() + new Date(), ) }) }) @@ -221,7 +221,7 @@ describe('Cache header functions', function () { }) expect(serverHasBeenUpSinceResourceCached(req)).to.equal(false) }) - } + }, ) context( 'when the If-Modified-Since header is after the process started', @@ -233,7 +233,7 @@ describe('Cache header functions', function () { }) expect(serverHasBeenUpSinceResourceCached(req)).to.equal(true) }) - } + }, ) }) }) diff --git a/core/base-service/check-error-response.js b/core/base-service/check-error-response.js index cda53fa7e954b2945c7cb9b5ed26ce2dc91acb4b..62b6b695775da9e7dd6ee5844f399aa6fa267eb7 100644 --- a/core/base-service/check-error-response.js +++ b/core/base-service/check-error-response.js @@ -13,7 +13,7 @@ export default function checkErrorResponse(httpErrors = {}) { error = new NotFound({ prettyMessage: httpErrors[404] }) } else if (res.statusCode !== 200) { const underlying = Error( - `Got status code ${res.statusCode} (expected 200)` + `Got status code ${res.statusCode} (expected 200)`, ) const props = { underlyingError: underlying } if (httpErrors[res.statusCode] !== undefined) { diff --git a/core/base-service/check-error-response.spec.js b/core/base-service/check-error-response.spec.js index 66d74994be1fdd3b9730d91adb0b63925fee6032..ba5d9a33e9b436ae2fab2c1004233edc07b0e5f5 100644 --- a/core/base-service/check-error-response.spec.js +++ b/core/base-service/check-error-response.spec.js @@ -56,7 +56,7 @@ describe('async error handler', function () { } catch (e) { expect(e).to.be.an.instanceof(InvalidResponse) expect(e.message).to.equal( - 'Invalid Response: Got status code 429 (expected 200)' + 'Invalid Response: Got status code 429 (expected 200)', ) expect(e.prettyMessage).to.equal('rate limited by upstream service') expect(e.response).to.equal(res) @@ -72,10 +72,10 @@ describe('async error handler', function () { } catch (e) { expect(e).to.be.an.instanceof(InvalidResponse) expect(e.message).to.equal( - 'Invalid Response: Got status code 429 (expected 200)' + 'Invalid Response: Got status code 429 (expected 200)', ) expect(e.prettyMessage).to.equal( - "terribly sorry but that's one too many requests" + "terribly sorry but that's one too many requests", ) } }) @@ -90,7 +90,7 @@ describe('async error handler', function () { } catch (e) { expect(e).to.be.an.instanceof(InvalidResponse) expect(e.message).to.equal( - 'Invalid Response: Got status code 499 (expected 200)' + 'Invalid Response: Got status code 499 (expected 200)', ) expect(e.prettyMessage).to.equal('invalid') expect(e.response).to.equal(res) @@ -106,7 +106,7 @@ describe('async error handler', function () { } catch (e) { expect(e).to.be.an.instanceof(InvalidResponse) expect(e.message).to.equal( - 'Invalid Response: Got status code 403 (expected 200)' + 'Invalid Response: Got status code 403 (expected 200)', ) expect(e.prettyMessage).to.equal('access denied') } @@ -122,7 +122,7 @@ describe('async error handler', function () { } catch (e) { expect(e).to.be.an.instanceof(Inaccessible) expect(e.message).to.equal( - 'Inaccessible: Got status code 503 (expected 200)' + 'Inaccessible: Got status code 503 (expected 200)', ) expect(e.prettyMessage).to.equal('inaccessible') expect(e.response).to.equal(res) @@ -138,7 +138,7 @@ describe('async error handler', function () { } catch (e) { expect(e).to.be.an.instanceof(Inaccessible) expect(e.message).to.equal( - 'Inaccessible: Got status code 500 (expected 200)' + 'Inaccessible: Got status code 500 (expected 200)', ) expect(e.prettyMessage).to.equal('server overloaded') } diff --git a/core/base-service/coalesce-badge.js b/core/base-service/coalesce-badge.js index 1d1714b482cf5d8949f4c2ca8d7e48580bf37d1b..d07214b61d8e5c5a4949bf1dd32dad8bc55dd8e3 100644 --- a/core/base-service/coalesce-badge.js +++ b/core/base-service/coalesce-badge.js @@ -36,7 +36,7 @@ export default function coalesceBadge( serviceData, // These two parameters were kept separate to make tests clearer. defaultBadgeData, - { category, _cacheLength: defaultCacheSeconds } = {} + { category, _cacheLength: defaultCacheSeconds } = {}, ) { // The "overrideX" naming is based on services that provide badge // parameters themselves, which can be overridden by a query string @@ -141,7 +141,7 @@ export default function coalesceBadge( } else { namedLogo = coalesce( serviceNamedLogo, - style === 'social' ? defaultNamedLogo : undefined + style === 'social' ? defaultNamedLogo : undefined, ) namedLogoColor = coalesce(overrideLogoColor, serviceLogoColor) } @@ -166,13 +166,13 @@ export default function coalesceBadge( isError ? undefined : overrideColor, serviceColor, defaultColor, - 'lightgrey' + 'lightgrey', ), labelColor: coalesce( // In case of an error, disregard user's color override. isError ? undefined : overrideLabelColor, serviceLabelColor, - defaultLabelColor + defaultLabelColor, ), style, namedLogo, diff --git a/core/base-service/coalesce-badge.spec.js b/core/base-service/coalesce-badge.spec.js index 7ca8cfe61167c18ca7b9aa3c8dd0610c505e991f..9cf4a7624f77a1e98a1b56e373b6b0644103ac60 100644 --- a/core/base-service/coalesce-badge.spec.js +++ b/core/base-service/coalesce-badge.spec.js @@ -25,7 +25,7 @@ describe('coalesceBadge', function () { it('overrides the label', function () { expect( - coalesceBadge({ label: 'purr count' }, { label: 'purrs' }, {}) + coalesceBadge({ label: 'purr count' }, { label: 'purrs' }, {}), ).to.include({ label: 'purr count' }) }) }) @@ -54,11 +54,11 @@ describe('coalesceBadge', function () { it('overrides the color', function () { expect( - coalesceBadge({ color: '10ADED' }, { color: 'red' }, {}) + coalesceBadge({ color: '10ADED' }, { color: 'red' }, {}), ).to.include({ color: '10ADED' }) // also expected for legacy name expect( - coalesceBadge({ colorB: 'B0ADED' }, { color: 'red' }, {}) + coalesceBadge({ colorB: 'B0ADED' }, { color: 'red' }, {}), ).to.include({ color: 'B0ADED' }) }) @@ -68,16 +68,16 @@ describe('coalesceBadge', function () { coalesceBadge( { color: '10ADED' }, { isError: true, color: 'lightgray' }, - {} - ) + {}, + ), ).to.include({ color: 'lightgray' }) // also expected for legacy name expect( coalesceBadge( { colorB: 'B0ADED' }, { isError: true, color: 'lightgray' }, - {} - ) + {}, + ), ).to.include({ color: 'lightgray' }) }) }) @@ -102,11 +102,11 @@ describe('coalesceBadge', function () { it('overrides the label color', function () { expect( - coalesceBadge({ labelColor: '42f483' }, { color: 'green' }, {}) + coalesceBadge({ labelColor: '42f483' }, { color: 'green' }, {}), ).to.include({ labelColor: '42f483' }) // also expected for legacy name expect( - coalesceBadge({ colorA: 'B2f483' }, { color: 'green' }, {}) + coalesceBadge({ colorA: 'B2f483' }, { color: 'green' }, {}), ).to.include({ labelColor: 'B2f483' }) }) @@ -116,8 +116,8 @@ describe('coalesceBadge', function () { // Scoutcamp converts numeric query params to numbers. { color: 123 }, { color: 'green' }, - {} - ) + {}, + ), ).to.include({ color: '123' }) // also expected for legacy name expect( @@ -125,8 +125,8 @@ describe('coalesceBadge', function () { // Scoutcamp converts numeric query params to numbers. { colorB: 123 }, { color: 'green' }, - {} - ) + {}, + ), ).to.include({ color: '123' }) }) }) @@ -140,7 +140,7 @@ describe('coalesceBadge', function () { it('when a social badge, uses the default named logo', function () { // .not.be.empty for confidence that nothing has changed with `getShieldsIcon()`. expect( - coalesceBadge({ style: 'social' }, {}, { namedLogo: 'appveyor' }).logo + coalesceBadge({ style: 'social' }, {}, { namedLogo: 'appveyor' }).logo, ).to.equal(getSimpleIcon({ name: 'appveyor' })).and.not.be.empty }) @@ -149,28 +149,28 @@ describe('coalesceBadge', function () { namedLogo: 'npm', }) expect(coalesceBadge({}, { namedLogo: 'npm' }, {}).logo).to.equal( - getShieldsIcon({ name: 'npm' }) + getShieldsIcon({ name: 'npm' }), ).and.not.to.be.empty }) it('applies the named monochrome logo with color', function () { expect( coalesceBadge({}, { namedLogo: 'dependabot', logoColor: 'blue' }, {}) - .logo + .logo, ).to.equal(getShieldsIcon({ name: 'dependabot', color: 'blue' })).and.not .to.be.empty }) it('applies the named multicolored logo with color', function () { expect( - coalesceBadge({}, { namedLogo: 'npm', logoColor: 'blue' }, {}).logo + coalesceBadge({}, { namedLogo: 'npm', logoColor: 'blue' }, {}).logo, ).to.equal(getSimpleIcon({ name: 'npm', color: 'blue' })).and.not.to.be .empty }) it('overrides the logo', function () { expect( - coalesceBadge({ logo: 'npm' }, { namedLogo: 'appveyor' }, {}).logo + coalesceBadge({ logo: 'npm' }, { namedLogo: 'appveyor' }, {}).logo, ).to.equal(getShieldsIcon({ name: 'npm' })).and.not.be.empty }) @@ -179,8 +179,8 @@ describe('coalesceBadge', function () { coalesceBadge( { logo: 'dependabot', logoColor: 'blue' }, { namedLogo: 'appveyor' }, - {} - ).logo + {}, + ).logo, ).to.equal(getShieldsIcon({ name: 'dependabot', color: 'blue' })).and.not .be.empty }) @@ -190,8 +190,8 @@ describe('coalesceBadge', function () { coalesceBadge( { logo: 'npm', logoColor: 'blue' }, { namedLogo: 'appveyor' }, - {} - ).logo + {}, + ).logo, ).to.equal(getSimpleIcon({ name: 'npm', color: 'blue' })).and.not.be.empty }) @@ -205,8 +205,8 @@ describe('coalesceBadge', function () { logoPosition: -3, logoWidth: 100, }, - {} - ).logo + {}, + ).logo, ).to.equal(getShieldsIcon({ name: 'npm' })).and.not.be.empty }) @@ -215,8 +215,8 @@ describe('coalesceBadge', function () { coalesceBadge( { logoColor: 'blue' }, { namedLogo: 'dependabot', logoColor: 'red' }, - {} - ).logo + {}, + ).logo, ).to.equal(getShieldsIcon({ name: 'dependabot', color: 'blue' })).and.not .be.empty }) @@ -226,8 +226,8 @@ describe('coalesceBadge', function () { coalesceBadge( { logoColor: 'blue' }, { namedLogo: 'npm', logoColor: 'red' }, - {} - ).logo + {}, + ).logo, ).to.equal(getSimpleIcon({ name: 'npm', color: 'blue' })).and.not.be.empty }) @@ -235,7 +235,7 @@ describe('coalesceBadge', function () { it('overrides logoSvg', function () { const logoSvg = 'data:image/svg+xml;base64,PHN2ZyB4bWxu' expect(coalesceBadge({ logo: 'npm' }, { logoSvg }, {}).logo).to.equal( - getShieldsIcon({ name: 'npm' }) + getShieldsIcon({ name: 'npm' }), ).and.not.be.empty }) }) @@ -244,7 +244,7 @@ describe('coalesceBadge', function () { it('overrides the logo with custom svg', function () { const logoSvg = 'data:image/svg+xml;base64,PHN2ZyB4bWxu' expect( - coalesceBadge({ logo: logoSvg }, { namedLogo: 'appveyor' }, {}) + coalesceBadge({ logo: logoSvg }, { namedLogo: 'appveyor' }, {}), ).to.include({ logo: logoSvg }) }) @@ -254,8 +254,8 @@ describe('coalesceBadge', function () { coalesceBadge( { logo: logoSvg, logoColor: 'brightgreen' }, { namedLogo: 'appveyor' }, - {} - ) + {}, + ), ).to.include({ logo: logoSvg }) }) }) @@ -269,7 +269,7 @@ describe('coalesceBadge', function () { it('applies the logo width', function () { expect( - coalesceBadge({}, { namedLogo: 'npm', logoWidth: 275 }, {}) + coalesceBadge({}, { namedLogo: 'npm', logoWidth: 275 }, {}), ).to.include({ logoWidth: 275 }) }) }) @@ -283,7 +283,7 @@ describe('coalesceBadge', function () { it('applies the logo position', function () { expect( - coalesceBadge({}, { namedLogo: 'npm', logoPosition: -10 }, {}) + coalesceBadge({}, { namedLogo: 'npm', logoPosition: -10 }, {}), ).to.include({ logoPosition: -10 }) }) }) @@ -296,8 +296,8 @@ describe('coalesceBadge', function () { { link: 'https://circleci.com/workflow-run/184ef3de-4836-4805-a2e4-0ceba099f92d', }, - {} - ).links + {}, + ).links, ).to.deep.equal(['https://circleci.com/gh/badges/daily-tests']) }) }) @@ -328,7 +328,7 @@ describe('coalesceBadge', function () { describe('Cache length', function () { it('overrides the cache length', function () { expect( - coalesceBadge({ style: 'pill' }, { cacheSeconds: 123 }, {}) + coalesceBadge({ style: 'pill' }, { cacheSeconds: 123 }, {}), ).to.include({ cacheLengthSeconds: 123 }) }) }) diff --git a/core/base-service/deprecated-service.js b/core/base-service/deprecated-service.js index 03ce5b2485e7415c43ce14a8653b72414e079c73..341c4843ec8779b7af9c64ada7e90ab045b5b20a 100644 --- a/core/base-service/deprecated-service.js +++ b/core/base-service/deprecated-service.js @@ -20,7 +20,7 @@ function deprecatedService(attrs) { const { route, name, label, category, examples, message } = Joi.attempt( attrs, attrSchema, - `Deprecated service for ${attrs.route.base}` + `Deprecated service for ${attrs.route.base}`, ) return class DeprecatedService extends BaseService { diff --git a/core/base-service/examples.js b/core/base-service/examples.js index 4f7f2342dfe7beafe6825805f58a1b3d59db3248..cf1b1c021d0b686062d3b54ca676de16300f7d02 100644 --- a/core/base-service/examples.js +++ b/core/base-service/examples.js @@ -6,7 +6,7 @@ import { makeFullUrl } from './route.js' const optionalObjectOfKeyValues = Joi.object().pattern( /./, - Joi.string().allow(null) + Joi.string().allow(null), ) const schema = Joi.object({ @@ -32,19 +32,19 @@ function validateExample(example, index, ServiceClass) { const result = Joi.attempt( example, schema, - `Example for ${ServiceClass.name} at index ${index}` + `Example for ${ServiceClass.name} at index ${index}`, ) const { pattern, namedParams } = result if (!pattern && !ServiceClass.route.pattern) { throw new Error( - `Example for ${ServiceClass.name} at index ${index} does not declare a pattern` + `Example for ${ServiceClass.name} at index ${index} does not declare a pattern`, ) } if (pattern === ServiceClass.route.pattern) { throw new Error( - `Example for ${ServiceClass.name} at index ${index} declares a redundant pattern which should be removed` + `Example for ${ServiceClass.name} at index ${index} declares a redundant pattern which should be removed`, ) } @@ -57,7 +57,7 @@ function validateExample(example, index, ServiceClass) { throw Error( `In example for ${ ServiceClass.name - } at index ${index}, ${e.message.toLowerCase()}` + } at index ${index}, ${e.message.toLowerCase()}`, ) } // Make sure there are no extra keys. @@ -73,8 +73,8 @@ function validateExample(example, index, ServiceClass) { `In example for ${ ServiceClass.name } at index ${index}, namedParams contains unknown keys: ${extraKeys.join( - ', ' - )}` + ', ', + )}`, ) } @@ -86,22 +86,22 @@ function validateExample(example, index, ServiceClass) { `In example for ${ ServiceClass.name } at index ${index}, keywords contains words that are less than two characters long: ${tinyKeywords.join( - ', ' - )}` + ', ', + )}`, ) } // Make sure none of the keywords are already included in the title. const title = (example.title || ServiceClass.name).toLowerCase() const redundantKeywords = example.keywords.filter(k => - title.includes(k.toLowerCase()) + title.includes(k.toLowerCase()), ) if (redundantKeywords.length) { throw Error( `In example for ${ ServiceClass.name } at index ${index}, keywords contains words that are already in the title: ${redundantKeywords.join( - ', ' - )}` + ', ', + )}`, ) } } @@ -126,7 +126,7 @@ function transformExample(inExample, index, ServiceClass) { {}, staticPreview, ServiceClass.defaultBadgeData, - ServiceClass + ServiceClass, ) const category = categories.find(c => c.id === ServiceClass.category) @@ -135,7 +135,7 @@ function transformExample(inExample, index, ServiceClass) { example: { pattern: makeFullUrl( ServiceClass.route.base, - pattern || ServiceClass.route.pattern + pattern || ServiceClass.route.pattern, ), namedParams, queryParams, diff --git a/core/base-service/examples.spec.js b/core/base-service/examples.spec.js index 770b2571659999d827f0ced500406fb0528fca41..7b64b204d48b58e3f2c50e64e70fcb9059a235ff 100644 --- a/core/base-service/examples.spec.js +++ b/core/base-service/examples.spec.js @@ -16,7 +16,7 @@ describe('validateExample function', function () { validExamples.forEach(example => { expect(() => - validateExample(example, 0, { route: {}, name: 'mockService' }) + validateExample(example, 0, { route: {}, name: 'mockService' }), ).not.to.throw(Error) }) }) @@ -66,7 +66,7 @@ describe('validateExample function', function () { invalidExamples.forEach(example => { expect(() => - validateExample(example, 0, { route: {}, name: 'mockService' }) + validateExample(example, 0, { route: {}, name: 'mockService' }), ).to.throw(Error) }) }) @@ -93,7 +93,7 @@ test(transformExample, function () { keywords: ['hello'], }, 0, - ExampleService + ExampleService, ).expect({ title: 'ExampleService', example: { @@ -119,7 +119,7 @@ test(transformExample, function () { keywords: ['hello'], }, 0, - ExampleService + ExampleService, ).expect({ title: 'ExampleService', example: { @@ -146,7 +146,7 @@ test(transformExample, function () { keywords: ['hello'], }, 0, - ExampleService + ExampleService, ).expect({ title: 'ExampleService', example: { diff --git a/core/base-service/got.spec.js b/core/base-service/got.spec.js index 37b201f0f57520d29d21b561b01602c22436b613..2a7f1f494bdfc111772fbec159b934d7433ed38f 100644 --- a/core/base-service/got.spec.js +++ b/core/base-service/got.spec.js @@ -21,7 +21,7 @@ describe('got wrapper', function () { .reply(200, 'x'.repeat(101)) const sendRequest = _fetchFactory(100) return expect( - sendRequest('https://www.google.com/foo/bar') + sendRequest('https://www.google.com/foo/bar'), ).to.be.rejectedWith(InvalidResponse, 'Maximum response size exceeded') }) @@ -29,7 +29,7 @@ describe('got wrapper', function () { nock('https://www.google.com').get('/foo/bar').replyWithError('oh no') const sendRequest = _fetchFactory(1024) return expect( - sendRequest('https://www.google.com/foo/bar') + sendRequest('https://www.google.com/foo/bar'), ).to.be.rejectedWith(Inaccessible, 'oh no') }) @@ -38,10 +38,10 @@ describe('got wrapper', function () { nock.disableNetConnect() const sendRequest = _fetchFactory(1024) return expect( - sendRequest('https://www.google.com/foo/bar') + sendRequest('https://www.google.com/foo/bar'), ).to.be.rejectedWith( Inaccessible, - 'Nock: Disallowed net connect for "www.google.com:443/foo/bar"' + 'Nock: Disallowed net connect for "www.google.com:443/foo/bar"', ) }) @@ -57,18 +57,18 @@ describe('got wrapper', function () { prettyMessage: 'Oh no! A terrible thing has happened', cacheSeconds: 10, }, - } - ) + }, + ), ) .to.be.rejectedWith( Inaccessible, - "Inaccessible: Timeout awaiting 'request' for 1ms" + "Inaccessible: Timeout awaiting 'request' for 1ms", ) // eslint-disable-next-line promise/prefer-await-to-then .then(error => { expect(error).to.have.property( 'prettyMessage', - 'Oh no! A terrible thing has happened' + 'Oh no! A terrible thing has happened', ) expect(error).to.have.property('cacheSeconds', 10) }) diff --git a/core/base-service/graphql.spec.js b/core/base-service/graphql.spec.js index 2267ecf41b7226ae7c65022c60a9f3452aa6e716..7ebe8427a87c35d7753dd48bbc2d6fa522fd2d9f 100644 --- a/core/base-service/graphql.spec.js +++ b/core/base-service/graphql.spec.js @@ -9,18 +9,16 @@ describe('mergeQueries function', function () { it('merges valid gql queries', function () { expect( print( - mergeQueries( - gql` - query ($param: String!) { - foo(param: $param) { - bar - } + mergeQueries(gql` + query ($param: String!) { + foo(param: $param) { + bar } - ` - ) - ) + } + `), + ), ).to.equalIgnoreSpaces( - 'query ($param: String!) { foo(param: $param) { bar } }' + 'query ($param: String!) { foo(param: $param) { bar } }', ) expect( @@ -37,11 +35,11 @@ describe('mergeQueries function', function () { query { baz } - ` - ) - ) + `, + ), + ), ).to.equalIgnoreSpaces( - 'query ($param: String!) { foo(param: $param) { bar } baz }' + 'query ($param: String!) { foo(param: $param) { bar } baz }', ) expect( @@ -61,9 +59,9 @@ describe('mergeQueries function', function () { query { baz } - ` - ) - ) + `, + ), + ), ).to.equalIgnoreSpaces('{ foo bar baz }') expect( @@ -78,9 +76,9 @@ describe('mergeQueries function', function () { { bar } - ` - ) - ) + `, + ), + ), ).to.equalIgnoreSpaces('{ foo bar }') }) diff --git a/core/base-service/legacy-request-handler.js b/core/base-service/legacy-request-handler.js index f7cbb94001f3c7831c2619d26d0827cf63ca8e4e..b7725081692ea32dfa4158a4c479b931519fb8eb 100644 --- a/core/base-service/legacy-request-handler.js +++ b/core/base-service/legacy-request-handler.js @@ -104,7 +104,7 @@ function handleRequest(cacheHeaderConfig, handlerOptions) { const badgeData = coalesceBadge( filteredQueryParams, { label: 'vendor', message: 'unresponsive' }, - {} + {}, ) const svg = makeBadge(badgeData) const extension = (match.slice(-1)[0] || '.svg').replace(/^\./, '') @@ -126,7 +126,7 @@ function handleRequest(cacheHeaderConfig, handlerOptions) { const svg = makeBadge(badgeData) setCacheHeadersOnResponse(ask.res, badgeData.cacheLengthSeconds) makeSend(format, ask.res, end)(svg) - } + }, ) // eslint-disable-next-line promise/prefer-await-to-then if (result && result.catch) { diff --git a/core/base-service/legacy-request-handler.spec.js b/core/base-service/legacy-request-handler.spec.js index 9293e42ecacd9d86024b1e9e7d88267a21eaf5f6..7bdd8e897399e66e695d1a6d89cc368607285312 100644 --- a/core/base-service/legacy-request-handler.spec.js +++ b/core/base-service/legacy-request-handler.spec.js @@ -18,7 +18,7 @@ function fakeHandler(queryParams, match, sendBadge, request) { label: 'testing', message: someValue, }, - {} + {}, ) sendBadge(format, badgeData) } @@ -35,7 +35,7 @@ function createFakeHandlerWithCacheLength(cacheLengthSeconds) { {}, { _cacheLength: cacheLengthSeconds, - } + }, ) sendBadge(format, badgeData) } @@ -66,7 +66,7 @@ describe('The request handler', function () { beforeEach(function () { camp.route( /^\/testing\/([^/]+)\.(svg|png|gif|jpg|json)$/, - handleRequest(standardCacheHeaders, { handler: fakeHandler }) + handleRequest(standardCacheHeaders, { handler: fakeHandler }), ) }) @@ -90,7 +90,7 @@ describe('The request handler', function () { beforeEach(function () { camp.route( /^\/testing\/([^/]+)\.(svg|png|gif|jpg|json)$/, - handleRequest(standardCacheHeaders, fakeHandler) + handleRequest(standardCacheHeaders, fakeHandler), ) }) @@ -119,8 +119,8 @@ describe('The request handler', function () { cacheHeaderConfig, (queryParams, match, sendBadge, request) => { fakeHandler(queryParams, match, sendBadge, request) - } - ) + }, + ), ) } @@ -128,7 +128,7 @@ describe('The request handler', function () { register({ cacheHeaderConfig: { defaultCacheLengthSeconds: 900 } }) const { headers } = await got(`${baseUrl}/testing/123.json`) const expectedExpiry = new Date( - +new Date(headers.date) + 900000 + +new Date(headers.date) + 900000, ).toGMTString() expect(headers.expires).to.equal(expectedExpiry) expect(headers['cache-control']).to.equal('max-age=900, s-maxage=900') @@ -142,7 +142,7 @@ describe('The request handler', function () { const { headers } = await got(`${baseUrl}/testing/123.json`) const expectedExpiry = new Date( - +new Date(headers.date) + 900000 + +new Date(headers.date) + 900000, ).toGMTString() expect(headers.expires).to.equal(expectedExpiry) expect(headers['cache-control']).to.equal('max-age=900, s-maxage=900') @@ -158,10 +158,10 @@ describe('The request handler', function () { queryParams, match, sendBadge, - request + request, ) - } - ) + }, + ), ) const { headers } = await got(`${baseUrl}/testing/123.json`) @@ -178,10 +178,10 @@ describe('The request handler', function () { queryParams, match, sendBadge, - request + request, ) - } - ) + }, + ), ) const { headers } = await got(`${baseUrl}/testing/123.json`) @@ -191,10 +191,10 @@ describe('The request handler', function () { it('should set the expires header to current time + cacheSeconds', async function () { register({ cacheHeaderConfig: { defaultCacheLengthSeconds: 0 } }) const { headers } = await got( - `${baseUrl}/testing/123.json?cacheSeconds=3600` + `${baseUrl}/testing/123.json?cacheSeconds=3600`, ) const expectedExpiry = new Date( - +new Date(headers.date) + 3600000 + +new Date(headers.date) + 3600000, ).toGMTString() expect(headers.expires).to.equal(expectedExpiry) expect(headers['cache-control']).to.equal('max-age=3600, s-maxage=3600') @@ -203,10 +203,10 @@ describe('The request handler', function () { it('should ignore cacheSeconds when shorter than defaultCacheLengthSeconds', async function () { register({ cacheHeaderConfig: { defaultCacheLengthSeconds: 600 } }) const { headers } = await got( - `${baseUrl}/testing/123.json?cacheSeconds=300` + `${baseUrl}/testing/123.json?cacheSeconds=300`, ) const expectedExpiry = new Date( - +new Date(headers.date) + 600000 + +new Date(headers.date) + 600000, ).toGMTString() expect(headers.expires).to.equal(expectedExpiry) expect(headers['cache-control']).to.equal('max-age=600, s-maxage=600') @@ -217,7 +217,7 @@ describe('The request handler', function () { const { headers } = await got(`${baseUrl}/testing/123.json`) expect(headers.expires).to.equal(headers.date) expect(headers['cache-control']).to.equal( - 'no-cache, no-store, must-revalidate' + 'no-cache, no-store, must-revalidate', ) }) }) @@ -234,7 +234,7 @@ describe('The request handler', function () { ++handlerCallCount fakeHandler(queryParams, match, sendBadge, request) }, - }) + }), ) }) @@ -242,7 +242,7 @@ describe('The request handler', function () { await performTwoRequests( baseUrl, '/testing/123.svg?foo=1', - '/testing/123.svg?foo=2' + '/testing/123.svg?foo=2', ) expect(handlerCallCount).to.equal(2) }) diff --git a/core/base-service/loader.js b/core/base-service/loader.js index dba2e10bb0320ae4bfb731a02d563c601894c5b7..7cd272e0d0500f29515759ad574196e07512e3db 100644 --- a/core/base-service/loader.js +++ b/core/base-service/loader.js @@ -10,7 +10,7 @@ const serviceDir = path.join( path.dirname(fileURLToPath(import.meta.url)), '..', '..', - 'services' + 'services', ) function toUnixPath(path) { @@ -51,14 +51,14 @@ async function loadServiceClasses(servicePaths) { const serviceClasses = [] for await (const servicePath of servicePaths) { const currentServiceClasses = Object.values( - await import(`file://${servicePath}`) + await import(`file://${servicePath}`), ).flatMap(element => - typeof element === 'object' ? Object.values(element) : element + typeof element === 'object' ? Object.values(element) : element, ) if (currentServiceClasses.length === 0) { throw new InvalidService( - `Expected ${servicePath} to export a service or a collection of services` + `Expected ${servicePath} to export a service or a collection of services`, ) } currentServiceClasses.forEach(serviceClass => { @@ -71,7 +71,7 @@ async function loadServiceClasses(servicePaths) { return serviceClasses.push(serviceClass) } throw new InvalidService( - `Expected ${servicePath} to export a service or a collection of services; one of them was ${serviceClass}` + `Expected ${servicePath} to export a service or a collection of services; one of them was ${serviceClass}`, ) }) } @@ -80,7 +80,7 @@ async function loadServiceClasses(servicePaths) { serviceClasses.map(({ name }) => name), { message: 'Duplicate service names found', - } + }, ) return serviceClasses @@ -102,8 +102,8 @@ async function collectDefinitions() { async function loadTesters() { return Promise.all( getServicePaths('*.tester.js').map( - async path => await import(`file://${path}`) - ) + async path => await import(`file://${path}`), + ), ) } diff --git a/core/base-service/loader.spec.js b/core/base-service/loader.spec.js index bb920a398e7f59e5d8cbe0ae9386caa2f767bd74..9990ef591583f330cdd3cdb560283736181b19ab 100644 --- a/core/base-service/loader.spec.js +++ b/core/base-service/loader.spec.js @@ -12,50 +12,56 @@ chai.use(chaiAsPromised) const { expect } = chai const fixturesDir = path.join( path.dirname(fileURLToPath(import.meta.url)), - 'loader-test-fixtures' + 'loader-test-fixtures', ) describe('loadServiceClasses function', function () { it('throws if module exports empty', async function () { await expect( - loadServiceClasses([path.join(fixturesDir, 'empty-undefined.fixture.js')]) + loadServiceClasses([ + path.join(fixturesDir, 'empty-undefined.fixture.js'), + ]), ).to.be.rejectedWith(InvalidService) await expect( - loadServiceClasses([path.join(fixturesDir, 'empty-array.fixture.js')]) + loadServiceClasses([path.join(fixturesDir, 'empty-array.fixture.js')]), ).to.be.rejectedWith(InvalidService) await expect( - loadServiceClasses([path.join(fixturesDir, 'empty-object.fixture.js')]) + loadServiceClasses([path.join(fixturesDir, 'empty-object.fixture.js')]), ).to.be.rejectedWith(InvalidService) await expect( - loadServiceClasses([path.join(fixturesDir, 'empty-no-export.fixture.js')]) + loadServiceClasses([ + path.join(fixturesDir, 'empty-no-export.fixture.js'), + ]), ).to.be.rejectedWith(InvalidService) await expect( loadServiceClasses([ path.join(fixturesDir, 'valid-array.fixture.js'), path.join(fixturesDir, 'valid-class.fixture.js'), path.join(fixturesDir, 'empty-array.fixture.js'), - ]) + ]), ).to.be.rejectedWith(InvalidService) }) it('throws if module exports invalid', async function () { await expect( - loadServiceClasses([path.join(fixturesDir, 'invalid-no-base.fixture.js')]) + loadServiceClasses([ + path.join(fixturesDir, 'invalid-no-base.fixture.js'), + ]), ).to.be.rejectedWith(InvalidService) await expect( loadServiceClasses([ path.join(fixturesDir, 'invalid-wrong-base.fixture.js'), - ]) + ]), ).to.be.rejectedWith(InvalidService) await expect( - loadServiceClasses([path.join(fixturesDir, 'invalid-mixed.fixture.js')]) + loadServiceClasses([path.join(fixturesDir, 'invalid-mixed.fixture.js')]), ).to.be.rejectedWith(InvalidService) await expect( loadServiceClasses([ path.join(fixturesDir, 'valid-array.fixture.js'), path.join(fixturesDir, 'valid-class.fixture.js'), path.join(fixturesDir, 'invalid-no-base.fixture.js'), - ]) + ]), ).to.be.rejectedWith(InvalidService) }) @@ -65,7 +71,7 @@ describe('loadServiceClasses function', function () { path.join(fixturesDir, 'valid-array.fixture.js'), path.join(fixturesDir, 'valid-object.fixture.js'), path.join(fixturesDir, 'valid-class.fixture.js'), - ]) + ]), ).to.eventually.have.length(5) }) }) diff --git a/core/base-service/openapi.js b/core/base-service/openapi.js index 4ea3169a7d5ae1e1999368a895eae8e8afbaf941..97760dd1f059be4529a9d386d340b795c0b1f3a5 100644 --- a/core/base-service/openapi.js +++ b/core/base-service/openapi.js @@ -158,7 +158,7 @@ function examples2openapi(examples) { const parameters = [ ...pathParams, ...Object.entries(queryParams).map(([paramName, exampleValue]) => - param2openapi(pattern, paramName, exampleValue, 'query') + param2openapi(pattern, paramName, exampleValue, 'query'), ), ...globalParamRefs, ] @@ -198,7 +198,7 @@ function services2openapi(services) { if (service.openApi) { // if the service declares its own OpenAPI definition, use that... for (const [key, value] of Object.entries( - addGlobalProperties(service.openApi) + addGlobalProperties(service.openApi), )) { if (key in paths) { throw new Error(`Conflicting route: ${key}`) @@ -208,7 +208,7 @@ function services2openapi(services) { } else { // ...otherwise do our best to build one from examples[] for (const [key, value] of Object.entries( - examples2openapi(service.examples) + examples2openapi(service.examples), )) { // allow conflicting routes for legacy examples paths[key] = value diff --git a/core/base-service/openapi.spec.js b/core/base-service/openapi.spec.js index 217cb37ac9424d2a3574799e75e57d07d596ab0c..f36e514fcec6a0ba8a48fc04834841f14bcd6e76 100644 --- a/core/base-service/openapi.spec.js +++ b/core/base-service/openapi.spec.js @@ -371,8 +371,8 @@ describe('category2openapi', function () { category2openapi({ name: 'build' }, [ OpenApiService.getDefinition(), LegacyService.getDefinition(), - ]) - ) + ]), + ), ).to.deep.equal(expected) }) }) diff --git a/core/base-service/redirector.js b/core/base-service/redirector.js index 094e3af07f48590f0d9f24f0b6705668b13f4a12..bac6e5809c5bfd75fb55134348adddf631f4f8ba 100644 --- a/core/base-service/redirector.js +++ b/core/base-service/redirector.js @@ -23,7 +23,7 @@ const attrSchema = Joi.object({ .required() .error( () => - '"transformPath" must be a function that transforms named params to a new path' + '"transformPath" must be a function that transforms named params to a new path', ), transformQueryParams: Joi.func().arity(1), dateAdded: Joi.date().required(), @@ -80,7 +80,7 @@ export default function redirector(attrs) { 'inbound', emojic.arrowHeadingUp, 'Redirector', - route.base + route.base, ) trace.logTrace('inbound', emojic.ticket, 'Named params', namedParams) trace.logTrace('inbound', emojic.crayon, 'Query params', queryParams) diff --git a/core/base-service/redirector.spec.js b/core/base-service/redirector.spec.js index 4b1912d2305e44c472dc3fce37ad7c495a99038f..837770573590730c88965083de8f61a2032fd646 100644 --- a/core/base-service/redirector.spec.js +++ b/core/base-service/redirector.spec.js @@ -27,7 +27,7 @@ describe('Redirector', function () { redirector({ ...attrs, name: 'ShinyRedirect', - }).name + }).name, ).to.equal('ShinyRedirect') }) @@ -41,7 +41,7 @@ describe('Redirector', function () { it('throws the expected error when dateAdded is missing', function () { expect(() => - redirector({ route, category, transformPath }).validateDefinition() + redirector({ route, category, transformPath }).validateDefinition(), ).to.throw('"dateAdded" is required') }) @@ -93,7 +93,7 @@ describe('Redirector', function () { }) ServiceClass.register( { camp }, - { rasterUrl: 'http://raster.example.test' } + { rasterUrl: 'http://raster.example.test' }, ) }) @@ -102,7 +102,7 @@ describe('Redirector', function () { `${baseUrl}/very/old/service/hello-world.svg`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) @@ -114,12 +114,12 @@ describe('Redirector', function () { `${baseUrl}/very/old/service/hello-world.png`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) expect(headers.location).to.equal( - 'http://raster.example.test/new/service/hello-world.png' + 'http://raster.example.test/new/service/hello-world.png', ) }) @@ -128,12 +128,12 @@ describe('Redirector', function () { `${baseUrl}/very/old/service/hello-world.svg?color=123&style=flat-square`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) expect(headers.location).to.equal( - '/new/service/hello-world.svg?color=123&style=flat-square' + '/new/service/hello-world.svg?color=123&style=flat-square', ) }) @@ -142,12 +142,12 @@ describe('Redirector', function () { `${baseUrl}/very/old/service/hello%0Dworld.svg?foobar=a%0Db`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) expect(headers.location).to.equal( - '/new/service/hello%0Dworld.svg?foobar=a%0Db' + '/new/service/hello%0Dworld.svg?foobar=a%0Db', ) }) @@ -174,12 +174,12 @@ describe('Redirector', function () { `${baseUrl}/another/old/service/token/abc123/hello-world.svg`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) expect(headers.location).to.equal( - '/new/service/hello-world.svg?token=abc123' + '/new/service/hello-world.svg?token=abc123', ) }) @@ -188,12 +188,12 @@ describe('Redirector', function () { `${baseUrl}/another/old/service/token/abc123/hello-world.svg?color=123&style=flat-square`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) expect(headers.location).to.equal( - '/new/service/hello-world.svg?color=123&style=flat-square&token=abc123' + '/new/service/hello-world.svg?color=123&style=flat-square&token=abc123', ) }) @@ -202,12 +202,12 @@ describe('Redirector', function () { `${baseUrl}/another/old/service/token/abc123/hello-world.svg?color=123&style=flat-square&token=def456`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) expect(headers.location).to.equal( - '/new/service/hello-world.svg?color=123&style=flat-square&token=abc123' + '/new/service/hello-world.svg?color=123&style=flat-square&token=abc123', ) }) @@ -229,12 +229,12 @@ describe('Redirector', function () { `${baseUrl}/override/service/token/abc123/hello-world.svg?style=flat-square&token=def456`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) expect(headers.location).to.equal( - '/new/service/hello-world.svg?style=flat-square&token=def456' + '/new/service/hello-world.svg?style=flat-square&token=def456', ) }) }) diff --git a/core/base-service/resource-cache.js b/core/base-service/resource-cache.js index 2bd8b747e550090efd0ab581645b3d12a58e0914..3e78935e74cf6dc132178a620112f7256e1e9a2f 100644 --- a/core/base-service/resource-cache.js +++ b/core/base-service/resource-cache.js @@ -40,7 +40,7 @@ async function getCachedResource({ } const { buffer } = await checkErrorResponse({})( - await requestFetcher(url, options) + await requestFetcher(url, options), ) let reqData diff --git a/core/base-service/route.js b/core/base-service/route.js index 24a7801ed14793501f06cf4db53fbe74d9a399a4..7c497fc872eac827f269b1c27219c46234a60ac5 100644 --- a/core/base-service/route.js +++ b/core/base-service/route.js @@ -52,7 +52,7 @@ function namedParamsForMatch(captureNames = [], match, ServiceClass) { if (captureNames.length !== captures.length) { throw new Error( `Service ${ServiceClass.name} declares incorrect number of named params ` + - `(expected ${captures.length}, got ${captureNames.length})` + `(expected ${captures.length}, got ${captureNames.length})`, ) } diff --git a/core/base-service/route.spec.js b/core/base-service/route.spec.js index 42326d8745d8b1efacfb500aace6c02ddccaa43a..932a9f1da25aefc87f451fc2dfdcede6dd43e87b 100644 --- a/core/base-service/route.spec.js +++ b/core/base-service/route.spec.js @@ -86,9 +86,9 @@ describe('Route helpers', function () { expect(() => namedParamsForMatch(captureNames, regex.exec('/foo/bar/baz.svg'), { name: 'MyService', - }) + }), ).to.throw( - 'Service MyService declares incorrect number of named params (expected 2, got 1)' + 'Service MyService declares incorrect number of named params (expected 2, got 1)', ) }) @@ -96,14 +96,14 @@ describe('Route helpers', function () { expect( getQueryParamNames({ queryParamSchema: Joi.object({ foo: Joi.string() }).required(), - }) + }), ).to.deep.equal(['foo']) expect( getQueryParamNames({ queryParamSchema: Joi.object({ foo: Joi.string() }) .rename('bar', 'foo', { ignoreUndefined: true, override: true }) .required(), - }) + }), ).to.deep.equal(['foo', 'bar']) }) }) diff --git a/core/base-service/service-definitions.js b/core/base-service/service-definitions.js index 8c1c94a155fc4c05b41e61658e5f7b921fa89816..6687e5bd61fa46ec58f15bf9cf0024507e888ef5 100644 --- a/core/base-service/service-definitions.js +++ b/core/base-service/service-definitions.js @@ -18,7 +18,7 @@ const serviceDefinition = Joi.object({ Joi.object({ format: Joi.string().required(), queryParams: arrayOfStrings, - }) + }), ), examples: Joi.array() .items( @@ -40,7 +40,7 @@ const serviceDefinition = Joi.object({ documentation: Joi.object({ __html: Joi.string().required(), // Valid HTML. }), - }) + }), ) .default([]), openApi: Joi.object().pattern( @@ -58,12 +58,12 @@ const serviceDefinition = Joi.object({ required: Joi.boolean().required(), schema: Joi.object({ type: Joi.string().required() }).required(), example: Joi.string(), - }) + }), ) .min(1) .required(), }).required(), - }).required() + }).required(), ), }).required() @@ -79,7 +79,7 @@ const serviceDefinitionExport = Joi.object({ id: Joi.string().required(), name: Joi.string().required(), keywords: arrayOfStrings, - }) + }), ) .required(), services: Joi.array().items(serviceDefinition).required(), diff --git a/core/base-service/validate.js b/core/base-service/validate.js index 23990b15dd58e1601f5b78befef4295bfb066bda..7e0de76920a453ba427e02adcc4008f94c31d079 100644 --- a/core/base-service/validate.js +++ b/core/base-service/validate.js @@ -12,7 +12,7 @@ function validate( allowAndStripUnknownKeys = true, }, data, - schema + schema, ) { if (!schema || !Joi.isSchema(schema)) { throw Error('A Joi schema is required') @@ -28,7 +28,7 @@ function validate( 'validate', emojic.womanShrugging, traceErrorMessage, - error.message + error.message, ) let prettyMessage = prettyErrorMessage diff --git a/core/base-service/validate.spec.js b/core/base-service/validate.spec.js index 9060e3256a5f76adfee6d3c27207ddce3b9143b1..14fc9cf1fa7bece39a4a05b6b373ccda213c0198 100644 --- a/core/base-service/validate.spec.js +++ b/core/base-service/validate.spec.js @@ -49,7 +49,7 @@ describe('validate', function () { sinon.match.string, traceSuccessMessage, { requiredString: 'bar' }, - { deep: true } + { deep: true }, ) }) }) @@ -60,13 +60,13 @@ describe('validate', function () { validate( options, { requiredString: ['this', "shouldn't", 'work'] }, - schema + schema, ) expect.fail('Expected to throw') } catch (e) { expect(e).to.be.an.instanceof(InvalidParameter) expect(e.message).to.equal( - 'Invalid Parameter: "requiredString" must be a string' + 'Invalid Parameter: "requiredString" must be a string', ) expect(e.prettyMessage).to.equal(prettyErrorMessage) } @@ -74,7 +74,7 @@ describe('validate', function () { 'validate', sinon.match.string, traceErrorMessage, - '"requiredString" must be a string' + '"requiredString" must be a string', ) }) @@ -86,16 +86,16 @@ describe('validate', function () { { requiredString: ['this', "shouldn't", 'work'], }, - schema + schema, ) expect.fail('Expected to throw') } catch (e) { expect(e).to.be.an.instanceof(InvalidParameter) expect(e.message).to.equal( - 'Invalid Parameter: "requiredString" must be a string' + 'Invalid Parameter: "requiredString" must be a string', ) expect(e.prettyMessage).to.equal( - `${prettyErrorMessage}: requiredString` + `${prettyErrorMessage}: requiredString`, ) } }) @@ -107,13 +107,13 @@ describe('validate', function () { validate( { ...options, allowAndStripUnknownKeys: false, includeKeys: true }, { requiredString: 'bar', extra: 'nonsense', more: 'bogus' }, - schema + schema, ) expect.fail('Expected to throw') } catch (e) { expect(e).to.be.an.instanceof(InvalidParameter) expect(e.message).to.equal( - 'Invalid Parameter: "extra" is not allowed. "more" is not allowed' + 'Invalid Parameter: "extra" is not allowed. "more" is not allowed', ) expect(e.prettyMessage).to.equal(`${prettyErrorMessage}: extra, more`) } diff --git a/core/server/influx-metrics.js b/core/server/influx-metrics.js index 961f6e93f0a2ac9961f5b8f738db59530a0e5300..07d9a48e3e3503850b935d793626f5aad6490729 100644 --- a/core/server/influx-metrics.js +++ b/core/server/influx-metrics.js @@ -27,14 +27,16 @@ export default class InfluxMetrics { response = await got.post(request) } catch (error) { log.error( - new Error(`Cannot push metrics. Cause: ${error.name}: ${error.message}`) + new Error( + `Cannot push metrics. Cause: ${error.name}: ${error.message}`, + ), ) } if (response && response.statusCode >= 300) { log.error( new Error( - `Cannot push metrics. ${request.url} responded with status code ${response.statusCode}` - ) + `Cannot push metrics. ${request.url} responded with status code ${response.statusCode}`, + ), ) } } @@ -42,7 +44,7 @@ export default class InfluxMetrics { startPushingMetrics() { this._intervalId = setInterval( () => this.sendMetrics(), - this._config.intervalSeconds * 1000 + this._config.intervalSeconds * 1000, ) } diff --git a/core/server/influx-metrics.spec.js b/core/server/influx-metrics.spec.js index f21f7c704fdb64b1654fc0a77d4d6fc15a5bed27..8862142749ffd9512e405e502f62b1cf1ab96442 100644 --- a/core/server/influx-metrics.spec.js +++ b/core/server/influx-metrics.spec.js @@ -47,7 +47,7 @@ describe('Influx metrics', function () { const influxMetrics = new InfluxMetrics(metricInstance, customConfig) expect(await influxMetrics.metrics()).to.be.contain( - 'instance=test-hostname' + 'instance=test-hostname', ) }) @@ -69,7 +69,7 @@ describe('Influx metrics', function () { const influxMetrics = new InfluxMetrics(metricInstance, customConfig) expect(await influxMetrics.metrics()).to.be.contain( - 'instance=test-hostname-alias' + 'instance=test-hostname-alias', ) }) }) @@ -96,7 +96,7 @@ describe('Influx metrics', function () { .persist() .post( '/metrics', - 'prometheus,application=shields,env=test-env,instance=instance2 counter1=11' + 'prometheus,application=shields,env=test-env,instance=instance2 counter1=11', ) .basicAuth({ user: 'metrics-username', pass: 'metrics-password' }) .reply(200) @@ -117,7 +117,7 @@ describe('Influx metrics', function () { await clock.tickAsync(10) expect(scope.isDone()).to.be.equal( true, - `pending mocks: ${scope.pendingMocks()}` + `pending mocks: ${scope.pendingMocks()}`, ) }) }) @@ -150,9 +150,9 @@ describe('Influx metrics', function () { .and( sinon.match.has( 'message', - 'Cannot push metrics. Cause: RequestError: Nock: Disallowed net connect for "shields-metrics.io:443/metrics"' - ) - ) + 'Cannot push metrics. Cause: RequestError: Nock: Disallowed net connect for "shields-metrics.io:443/metrics"', + ), + ), ) }) @@ -167,9 +167,9 @@ describe('Influx metrics', function () { .and( sinon.match.has( 'message', - 'Cannot push metrics. https://shields-metrics.io/metrics responded with status code 400' - ) - ) + 'Cannot push metrics. https://shields-metrics.io/metrics responded with status code 400', + ), + ), ) }) }) diff --git a/core/server/metrics/format-converters.js b/core/server/metrics/format-converters.js index 53a60b0f546305dd9e129350d9943ec341fca3f4..dbc0f000d4447e0d555b4b1e36eeeaa80735ee75 100644 --- a/core/server/metrics/format-converters.js +++ b/core/server/metrics/format-converters.js @@ -4,7 +4,7 @@ function promClientJsonToInfluxV2(metrics, extraLabels = {}) { return metrics .flatMap(metric => { const valuesByLabels = groupBy(metric.values, value => - JSON.stringify(Object.entries(value.labels).sort()) + JSON.stringify(Object.entries(value.labels).sort()), ) return Object.values(valuesByLabels).map(metricsWithSameLabel => { const labels = Object.entries(metricsWithSameLabel[0].labels) diff --git a/core/server/metrics/format-converters.spec.js b/core/server/metrics/format-converters.spec.js index 3ea4a51028cdc2df3e39b2feb8ba160e5f6ae6bc..0b5fde9c4d59c342eff24e89d6b44a365faa0a17 100644 --- a/core/server/metrics/format-converters.spec.js +++ b/core/server/metrics/format-converters.spec.js @@ -95,7 +95,7 @@ describe('Metric format converters', function () { prometheus,le=50 histogram1_bucket=2 prometheus,le=15 histogram1_bucket=2 prometheus,le=5 histogram1_bucket=1 -prometheus histogram1_count=3,histogram1_sum=111`) +prometheus histogram1_count=3,histogram1_sum=111`), ) }) @@ -118,7 +118,7 @@ prometheus histogram1_count=3,histogram1_sum=111`) prometheus,le=50 histogram1_bucket=2 prometheus,le=15 histogram1_bucket=2 prometheus,le=5 histogram1_bucket=1 -prometheus histogram1_count=3,histogram1_sum=111`) +prometheus histogram1_count=3,histogram1_sum=111`), ) }) @@ -145,7 +145,7 @@ prometheus histogram1_count=3,histogram1_sum=111`) sortLines(`prometheus,quantile=0.99 summary1=100 prometheus,quantile=0.9 summary1=100 prometheus,quantile=0.1 summary1=1 -prometheus summary1_count=3,summary1_sum=111`) +prometheus summary1_count=3,summary1_sum=111`), ) }) @@ -167,7 +167,7 @@ prometheus summary1_count=3,summary1_sum=111`) sortLines(`prometheus,quantile=0.99 summary1=100 prometheus,quantile=0.9 summary1=100 prometheus,quantile=0.1 summary1=1 -prometheus summary1_count=3,summary1_sum=111`) +prometheus summary1_count=3,summary1_sum=111`), ) }) @@ -204,7 +204,7 @@ prometheus summary1_count=3,summary1_sum=111`) }) expect(influx).to.be.equal( - 'prometheus,env=production,instance=instance1 counter1=11' + 'prometheus,env=production,instance=instance1 counter1=11', ) }) }) diff --git a/core/server/prometheus-metrics.js b/core/server/prometheus-metrics.js index 072a497c1bafb3dd05d111cf9f0830abc341a8f1..2aa211e0e400f1080899fe9a1c0a5c02d77f1ca3 100644 --- a/core/server/prometheus-metrics.js +++ b/core/server/prometheus-metrics.js @@ -79,7 +79,7 @@ export default class PrometheusMetrics { return this.counters.serviceResponseSize.labels( category, serviceFamily, - service + service, ) } } diff --git a/core/server/server.js b/core/server/server.js index 98d8673c97b917877e78a278bdf936c9542ecaa1..09b911202700724dcf1bf8337469292338a99c14 100644 --- a/core/server/server.js +++ b/core/server/server.js @@ -65,11 +65,11 @@ const publicConfigSchema = Joi.object({ bind: { port: Joi.alternatives().try( Joi.number().port(), - Joi.string().pattern(/^\\\\\.\\pipe\\.+$/) + Joi.string().pattern(/^\\\\\.\\pipe\\.+$/), ), address: Joi.alternatives().try( Joi.string().ip().required(), - Joi.string().hostname().required() + Joi.string().hostname().required(), ), }, metrics: { @@ -154,8 +154,8 @@ const publicConfigSchema = Joi.object({ path.dirname(fileURLToPath(import.meta.url)), '..', '..', - 'public' - ) + 'public', + ), ), requireCloudflare: Joi.boolean().required(), }).required() @@ -236,7 +236,7 @@ class Server { const publicConfig = Joi.attempt(config.public, publicConfigSchema) const privateConfig = this.validatePrivateConfig( config.private, - privateConfigSchema + privateConfigSchema, ) // We want to require an username and a password for the influx metrics // only if the influx metrics are enabled. The private config schema @@ -245,7 +245,7 @@ class Server { if (publicConfig.metrics.influx && publicConfig.metrics.influx.enabled) { this.validatePrivateConfig( config.private, - privateMetricsInfluxConfigSchema + privateMetricsInfluxConfigSchema, ) } this.config = { @@ -270,7 +270,7 @@ class Server { Object.assign({}, publicConfig.metrics.influx, { username: privateConfig.influx_username, password: privateConfig.influx_password, - }) + }), ) } } @@ -283,8 +283,8 @@ class Server { const badPaths = e.details.map(({ path }) => path) throw Error( `Private configuration is invalid. Check these paths: ${badPaths.join( - ',' - )}` + ',', + )}`, ) } } @@ -350,14 +350,14 @@ class Server { makeSend( 'svg', request.res, - end + end, )( makeBadge({ label: '410', message: `${format} no longer available`, color: 'lightgray', format: 'svg', - }) + }), ) }) @@ -366,14 +366,14 @@ class Server { makeSend( 'svg', request.res, - end + end, )( makeBadge({ label: '404', message: 'raster badges not available', color: 'lightgray', format: 'svg', - }) + }), ) }) } @@ -385,14 +385,14 @@ class Server { makeSend( format, request.res, - end + end, )( makeBadge({ label: '404', message: 'badge not found', color: 'red', format, - }) + }), ) }) } @@ -416,7 +416,7 @@ class Server { ask.res.statusCode = 301 ask.res.setHeader( 'Location', - rasterRedirectUrl({ rasterUrl }, ask.req.url) + rasterRedirectUrl({ rasterUrl }, ask.req.url), ) const cacheDuration = (30 * 24 * 3600) | 0 // 30 days. @@ -459,8 +459,8 @@ class Server { rasterUrl: config.public.rasterUrl, private: config.private, public: config.public, - } - ) + }, + ), ) } diff --git a/core/server/server.spec.js b/core/server/server.spec.js index 6de51974ff9590e17acdd617cf4fe870bd1beac5..32c0e04bf892b6aa51150962ff10f6878539a465 100644 --- a/core/server/server.spec.js +++ b/core/server/server.spec.js @@ -19,7 +19,7 @@ describe('The server', function () { public: { documentRoot: path.resolve( path.dirname(fileURLToPath(import.meta.url)), - 'test-public' + 'test-public', ), }, }) @@ -66,7 +66,7 @@ describe('The server', function () { it('should return cors header for the request', async function () { const { statusCode, headers } = await got( - `${baseUrl}badge/foo-bar-blue.svg` + `${baseUrl}badge/foo-bar-blue.svg`, ) expect(statusCode).to.equal(200) expect(headers['access-control-allow-origin']).to.equal('*') @@ -77,11 +77,11 @@ describe('The server', function () { `${baseUrl}:fruit-apple-green.png`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) expect(headers.location).to.equal( - 'http://raster.example.test/:fruit-apple-green.png' + 'http://raster.example.test/:fruit-apple-green.png', ) }) @@ -90,11 +90,11 @@ describe('The server', function () { `${baseUrl}badge/foo-bar-blue.png`, { followRedirect: false, - } + }, ) expect(statusCode).to.equal(301) expect(headers.location).to.equal( - 'http://raster.example.test/badge/foo-bar-blue.png' + 'http://raster.example.test/badge/foo-bar-blue.png', ) }) @@ -105,7 +105,7 @@ describe('The server', function () { it('should produce SVG badges with expected headers', async function () { const { statusCode, headers } = await got( - `${baseUrl}:fruit-apple-green.svg` + `${baseUrl}:fruit-apple-green.svg`, ) expect(statusCode).to.equal(200) expect(headers['content-type']).to.equal('image/svg+xml;charset=utf-8') @@ -119,7 +119,7 @@ describe('The server', function () { it('should produce JSON badges with expected headers', async function () { const { statusCode, body, headers } = await got( - `${baseUrl}:fruit-apple-green.json` + `${baseUrl}:fruit-apple-green.json`, ) expect(statusCode).to.equal(200) expect(headers['content-type']).to.equal('application/json') @@ -137,7 +137,7 @@ describe('The server', function () { // https://github.com/badges/shields/pull/1319 it('should not crash with a numeric logo', async function () { const { statusCode, body } = await got( - `${baseUrl}:fruit-apple-green.svg?logo=1` + `${baseUrl}:fruit-apple-green.svg?logo=1`, ) expect(statusCode).to.equal(200) expect(body) @@ -148,7 +148,7 @@ describe('The server', function () { it('should not crash with a numeric link', async function () { const { statusCode, body } = await got( - `${baseUrl}:fruit-apple-green.svg?link=1` + `${baseUrl}:fruit-apple-green.svg?link=1`, ) expect(statusCode).to.equal(200) expect(body) @@ -159,7 +159,7 @@ describe('The server', function () { it('should not crash with a boolean link', async function () { const { statusCode, body } = await got( - `${baseUrl}:fruit-apple-green.svg?link=true` + `${baseUrl}:fruit-apple-green.svg?link=true`, ) expect(statusCode).to.equal(200) expect(body) @@ -173,7 +173,7 @@ describe('The server', function () { `${baseUrl}this/is/not/a/badge.svg`, { throwHttpErrors: false, - } + }, ) expect(statusCode).to.equal(404) expect(body) @@ -187,7 +187,7 @@ describe('The server', function () { `${baseUrl}this/is/most/definitely/not/a/badge.js`, { throwHttpErrors: false, - } + }, ) expect(statusCode).to.equal(404) expect(body) @@ -211,7 +211,7 @@ describe('The server', function () { `${baseUrl}badge/foo-bar-blue.jpg`, { throwHttpErrors: false, - } + }, ) // TODO It would be nice if this were 404 or 410. expect(statusCode).to.equal(200) @@ -236,7 +236,7 @@ describe('The server', function () { await server.start() const { statusCode, body } = await got( - `${server.baseUrl}badge/foo-bar-blue.svg` + `${server.baseUrl}badge/foo-bar-blue.svg`, ) expect(statusCode).to.be.equal(200) @@ -365,7 +365,7 @@ describe('The server', function () { it('should require url when influx configuration is enabled', function () { delete customConfig.public.metrics.influx.url expect(() => new Server(customConfig)).to.throw( - '"metrics.influx.url" is required' + '"metrics.influx.url" is required', ) }) @@ -378,21 +378,21 @@ describe('The server', function () { it('should require timeoutMilliseconds when influx configuration is enabled', function () { delete customConfig.public.metrics.influx.timeoutMilliseconds expect(() => new Server(customConfig)).to.throw( - '"metrics.influx.timeoutMilliseconds" is required' + '"metrics.influx.timeoutMilliseconds" is required', ) }) it('should require intervalSeconds when influx configuration is enabled', function () { delete customConfig.public.metrics.influx.intervalSeconds expect(() => new Server(customConfig)).to.throw( - '"metrics.influx.intervalSeconds" is required' + '"metrics.influx.intervalSeconds" is required', ) }) it('should require instanceIdFrom when influx configuration is enabled', function () { delete customConfig.public.metrics.influx.instanceIdFrom expect(() => new Server(customConfig)).to.throw( - '"metrics.influx.instanceIdFrom" is required' + '"metrics.influx.instanceIdFrom" is required', ) }) @@ -400,7 +400,7 @@ describe('The server', function () { customConfig.public.metrics.influx.instanceIdFrom = 'env-var' delete customConfig.public.metrics.influx.instanceIdEnvVarName expect(() => new Server(customConfig)).to.throw( - '"metrics.influx.instanceIdEnvVarName" is required' + '"metrics.influx.instanceIdEnvVarName" is required', ) }) @@ -422,7 +422,7 @@ describe('The server', function () { it('should require envLabel when influx configuration is enabled', function () { delete customConfig.public.metrics.influx.envLabel expect(() => new Server(customConfig)).to.throw( - '"metrics.influx.envLabel" is required' + '"metrics.influx.envLabel" is required', ) }) @@ -439,14 +439,14 @@ describe('The server', function () { it('should require username when influx configuration is enabled', function () { delete customConfig.private.influx_username expect(() => new Server(customConfig)).to.throw( - 'Private configuration is invalid. Check these paths: influx_username' + 'Private configuration is invalid. Check these paths: influx_username', ) }) it('should require password when influx configuration is enabled', function () { delete customConfig.private.influx_password expect(() => new Server(customConfig)).to.throw( - 'Private configuration is invalid. Check these paths: influx_password' + 'Private configuration is invalid. Check these paths: influx_password', ) }) @@ -505,7 +505,7 @@ describe('The server', function () { }) .post( '/metrics', - /prometheus,application=shields,category=static,env=localhost-env,family=static-badge,instance=test-instance,service=static_badge service_requests_total=1\n/ + /prometheus,application=shields,category=static,env=localhost-env,family=static-badge,instance=test-instance,service=static_badge service_requests_total=1\n/, ) .basicAuth({ user: 'influx-username', pass: 'influx-password' }) .reply(200) @@ -515,7 +515,7 @@ describe('The server', function () { expect(scope.isDone()).to.be.equal( true, - `pending mocks: ${scope.pendingMocks()}` + `pending mocks: ${scope.pendingMocks()}`, ) }) }) diff --git a/core/service-test-runner/cli.js b/core/service-test-runner/cli.js index 917c1f859b499c4cc063c6b5d9e095bb77c0672a..9139977f3b0e82c3a5c5cf07d42f001921a3b397 100644 --- a/core/service-test-runner/cli.js +++ b/core/service-test-runner/cli.js @@ -121,8 +121,8 @@ if (typeof onlyServices === 'undefined' || onlyServices.includes('*****')) { } else { console.info( `Running tests for ${onlyServices.length} services: ${onlyServices.join( - ', ' - )}.\n` + ', ', + )}.\n`, ) runner.only(onlyServices) } diff --git a/core/service-test-runner/create-service-tester.js b/core/service-test-runner/create-service-tester.js index 17246b6693374427c4e8d590bf8cccf502a7b569..b59dfdaefb7abd4ae35e57ce8d1df25269fd1942 100644 --- a/core/service-test-runner/create-service-tester.js +++ b/core/service-test-runner/create-service-tester.js @@ -23,7 +23,7 @@ async function createServiceTester() { const ServiceClass = Object.values(await import(servicePath))[0] if (!(ServiceClass.prototype instanceof BaseService)) { throw Error( - `${servicePath} does not export a single service. Invoke new ServiceTester() directly.` + `${servicePath} does not export a single service. Invoke new ServiceTester() directly.`, ) } return ServiceTester.forServiceClass(ServiceClass) diff --git a/core/service-test-runner/icedfrisby-shields.js b/core/service-test-runner/icedfrisby-shields.js index 0cdbd9516ec3794a8454cdc0e49160124cfc9e9f..982911e90d824ada70ee558016c607121b5f3751 100644 --- a/core/service-test-runner/icedfrisby-shields.js +++ b/core/service-test-runner/icedfrisby-shields.js @@ -91,11 +91,11 @@ const factory = superclass => Joi.attempt( json[name], Joi.string().regex(expected), - `${name} mismatch:` + `${name} mismatch:`, ) } else { throw new Error( - "'expected' must be a string, a number, a regex, an array or a Joi schema" + "'expected' must be a string, a number, a regex, an array or a Joi schema", ) } } diff --git a/core/service-test-runner/runner.js b/core/service-test-runner/runner.js index 4b6cf47f898638975f8f77103ca1f0ae82250ee3..4f37bee3cae37bff11991449434abfe175cc7049 100644 --- a/core/service-test-runner/runner.js +++ b/core/service-test-runner/runner.js @@ -25,7 +25,7 @@ class Runner { */ async prepare() { this.testers = (await loadTesters()).flatMap(testerModule => - Object.values(testerModule) + Object.values(testerModule), ) this.testers.forEach(tester => { tester.beforeEach = () => { diff --git a/core/service-test-runner/services-for-title.spec.js b/core/service-test-runner/services-for-title.spec.js index f89f23d8f5af289cb9529fb6e6e5fa64fc8ff4cd..3d24af817089432a1367c51a1cbf2570a5ff6e70 100644 --- a/core/service-test-runner/services-for-title.spec.js +++ b/core/service-test-runner/services-for-title.spec.js @@ -10,7 +10,7 @@ describe('Services from PR title', function () { ]) given('[CRAN CPAN CTAN] Add test coverage').expect(['cran', 'cpan', 'ctan']) given( - '[RFC] Add Joi-based request validation to BaseJsonService and rewrite [NPM] badges' + '[RFC] Add Joi-based request validation to BaseJsonService and rewrite [NPM] badges', ).expect(['npm']) given('make changes to [CRAN] and [CPAN]').expect(['cran', 'cpan']) given('[github appveyor ]').expect(['github', 'appveyor']) diff --git a/core/token-pooling/sql-token-persistence.integration.js b/core/token-pooling/sql-token-persistence.integration.js index 862a898b5efd7b2c1aec63331595557ae737b391..2febee7483924ff58bda846daed9adab319f1ce9 100644 --- a/core/token-pooling/sql-token-persistence.integration.js +++ b/core/token-pooling/sql-token-persistence.integration.js @@ -36,7 +36,7 @@ describe('SQL token persistence', function () { beforeEach('Create temporary table', async function () { await pool.query( - `CREATE TEMPORARY TABLE ${tableName} (LIKE github_user_tokens INCLUDING ALL);` + `CREATE TEMPORARY TABLE ${tableName} (LIKE github_user_tokens INCLUDING ALL);`, ) }) afterEach('Drop temporary table', async function () { @@ -57,7 +57,7 @@ describe('SQL token persistence', function () { initialTokens.forEach(async token => { await pool.query( `INSERT INTO pg_temp.${tableName} (token) VALUES ($1::text);`, - [token] + [token], ) }) }) @@ -77,7 +77,7 @@ describe('SQL token persistence', function () { await persistence.noteTokenAdded(newToken) const result = await pool.query( - `SELECT token FROM pg_temp.${tableName};` + `SELECT token FROM pg_temp.${tableName};`, ) const savedTokens = result.rows.map(row => row.token) expect(savedTokens.sort()).to.deep.equal(expected) @@ -93,7 +93,7 @@ describe('SQL token persistence', function () { await persistence.noteTokenRemoved(toRemove) const result = await pool.query( - `SELECT token FROM pg_temp.${tableName};` + `SELECT token FROM pg_temp.${tableName};`, ) const savedTokens = result.rows.map(row => row.token) expect(savedTokens.sort()).to.deep.equal(expected) diff --git a/core/token-pooling/sql-token-persistence.js b/core/token-pooling/sql-token-persistence.js index 4c706966d75d12a1f1d1e176d4d17e8a14e0aa89..37e0112a48ea4f5f2fabf0c4bb59e6d310ed4978 100644 --- a/core/token-pooling/sql-token-persistence.js +++ b/core/token-pooling/sql-token-persistence.js @@ -28,14 +28,14 @@ export default class SqlTokenPersistence { async onTokenAdded(token) { return await this.pool.query( `INSERT INTO ${this.table} (token) VALUES ($1::text) ON CONFLICT (token) DO NOTHING;`, - [token] + [token], ) } async onTokenRemoved(token) { return await this.pool.query( `DELETE FROM ${this.table} WHERE token=$1::text;`, - [token] + [token], ) } diff --git a/core/token-pooling/token-pool.spec.js b/core/token-pooling/token-pool.spec.js index 373a4ef479ff8c3c0704b709fa018a33acfe9f39..2182251a45b3ae7e242f27fb8a0ae8757e6c802f 100644 --- a/core/token-pooling/token-pool.spec.js +++ b/core/token-pooling/token-pool.spec.js @@ -21,16 +21,16 @@ describe('The token pool', function () { it('should yield the expected tokens', function () { ids.forEach(id => - times(batchSize, () => expect(tokenPool.next().id).to.equal(id)) + times(batchSize, () => expect(tokenPool.next().id).to.equal(id)), ) }) it('should repeat when reaching the end', function () { ids.forEach(id => - times(batchSize, () => expect(tokenPool.next().id).to.equal(id)) + times(batchSize, () => expect(tokenPool.next().id).to.equal(id)), ) ids.forEach(id => - times(batchSize, () => expect(tokenPool.next().id).to.equal(id)) + times(batchSize, () => expect(tokenPool.next().id).to.equal(id)), ) }) diff --git a/dangerfile.js b/dangerfile.js index c54b5a4392ebf93a03f4a8b11d8e4d28aeeaf089..527be50d9c10b3ad6b2eb7e4ff4b327859778ce0 100644 --- a/dangerfile.js +++ b/dangerfile.js @@ -16,7 +16,7 @@ const { fileMatch } = danger.git const documentation = fileMatch( '**/*.md', 'frontend/docs/**', - 'frontend/src/**' + 'frontend/src/**', ) const server = fileMatch('core/server/**.js', '!*.spec.js') const serverTests = fileMatch('core/server/**.spec.js') @@ -33,7 +33,7 @@ message( [ ':sparkles: Thanks for your contribution to Shields, ', `@${danger.github.pr.user.login}!`, - ].join('') + ].join(''), ) const targetBranch = danger.github.pr.base.ref @@ -48,7 +48,7 @@ if (documentation.edited) { [ 'Thanks for contributing to our documentation. ', 'We :heart: our [documentarians](http://www.writethedocs.org/)!', - ].join('') + ].join(''), ) } @@ -63,7 +63,7 @@ if (server.modified && !serverTests.modified) { [ 'This PR modified the server but none of its tests. <br>', "That's okay so long as it's refactoring existing code.", - ].join('') + ].join(''), ) } @@ -74,7 +74,7 @@ if (legacyHelpers.created) { [ 'This PR modified helper functions in `lib/` but not accompanying tests. <br>', "That's okay so long as it's refactoring existing code.", - ].join('') + ].join(''), ) } @@ -85,7 +85,7 @@ if (logos.created) { 'Please ensure your contribution follows our ', '[guidance](https://github.com/badges/shields/blob/master/doc/logos.md#contributing-logos) ', 'for logo submissions.', - ].join('') + ].join(''), ) } @@ -94,7 +94,7 @@ if (capitals.created || underscores.created) { [ 'JavaScript source files should be named with `kebab-case` ', '(dash-separated lowercase).', - ].join('') + ].join(''), ) } @@ -116,7 +116,7 @@ if (allFiles.length > 100) { ':books: Remember to ensure any changes to `config.private` ', `in \`${file}\` are reflected in the [server secrets documentation]`, '(https://github.com/badges/shields/blob/master/doc/server-secrets.md)', - ].join('') + ].join(''), ) } @@ -126,7 +126,7 @@ if (allFiles.length > 100) { `Found 'assert' statement added in \`${file}\`. <br>`, 'Please ensure tests are written using Chai ', '[expect syntax](http://chaijs.com/guide/styles/#expect)', - ].join('') + ].join(''), ) } @@ -135,7 +135,7 @@ if (allFiles.length > 100) { [ `Found import of '@hapi/joi' in \`${file}\`. <br>`, "Joi must be imported as 'joi'.", - ].join('') + ].join(''), ) } }) @@ -168,7 +168,7 @@ affectedServices.forEach(service => { [ `This PR modified service code for <kbd>${service}</kbd> but not its test code. <br>`, "That's okay so long as it's refactoring existing code.", - ].join('') + ].join(''), ) } }) diff --git a/doc/service-tests.md b/doc/service-tests.md index 45f5cd81633caf1e07f8e12abec7341fc5537d02..cb655ee3009b0fc5b81dfe0b20ead9efdc3aa96f 100644 --- a/doc/service-tests.md +++ b/doc/service-tests.md @@ -186,7 +186,7 @@ t.create('Build status (private application)') .intercept(nock => nock('https://app.wercker.com/api/v3/applications/') .get('/wercker/go-wercker-api/builds?limit=1') - .reply(401) + .reply(401), ) .expectBadge({ label: 'build', message: 'private application not supported' }) ``` @@ -227,7 +227,7 @@ t.create('Build passed') .intercept(nock => nock('https://app.wercker.com/api/v3/applications/') .get('/wercker/go-wercker-api/builds?limit=1') - .reply(200, [{ status: 'finished', result: 'passed' }]) + .reply(200, [{ status: 'finished', result: 'passed' }]), ) .expectBadge({ label: 'build', @@ -240,7 +240,7 @@ t.create('Build failed') .intercept(nock => nock('https://app.wercker.com/api/v3/applications/') .get('/wercker/go-wercker-api/builds?limit=1') - .reply(200, [{ status: 'finished', result: 'failed' }]) + .reply(200, [{ status: 'finished', result: 'failed' }]), ) .expectBadge({ label: 'build', message: 'failed', color: 'red' }) ``` diff --git a/entrypoint.spec.js b/entrypoint.spec.js index 4325c0365ab81a95144fb56d002009ea99fc49ad..6246d70a914747f61b0bbbf571ef27c4b4922230 100644 --- a/entrypoint.spec.js +++ b/entrypoint.spec.js @@ -18,7 +18,7 @@ after('shut down the server', async function () { it('should render a badge', async function () { this.timeout('30s') const { statusCode, body } = await got( - 'http://localhost:1111/badge/fruit-apple-green.svg' + 'http://localhost:1111/badge/fruit-apple-green.svg', ) expect(statusCode).to.equal(200) expect(body).to.satisfy(isSvg).and.to.include('fruit').and.to.include('apple') diff --git a/frontend/src/theme/ApiDemoPanel/Curl/index.js b/frontend/src/theme/ApiDemoPanel/Curl/index.js index 59d3a3b0822186ed02e0563c5922b8b4f058eb4c..91e077cfc48b0aed362c75ed86cd524cbe7e3883 100644 --- a/frontend/src/theme/ApiDemoPanel/Curl/index.js +++ b/frontend/src/theme/ApiDemoPanel/Curl/index.js @@ -183,11 +183,11 @@ function Curl({ postman, codeSamples }) { } setCodeText(snippet) - } + }, ) } else if (language && !!language.source) { setCodeText( - language.source.replace('$url', postmanRequest.url.toString()) + language.source.replace('$url', postmanRequest.url.toString()), ) } else { setCodeText('') @@ -230,7 +230,7 @@ function Curl({ postman, codeSamples }) { className={clsx( language === lang ? styles.selected : undefined, language === lang ? 'api-code-tab--active' : undefined, - 'api-code-tab' + 'api-code-tab', )} key={lang.tabName || lang.label} onClick={() => setLanguage(lang)} diff --git a/lib/load-logos.js b/lib/load-logos.js index f48f32d0d939865d044679c238d864e0092d627f..9af0cc875b32f436850052bc39fc9cf6b02b5eaa 100644 --- a/lib/load-logos.js +++ b/lib/load-logos.js @@ -9,7 +9,7 @@ function loadLogos() { const logoDir = path.join( path.dirname(fileURLToPath(import.meta.url)), '..', - 'logo' + 'logo', ) const logoFiles = fs.readdirSync(logoDir) logoFiles.forEach(filename => { diff --git a/lib/load-simple-icons.spec.js b/lib/load-simple-icons.spec.js index da64c20d34a807896f8c363b543de6164e5f2946..46aa39eb3d2ab296c1a7115e902ad3979e7c87a2 100644 --- a/lib/load-simple-icons.spec.js +++ b/lib/load-simple-icons.spec.js @@ -11,7 +11,7 @@ describe('loadSimpleIcons', function () { expect(simpleIcons.sentry.base64).to.have.all.keys( 'default', 'light', - 'dark' + 'dark', ) }) diff --git a/lib/logos.js b/lib/logos.js index dd4e7f7247cf60f8167288f9c1d50ebca0d9ab8c..57e4caf124eac1a824c9df312813d226f0c173c1 100644 --- a/lib/logos.js +++ b/lib/logos.js @@ -98,7 +98,7 @@ function getSimpleIcon({ name, color, style }) { const svgColor = toSvgColor(color) if (svgColor) { return svg2base64( - simpleIcons[key].svg.replace('<svg', `<svg fill="${svgColor}"`) + simpleIcons[key].svg.replace('<svg', `<svg fill="${svgColor}"`), ) } else { const iconStyle = getSimpleIconStyle({ icon: simpleIcons[key], style }) diff --git a/lib/logos.spec.js b/lib/logos.spec.js index b0bb5d23367127150c2c27b1474608c5fd0c24e0..33b6175e8ec0265aa587472dadd9455f2f7d7489 100644 --- a/lib/logos.spec.js +++ b/lib/logos.spec.js @@ -11,7 +11,7 @@ import { describe('Logo helpers', function () { test(prependPrefix, () => { given('data:image/svg+xml;base64,PHN2ZyB4bWxu', 'data:').expect( - 'data:image/svg+xml;base64,PHN2ZyB4bWxu' + 'data:image/svg+xml;base64,PHN2ZyB4bWxu', ) given('foobar', 'data:').expect('data:foobar') given(undefined, 'data:').expect(undefined) @@ -26,52 +26,52 @@ describe('Logo helpers', function () { // attempted XSS attack given( - 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+P+/HgAFhAJ/wlseKgAAAABJRU5ErkJggg=="/><script>alert()</script>' + 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+P+/HgAFhAJ/wlseKgAAAABJRU5ErkJggg=="/><script>alert()</script>', ).expect(false) }) test(prepareNamedLogo, () => { // use multicolored shield icon given({ name: 'npm' }).expect( - 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0MCA0MCI+PHBhdGggZD0iTTAgMGg0MHY0MEgwVjB6IiBmaWxsPSIjY2IwMDAwIi8+PHBhdGggZmlsbD0iI2ZmZiIgZD0iTTcgN2gyNnYyNmgtN1YxNGgtNnYxOUg3eiIvPjwvc3ZnPg==' + 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0MCA0MCI+PHBhdGggZD0iTTAgMGg0MHY0MEgwVjB6IiBmaWxsPSIjY2IwMDAwIi8+PHBhdGggZmlsbD0iI2ZmZiIgZD0iTTcgN2gyNnYyNmgtN1YxNGgtNnYxOUg3eiIvPjwvc3ZnPg==', ) // use simple icon with color given({ name: 'npm', color: 'blue' }).expect( - 'data:image/svg+xml;base64,PHN2ZyBmaWxsPSIjMDA3ZWM2IiByb2xlPSJpbWciIHZpZXdCb3g9IjAgMCAyNCAyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48dGl0bGU+bnBtPC90aXRsZT48cGF0aCBkPSJNMS43NjMgMEMuNzg2IDAgMCAuNzg2IDAgMS43NjN2MjAuNDc0QzAgMjMuMjE0Ljc4NiAyNCAxLjc2MyAyNGgyMC40NzRjLjk3NyAwIDEuNzYzLS43ODYgMS43NjMtMS43NjNWMS43NjNDMjQgLjc4NiAyMy4yMTQgMCAyMi4yMzcgMHpNNS4xMyA1LjMyM2wxMy44MzcuMDE5LS4wMDkgMTMuODM2aC0zLjQ2NGwuMDEtMTAuMzgyaC0zLjQ1NkwxMi4wNCAxOS4xN0g1LjExM3oiLz48L3N2Zz4=' + 'data:image/svg+xml;base64,PHN2ZyBmaWxsPSIjMDA3ZWM2IiByb2xlPSJpbWciIHZpZXdCb3g9IjAgMCAyNCAyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj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Y2LTUuOTMgMC0xLjMxLjQ2NS0yLjM4IDEuMjM1LTMuMjItLjEzNS0uMzAzLS41NC0xLjUyMy4xMDUtMy4xNzYgMCAwIDEuMDA1LS4zMjIgMy4zIDEuMjMuOTYtLjI2NyAxLjk4LS4zOTkgMy0uNDA1IDEuMDIuMDA2IDIuMDQuMTM4IDMgLjQwNSAyLjI4LTEuNTUyIDMuMjg1LTEuMjMgMy4yODUtMS4yMy42NDUgMS42NTMuMjQgMi44NzMuMTIgMy4xNzYuNzY1Ljg0IDEuMjMgMS45MSAxLjIzIDMuMjIgMCA0LjYxLTIuODA1IDUuNjI1LTUuNDc1IDUuOTIuNDIuMzYuODEgMS4wOTYuODEgMi4yMiAwIDEuNjA2LS4wMTUgMi44OTYtLjAxNSAzLjI4NiAwIC4zMTUuMjEuNjkuODI1LjU3QzIwLjU2NSAyMi4wOTIgMjQgMTcuNTkyIDI0IDEyLjI5N2MwLTYuNjI3LTUuMzczLTEyLTEyLTEyIi8+PC9zdmc+', ) // use simple icon with color given({ name: 'github', color: 'red' }).expect( - 'data:image/svg+xml;base64,PHN2ZyBmaWxsPSIjZTA1ZDQ0IiByb2xlPSJpbWciIHZpZXdCb3g9IjAgMCAyNCAyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48dGl0bGU+R2l0SHViPC90aXRsZT48cGF0aCBkPSJNMTIgLjI5N2MtNi42MyAwLTEyIDUuMzczLTEyIDEyIDAgNS4zMDMgMy40MzggOS44IDguMjA1IDExLjM4NS42LjExMy44Mi0uMjU4LjgyLS41NzcgMC0uMjg1LS4wMS0xLjA0LS4wMTUtMi4wNC0zLjMzOC43MjQtNC4wNDItMS42MS00LjA0Mi0xLjYxQzQuNDIyIDE4LjA3IDMuNjMzIDE3LjcgMy42MzMgMTcuN2MtMS4wODctLjc0NC4wODQtLjcyOS4wODQtLjcyOSAxLjIwNS4wODQgMS44MzggMS4yMzYgMS44MzggMS4yMzYgMS4wNyAxLjgzN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jQ4NS40ODV2LjgxMWEuNDg1LjQ4NSAwIDEgMCAuOTcgMHYtLjMyNmguNzQ2djMuMzA4aC0uNTIxYS40ODUuNDg1IDAgMSAwIDAgLjk3aDIuMDYxYS40ODUuNDg1IDAgMSAwIDAtLjk3aC0uNTdWMy45NjNoLjg1M3YuMzI2YS40ODUuNDg1IDAgMSAwIC45NyAwdi0uODExYS40ODUuNDg1IDAgMCAwLS40ODUtLjQ4NXoiLz48L3N2Zz4=', ) it('preserves color if light logo on dark background', function () { const logo = prepareNamedLogo({ name: 'javascript' }) const decodedLogo = Buffer.from( logo.replace('data:image/svg+xml;base64,', ''), - 'base64' + 'base64', ).toString('ascii') expect(decodedLogo).to.contain('fill="#F7DF1E"') }) @@ -79,7 +79,7 @@ describe('Logo helpers', function () { const logo = prepareNamedLogo({ name: 'javascript', style: 'social' }) const decodedLogo = Buffer.from( logo.replace('data:image/svg+xml;base64,', ''), - 'base64' + 'base64', ).toString('ascii') expect(decodedLogo).to.contain('fill="#333"') }) @@ -88,7 +88,7 @@ describe('Logo helpers', function () { const logo = prepareNamedLogo({ name: 'nuget', style: 'social' }) const decodedLogo = Buffer.from( logo.replace('data:image/svg+xml;base64,', ''), - 'base64' + 'base64', ).toString('ascii') expect(decodedLogo).to.contain('fill="#004880"') }) @@ -96,7 +96,7 @@ describe('Logo helpers', function () { const logo = prepareNamedLogo({ name: 'nuget' }) const decodedLogo = Buffer.from( logo.replace('data:image/svg+xml;base64,', ''), - 'base64' + 'base64', ).toString('ascii') expect(decodedLogo).to.contain('fill="whitesmoke"') }) @@ -105,7 +105,7 @@ describe('Logo helpers', function () { const logo = prepareNamedLogo({ name: 'skype' }) const decodedLogo = Buffer.from( logo.replace('data:image/svg+xml;base64,', ''), - 'base64' + 'base64', ).toString('ascii') expect(decodedLogo).to.contain('fill="#00AFF0"') }) @@ -113,7 +113,7 @@ describe('Logo helpers', function () { const logo = prepareNamedLogo({ name: 'skype', style: 'social' }) const decodedLogo = Buffer.from( logo.replace('data:image/svg+xml;base64,', ''), - 'base64' + 'base64', ).toString('ascii') expect(decodedLogo).to.contain('fill="#00AFF0"') }) @@ -134,10 +134,10 @@ describe('Logo helpers', function () { given('npm', { logo: 'data:image/svg+xml;base64,PHN2ZyB\n4bWxu' }), ]).expect('data:image/svg+xml;base64,PHN2ZyB4bWxu') forCases([given('npm', { logo: '' }), given(undefined, {})]).expect( - undefined + undefined, ) given('npm', {}).expect( - 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0MCA0MCI+PHBhdGggZD0iTTAgMGg0MHY0MEgwVjB6IiBmaWxsPSIjY2IwMDAwIi8+PHBhdGggZmlsbD0iI2ZmZiIgZD0iTTcgN2gyNnYyNmgtN1YxNGgtNnYxOUg3eiIvPjwvc3ZnPg==' + 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0MCA0MCI+PHBhdGggZD0iTTAgMGg0MHY0MEgwVjB6IiBmaWxsPSIjY2IwMDAwIi8+PHBhdGggZmlsbD0iI2ZmZiIgZD0iTTcgN2gyNnYyNmgtN1YxNGgtNnYxOUg3eiIvPjwvc3ZnPg==', ) }) }) diff --git a/lib/svg-helpers.js b/lib/svg-helpers.js index c688c347766fce0529234dc9370f2d19f738f980..e36bf10e1981a5fb3348e5f28c39ad3aef2a2680 100644 --- a/lib/svg-helpers.js +++ b/lib/svg-helpers.js @@ -1,6 +1,6 @@ function svg2base64(svg) { return `data:image/svg+xml;base64,${Buffer.from(svg.trim()).toString( - 'base64' + 'base64', )}` } diff --git a/lib/svg-helpers.spec.js b/lib/svg-helpers.spec.js index 6434f661f89dd00e4d0674964c0e4e2cc4ca2784..dac50f8f81219ec069984da20eeeef330eb457a2 100644 --- a/lib/svg-helpers.spec.js +++ b/lib/svg-helpers.spec.js @@ -4,7 +4,7 @@ import { svg2base64 } from './svg-helpers.js' describe('SVG helpers', function () { test(svg2base64, () => { given('<svg xmlns="http://www.w3.org/2000/svg"/>').expect( - 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciLz4=' + 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciLz4=', ) }) }) diff --git a/package-lock.json b/package-lock.json index 3051239c9f90fc804b0df9251e4ec2228add8277..ccf7e1dd1eee2179adc84afe5078f43c96bab139 100644 --- a/package-lock.json +++ b/package-lock.json @@ -109,7 +109,7 @@ "npm-run-all": "^4.1.5", "open-cli": "^7.2.0", "portfinder": "^1.0.32", - "prettier": "2.8.8", + "prettier": "3.0.0", "prism-react-renderer": "^1.2.1", "react": "^17.0.2", "react-dom": "^17.0.2", @@ -20806,15 +20806,15 @@ } }, "node_modules/prettier": { - "version": "2.8.8", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz", - "integrity": "sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.0.0.tgz", + "integrity": "sha512-zBf5eHpwHOGPC47h0zrPyNn+eAEIdEzfywMoYn2XPi0P44Zp0tSq64rq0xAREh4auw2cJZHo9QUob+NqCQky4g==", "dev": true, "bin": { - "prettier": "bin-prettier.js" + "prettier": "bin/prettier.cjs" }, "engines": { - "node": ">=10.13.0" + "node": ">=14" }, "funding": { "url": "https://github.com/prettier/prettier?sponsor=1" @@ -43451,9 +43451,9 @@ "dev": true }, "prettier": { - "version": "2.8.8", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.8.tgz", - "integrity": "sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.0.0.tgz", + "integrity": "sha512-zBf5eHpwHOGPC47h0zrPyNn+eAEIdEzfywMoYn2XPi0P44Zp0tSq64rq0xAREh4auw2cJZHo9QUob+NqCQky4g==", "dev": true }, "pretty-bytes": { diff --git a/package.json b/package.json index 15f374f0fe39f3aa6ae49ce0fc3811dd82de00ce..274916c162382212c50fed696bfc03a60937b738 100644 --- a/package.json +++ b/package.json @@ -196,7 +196,7 @@ "npm-run-all": "^4.1.5", "open-cli": "^7.2.0", "portfinder": "^1.0.32", - "prettier": "2.8.8", + "prettier": "3.0.0", "prism-react-renderer": "^1.2.1", "react": "^17.0.2", "react-dom": "^17.0.2", diff --git a/scripts/badge-cli.js b/scripts/badge-cli.js index bf8e94382819941a44f7ce4735fc4c54be5bf492..8bc36f907bc070f662c375ba6d1e8d30e850f520 100644 --- a/scripts/badge-cli.js +++ b/scripts/badge-cli.js @@ -19,7 +19,7 @@ async function traceBadge(badgeUrl) { const server = new Server(config.util.toObject()) await server.start() const body = await got( - `${server.baseUrl.replace(/\/$/, '')}${badgeUrl}` + `${server.baseUrl.replace(/\/$/, '')}${badgeUrl}`, ).json() trace.logTrace('outbound', emojic.shield, 'Rendered badge', body) await server.stop() diff --git a/scripts/capture-timings.js b/scripts/capture-timings.js index f68daed7e632c752d77488a5d1ee21d95f690fc8..ed901f93511e1845a29dcbe9125cc0751f340d2b 100644 --- a/scripts/capture-timings.js +++ b/scripts/capture-timings.js @@ -29,14 +29,14 @@ async function captureTimings(warmupIterations) { function logResults({ times, iterations, warmupIterations }) { if (isNaN(iterations)) { console.log( - 'No timings captured. Have you included console.time statements in the badge creation code path?' + 'No timings captured. Have you included console.time statements in the badge creation code path?', ) } else { const timedIterations = iterations - warmupIterations for (const [label, time] of Object.entries(times)) { const averageTime = time / timedIterations console.log( - `Average '${label}' time over ${timedIterations} iterations: ${averageTime}ms` + `Average '${label}' time over ${timedIterations} iterations: ${averageTime}ms`, ) } } diff --git a/scripts/export-openapi-cli.js b/scripts/export-openapi-cli.js index bc0481ba17576097d57585859dd2e0fac706ecb1..f35bc049407e8f679da5c3a7804eb865b0c3bf55 100644 --- a/scripts/export-openapi-cli.js +++ b/scripts/export-openapi-cli.js @@ -13,7 +13,7 @@ function writeSpec(filename, spec) { fs.writeFileSync( filename, - yaml.dump(cleaned, { flowLevel: 5, forceQuotes: true }) + yaml.dump(cleaned, { flowLevel: 5, forceQuotes: true }), ) } @@ -22,28 +22,28 @@ function writeSpec(filename, spec) { for (const category of definitions.categories) { const services = definitions.services.filter( - service => service.category === category.id && !service.isDeprecated + service => service.category === category.id && !service.isDeprecated, ) writeSpec( path.join(specsPath, `${category.id}.yaml`), - category2openapi(category, services) + category2openapi(category, services), ) } let coreServices = [] coreServices = coreServices.concat( definitions.services.filter( - service => service.category === 'static' && !service.isDeprecated - ) + service => service.category === 'static' && !service.isDeprecated, + ), ) coreServices = coreServices.concat( definitions.services.filter( - service => service.category === 'dynamic' && !service.isDeprecated - ) + service => service.category === 'dynamic' && !service.isDeprecated, + ), ) writeSpec( path.join(specsPath, '1core.yaml'), - category2openapi({ name: 'Core' }, coreServices) + category2openapi({ name: 'Core' }, coreServices), ) })() diff --git a/scripts/update-github-api.js b/scripts/update-github-api.js index d66f9426c07cf0577c7a1f9508a5368331f12b61..63685ed23b62596d2a4bd91cfa9b93a1ffe9dad1 100644 --- a/scripts/update-github-api.js +++ b/scripts/update-github-api.js @@ -15,5 +15,5 @@ if (latestDate === config.public.services.github.restApiVersion) { config.public.services.github.restApiVersion = latestDate await fs.writeFile( './config/default.yml', - yaml.dump(config, { forceQuotes: true }) + yaml.dump(config, { forceQuotes: true }), ) diff --git a/server.js b/server.js index a339dc2679a27c9be8fae14f7b651ecd10e6a90e..fb83100178dd2cacdc8ec5acffefd48adc26a75e 100644 --- a/server.js +++ b/server.js @@ -12,13 +12,13 @@ Sentry.init({ dsn: process.env.SENTRY_DSN || config.private.sentry_dsn, integrations: integrations => { const filtered = integrations.filter( - integration => !disabledIntegrations.includes(integration.name) + integration => !disabledIntegrations.includes(integration.name), ) if (filtered.length !== integrations.length - disabledIntegrations.length) { throw Error( `An error occurred while filtering integrations. The following inetgrations were found: ${integrations.map( - ({ name }) => name - )}` + ({ name }) => name, + )}`, ) } return filtered @@ -37,14 +37,14 @@ console.dir(config.public, { depth: null }) if (fs.existsSync('.env')) { console.error( - 'Legacy .env file found. It should be deleted and replaced with environment variables or config/local.yml' + 'Legacy .env file found. It should be deleted and replaced with environment variables or config/local.yml', ) process.exit(1) } if (config.private.redis_url != null) { console.error( - 'RedisTokenPersistence has been removed. Migrate to SqlTokenPersistence' + 'RedisTokenPersistence has been removed. Migrate to SqlTokenPersistence', ) process.exit(1) } @@ -52,11 +52,11 @@ if (config.private.redis_url != null) { const legacySecretsPath = path.join( path.dirname(fileURLToPath(import.meta.url)), 'private', - 'secret.json' + 'secret.json', ) if (fs.existsSync(legacySecretsPath)) { console.error( - `Legacy secrets file found at ${legacySecretsPath}. It should be deleted and secrets replaced with environment variables or config/local.yml` + `Legacy secrets file found at ${legacySecretsPath}. It should be deleted and secrets replaced with environment variables or config/local.yml`, ) process.exit(1) } diff --git a/services/appveyor/appveyor-build.tester.js b/services/appveyor/appveyor-build.tester.js index b1141067e49b09252117c7ec4f809b56982f375d..420dd9660580aa1fa12780084bc1c9f86d973d58 100644 --- a/services/appveyor/appveyor-build.tester.js +++ b/services/appveyor/appveyor-build.tester.js @@ -25,7 +25,7 @@ t.create('CI status on project that does exist but has no builds yet') .intercept(nock => nock('https://ci.appveyor.com/api/projects/') .get('/gruntjs/grunt') - .reply(200, {}) + .reply(200, {}), ) .expectBadge({ label: 'build', diff --git a/services/appveyor/appveyor-job-build.spec.js b/services/appveyor/appveyor-job-build.spec.js index 4e83a26fd427d17334d5feadc6f6e8cb07171812..494ff9edca2dc100491516e749de17a73c89abfa 100644 --- a/services/appveyor/appveyor-job-build.spec.js +++ b/services/appveyor/appveyor-job-build.spec.js @@ -53,7 +53,7 @@ describe('AppveyorJobBuild', function () { ], }, }, - }) + }), ) .to.throw(NotFound) .with.property('prettyMessage', 'job not found') diff --git a/services/appveyor/appveyor-tests.service.js b/services/appveyor/appveyor-tests.service.js index d68653971f7b977b282b2b463258c6bcd7d99a6e..05df133dfc84393a0cca08439edb082c4c5b4dfd 100644 --- a/services/appveyor/appveyor-tests.service.js +++ b/services/appveyor/appveyor-tests.service.js @@ -111,7 +111,7 @@ export default class AppVeyorTests extends AppVeyorBase { passed_label: passedLabel, failed_label: failedLabel, skipped_label: skippedLabel, - } + }, ) { const isCompact = compactMessage !== undefined const data = await this.fetch({ user, repo, branch }) diff --git a/services/appveyor/appveyor-tests.tester.js b/services/appveyor/appveyor-tests.tester.js index 2c3f564df1ef5a59a503f8279e32d3bad379e266..8d7130aabe7b45cd1542e905a3cf80348dae2ac5 100644 --- a/services/appveyor/appveyor-tests.tester.js +++ b/services/appveyor/appveyor-tests.tester.js @@ -61,7 +61,7 @@ t.create('Test status on project that does exist but has no builds yet') .intercept(nock => nock('https://ci.appveyor.com/api/projects/') .get('/gruntjs/grunt') - .reply(200, {}) + .reply(200, {}), ) .expectBadge({ label: 'tests', diff --git a/services/archlinux/archlinux.service.js b/services/archlinux/archlinux.service.js index c3ee192b13fdcf49bf7c5e18fc517e35a67bcd72..8694c3b38948ad0a78a73d3a8735dc0c33658c95 100644 --- a/services/archlinux/archlinux.service.js +++ b/services/archlinux/archlinux.service.js @@ -31,9 +31,9 @@ export default class ArchLinux extends BaseJsonService { const data = await this._requestJson({ schema, url: `https://www.archlinux.org/packages/${encodeURIComponent( - repository + repository, )}/${encodeURIComponent(architecture)}/${encodeURIComponent( - packageName + packageName, )}/json/`, }) return renderVersionBadge({ version: data.pkgver }) diff --git a/services/archlinux/archlinux.tester.js b/services/archlinux/archlinux.tester.js index d92b65464b2cdf65508085a05662d15a38d5ae25..122868ce07f3d429e13c26c233684761a57aac50 100644 --- a/services/archlinux/archlinux.tester.js +++ b/services/archlinux/archlinux.tester.js @@ -18,7 +18,7 @@ t.create('Arch Linux package (valid)') pkgname: 'pacman', pkgver: '5.1.3', pkgrel: '1', - }) + }), ) .expectBadge({ label: 'arch linux', message: 'v5.1.3' }) diff --git a/services/aur/aur.service.js b/services/aur/aur.service.js index a55cd3d79f1763724d843ba4b8fd56ac157de28e..3484476e16bdd41a34d2fbde1d3ee6a2aea10982 100644 --- a/services/aur/aur.service.js +++ b/services/aur/aur.service.js @@ -19,7 +19,7 @@ const aurSchema = Joi.object({ OutOfDate: nonNegativeInteger.allow(null), Maintainer: Joi.string().required().allow(null), LastModified: nonNegativeInteger, - }) + }), ) .required(), }).required() diff --git a/services/aur/aur.tester.js b/services/aur/aur.tester.js index 2fc2c4c86d6d95c8394b5e7327c93d6c5f88e80e..0cdbe375805d88e6550e54bf27d464add3585ceb 100644 --- a/services/aur/aur.tester.js +++ b/services/aur/aur.tester.js @@ -63,7 +63,7 @@ t.create('license (no license)') LastModified: 1, }, ], - }) + }), ) .expectBadge({ label: 'license', message: 'not specified' }) diff --git a/services/azure-devops/azure-devops-base.js b/services/azure-devops/azure-devops-base.js index 85331836d49dd5e321244546881064f116073e78..04b618580527e68b614d8bf8258f0a3dd5a173a5 100644 --- a/services/azure-devops/azure-devops-base.js +++ b/services/azure-devops/azure-devops-base.js @@ -7,7 +7,7 @@ const latestBuildSchema = Joi.object({ .items( Joi.object({ id: Joi.number().required(), - }) + }), ) .required(), }).required() @@ -26,7 +26,7 @@ export default class AzureDevOpsBase extends BaseJsonService { url, options, httpErrors, - }) + }), ) } @@ -35,7 +35,7 @@ export default class AzureDevOpsBase extends BaseJsonService { project, definitionId, branch, - httpErrors + httpErrors, ) { // Microsoft documentation: https://docs.microsoft.com/en-us/rest/api/azure/devops/build/builds/list?view=azure-devops-rest-5.0 const url = `https://dev.azure.com/${organization}/${project}/_apis/build/builds` diff --git a/services/azure-devops/azure-devops-build.service.js b/services/azure-devops/azure-devops-build.service.js index fdfeee38b488b7752aa604ebfbff80376d63470c..df715b83f3210363d5f21917734224a61c566a4b 100644 --- a/services/azure-devops/azure-devops-build.service.js +++ b/services/azure-devops/azure-devops-build.service.js @@ -96,7 +96,7 @@ export default class AzureDevOpsBuild extends BaseSvgScrapingService { async handle( { organization, projectId, definitionId, branch }, - { stage, job } + { stage, job }, ) { // Microsoft documentation: https://docs.microsoft.com/en-us/rest/api/vsts/build/status/get const { status } = await fetch(this, { diff --git a/services/azure-devops/azure-devops-build.tester.js b/services/azure-devops/azure-devops-build.tester.js index 73027411170a8339fd52dacdf7c22b6bd853929c..7376a29a9e0f760d156ced0f6ab067976d2394e6 100644 --- a/services/azure-devops/azure-devops-build.tester.js +++ b/services/azure-devops/azure-devops-build.tester.js @@ -24,7 +24,7 @@ t.create('stage badge') t.create('job badge') .get( - '/totodem/Shields.io/5.json?stage=Successful%20Stage&job=Successful%20Job' + '/totodem/Shields.io/5.json?stage=Successful%20Stage&job=Successful%20Job', ) .expectBadge({ label: 'build', diff --git a/services/azure-devops/azure-devops-coverage.service.js b/services/azure-devops/azure-devops-coverage.service.js index 3e902dbc0de9be93f5e414268fc64ae61474e9f0..c53b7a6c857022840ab334bff22422bc62cb72f2 100644 --- a/services/azure-devops/azure-devops-coverage.service.js +++ b/services/azure-devops/azure-devops-coverage.service.js @@ -30,11 +30,11 @@ const buildCodeCoverageSchema = Joi.object({ label: Joi.string().required(), total: Joi.number().required(), covered: Joi.number().required(), - }) + }), ) .min(1) .required(), - }) + }), ) .required(), }).required() @@ -93,7 +93,7 @@ export default class AzureDevOpsCoverage extends AzureDevOpsBase { project, definitionId, branch, - httpErrors + httpErrors, ) // Microsoft documentation: https://docs.microsoft.com/en-us/rest/api/azure/devops/test/code%20coverage/get%20build%20code%20coverage?view=azure-devops-rest-5.0 const url = `https://dev.azure.com/${organization}/${project}/_apis/test/codecoverage` diff --git a/services/azure-devops/azure-devops-coverage.tester.js b/services/azure-devops/azure-devops-coverage.tester.js index 2177d9077c8bfe7300cb54a31fe3099c673b3692..7f0e8d2429500da9c6ba501e688cbe103766c564 100644 --- a/services/azure-devops/azure-devops-coverage.tester.js +++ b/services/azure-devops/azure-devops-coverage.tester.js @@ -73,7 +73,7 @@ t.create('unknown build definition') t.create('404 latest build error response') .get(mockBadgeUriPath) .intercept(nock => - nock(azureDevOpsApiBaseUri).get(mockLatestBuildApiUriPath).reply(404) + nock(azureDevOpsApiBaseUri).get(mockLatestBuildApiUriPath).reply(404), ) .expectBadge({ label: 'coverage', @@ -85,12 +85,12 @@ t.create('no build response') .intercept(nock => nock(azureDevOpsApiBaseUri) .get( - `/build/builds?definitions=${nonExistentDefinitionId}&%24top=1&statusFilter=completed&api-version=5.0-preview.4` + `/build/builds?definitions=${nonExistentDefinitionId}&%24top=1&statusFilter=completed&api-version=5.0-preview.4`, ) .reply(200, { count: 0, value: [], - }) + }), ) .expectBadge({ label: 'coverage', message: 'build pipeline not found' }) @@ -101,7 +101,7 @@ t.create('404 code coverage error response') .get(mockLatestBuildApiUriPath) .reply(200, latestBuildResponse) .get(mockCodeCoverageApiUriPath) - .reply(404) + .reply(404), ) .expectBadge({ label: 'coverage', @@ -115,7 +115,7 @@ t.create('invalid code coverage response') .get(mockLatestBuildApiUriPath) .reply(200, latestBuildResponse) .get(mockCodeCoverageApiUriPath) - .reply(200, {}) + .reply(200, {}), ) .expectBadge({ label: 'coverage', message: 'invalid response data' }) @@ -126,7 +126,7 @@ t.create('no code coverage reports') .get(mockLatestBuildApiUriPath) .reply(200, latestBuildResponse) .get(mockCodeCoverageApiUriPath) - .reply(200, { coverageData: [] }) + .reply(200, { coverageData: [] }), ) .expectBadge({ label: 'coverage', message: '0%' }) @@ -137,7 +137,7 @@ t.create('no code coverage reports') .get(mockLatestBuildApiUriPath) .reply(200, latestBuildResponse) .get(mockCodeCoverageApiUriPath) - .reply(200, { coverageData: [] }) + .reply(200, { coverageData: [] }), ) .expectBadge({ label: 'coverage', message: '0%' }) @@ -154,7 +154,7 @@ t.create('no line coverage stats') coverageStats: [branchCovStat], }, ], - }) + }), ) .expectBadge({ label: 'coverage', message: '0%' }) @@ -171,7 +171,7 @@ t.create('single line coverage stats') coverageStats: [firstLinesCovStat], }, ], - }) + }), ) .expectBadge({ label: 'coverage', message: expCoverageSingleReport }) @@ -188,7 +188,7 @@ t.create('mixed line and branch coverage stats') coverageStats: [firstLinesCovStat, branchCovStat], }, ], - }) + }), ) .expectBadge({ label: 'coverage', message: expCoverageSingleReport }) @@ -209,7 +209,7 @@ t.create('multiple line coverage stat reports') ], }, ], - }) + }), ) t.create('single JaCoCo style line coverage stats') @@ -225,7 +225,7 @@ t.create('single JaCoCo style line coverage stats') coverageStats: [firstLineCovStat], }, ], - }) + }), ) .expectBadge({ label: 'coverage', message: expCoverageSingleReport }) @@ -242,7 +242,7 @@ t.create('mixed JaCoCo style line and branch coverage stats') coverageStats: [firstLineCovStat, branchCovStat], }, ], - }) + }), ) .expectBadge({ label: 'coverage', message: expCoverageSingleReport }) @@ -259,6 +259,6 @@ t.create('multiple JaCoCo style line coverage stat reports') coverageStats: [firstLineCovStat, branchCovStat, secondLineCovStat], }, ], - }) + }), ) .expectBadge({ label: 'coverage', message: expCoverageMultipleReports }) diff --git a/services/azure-devops/azure-devops-helpers.js b/services/azure-devops/azure-devops-helpers.js index a2a0c89694d4d15c667e8c80b3992fbadc5f4cac..3b666a5a9b3e364ad4eb58ec69c23bbb47255d73 100644 --- a/services/azure-devops/azure-devops-helpers.js +++ b/services/azure-devops/azure-devops-helpers.js @@ -10,7 +10,7 @@ const schema = Joi.object({ Joi.equal('unknown'), Joi.equal('set up now'), Joi.equal('never built'), - Joi.equal('never deployed') + Joi.equal('never deployed'), ) .required(), }).required() diff --git a/services/azure-devops/azure-devops-tests.service.js b/services/azure-devops/azure-devops-tests.service.js index f037ae9d872c29604eab434f442a7fc1a3453553..4f9cfb81b7ed4982d27f42eb5774ac91b682699a 100644 --- a/services/azure-devops/azure-devops-tests.service.js +++ b/services/azure-devops/azure-devops-tests.service.js @@ -150,7 +150,7 @@ export default class AzureDevOpsTests extends AzureDevOpsBase { project, definitionId, branch, - httpErrors + httpErrors, ) // https://dev.azure.com/azuredevops-powershell/azuredevops-powershell/_apis/test/ResultSummaryByBuild?buildId=20 @@ -171,7 +171,7 @@ export default class AzureDevOpsTests extends AzureDevOpsBase { passed_label: passedLabel, failed_label: failedLabel, skipped_label: skippedLabel, - } + }, ) { const json = await this.fetchTestResults({ organization, diff --git a/services/azure-devops/azure-devops-tests.tester.js b/services/azure-devops/azure-devops-tests.tester.js index 01b75c617e1aa0d0e0e35161e720395f07fbb215..59e315de157c5b185bd08810b9821567894de601 100644 --- a/services/azure-devops/azure-devops-tests.tester.js +++ b/services/azure-devops/azure-devops-tests.tester.js @@ -22,7 +22,7 @@ t.create('404 latest build error response') statusFilter: 'completed', 'api-version': '5.0-preview.4', }) - .reply(404) + .reply(404), ) .expectBadge({ label: 'tests', @@ -43,7 +43,7 @@ t.create('no test result summary response') .reply(200, { count: 1, value: [{ id: 1234 }] }) .get('/test/ResultSummaryByBuild') .query({ buildId: 1234 }) - .reply(404) + .reply(404), ) .expectBadge({ label: 'tests', diff --git a/services/azure-devops/vso-redirect.tester.js b/services/azure-devops/vso-redirect.tester.js index d36f81ca2779e1518cbf1d38e3119a460d459756..c187d445d243733c7c0efe31506df7d88b403f9d 100644 --- a/services/azure-devops/vso-redirect.tester.js +++ b/services/azure-devops/vso-redirect.tester.js @@ -8,17 +8,17 @@ export const t = new ServiceTester({ t.create('Build: default branch') .get('/build/totodem/8cf3ec0e-d0c2-4fcd-8206-ad204f254a96/2.svg') .expectRedirect( - '/azure-devops/build/totodem/8cf3ec0e-d0c2-4fcd-8206-ad204f254a96/2.svg' + '/azure-devops/build/totodem/8cf3ec0e-d0c2-4fcd-8206-ad204f254a96/2.svg', ) t.create('Build: named branch') .get('/build/totodem/8cf3ec0e-d0c2-4fcd-8206-ad204f254a96/2/master.svg') .expectRedirect( - '/azure-devops/build/totodem/8cf3ec0e-d0c2-4fcd-8206-ad204f254a96/2/master.svg' + '/azure-devops/build/totodem/8cf3ec0e-d0c2-4fcd-8206-ad204f254a96/2/master.svg', ) t.create('Release status') .get('/release/totodem/8cf3ec0e-d0c2-4fcd-8206-ad204f254a96/1/1.svg') .expectRedirect( - '/azure-devops/release/totodem/8cf3ec0e-d0c2-4fcd-8206-ad204f254a96/1/1.svg' + '/azure-devops/release/totodem/8cf3ec0e-d0c2-4fcd-8206-ad204f254a96/1/1.svg', ) diff --git a/services/bitbucket/bitbucket-pipelines.service.js b/services/bitbucket/bitbucket-pipelines.service.js index 878a518a3b229f97aa8cbb919f78f26fbd6f9558..d00b85e64711baececca07a0a2949c3f7fc7b33b 100644 --- a/services/bitbucket/bitbucket-pipelines.service.js +++ b/services/bitbucket/bitbucket-pipelines.service.js @@ -14,11 +14,11 @@ const bitbucketPipelinesSchema = Joi.object({ 'FAILED', 'ERROR', 'STOPPED', - 'EXPIRED' + 'EXPIRED', ), }).required(), }).required(), - }) + }), ) .required(), }).required() @@ -69,7 +69,7 @@ class BitbucketPipelines extends BaseJsonService { static transform(data) { const values = data.values.filter( - value => value.state && value.state.name === 'COMPLETED' + value => value.state && value.state.name === 'COMPLETED', ) if (values.length > 0) { return values[0].state.result.name diff --git a/services/bitbucket/bitbucket-pipelines.tester.js b/services/bitbucket/bitbucket-pipelines.tester.js index 1fe7293a8a7cb44896a37732a88ac23d9dd20033..a271c04daea5e111469c6ceef3cee0cdf748f607 100644 --- a/services/bitbucket/bitbucket-pipelines.tester.js +++ b/services/bitbucket/bitbucket-pipelines.tester.js @@ -47,7 +47,7 @@ t.create('build result (passing)') .intercept(nock => nock('https://api.bitbucket.org') .get(/^\/2.0\/.*/) - .reply(200, bitbucketApiResponse('SUCCESSFUL')) + .reply(200, bitbucketApiResponse('SUCCESSFUL')), ) .expectBadge({ label: 'build', message: 'passing' }) @@ -56,7 +56,7 @@ t.create('build result (failing)') .intercept(nock => nock('https://api.bitbucket.org') .get(/^\/2.0\/.*/) - .reply(200, bitbucketApiResponse('FAILED')) + .reply(200, bitbucketApiResponse('FAILED')), ) .expectBadge({ label: 'build', message: 'failing' }) @@ -65,7 +65,7 @@ t.create('build result (error)') .intercept(nock => nock('https://api.bitbucket.org') .get(/^\/2.0\/.*/) - .reply(200, bitbucketApiResponse('ERROR')) + .reply(200, bitbucketApiResponse('ERROR')), ) .expectBadge({ label: 'build', message: 'error' }) @@ -74,7 +74,7 @@ t.create('build result (stopped)') .intercept(nock => nock('https://api.bitbucket.org') .get(/^\/2.0\/.*/) - .reply(200, bitbucketApiResponse('STOPPED')) + .reply(200, bitbucketApiResponse('STOPPED')), ) .expectBadge({ label: 'build', message: 'stopped' }) @@ -83,7 +83,7 @@ t.create('build result (expired)') .intercept(nock => nock('https://api.bitbucket.org') .get(/^\/2.0\/.*/) - .reply(200, bitbucketApiResponse('EXPIRED')) + .reply(200, bitbucketApiResponse('EXPIRED')), ) .expectBadge({ label: 'build', message: 'expired' }) @@ -92,12 +92,12 @@ t.create('build result (unexpected status)') .intercept(nock => nock('https://api.bitbucket.org') .get(/^\/2.0\/.*/) - .reply(200, bitbucketApiResponse('NEW_AND_UNEXPECTED')) + .reply(200, bitbucketApiResponse('NEW_AND_UNEXPECTED')), ) .expectBadge({ label: 'build', message: 'invalid response data' }) t.create('build result no branch redirect') .get('/atlassian/adf-builder-javascript.svg') .expectRedirect( - '/bitbucket/pipelines/atlassian/adf-builder-javascript/master.svg' + '/bitbucket/pipelines/atlassian/adf-builder-javascript/master.svg', ) diff --git a/services/bitbucket/bitbucket-pull-request.service.js b/services/bitbucket/bitbucket-pull-request.service.js index 9606e8213885a31bf1b2353f0cfbab1bc5735a2c..58c51acb765be0affdc7e3fb9961449aaa35e77a 100644 --- a/services/bitbucket/bitbucket-pull-request.service.js +++ b/services/bitbucket/bitbucket-pull-request.service.js @@ -69,7 +69,7 @@ function pullRequestClassGenerator(raw) { passKey: 'bitbucket_password', authorizedOrigins: ['https://bitbucket.org'], }, - config + config, ) this.bitbucketServerAuthHelper = new AuthHelper( { @@ -77,7 +77,7 @@ function pullRequestClassGenerator(raw) { passKey: 'bitbucket_server_password', serviceKey: 'bitbucketServer', }, - config + config, ) } @@ -88,7 +88,7 @@ function pullRequestClassGenerator(raw) { schema, options: { searchParams: { state: 'OPEN', limit: 0 } }, httpErrors, - }) + }), ) } @@ -107,7 +107,7 @@ function pullRequestClassGenerator(raw) { }, }, httpErrors, - }) + }), ) } diff --git a/services/bitbucket/bitbucket-pull-request.spec.js b/services/bitbucket/bitbucket-pull-request.spec.js index 565a2c1634777277a238fb2816ab9d054dfa60ff..1c136fadc1258b9b8eca8f8508a643dca6872c70 100644 --- a/services/bitbucket/bitbucket-pull-request.spec.js +++ b/services/bitbucket/bitbucket-pull-request.spec.js @@ -28,8 +28,8 @@ describe('BitbucketPullRequest', function () { }, private: { bitbucket_username: user, bitbucket_password: pass }, }, - { user: 'atlassian', repo: 'python-bitbucket' } - ) + { user: 'atlassian', repo: 'python-bitbucket' }, + ), ).to.deep.equal({ message: '42', color: 'yellow', @@ -61,8 +61,8 @@ describe('BitbucketPullRequest', function () { }, }, { user: 'project', repo: 'repo' }, - { server: 'https://bitbucket.example.test' } - ) + { server: 'https://bitbucket.example.test' }, + ), ).to.deep.equal({ message: '42', color: 'yellow', diff --git a/services/bitbucket/bitbucket-pull-request.tester.js b/services/bitbucket/bitbucket-pull-request.tester.js index ca3273e6ec1a699d8fea4a850f89a2c9622dfee4..c1e6e04ee229885a12c942bfdc74f77044fb5c90 100644 --- a/services/bitbucket/bitbucket-pull-request.tester.js +++ b/services/bitbucket/bitbucket-pull-request.tester.js @@ -46,7 +46,7 @@ t.create('pr (server)') withProperties: false, withAttributes: false, }) - .reply(200, { size: 42 }) + .reply(200, { size: 42 }), ) .expectBadge({ label: 'pull requests', @@ -64,7 +64,7 @@ t.create('pr (server, invalid credentials)') withProperties: false, withAttributes: false, }) - .reply(401) + .reply(401), ) .expectBadge({ label: 'pull requests', @@ -82,7 +82,7 @@ t.create('pr (server, private repo)') withProperties: false, withAttributes: false, }) - .reply(403) + .reply(403), ) .expectBadge({ label: 'pull requests', @@ -100,7 +100,7 @@ t.create('pr (server, not found)') withProperties: false, withAttributes: false, }) - .reply(404) + .reply(404), ) .expectBadge({ label: 'pull requests', diff --git a/services/bitrise/bitrise.service.js b/services/bitrise/bitrise.service.js index 49e5f2fb901c6c743bb050efeeb50c73466a457c..47d6c1cd34991c0a284968dbb80ab624fc65c498 100644 --- a/services/bitrise/bitrise.service.js +++ b/services/bitrise/bitrise.service.js @@ -51,7 +51,7 @@ export default class Bitrise extends BaseJsonService { async fetch({ appId, branch, token }) { return this._requestJson({ url: `https://app.bitrise.io/app/${encodeURIComponent( - appId + appId, )}/status.json`, options: { searchParams: { token, branch } }, schema, diff --git a/services/bower/bower-base.js b/services/bower/bower-base.js index 2ead07514aab555189d939c3131b845a049072a7..3b059b3b77d0585928f9da80e382d28fa15f7d50 100644 --- a/services/bower/bower-base.js +++ b/services/bower/bower-base.js @@ -6,7 +6,7 @@ const schema = Joi.object() normalized_licenses: Joi.array() .items( // normalized_license may be [] if the package does not declare a license - Joi.string() + Joi.string(), ) .required(), diff --git a/services/bower/bower-version.spec.js b/services/bower/bower-version.spec.js index 84da629378732851a1c93ffe3272a322642599dd..e3f3bd15281a7ce7a0c910efba3f2a1b4381c942 100644 --- a/services/bower/bower-version.spec.js +++ b/services/bower/bower-version.spec.js @@ -13,20 +13,20 @@ describe('BowerVersion', function () { latest_release_number: '2.0.0-beta', latest_stable_release_number: '1.8.3', }, - false + false, ).expect('1.8.3') given( { latest_release_number: '2.0.0-beta', latest_stable_release_number: '1.8.3', }, - true + true, ).expect('2.0.0-beta') }) it('throws `no releases` InvalidResponse if no stable version', function () { expect(() => - BowerVersion.transform({ latest_release_number: 'panda' }, false) + BowerVersion.transform({ latest_release_number: 'panda' }, false), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'no releases') @@ -34,7 +34,7 @@ describe('BowerVersion', function () { it('throws `no releases` InvalidResponse if no prereleases', function () { expect(() => - BowerVersion.transform({ latest_stable_release_number: 'penguin' }, true) + BowerVersion.transform({ latest_stable_release_number: 'penguin' }, true), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'no releases') @@ -78,8 +78,8 @@ describe('BowerVersion', function () { }, { include_prereleases: '', - } - ) + }, + ), ).to.deep.equal({ message: 'v2.0.0-beta', color: 'orange', diff --git a/services/bugzilla/bugzilla.service.js b/services/bugzilla/bugzilla.service.js index aadc849eedd0df4a9b369add519da883435459fa..3036d6676a9814de1fe0e03bc2270fda0fb36660 100644 --- a/services/bugzilla/bugzilla.service.js +++ b/services/bugzilla/bugzilla.service.js @@ -12,7 +12,7 @@ const schema = Joi.object({ Joi.object({ status: Joi.string().required(), resolution: Joi.string().allow('').required(), - }).required() + }).required(), ) .min(1) .required(), diff --git a/services/bugzilla/bugzilla.spec.js b/services/bugzilla/bugzilla.spec.js index 114e29fa429e0022f7458f9e63b246a255f1c9a7..1baa9eb207cf8890388752e9307fda83f06c58a2 100644 --- a/services/bugzilla/bugzilla.spec.js +++ b/services/bugzilla/bugzilla.spec.js @@ -5,7 +5,7 @@ describe('getDisplayStatus function', function () { it('formats status correctly', async function () { test(Bugzilla.getDisplayStatus, () => { given({ status: 'RESOLVED', resolution: 'WORKSFORME' }).expect( - 'works for me' + 'works for me', ) given({ status: 'RESOLVED', resolution: 'WONTFIX' }).expect("won't fix") given({ status: 'ASSIGNED', resolution: '' }).expect('assigned') diff --git a/services/bugzilla/bugzilla.tester.js b/services/bugzilla/bugzilla.tester.js index bcd46f9041bb27de086c292f14dbd86b52cce999..1160fe32e514ca95d9769bf547f652fa42f05cea 100644 --- a/services/bugzilla/bugzilla.tester.js +++ b/services/bugzilla/bugzilla.tester.js @@ -11,7 +11,7 @@ const bzBugStatus = Joi.equal( "won't fix", 'duplicate', 'works for me', - 'incomplete' + 'incomplete', ) t.create('Bugzilla valid bug status').get('/996038.json').expectBadge({ diff --git a/services/build-status.spec.js b/services/build-status.spec.js index b135504bcbe789e80b6280bdb2d5be47ce076950..9a06fd2730c5b516867c6a7f3e188106ce49e949 100644 --- a/services/build-status.spec.js +++ b/services/build-status.spec.js @@ -39,7 +39,7 @@ test(renderBuildStatusBadge, () => { given({ status: 'success' }), given({ status: 'successful' }), ]).assert('should be brightgreen', b => - expect(b).to.include({ color: 'brightgreen' }) + expect(b).to.include({ color: 'brightgreen' }), ) }) @@ -85,6 +85,6 @@ test(renderBuildStatusBadge, () => { given({ status: 'testing' }), given({ status: 'waiting' }), ]).assert('should have undefined color', b => - expect(b).to.include({ color: undefined }) + expect(b).to.include({ color: undefined }), ) }) diff --git a/services/buildkite/buildkite.tester.js b/services/buildkite/buildkite.tester.js index d2819659f97d07431b6b3797e79969cbc0bbbe96..fac5ea4751725fbe7378b82fe6f2dbc94e7b94e7 100644 --- a/services/buildkite/buildkite.tester.js +++ b/services/buildkite/buildkite.tester.js @@ -23,6 +23,6 @@ t.create('buildkite valid pipeline skipping branch') t.create('buildkite unknown branch') .get( - '/3826789cf8890b426057e6fe1c4e683bdf04fa24d498885489/unknown-branch.json' + '/3826789cf8890b426057e6fe1c4e683bdf04fa24d498885489/unknown-branch.json', ) .expectBadge({ label: 'build', message: 'unknown' }) diff --git a/services/chrome-web-store/chrome-web-store-users.tester.js b/services/chrome-web-store/chrome-web-store-users.tester.js index d00b6c3c13217f8dbba59e0b32ddd5140da6d4e5..54959019b45c017748d18db5100af75aa19cd50a 100644 --- a/services/chrome-web-store/chrome-web-store-users.tester.js +++ b/services/chrome-web-store/chrome-web-store-users.tester.js @@ -10,7 +10,7 @@ export const t = new ServiceTester({ t.create('Downloads (redirect)') .get('/d/alhjnofcnnpeaphgeakdhkebafjcpeae.svg') .expectRedirect( - '/chrome-web-store/users/alhjnofcnnpeaphgeakdhkebafjcpeae.svg' + '/chrome-web-store/users/alhjnofcnnpeaphgeakdhkebafjcpeae.svg', ) t.create('Users') diff --git a/services/cii-best-practices/cii-best-practices.service.js b/services/cii-best-practices/cii-best-practices.service.js index 2ee81cec50a63189dd58f1dd1fe9ed13f889c6a9..b83a9013c5eac1bc941cd100aa6ed75ff6649b1a 100644 --- a/services/cii-best-practices/cii-best-practices.service.js +++ b/services/cii-best-practices/cii-best-practices.service.js @@ -25,7 +25,7 @@ const summaryColorScale = colorScale( 'brightgreen', '#BBBBBB', '#E9C504', - ] + ], ) export default class CIIBestPracticesService extends BaseJsonService { diff --git a/services/cii-best-practices/cii-best-practices.tester.js b/services/cii-best-practices/cii-best-practices.tester.js index 6367902b022844b060e82563a6f0c27a4e1d6372..e75a527c7c8cf13b47acef46423ee9b18189900d 100644 --- a/services/cii-best-practices/cii-best-practices.tester.js +++ b/services/cii-best-practices/cii-best-practices.tester.js @@ -35,7 +35,7 @@ t.create('level: gold project') .reply(200, { badge_level: 'gold', tiered_percentage: 300, - }) + }), ) .expectBadge({ label: 'cii', @@ -50,7 +50,7 @@ t.create('level: silver project') .reply(200, { badge_level: 'silver', tiered_percentage: 297, - }) + }), ) .expectBadge({ label: 'cii', @@ -65,7 +65,7 @@ t.create('level: passing project') .reply(200, { badge_level: 'passing', tiered_percentage: 107, - }) + }), ) .expectBadge({ label: 'cii', @@ -80,7 +80,7 @@ t.create('level: in progress project') .reply(200, { badge_level: 'in_progress', tiered_percentage: 94, - }) + }), ) .expectBadge({ label: 'cii', @@ -95,7 +95,7 @@ t.create('percentage: gold project') .reply(200, { badge_level: 'gold', tiered_percentage: 300, - }) + }), ) .expectBadge({ label: 'cii', @@ -110,7 +110,7 @@ t.create('percentage: silver project') .reply(200, { badge_level: 'silver', tiered_percentage: 297, - }) + }), ) .expectBadge({ label: 'cii', @@ -125,7 +125,7 @@ t.create('percentage: passing project') .reply(200, { badge_level: 'passing', tiered_percentage: 107, - }) + }), ) .expectBadge({ label: 'cii', @@ -140,7 +140,7 @@ t.create('percentage: in progress project') .reply(200, { badge_level: 'in_progress', tiered_percentage: 94, - }) + }), ) .expectBadge({ label: 'cii', @@ -155,7 +155,7 @@ t.create('summary: gold project') .reply(200, { badge_level: 'gold', tiered_percentage: 300, - }) + }), ) .expectBadge({ label: 'cii', @@ -170,7 +170,7 @@ t.create('summary: silver project') .reply(200, { badge_level: 'silver', tiered_percentage: 297, - }) + }), ) .expectBadge({ label: 'cii', @@ -185,7 +185,7 @@ t.create('summary: passing project') .reply(200, { badge_level: 'passing', tiered_percentage: 107, - }) + }), ) .expectBadge({ label: 'cii', @@ -200,7 +200,7 @@ t.create('summary: in progress project') .reply(200, { badge_level: 'in_progress', tiered_percentage: 94, - }) + }), ) .expectBadge({ label: 'cii', diff --git a/services/circleci/circleci.tester.js b/services/circleci/circleci.tester.js index 8cbda6b312e33dd5af8ae35256c8e78043e4d1a5..614971a97efd3b404d12868028701d819a0bdf78 100644 --- a/services/circleci/circleci.tester.js +++ b/services/circleci/circleci.tester.js @@ -33,7 +33,7 @@ t.create('circle ci (not found)') t.create('circle ci (valid, with token)') .get( - '/build/gh/RedSparr0w/node-csgo-parser/master.json?token=b90b5c49e59a4c67ba3a92f7992587ac7a0408c2' + '/build/gh/RedSparr0w/node-csgo-parser/master.json?token=b90b5c49e59a4c67ba3a92f7992587ac7a0408c2', ) .expectBadge({ label: 'build', @@ -50,16 +50,16 @@ t.create('legacy route (assume "github" as a default VCS)') t.create('legacy route with token and VCS') .get( - '/token/b90b5c49e59a4c67ba3a92f7992587ac7a0408c2/project/github/RedSparr0w/node-csgo-parser/master.svg' + '/token/b90b5c49e59a4c67ba3a92f7992587ac7a0408c2/project/github/RedSparr0w/node-csgo-parser/master.svg', ) .expectRedirect( - '/circleci/build/github/redsparr0w/node-csgo-parser/master.svg?token=b90b5c49e59a4c67ba3a92f7992587ac7a0408c2' + '/circleci/build/github/redsparr0w/node-csgo-parser/master.svg?token=b90b5c49e59a4c67ba3a92f7992587ac7a0408c2', ) t.create('legacy route with token (assume "github" as a default VCS)') .get( - '/token/b90b5c49e59a4c67ba3a92f7992587ac7a0408c2/project/RedSparr0w/node-csgo-parser/master.svg' + '/token/b90b5c49e59a4c67ba3a92f7992587ac7a0408c2/project/RedSparr0w/node-csgo-parser/master.svg', ) .expectRedirect( - '/circleci/build/gh/redsparr0w/node-csgo-parser/master.svg?token=b90b5c49e59a4c67ba3a92f7992587ac7a0408c2' + '/circleci/build/gh/redsparr0w/node-csgo-parser/master.svg?token=b90b5c49e59a4c67ba3a92f7992587ac7a0408c2', ) diff --git a/services/cocoapods/cocoapods-base.js b/services/cocoapods/cocoapods-base.js index 98bcbf49ded2c899fb650aecd5315424322a8b50..2a5a935106f13ffbd9ade78724ab4908d763548e 100644 --- a/services/cocoapods/cocoapods-base.js +++ b/services/cocoapods/cocoapods-base.js @@ -8,7 +8,7 @@ const schema = Joi.object({ Joi.string().required(), Joi.object({ type: Joi.string().required(), - }).required() + }).required(), ), // https://github.com/badges/shields/pull/209 platforms: Joi.object().default({ ios: '5.0', osx: '10.7' }), diff --git a/services/cocoapods/cocoapods-docs.tester.js b/services/cocoapods/cocoapods-docs.tester.js index 746505bc21e7f124bc2fbc2a232f94efa215f302..65e49f21690dbfeed0a8c2666f12538299c6fef9 100644 --- a/services/cocoapods/cocoapods-docs.tester.js +++ b/services/cocoapods/cocoapods-docs.tester.js @@ -12,7 +12,7 @@ t.create('doc percent (null)') .intercept(nock => nock('https://metrics.cocoapods.org') .get('/api/v1/pods/AFNetworking') - .reply(200, '{"cocoadocs": {"doc_percent": null}}') + .reply(200, '{"cocoadocs": {"doc_percent": null}}'), ) .expectBadge({ label: 'docs', message: '0%' }) diff --git a/services/cocoapods/cocoapods-license.tester.js b/services/cocoapods/cocoapods-license.tester.js index c4eba4f9ff26e0b912ed45ffa25739f53e82a560..6be0867f9eb3303ab2cd7793c37dc14a0d094c61 100644 --- a/services/cocoapods/cocoapods-license.tester.js +++ b/services/cocoapods/cocoapods-license.tester.js @@ -13,7 +13,7 @@ t.create('missing license') .reply(200, { version: '1.0.7', platforms: { ios: '8.0' }, - }) + }), ) .expectBadge({ label: 'license', message: 'not specified' }) diff --git a/services/cocoapods/cocoapods-platform.tester.js b/services/cocoapods/cocoapods-platform.tester.js index f2d176f97355f0f6c97cc9a1373648a4eda73972..6d92fe089bdc14ead7bb878a8e357de8993035ca 100644 --- a/services/cocoapods/cocoapods-platform.tester.js +++ b/services/cocoapods/cocoapods-platform.tester.js @@ -3,7 +3,7 @@ import { createServiceTester } from '../tester.js' export const t = await createServiceTester() const isPlatform = Joi.string().regex( - /^(osx|ios|tvos|watchos)( \| (osx|ios|tvos|watchos))*$/ + /^(osx|ios|tvos|watchos)( \| (osx|ios|tvos|watchos))*$/, ) t.create('platform (valid)').get('/AFNetworking.json').expectBadge({ @@ -20,6 +20,6 @@ t.create('platform (missing platforms key)') .intercept(nock => nock('https://trunk.cocoapods.org') .get('/api/v1/pods/AFNetworking/specs/latest') - .reply(200, { version: 'v1.0', license: 'MIT' }) + .reply(200, { version: 'v1.0', license: 'MIT' }), ) .expectBadge({ label: 'platform', message: 'ios | osx' }) diff --git a/services/codacy/codacy-coverage.service.js b/services/codacy/codacy-coverage.service.js index 7deae5d34d08977b45be39e5f8361c362956cc90..7d6f58081d06d88c4a4b2b3d008318132849891a 100644 --- a/services/codacy/codacy-coverage.service.js +++ b/services/codacy/codacy-coverage.service.js @@ -49,7 +49,7 @@ export default class CodacyCoverage extends BaseSvgScrapingService { const { message: coverageString } = await this._requestSvg({ schema, url: `https://api.codacy.com/project/badge/coverage/${encodeURIComponent( - projectId + projectId, )}`, options: { searchParams: { branch } }, valueMatcher: /text-anchor="middle">([^<>]+)<\/text>/, diff --git a/services/codacy/codacy-grade.service.js b/services/codacy/codacy-grade.service.js index afb4ccabcc42af9782a12db9889dad1811bdda9b..c2a8e3f1565d2389bf2fa9fc5fc6f4f77e75ea09 100644 --- a/services/codacy/codacy-grade.service.js +++ b/services/codacy/codacy-grade.service.js @@ -48,7 +48,7 @@ export default class CodacyGrade extends BaseSvgScrapingService { const { message: grade } = await this._requestSvg({ schema, url: `https://api.codacy.com/project/badge/grade/${encodeURIComponent( - projectId + projectId, )}`, options: { searchParams: { branch } }, httpErrors: { 404: 'project or branch not found' }, diff --git a/services/codeclimate/codeclimate-analysis.service.js b/services/codeclimate/codeclimate-analysis.service.js index f6e59055667b3bc0794ebe81fdeba58610684b48..b8df15625f198d146a43e5d48add1cc6109a1912 100644 --- a/services/codeclimate/codeclimate-analysis.service.js +++ b/services/codeclimate/codeclimate-analysis.service.js @@ -17,7 +17,7 @@ const schema = Joi.object({ measure: Joi.object({ value: Joi.number().required(), }).required(), - }) + }), ) .length(1) .required(), @@ -27,15 +27,15 @@ const schema = Joi.object({ const maintainabilityColorScale = colorScale( [50, 80, 90, 95], - ['red', 'yellow', 'yellowgreen', 'green', 'brightgreen'] + ['red', 'yellow', 'yellowgreen', 'green', 'brightgreen'], ) const techDebtColorScale = colorScale( [5, 10, 20, 50], - ['brightgreen', 'green', 'yellowgreen', 'yellow', 'red'] + ['brightgreen', 'green', 'yellowgreen', 'yellow', 'red'], ) const issueColorScale = colorScale( [1, 5, 10, 20], - ['brightgreen', 'green', 'yellowgreen', 'yellow', 'red'] + ['brightgreen', 'green', 'yellowgreen', 'yellow', 'red'], ) const variantMap = { @@ -140,7 +140,7 @@ export default class CodeclimateAnalysis extends BaseJsonService { async fetch({ user, repo }) { const repoInfos = await fetchRepo(this, { user, repo }) const repoInfosWithSnapshot = repoInfos.filter( - repoInfo => repoInfo.relationships.latest_default_branch_snapshot.data + repoInfo => repoInfo.relationships.latest_default_branch_snapshot.data, ) if (repoInfosWithSnapshot.length === 0) { throw new NotFound({ prettyMessage: 'snapshot not found' }) diff --git a/services/codeclimate/codeclimate-analysis.tester.js b/services/codeclimate/codeclimate-analysis.tester.js index b52283f80c19fe1b542f5f2e6093e0da84bbeb6f..f5143d0607525ad255341a04b1261e8a10f3b97b 100644 --- a/services/codeclimate/codeclimate-analysis.tester.js +++ b/services/codeclimate/codeclimate-analysis.tester.js @@ -65,7 +65,7 @@ t.create('issues when outer user repos query returns multiple items') }, }, ], - }) + }), ) .networkOn() // Combined with allowUnmocked: true, this allows the inner snapshots query to go through. .expectBadge({ @@ -94,7 +94,7 @@ t.create('malformed response for outer user repos query') .get('/v1/repos?github_slug=tensorflow%2Fmodels') .reply(200, { data: [{}], // No relationships in the list of data elements. - }) + }), ) .expectBadge({ label: 'analysis', @@ -106,7 +106,7 @@ t.create('malformed response for inner specific repo query') .intercept(nock => nock('https://api.codeclimate.com', { allowUnmocked: true }) .get(/\/v1\/repos\/[a-z0-9]+\/snapshots\/[a-z0-9]+/) - .reply(200, {}) + .reply(200, {}), ) // No data. .networkOn() // Combined with allowUnmocked: true, this allows the outer user repos query to go through. .expectBadge({ diff --git a/services/codeclimate/codeclimate-common.js b/services/codeclimate/codeclimate-common.js index 0e919e6103d9801b495eba65d3cc9230789ee0f0..83146074f7e7333aeef00e86da492ab144e276e4 100644 --- a/services/codeclimate/codeclimate-common.js +++ b/services/codeclimate/codeclimate-common.js @@ -22,7 +22,7 @@ const repoSchema = Joi.object({ }).allow(null), }).required(), }).required(), - }) + }), ) .required(), }).required() diff --git a/services/codeclimate/codeclimate-coverage.service.js b/services/codeclimate/codeclimate-coverage.service.js index 7e764c6c5de949f29a827863f8b2ce49b580d840..b9c654bfa413069db922f3790dfd9a6ba2dfb6ba 100644 --- a/services/codeclimate/codeclimate-coverage.service.js +++ b/services/codeclimate/codeclimate-coverage.service.js @@ -55,7 +55,7 @@ export default class CodeclimateCoverage extends BaseJsonService { async fetch({ user, repo }) { const repoInfos = await fetchRepo(this, { user, repo }) const repoInfosWithTestReport = repoInfos.filter( - repoInfo => repoInfo.relationships.latest_default_branch_test_report.data + repoInfo => repoInfo.relationships.latest_default_branch_test_report.data, ) if (repoInfosWithTestReport.length === 0) { throw new NotFound({ prettyMessage: 'test report not found' }) diff --git a/services/codeclimate/codeclimate-coverage.tester.js b/services/codeclimate/codeclimate-coverage.tester.js index 94e20d1176167ca6e5e08718c23b514bb889365f..f9123d94e184a496534b1ac94ac988e90d88e8d1 100644 --- a/services/codeclimate/codeclimate-coverage.tester.js +++ b/services/codeclimate/codeclimate-coverage.tester.js @@ -53,7 +53,7 @@ t.create('test coverage when outer user repos query returns multiple items') }, }, ], - }) + }), ) .networkOn() // Combined with allowUnmocked: true, this allows the inner test reports query to go through. .expectBadge({ diff --git a/services/codecov/codecov-redirect.tester.js b/services/codecov/codecov-redirect.tester.js index 4e23c04550b7fba3985fde5e599b773ab86d21b7..34fc088b32119e273efa90903930ee2ae95ea2c1 100644 --- a/services/codecov/codecov-redirect.tester.js +++ b/services/codecov/codecov-redirect.tester.js @@ -9,17 +9,17 @@ export const t = new ServiceTester({ t.create('codecov token') .get('/c/token/abc123def456/gh/codecov/private-example.svg') .expectRedirect( - '/codecov/c/github/codecov/private-example.svg?token=abc123def456' + '/codecov/c/github/codecov/private-example.svg?token=abc123def456', ) t.create('codecov branch token') .get('/c/token/abc123def456/bb/private-shields/private-badges/master.svg') .expectRedirect( - '/codecov/c/bitbucket/private-shields/private-badges/master.svg?token=abc123def456' + '/codecov/c/bitbucket/private-shields/private-badges/master.svg?token=abc123def456', ) t.create('codecov gl short form expanded to long form') .get('/c/token/abc123def456/gl/private-shields/private-badges/master.svg') .expectRedirect( - '/codecov/c/gitlab/private-shields/private-badges/master.svg?token=abc123def456' + '/codecov/c/gitlab/private-shields/private-badges/master.svg?token=abc123def456', ) diff --git a/services/codecov/codecov.tester.js b/services/codecov/codecov.tester.js index d9f5225f08719f7819bdf63cdb27bee57f29c2da..0ef392eae0bb6f78705eb98803b417334b560dde 100644 --- a/services/codecov/codecov.tester.js +++ b/services/codecov/codecov.tester.js @@ -39,7 +39,7 @@ t.create('handles unknown repository') t.create('handles unknown repository with flag') .get( - '/github/codecov2/fake-not-even-a-little-bit-real-node.json?flag=istanbul_mocha' + '/github/codecov2/fake-not-even-a-little-bit-real-node.json?flag=istanbul_mocha', ) .expectBadge({ label: 'coverage', @@ -62,7 +62,7 @@ t.create('handles unauthorized private repository') .get('/github/codecov/private-example-python/graph/badge.svg') .reply(200, '<g><text x="105.5" y="14">unknown</text></g>', { 'Content-Type': 'image/svg+xml', - }) + }), ) .expectBadge({ label: 'coverage', @@ -78,7 +78,7 @@ t.create('handles unauthorized error (with api token)') }, }) .get('/github/codecov/private-example-python') - .reply(401) + .reply(401), ) .expectBadge({ label: 'coverage', @@ -87,7 +87,7 @@ t.create('handles unauthorized error (with api token)') t.create('handles unknown repository (with api token)') .get( - '/github/codecov2/fake-not-even-a-little-bit-real-python.json?token=a1b2c3d4e5f6g7h8' + '/github/codecov2/fake-not-even-a-little-bit-real-python.json?token=a1b2c3d4e5f6g7h8', ) .intercept(nock => nock('https://codecov.io/api', { @@ -96,7 +96,7 @@ t.create('handles unknown repository (with api token)') }, }) .get('/github/codecov2/fake-not-even-a-little-bit-real-python') - .reply(404) + .reply(404), ) .expectBadge({ label: 'coverage', @@ -108,11 +108,11 @@ t.create('gets coverage for private repository') .intercept(nock => nock('https://codecov.io') .get( - '/gh/codecov/private-example-python/graph/badge.svg?token=a1b2c3d4e5' + '/gh/codecov/private-example-python/graph/badge.svg?token=a1b2c3d4e5', ) .reply(200, '<g><text x="105.5" y="14">100%</text></g>', { 'Content-Type': 'image/svg+xml', - }) + }), ) .expectBadge({ label: 'coverage', @@ -134,7 +134,7 @@ t.create('gets coverage for private repository (with api token)') c: 94.75, }, }, - }) + }), ) .expectBadge({ label: 'coverage', diff --git a/services/codeship/codeship.service.js b/services/codeship/codeship.service.js index 78a412fb77db0f90d2470a54de895f2698727322..8ddc631acc2c8f1e1d0fdbfba1872a9aed9b88a1 100644 --- a/services/codeship/codeship.service.js +++ b/services/codeship/codeship.service.js @@ -6,7 +6,7 @@ const schema = Joi.object({ message: Joi.alternatives() .try( isBuildStatus, - Joi.equal('project not found', 'branch not found', 'ignored', 'blocked') + Joi.equal('project not found', 'branch not found', 'ignored', 'blocked'), ) .required(), }).required() diff --git a/services/coincap/coincap-changepercent24hr.tester.js b/services/coincap/coincap-changepercent24hr.tester.js index 564553d289e0d04a6572126edee867ab0ef1884e..d57f69b8c8ad7ff200ffe59d6dbf83df7f75a1c6 100644 --- a/services/coincap/coincap-changepercent24hr.tester.js +++ b/services/coincap/coincap-changepercent24hr.tester.js @@ -9,7 +9,7 @@ t.create('request for existing asset with positive') .get('/v2/assets/bitcoin') .reply(200, { data: { changePercent24Hr: '1.4767080598737783', name: 'Bitcoin' }, - }) + }), ) .expectBadge({ label: 'bitcoin', @@ -24,7 +24,7 @@ t.create('request for existing asset with negative') .get('/v2/assets/bitcoin') .reply(200, { data: { changePercent24Hr: '-1.4767080598737783', name: 'Bitcoin' }, - }) + }), ) .expectBadge({ label: 'bitcoin', diff --git a/services/coincap/coincap-priceusd.tester.js b/services/coincap/coincap-priceusd.tester.js index bb7acec283b4149077120796f803f3c8989c81cf..d10f1719567475775975489183359be5ec5ddd4e 100644 --- a/services/coincap/coincap-priceusd.tester.js +++ b/services/coincap/coincap-priceusd.tester.js @@ -9,7 +9,7 @@ t.create('request for existing asset') .get('/v2/assets/bitcoin') .reply(200, { data: { priceUsd: '16417.7176754790740415', name: 'Bitcoin' }, - }) + }), ) .expectBadge({ label: 'bitcoin', diff --git a/services/coincap/coincap-rank.tester.js b/services/coincap/coincap-rank.tester.js index 3ee469a19c686c3862a2716ad7366d530bdfafcf..3d1c5fc5cf0daeb57afc69c59d46e066a56b4158 100644 --- a/services/coincap/coincap-rank.tester.js +++ b/services/coincap/coincap-rank.tester.js @@ -7,7 +7,7 @@ t.create('request for existing asset') .intercept(nock => nock('https://api.coincap.io') .get('/v2/assets/bitcoin') - .reply(200, { data: { rank: '1', name: 'Bitcoin' } }) + .reply(200, { data: { rank: '1', name: 'Bitcoin' } }), ) .expectBadge({ label: 'bitcoin', diff --git a/services/color-formatters.js b/services/color-formatters.js index 154710ef8df42f54ac1a166ce398b2dea3e86656..223eafbe7c35041ece3c4e7d2166c92a66540301 100644 --- a/services/color-formatters.js +++ b/services/color-formatters.js @@ -155,7 +155,7 @@ function colorScale(steps, colors, reversed) { if (steps.length !== colors.length - 1) { throw Error( - 'When colors are provided, there should be n + 1 colors for n steps.' + 'When colors are provided, there should be n + 1 colors for n steps.', ) } diff --git a/services/color-formatters.spec.js b/services/color-formatters.spec.js index 14b119783e72fbeed584cc21de2d72f07900b022..c661acc86447fe962bb2597792162817514d749d 100644 --- a/services/color-formatters.spec.js +++ b/services/color-formatters.spec.js @@ -26,8 +26,8 @@ describe('Color formatters', function () { forCases( [-1, 0, 0.5, 1, 50, 80, 85, 90, 100, 101].map(v => - given(v).expect(coveragePercentage(v)) - ) + given(v).expect(coveragePercentage(v)), + ), ).should("return '%s', for parity with coveragePercentage()") }) @@ -93,19 +93,19 @@ describe('Color formatters', function () { expect(() => version(null)).to.throw( Error, - "Can't generate a version color for null" + "Can't generate a version color for null", ) expect(() => version(undefined)).to.throw( Error, - "Can't generate a version color for undefined" + "Can't generate a version color for undefined", ) expect(() => version(true)).to.throw( Error, - "Can't generate a version color for true" + "Can't generate a version color for true", ) expect(() => version({})).to.throw( Error, - "Can't generate a version color for [object Object]" + "Can't generate a version color for [object Object]", ) }) diff --git a/services/conan/conan-version-helpers.spec.js b/services/conan/conan-version-helpers.spec.js index 3c622b0ab2223a2a5c36fc9291f0e0b8ac1bec7e..49f20acbc2348a0d8610131e419536cb09c30b80 100644 --- a/services/conan/conan-version-helpers.spec.js +++ b/services/conan/conan-version-helpers.spec.js @@ -13,7 +13,7 @@ describe('parseLatestVersionFromConfig', function () { folder: all 1.69.0: folder: all - `) + `), ).to.equal('1.70.0') }) @@ -22,12 +22,12 @@ describe('parseLatestVersionFromConfig', function () { }) it('treats no results array as invalid', function () { expect(() => - parseLatestVersionFromConfig('somethingElse: whatever') + parseLatestVersionFromConfig('somethingElse: whatever'), ).to.throw(InvalidResponse) }) it('treats empty results array as not found', function () { expect(() => parseLatestVersionFromConfig('versions: []')).to.throw( - NotFound + NotFound, ) }) }) diff --git a/services/conda/conda-base.js b/services/conda/conda-base.js index d7cd3f7a0011b433e8cc7897547789e947f848c2..73fc57205515676b9ab318e0c0295c5ad22a8076 100644 --- a/services/conda/conda-base.js +++ b/services/conda/conda-base.js @@ -9,7 +9,7 @@ const condaSchema = Joi.object({ .items( Joi.object({ ndownloads: nonNegativeInteger, - }) + }), ) .required(), }).required() diff --git a/services/conda/conda-downloads.service.js b/services/conda/conda-downloads.service.js index 0bd76840c7b6dcbf7b11701d436f0a2051670fe7..a08152ed42729cd0c52e0797ed4362ba18ee79e0 100644 --- a/services/conda/conda-downloads.service.js +++ b/services/conda/conda-downloads.service.js @@ -23,7 +23,7 @@ export default class CondaDownloads extends BaseCondaService { const json = await this.fetch({ channel, pkg }) const downloads = json.files.reduce( (total, file) => total + file.ndownloads, - 0 + 0, ) return this.constructor.render({ variant, downloads }) } diff --git a/services/cookbook/cookbook.tester.js b/services/cookbook/cookbook.tester.js index 2cecfad4678b8fadbdff61d0ff56b4c31c33ef05..cbab7ae8443a365d2200e0ffcaf26b716b6e7113 100644 --- a/services/cookbook/cookbook.tester.js +++ b/services/cookbook/cookbook.tester.js @@ -14,7 +14,7 @@ t.create('version') .get('/api/v1/cookbooks/chef-sugar/versions/latest') .reply(200, { version: '4.1.0', - }) + }), ) .expectBadge({ label: 'cookbook', diff --git a/services/coveralls/coveralls-redirector.tester.js b/services/coveralls/coveralls-redirector.tester.js index d258169c0f323729b595ab0b22536da0831472f6..000102a6b5e8b50b3bfcb4ebfa848cd932bd87db 100644 --- a/services/coveralls/coveralls-redirector.tester.js +++ b/services/coveralls/coveralls-redirector.tester.js @@ -15,27 +15,27 @@ t.create('Coveralls VCS type missing + specified branch') .expectRedirect('/coverallsCoverage/github/jekyll/jekyll.svg?branch=master') t.create( - 'Redirect from before branch was a query param - github, with specified branch' + 'Redirect from before branch was a query param - github, with specified branch', ) .get('/github/jekyll/jekyll/master.svg') .expectRedirect('/coverallsCoverage/github/jekyll/jekyll.svg?branch=master') t.create( - 'Redirect from before branch was a query param - github, without specified branch' + 'Redirect from before branch was a query param - github, without specified branch', ) .get('/github/badges/shields') .expectRedirect('/coverallsCoverage/github/badges/shields.svg') t.create( - 'Redirect from before branch was a query param - bitbucket, with specified branch' + 'Redirect from before branch was a query param - bitbucket, with specified branch', ) .get('/bitbucket/pyKLIP/pyklip/master.svg') .expectRedirect( - '/coverallsCoverage/bitbucket/pyKLIP/pyklip.svg?branch=master' + '/coverallsCoverage/bitbucket/pyKLIP/pyklip.svg?branch=master', ) t.create( - 'Redirect from before branch was a query param - bitbucket, without specified branch' + 'Redirect from before branch was a query param - bitbucket, without specified branch', ) .get('/bitbucket/pyKLIP/pyklip.svg') .expectRedirect('/coverallsCoverage/bitbucket/pyKLIP/pyklip.svg') diff --git a/services/coverity/coverity-scan.tester.js b/services/coverity/coverity-scan.tester.js index 83aa2b092eda32be11bfd582980e1ab5f928b66c..4707bfa07da35485dcffc27745262d4d9b665be2 100644 --- a/services/coverity/coverity-scan.tester.js +++ b/services/coverity/coverity-scan.tester.js @@ -16,7 +16,7 @@ t.create('unknown project id') t.create('404 response') .get('/1.json') .intercept(nock => - nock('https://scan.coverity.com/projects/1').get('/badge.json').reply(404) + nock('https://scan.coverity.com/projects/1').get('/badge.json').reply(404), ) .expectBadge({ label: 'coverity', message: 'project not found' }) @@ -25,7 +25,7 @@ t.create('passed') .intercept(nock => nock('https://scan.coverity.com/projects/2').get('/badge.json').reply(200, { message: 'passed', - }) + }), ) .expectBadge({ label: 'coverity', @@ -38,7 +38,7 @@ t.create('passed with defects') .intercept(nock => nock('https://scan.coverity.com/projects/2').get('/badge.json').reply(200, { message: 'passed 51 new defects', - }) + }), ) .expectBadge({ label: 'coverity', @@ -51,7 +51,7 @@ t.create('pending') .intercept(nock => nock('https://scan.coverity.com/projects/2').get('/badge.json').reply(200, { message: 'pending', - }) + }), ) .expectBadge({ label: 'coverity', @@ -64,7 +64,7 @@ t.create('failed') .intercept(nock => nock('https://scan.coverity.com/projects/2').get('/badge.json').reply(200, { message: 'failed', - }) + }), ) .expectBadge({ label: 'coverity', diff --git a/services/cpan/cpan-version.tester.js b/services/cpan/cpan-version.tester.js index 402601004d6f104a7bc028e1537496b8d8029af8..c2a64ca474b1d285e70e2180d241fb91231940ac 100644 --- a/services/cpan/cpan-version.tester.js +++ b/services/cpan/cpan-version.tester.js @@ -15,7 +15,7 @@ t.create('version (version is a number rather than a string)') .reply(200, { license: ['GPL'], version: 0.88, - }) + }), ) .expectBadge({ label: 'cpan', diff --git a/services/crates/crates-base.js b/services/crates/crates-base.js index d553adb8eabb59d230973d5d7c3da5fd3f7438e3..112befc83f62b4a411520903872af536cad8e772 100644 --- a/services/crates/crates-base.js +++ b/services/crates/crates-base.js @@ -15,7 +15,7 @@ const crateSchema = Joi.object({ Joi.object({ downloads: nonNegativeInteger, license: Joi.string().required().allow(null), - }) + }), ) .min(1) .required(), diff --git a/services/crates/crates-downloads.tester.js b/services/crates/crates-downloads.tester.js index 34953c23c18dd61f02db32bf4dc16bb075cfce72..407241f91334b57d7abad4f428dd0cbfa802935f 100644 --- a/services/crates/crates-downloads.tester.js +++ b/services/crates/crates-downloads.tester.js @@ -42,7 +42,7 @@ t.create('recent downloads (null)') max_version: '0.2.71', }, versions: [{ downloads: 42, license: 'MIT OR Apache-2.0' }], - }) + }), ) .expectBadge({ label: 'recent downloads', message: '0' }) diff --git a/services/crates/crates-license.spec.js b/services/crates/crates-license.spec.js index f6454094dc3d2f76d7a86d36d7f771a10c9ba56f..54259e3c9d2f97ad811f3f44b0156cde02013b1d 100644 --- a/services/crates/crates-license.spec.js +++ b/services/crates/crates-license.spec.js @@ -16,7 +16,7 @@ describe('CratesLicense', function () { it('throws InvalidResponse on error response', function () { expect(() => - CratesLicense.transform({ errors: [{ detail: 'invalid semver' }] }) + CratesLicense.transform({ errors: [{ detail: 'invalid semver' }] }), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'invalid semver') @@ -24,7 +24,7 @@ describe('CratesLicense', function () { it('throws InvalidResponse on null license with specific version', function () { expect(() => - CratesLicense.transform({ version: { num: '1.2.3', license: null } }) + CratesLicense.transform({ version: { num: '1.2.3', license: null } }), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'invalid null license') diff --git a/services/crates/crates-version.spec.js b/services/crates/crates-version.spec.js index 795629689e82fff654a1ac7a63ee4089b64c5a2a..481eaf2414e5b61acf1e512af5259cc1a33d90c7 100644 --- a/services/crates/crates-version.spec.js +++ b/services/crates/crates-version.spec.js @@ -13,7 +13,7 @@ describe('CratesVersion', function () { it('throws InvalidResponse on error response', function () { expect(() => - CratesVersion.prototype.transform({ errors: [{ detail: 'idk how...' }] }) + CratesVersion.prototype.transform({ errors: [{ detail: 'idk how...' }] }), ).to.throw(InvalidResponse) }) }) diff --git a/services/ctan/ctan.tester.js b/services/ctan/ctan.tester.js index ae29df914a6100837b9d86a3dcd5fae3eab261d7..153be112615164f87e34c4e74a545525de483343 100644 --- a/services/ctan/ctan.tester.js +++ b/services/ctan/ctan.tester.js @@ -6,7 +6,7 @@ import { withRegex } from '../test-validators.js' // single lowercase alphabet letter suffix // e.g.: v1.81a const isVPlusDottedVersionAtLeastOneWithOptionalAlphabetLetter = withRegex( - /^v\d+(\.\d+)?(\.\d+)?[a-z]?$/ + /^v\d+(\.\d+)?(\.\d+)?[a-z]?$/, ) export const t = new ServiceTester({ @@ -29,7 +29,7 @@ t.create('license missing') number: 'notRelevant', date: 'notRelevant', }, - }) + }), ) .expectBadge({ label: 'license', @@ -47,7 +47,7 @@ t.create('single license') number: 'notRelevant', date: 'notRelevant', }, - }) + }), ) .expectBadge({ label: 'license', @@ -69,7 +69,7 @@ t.create('version') number: 'v1.11', date: '', }, - }) + }), ) .expectBadge({ label: 'ctan', diff --git a/services/debian/debian.service.js b/services/debian/debian.service.js index 1c70f1746f44416feb7bb655e56f818c15bbc395..14f29b30c58b1b909cc1d4d0e66c411b58c813b0 100644 --- a/services/debian/debian.service.js +++ b/services/debian/debian.service.js @@ -8,8 +8,8 @@ const schema = Joi.array() /./, Joi.object() .pattern(/./, Joi.object().pattern(/./, Joi.object())) - .required() - ) // Optional, missing means not found + .required(), + ), // Optional, missing means not found ) .max(1) .required() diff --git a/services/debian/debian.tester.js b/services/debian/debian.tester.js index d56026c476516069c32c48c3b163e06ff317434d..d379c00ff06db16325892bdf4616f6f1bb18de50 100644 --- a/services/debian/debian.tester.js +++ b/services/debian/debian.tester.js @@ -25,7 +25,7 @@ t.create('Debian package (valid)') { apt: { unstable: { '1.8.0': { source: 'apt', component: 'main' } } }, }, - ]) + ]), ) .expectBadge({ label: 'debian', message: 'v1.8.0' }) @@ -41,7 +41,7 @@ t.create('Debian package (invalid, more than one result)') { apt: { unstable: { '1.8.1': { source: 'apt', component: 'main' } } }, }, - ]) + ]), ) .expectBadge({ label: 'debian', message: 'invalid response data' }) @@ -56,7 +56,7 @@ t.create('Debian package (invalid, requested package missing from response)') unstable: { '1.8.0': { source: 'apt', component: 'main' } }, }, }, - ]) + ]), ) .expectBadge({ label: 'debian', message: 'invalid response data' }) diff --git a/services/depfu/depfu.tester.js b/services/depfu/depfu.tester.js index 36b8b2375728e3c452bd8d038aa3f95893db9478..17e6c829cf477124afe3cc32072d6671b832f5e9 100644 --- a/services/depfu/depfu.tester.js +++ b/services/depfu/depfu.tester.js @@ -5,7 +5,7 @@ const isDependencyStatus = Joi.string().valid( 'insecure', 'latest', 'recent', - 'stale' + 'stale', ) export const t = new ServiceTester({ id: 'depfu', title: 'Depfu' }) @@ -37,7 +37,7 @@ t.create('depfu Github dependencies (no separator)') t.create('depfu Gitlab dependencies (valid with subgroup)') .get( - '/dependencies/gitlab/shields-example-group/subgroup/example-nodejs.json' + '/dependencies/gitlab/shields-example-group/subgroup/example-nodejs.json', ) .expectBadge({ label: 'dependencies', diff --git a/services/discord/discord.service.js b/services/discord/discord.service.js index 5fe8944be119d129aa273fbb89e80904e601ee34..8d13d14700790d69ab7cd104f978ff5aa45e6ef2 100644 --- a/services/discord/discord.service.js +++ b/services/discord/discord.service.js @@ -68,8 +68,8 @@ export default class Discord extends BaseJsonService { 403: 'widget disabled', }, }, - 'Bot' - ) + 'Bot', + ), ) } diff --git a/services/discord/discord.spec.js b/services/discord/discord.spec.js index d787711df54c297932e45b51278aa79f1ec2c7e9..c563ea826d42342090befa8600c9af75410fa2f0 100644 --- a/services/discord/discord.spec.js +++ b/services/discord/discord.spec.js @@ -27,7 +27,7 @@ describe('Discord', function () { expect( await Discord.invoke(defaultContext, config, { serverId: '12345', - }) + }), ).to.deep.equal({ message: '125 online', color: 'brightgreen', diff --git a/services/discord/discord.tester.js b/services/discord/discord.tester.js index 4e9ca9d6d627adaaaf6c5d8b0f6211eb8586fb6b..4d027b24b78230ee4841f90362ffa3fc2a830d3a 100644 --- a/services/discord/discord.tester.js +++ b/services/discord/discord.tester.js @@ -22,7 +22,7 @@ t.create('widget disabled') .reply(403, { code: 50004, message: 'Widget Disabled', - }) + }), ) .expectBadge({ label: 'chat', message: 'widget disabled' }) @@ -31,6 +31,6 @@ t.create('server error') .intercept(nock => nock('https://discord.com/') .get('/api/v6/guilds/12345/widget.json') - .reply(500, 'Something broke') + .reply(500, 'Something broke'), ) .expectBadge({ label: 'chat', message: 'inaccessible' }) diff --git a/services/discourse/discourse-redirect.tester.js b/services/discourse/discourse-redirect.tester.js index 6dce032f5b32178d5357aaa6cd1d760fa3bcf46a..84e15b0565b2dc7d833f31c4ee7336041634a404 100644 --- a/services/discourse/discourse-redirect.tester.js +++ b/services/discourse/discourse-redirect.tester.js @@ -10,38 +10,38 @@ t.create('discourse status') .get('/https/meta.discourse.org/status.svg') .expectRedirect( `/discourse/status.svg?server=${encodeURIComponent( - 'https://meta.discourse.org' - )}` + 'https://meta.discourse.org', + )}`, ) t.create('discourse topics') .get('/https/meta.discourse.org/topics.svg') .expectRedirect( `/discourse/topics.svg?server=${encodeURIComponent( - 'https://meta.discourse.org' - )}` + 'https://meta.discourse.org', + )}`, ) t.create('discourse users') .get('/https/meta.discourse.org/users.svg') .expectRedirect( `/discourse/users.svg?server=${encodeURIComponent( - 'https://meta.discourse.org' - )}` + 'https://meta.discourse.org', + )}`, ) t.create('discourse likes') .get('/https/meta.discourse.org/likes.svg') .expectRedirect( `/discourse/likes.svg?server=${encodeURIComponent( - 'https://meta.discourse.org' - )}` + 'https://meta.discourse.org', + )}`, ) t.create('discourse posts') .get('/https/meta.discourse.org/posts.svg') .expectRedirect( `/discourse/posts.svg?server=${encodeURIComponent( - 'https://meta.discourse.org' - )}` + 'https://meta.discourse.org', + )}`, ) diff --git a/services/discourse/discourse.tester.js b/services/discourse/discourse.tester.js index dc779eb291a455895452b85cf7f9f75272617c2e..bdaac3d56c57282aa454d8a7753ed2932ee7589c 100644 --- a/services/discourse/discourse.tester.js +++ b/services/discourse/discourse.tester.js @@ -28,7 +28,7 @@ t.create('Topics') .intercept(nock => nock('https://meta.discourse.org') .get('/site/statistics.json') - .reply(200, data) + .reply(200, data), ) .expectBadge({ label: 'discourse', message: '23k topics' }) @@ -37,7 +37,7 @@ t.create('Posts') .intercept(nock => nock('https://meta.discourse.org') .get('/site/statistics.json') - .reply(200, data) + .reply(200, data), ) .expectBadge({ label: 'discourse', message: '338k posts' }) @@ -46,7 +46,7 @@ t.create('Users') .intercept(nock => nock('https://meta.discourse.org') .get('/site/statistics.json') - .reply(200, data) + .reply(200, data), ) .expectBadge({ label: 'discourse', message: '31k users' }) @@ -55,7 +55,7 @@ t.create('Likes') .intercept(nock => nock('https://meta.discourse.org') .get('/site/statistics.json') - .reply(200, data) + .reply(200, data), ) .expectBadge({ label: 'discourse', message: '309k likes' }) @@ -64,7 +64,7 @@ t.create('Status') .intercept(nock => nock('https://meta.discourse.org') .get('/site/statistics.json') - .reply(200, data) + .reply(200, data), ) .expectBadge({ label: 'discourse', message: 'online' }) @@ -73,7 +73,7 @@ t.create('Status with http (not https)') .intercept(nock => nock('http://meta.discourse.org') .get('/site/statistics.json') - .reply(200, data) + .reply(200, data), ) .expectBadge({ label: 'discourse', message: 'online' }) @@ -82,7 +82,7 @@ t.create('Invalid Host') .intercept(nock => nock('https://some.host') .get('/site/statistics.json') - .reply(404, '<h1>Not Found</h1>') + .reply(404, '<h1>Not Found</h1>'), ) .expectBadge({ label: 'discourse', message: 'not found' }) @@ -91,7 +91,7 @@ t.create('Topics') .expectBadge({ label: 'discourse', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) topics$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) topics$/, ), }) @@ -100,7 +100,7 @@ t.create('Posts') .expectBadge({ label: 'discourse', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) posts$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) posts$/, ), }) @@ -109,7 +109,7 @@ t.create('Users') .expectBadge({ label: 'discourse', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) users$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) users$/, ), }) @@ -118,7 +118,7 @@ t.create('Likes') .expectBadge({ label: 'discourse', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) likes$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) likes$/, ), }) diff --git a/services/docker/docker-automated.service.js b/services/docker/docker-automated.service.js index c5432f813439422f144a97308ab179545ee18468..067b778a31023557b51454f2440e0e5b982465b0 100644 --- a/services/docker/docker-automated.service.js +++ b/services/docker/docker-automated.service.js @@ -38,7 +38,7 @@ export default class DockerAutomatedBuild extends BaseJsonService { return this._requestJson({ schema: automatedBuildSchema, url: `https://registry.hub.docker.com/v2/repositories/${getDockerHubUser( - user + user, )}/${repo}`, httpErrors: { 404: 'repo not found' }, }) diff --git a/services/docker/docker-automated.tester.js b/services/docker/docker-automated.tester.js index f52ae96d0db69a1c609ded4c7002c702a7198308..38e312de3a251fa6ba8a237f0b14610f9e12251e 100644 --- a/services/docker/docker-automated.tester.js +++ b/services/docker/docker-automated.tester.js @@ -28,7 +28,7 @@ t.create('docker automated build - automated') .intercept(nock => nock('https://registry.hub.docker.com/') .get('/v2/repositories/library/ubuntu') - .reply(200, { is_automated: true }) + .reply(200, { is_automated: true }), ) .expectBadge({ label: 'docker build', @@ -41,6 +41,6 @@ t.create('docker automated build - manual') .intercept(nock => nock('https://registry.hub.docker.com/') .get('/v2/repositories/library/ubuntu') - .reply(200, { is_automated: false }) + .reply(200, { is_automated: false }), ) .expectBadge({ label: 'docker build', message: 'manual', color: 'yellow' }) diff --git a/services/docker/docker-cloud-automated.tester.js b/services/docker/docker-cloud-automated.tester.js index d68175bc96a5f57a1be617c388009bca6138c50f..204b8dc8a8d49fe083bde1b757bd4fdbc07dc68b 100644 --- a/services/docker/docker-cloud-automated.tester.js +++ b/services/docker/docker-cloud-automated.tester.js @@ -20,7 +20,7 @@ t.create('docker cloud automated build status (invalid, nonexisting user)') }) t.create( - "docker cloud build status (valid user, but the 'objects' array from the response is empty)" + "docker cloud build status (valid user, but the 'objects' array from the response is empty)", ) .get('/pavics/weaver.json') .expectBadge({ @@ -34,10 +34,10 @@ t.create('docker cloud automated build (not found)') nock('https://cloud.docker.com/') .get( `/api/build/v1/source?image=${encodeURIComponent( - 'badges/not-a-real-repo' - )}` + 'badges/not-a-real-repo', + )}`, ) - .reply(404, { detail: 'Object not found' }) + .reply(404, { detail: 'Object not found' }), ) .expectBadge({ label: 'docker build', message: 'repo not found' }) @@ -46,7 +46,7 @@ t.create('docker cloud automated build - automated') .intercept(nock => nock('https://cloud.docker.com/') .get(`/api/build/v1/source?image=${encodeURIComponent('xenolf/lego')}`) - .reply(200, { objects: [{ build_settings: ['test1'] }] }) + .reply(200, { objects: [{ build_settings: ['test1'] }] }), ) .expectBadge({ label: 'docker build', @@ -59,6 +59,6 @@ t.create('docker cloud automated build - manual') .intercept(nock => nock('https://cloud.docker.com/') .get(`/api/build/v1/source?image=${encodeURIComponent('xenolf/lego')}`) - .reply(200, { objects: [{ build_settings: [] }] }) + .reply(200, { objects: [{ build_settings: [] }] }), ) .expectBadge({ label: 'docker build', message: 'manual', color: 'yellow' }) diff --git a/services/docker/docker-cloud-build.tester.js b/services/docker/docker-cloud-build.tester.js index 9d63a7e0ebb49bb03a2b879b4ab75f79ee45f936..5009c825289a2b3c86f35fd6ebd6c15547bb9c20 100644 --- a/services/docker/docker-cloud-build.tester.js +++ b/services/docker/docker-cloud-build.tester.js @@ -18,7 +18,7 @@ t.create('docker cloud build status (invalid, nonexisting user)') }) t.create( - "docker cloud build status (valid user, but the 'objects' array from the response is empty)" + "docker cloud build status (valid user, but the 'objects' array from the response is empty)", ) .get('/pavics/weaver.json') .expectBadge({ @@ -32,10 +32,10 @@ t.create('docker cloud build status (not found)') nock('https://cloud.docker.com/') .get( `/api/build/v1/source?image=${encodeURIComponent( - 'badges/not-a-real-repo' - )}` + 'badges/not-a-real-repo', + )}`, ) - .reply(404, { detail: 'Object not found' }) + .reply(404, { detail: 'Object not found' }), ) .expectBadge({ label: 'docker build', message: 'repo not found' }) @@ -44,7 +44,7 @@ t.create('docker cloud build status (passing)') .intercept(nock => nock('https://cloud.docker.com/') .get(`/api/build/v1/source?image=${encodeURIComponent('xenolf/lego')}`) - .reply(200, { objects: [{ state: 'Success' }] }) + .reply(200, { objects: [{ state: 'Success' }] }), ) .expectBadge({ label: 'docker build', @@ -57,7 +57,7 @@ t.create('docker cloud build status (failing)') .intercept(nock => nock('https://cloud.docker.com/') .get(`/api/build/v1/source?image=${encodeURIComponent('xenolf/lego')}`) - .reply(200, { objects: [{ state: 'Failed' }] }) + .reply(200, { objects: [{ state: 'Failed' }] }), ) .expectBadge({ label: 'docker build', message: 'failing', color: 'red' }) @@ -66,7 +66,7 @@ t.create('docker cloud build status (building)') .intercept(nock => nock('https://cloud.docker.com/') .get(`/api/build/v1/source?image=${encodeURIComponent('xenolf/lego')}`) - .reply(200, { objects: [{ state: 'Empty' }] }) + .reply(200, { objects: [{ state: 'Empty' }] }), ) .expectBadge({ label: 'docker build', diff --git a/services/docker/docker-cloud-common-fetch.js b/services/docker/docker-cloud-common-fetch.js index bea59e66d3e50f33f0a35adb26ffd447b95afddb..60e12ffb0b38a6daab1fb3116dfcd954193dcccd 100644 --- a/services/docker/docker-cloud-common-fetch.js +++ b/services/docker/docker-cloud-common-fetch.js @@ -6,7 +6,7 @@ const cloudBuildSchema = Joi.object({ Joi.object({ state: Joi.string(), build_settings: Joi.array(), - }) + }), ) .required(), }).required() diff --git a/services/docker/docker-helpers.js b/services/docker/docker-helpers.js index c7da530fd5f7d592d66aea638e8262cbc87fb88a..c373297499f963468090ce9f9020c62712ded878 100644 --- a/services/docker/docker-helpers.js +++ b/services/docker/docker-helpers.js @@ -18,9 +18,9 @@ const archSchema = Joi.alternatives( 'mipsle', 'mips64', 'mips64le', - 'riscv64' + 'riscv64', ), - Joi.number().valid(386).cast('string') + Joi.number().valid(386).cast('string'), ) function buildDockerUrl(badgeName, includeTagRoute) { @@ -56,8 +56,8 @@ async function getMultiPageData({ user, repo, fetch }) { const pageData = await Promise.all( [...Array(numberOfPages - 1).keys()].map((_, i) => - fetch({ user, repo, page: ++i + 1 }) - ) + fetch({ user, repo, page: ++i + 1 }), + ), ) return [...data.results].concat(...pageData.map(p => p.results)) } diff --git a/services/docker/docker-pulls.service.js b/services/docker/docker-pulls.service.js index a3ac7924638a1b2cd8e5775b0e1818b2f584b2e3..51b010e843230dcd77f553d1b80b66ede9ce15d7 100644 --- a/services/docker/docker-pulls.service.js +++ b/services/docker/docker-pulls.service.js @@ -38,7 +38,7 @@ export default class DockerPulls extends BaseJsonService { return this._requestJson({ schema: pullsSchema, url: `https://hub.docker.com/v2/repositories/${getDockerHubUser( - user + user, )}/${repo}`, httpErrors: { 404: 'repo not found' }, }) diff --git a/services/docker/docker-size.service.js b/services/docker/docker-size.service.js index bef483105c86a66168705120c1254f6fb12dc8da..03f33ad8f2a675f8d1c3c5b566ea0e87db75a90d 100644 --- a/services/docker/docker-size.service.js +++ b/services/docker/docker-size.service.js @@ -17,7 +17,7 @@ const buildSchema = Joi.object({ Joi.object({ size: nonNegativeInteger.required(), architecture: Joi.string().required(), - }) + }), ), }).required() @@ -31,9 +31,9 @@ const pagedSchema = Joi.object({ Joi.object({ size: nonNegativeInteger.required(), architecture: Joi.string().required(), - }) + }), ), - }) + }), ), }).required() @@ -49,7 +49,7 @@ const queryParamSchema = Joi.object({ // For details see: https://github.com/badges/shields/issues/8238 function getImageSizeForArch(images, arch) { const imgWithArch = Object.values(images).find( - img => img.architecture === arch + img => img.architecture === arch, ) if (!imgWithArch) { @@ -103,7 +103,7 @@ export default class DockerSize extends BaseJsonService { return this._requestJson({ schema: tag ? buildSchema : pagedSchema, url: `https://registry.hub.docker.com/v2/repositories/${getDockerHubUser( - user + user, )}/${repo}/tags${ tag ? `/${tag}` : '?page_size=100&ordering=last_updated' }${page}`, @@ -139,7 +139,7 @@ export default class DockerSize extends BaseJsonService { i[d.name] = d.images return [m, v, i] }, - [{}, [], {}] + [{}, [], {}], ) const version = latest(versions) diff --git a/services/docker/docker-size.spec.js b/services/docker/docker-size.spec.js index 66c9c4270aded5c1147254784895b614e45f94af..b53cd4d67ab650c9a59fd7ed18081c68db628e91 100644 --- a/services/docker/docker-size.spec.js +++ b/services/docker/docker-size.spec.js @@ -9,7 +9,7 @@ describe('DockerSize', function () { count: 0, results: [], }, - 'amd64' + 'amd64', ).expectError('Not Found: repository not found') given( { @@ -22,7 +22,7 @@ describe('DockerSize', function () { }, ], }, - 'amd64' + 'amd64', ).expect({ size: 219939484, }) @@ -55,7 +55,7 @@ describe('DockerSize', function () { }, ], }, - 'arm64777' + 'arm64777', ).expectError('Not Found: architecture not found') }) @@ -66,7 +66,7 @@ describe('DockerSize', function () { name: 'next', images: [{ architecture: 'amd64', size: 219939484 }], }, - 'amd64' + 'amd64', ).expect({ size: 219939484, }) @@ -83,7 +83,7 @@ describe('DockerSize', function () { name: 'next', images: [{ architecture: 'amd64', size: 219939484 }], }, - 'arm64777' + 'arm64777', ).expectError('Not Found: architecture not found') }) @@ -95,7 +95,7 @@ describe('DockerSize', function () { size: 400000000, }) given(sizeDataNoTagSemVerSort, 'nonexistentArch').expectError( - 'Not Found: architecture not found' + 'Not Found: architecture not found', ) }) }) diff --git a/services/docker/docker-stars.service.js b/services/docker/docker-stars.service.js index cff58af37bd3032b9a6f259ff25ec412a65457f5..398413dc06c6d5af7998400ad0aa043ddf9e7e83 100644 --- a/services/docker/docker-stars.service.js +++ b/services/docker/docker-stars.service.js @@ -41,7 +41,7 @@ export default class DockerStars extends BaseJsonService { return this._requestJson({ schema, url: `https://hub.docker.com/v2/repositories/${getDockerHubUser( - user + user, )}/${repo}/`, httpErrors: { 404: 'repo not found' }, }) diff --git a/services/docker/docker-version.service.js b/services/docker/docker-version.service.js index e61ff42a423adc5133ace186e3402fe3f6e8b355..f3152432dcfffbfd0edc1d8d9c5f46e5765d112f 100644 --- a/services/docker/docker-version.service.js +++ b/services/docker/docker-version.service.js @@ -19,9 +19,9 @@ const buildSchema = Joi.object({ Joi.object({ digest: Joi.string(), architecture: Joi.string().required(), - }) + }), ), - }) + }), ), }).required() @@ -67,7 +67,7 @@ export default class DockerVersion extends BaseJsonService { return this._requestJson({ schema: buildSchema, url: `https://registry.hub.docker.com/v2/repositories/${getDockerHubUser( - user + user, )}/${repo}/tags?page_size=100&ordering=last_updated${page}`, httpErrors: { 404: 'repository or tag not found' }, }) diff --git a/services/docsrs/docsrs.service.js b/services/docsrs/docsrs.service.js index de9909b44d76c0030f16a21e3ae0bd7968217d9d..f1c9d5f4dda73c0e66be56104ee8b9483543fc69 100644 --- a/services/docsrs/docsrs.service.js +++ b/services/docsrs/docsrs.service.js @@ -5,7 +5,7 @@ const schema = Joi.array() .items( Joi.object({ build_status: Joi.boolean().required(), - }) + }), ) .min(1) .required() diff --git a/services/drone/drone-build.service.js b/services/drone/drone-build.service.js index 74132b604671746dca7077f346963cbb1392c0de..11e06496b4aeb3a96fa1937017b7c8bffbc6072e 100644 --- a/services/drone/drone-build.service.js +++ b/services/drone/drone-build.service.js @@ -78,7 +78,7 @@ export default class DroneBuild extends BaseJsonService { httpErrors: { 401: 'repo not found or not authorized', }, - }) + }), ) return renderBuildStatusBadge({ status: json.status }) } diff --git a/services/drone/drone-build.spec.js b/services/drone/drone-build.spec.js index 966e952f054ffe95b215012cb76796b4ce972532..d14812cc86d81cfede8748131668f93ca00dd66a 100644 --- a/services/drone/drone-build.spec.js +++ b/services/drone/drone-build.spec.js @@ -30,8 +30,8 @@ describe('DroneBuild', function () { drone_token: token, }, }, - { user: 'atlassian', repo: 'python-bitbucket' } - ) + { user: 'atlassian', repo: 'python-bitbucket' }, + ), ).to.deep.equal({ label: undefined, message: 'passing', diff --git a/services/drone/drone-build.tester.js b/services/drone/drone-build.tester.js index fccb0a06fb726698ebda92c65cc03b49f6089e95..4e6ce48571fa7f73a5b779cd21632dccd63ffefd 100644 --- a/services/drone/drone-build.tester.js +++ b/services/drone/drone-build.tester.js @@ -6,7 +6,7 @@ export const t = await createServiceTester() const isDroneBuildStatus = Joi.alternatives().try( isBuildStatus, Joi.equal('none'), - Joi.equal('killed') + Joi.equal('killed'), ) t.create('cloud-hosted build status on default branch') @@ -35,7 +35,7 @@ t.create('self-hosted build status on default branch') .intercept(nock => nock('https://drone.shields.io/api/repos') .get('/badges/shields/builds/latest') - .reply(200, { status: 'success' }) + .reply(200, { status: 'success' }), ) .expectBadge({ label: 'build', @@ -44,13 +44,13 @@ t.create('self-hosted build status on default branch') t.create('self-hosted build status on named branch') .get( - '/badges/shields/feat/awesome-thing.json?server=https://drone.shields.io' + '/badges/shields/feat/awesome-thing.json?server=https://drone.shields.io', ) .intercept(nock => nock('https://drone.shields.io/api/repos') .get('/badges/shields/builds/latest') .query({ ref: 'refs/heads/feat/awesome-thing' }) - .reply(200, { status: 'success' }) + .reply(200, { status: 'success' }), ) .expectBadge({ label: 'build', diff --git a/services/dub/dub-download.tester.js b/services/dub/dub-download.tester.js index 4733e5343a2b9d9b0a6207c276760e2aac272d6f..aa1697837240399236ba69342ee7e41e71f6bbfd 100644 --- a/services/dub/dub-download.tester.js +++ b/services/dub/dub-download.tester.js @@ -8,7 +8,7 @@ const isDownloadsColor = Joi.equal( 'yellow', 'yellowgreen', 'green', - 'brightgreen' + 'brightgreen', ) t.create('total downloads (valid)').get('/dt/vibe-d.json').expectBadge({ diff --git a/services/dynamic-common.js b/services/dynamic-common.js index 04a68e78cd301178f6a018cb42a7d9e82dd25dfa..c1be2faf2bb5a0dca99df95e8083db15531f1f44 100644 --- a/services/dynamic-common.js +++ b/services/dynamic-common.js @@ -37,7 +37,7 @@ const individualValueSchema = Joi.alternatives() const compoundValueSchema = Joi.alternatives().try( individualValueSchema, Joi.array().items(individualValueSchema).required(), - Joi.array().length(0) + Joi.array().length(0), ) /** @@ -58,7 +58,7 @@ function transformAndValidate({ data, key }) { traceSuccessMessage: 'Key value after validation', }, data[key], - compoundValueSchema + compoundValueSchema, ) } diff --git a/services/dynamic/dynamic-json.tester.js b/services/dynamic/dynamic-json.tester.js index 38bb48ee7479469da0e9b133713b56bcd996bc9c..2995e064f814a1361f649cfd6755bf64c37d8cbc 100644 --- a/services/dynamic/dynamic-json.tester.js +++ b/services/dynamic/dynamic-json.tester.js @@ -13,7 +13,7 @@ t.create('No URL specified') t.create('No query specified') .get( - '.json?url=https://github.com/badges/shields/raw/master/package.json&label=Package Name' + '.json?url=https://github.com/badges/shields/raw/master/package.json&label=Package Name', ) .expectBadge({ label: 'Package Name', @@ -23,7 +23,7 @@ t.create('No query specified') t.create('Malformed url') .get( - '.json?url=https://github.com/badges/shields/raw/master/%0package.json&query=$.name&label=Package Name' + '.json?url=https://github.com/badges/shields/raw/master/%0package.json&query=$.name&label=Package Name', ) .expectBadge({ label: 'Package Name', @@ -33,7 +33,7 @@ t.create('Malformed url') t.create('JSON from url') .get( - '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.name' + '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.name', ) .expectBadge({ label: 'custom badge', @@ -43,7 +43,7 @@ t.create('JSON from url') t.create('support uri query parameter') .get( - '.json?uri=https://github.com/badges/shields/raw/master/package.json&query=$.name' + '.json?uri=https://github.com/badges/shields/raw/master/package.json&query=$.name', ) .expectBadge({ label: 'custom badge', @@ -53,13 +53,13 @@ t.create('support uri query parameter') t.create('multiple results') .get( - '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$..keywords[0:2:1]' + '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$..keywords[0:2:1]', ) .expectBadge({ label: 'custom badge', message: 'GitHub, badge' }) t.create('caching with new query params') .get( - '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.version' + '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.version', ) .expectBadge({ label: 'custom badge', @@ -68,7 +68,7 @@ t.create('caching with new query params') t.create('prefix & suffix & label') .get( - '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.version&prefix=v&suffix= dev&label=Shields' + '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.version&prefix=v&suffix= dev&label=Shields', ) .expectBadge({ label: 'Shields', @@ -77,7 +77,7 @@ t.create('prefix & suffix & label') t.create("key doesn't exist") .get( - '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.does_not_exist' + '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.does_not_exist', ) .expectBadge({ label: 'custom badge', @@ -87,7 +87,7 @@ t.create("key doesn't exist") t.create('invalid url') .get( - '.json?url=https://github.com/badges/shields/raw/master/notafile.json&query=$.version' + '.json?url=https://github.com/badges/shields/raw/master/notafile.json&query=$.version', ) .expectBadge({ label: 'custom badge', @@ -97,7 +97,7 @@ t.create('invalid url') t.create('user color overrides default') .get( - '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.name&color=10ADED' + '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.name&color=10ADED', ) .expectBadge({ label: 'custom badge', @@ -107,7 +107,7 @@ t.create('user color overrides default') t.create('error color overrides default') .get( - '.json?url=https://github.com/badges/shields/raw/master/notafile.json&query=$.version' + '.json?url=https://github.com/badges/shields/raw/master/notafile.json&query=$.version', ) .expectBadge({ label: 'custom badge', @@ -132,7 +132,7 @@ t.create('request should set Accept header') .reply(200, function (uri, requestBody) { headers = this.req.headers return '{"name":"test"}' - }) + }), ) .expectBadge({ label: 'custom badge', message: 'test' }) .after(() => { @@ -141,7 +141,7 @@ t.create('request should set Accept header') t.create('query with lexical error') .get( - '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$[?' + '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$[?', ) .expectBadge({ label: 'custom badge', @@ -151,7 +151,7 @@ t.create('query with lexical error') t.create('query with parse error') .get( - '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.foo,' + '.json?url=https://github.com/badges/shields/raw/master/package.json&query=$.foo,', ) .expectBadge({ label: 'custom badge', @@ -165,8 +165,8 @@ const badQuery = t.create('query with invalid token') .get( `.json?url=https://github.com/badges/shields/raw/master/package.json&query=${encodeURIComponent( - badQuery - )}` + badQuery, + )}`, ) .expectBadge({ label: 'custom badge', @@ -177,7 +177,7 @@ t.create('query with invalid token') t.create('JSON contains an array') .get('.json?url=https://example.test/json&query=$[0]') .intercept(nock => - nock('https://example.test').get('/json').reply(200, '["foo"]') + nock('https://example.test').get('/json').reply(200, '["foo"]'), ) .expectBadge({ label: 'custom badge', @@ -187,7 +187,7 @@ t.create('JSON contains an array') t.create('JSON contains a string') .get('.json?url=https://example.test/json&query=$.foo,') .intercept(nock => - nock('https://example.test').get('/json').reply(200, '"foo"') + nock('https://example.test').get('/json').reply(200, '"foo"'), ) .expectBadge({ label: 'custom badge', diff --git a/services/dynamic/dynamic-xml.spec.js b/services/dynamic/dynamic-xml.spec.js index ca233d2c0abeb9829828c42fa37f1b42a4d79ca8..e239545656db796ef08d2fa0880fdab135985b1c 100644 --- a/services/dynamic/dynamic-xml.spec.js +++ b/services/dynamic/dynamic-xml.spec.js @@ -35,7 +35,7 @@ describe('DynamicXml', function () { DynamicXml.prototype.transform({ pathExpression: '//book/title', buffer: exampleXml, - }) + }), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'unsupported query') @@ -52,7 +52,7 @@ describe('DynamicXml', function () { given({ pathExpression: '//book/title/text()', buffer: exampleXml }).expect( { values: ["XML Developer's Guide", 'Midnight Rain'], - } + }, ) given({ pathExpression: 'string(//book[1]/title)', diff --git a/services/dynamic/dynamic-xml.tester.js b/services/dynamic/dynamic-xml.tester.js index a35d303c3ec41c924f2c8425e1716540dec9f847..ffaaa2ebb90a76c396f33be7311b7172893c0171 100644 --- a/services/dynamic/dynamic-xml.tester.js +++ b/services/dynamic/dynamic-xml.tester.js @@ -28,7 +28,7 @@ t.create('XML from url') `.json?${queryString.stringify({ url: exampleUrl, query: "//book[@id='bk102']/title", - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -42,7 +42,7 @@ t.create('uri query parameter alias') `.json?${queryString.stringify({ uri: exampleUrl, query: "//book[@id='bk102']/title", - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -56,7 +56,7 @@ t.create('attribute') `.json?${queryString.stringify({ url: exampleUrl, query: '//book[2]/@id', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -69,7 +69,7 @@ t.create('multiple results') `.json?${queryString.stringify({ url: exampleUrl, query: '//book/title', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -85,7 +85,7 @@ t.create('prefix and suffix') query: "//book[@id='bk102']/title", prefix: 'title is ', suffix: ', innit', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -97,7 +97,7 @@ t.create('query doesnt exist') `.json?${queryString.stringify({ url: exampleUrl, query: '//does/not/exist', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -111,7 +111,7 @@ t.create('query doesnt exist (attribute)') `.json?${queryString.stringify({ url: exampleUrl, query: '//does/not/@exist', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -125,7 +125,7 @@ t.create('Cannot resolve QName') `.json?${queryString.stringify({ url: exampleUrl, query: '//a:si', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -139,7 +139,7 @@ t.create('XPath parse error') `.json?${queryString.stringify({ url: exampleUrl, query: '//a[contains(@href, "foo"]', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -150,7 +150,7 @@ t.create('XPath parse error') t.create('XML from url | invalid url') .get( - '.json?url=https://github.com/badges/shields/raw/master/notafile.xml&query=//version' + '.json?url=https://github.com/badges/shields/raw/master/notafile.xml&query=//version', ) .expectBadge({ label: 'custom badge', @@ -163,14 +163,14 @@ t.create('request should set Accept header') `.json?${queryString.stringify({ url: exampleUrl, query: "//book[@id='bk102']/title", - })}` + })}`, ) .intercept(nock => nock('https://example.test', { reqheaders: { accept: 'application/xml, text/xml' }, }) .get('/example.xml') - .reply(200, exampleXml) + .reply(200, exampleXml), ) .expectBadge({ label: 'custom badge', message: 'Midnight Rain' }) @@ -179,7 +179,7 @@ t.create('query with node function') `.json?${queryString.stringify({ url: exampleUrl, query: '//book[1]/title/text()', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -193,7 +193,7 @@ t.create('query with type conversion to string') `.json?${queryString.stringify({ url: exampleUrl, query: 'string(//book[1]/title)', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ @@ -207,7 +207,7 @@ t.create('query with type conversion to number') `.json?${queryString.stringify({ url: exampleUrl, query: 'number(//book[1]/price)', - })}` + })}`, ) .intercept(withExampleXml) .expectBadge({ diff --git a/services/dynamic/dynamic-yaml.tester.js b/services/dynamic/dynamic-yaml.tester.js index e3d5cce1fcae3597a36eebe250edc4c6d4c0dfa3..f1b43b78aa2e0d8ff1dd4bd70d9be744f9854bdc 100644 --- a/services/dynamic/dynamic-yaml.tester.js +++ b/services/dynamic/dynamic-yaml.tester.js @@ -11,7 +11,7 @@ t.create('No URL specified') t.create('No query specified') .get( - '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&label=Package Name' + '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&label=Package Name', ) .expectBadge({ label: 'Package Name', @@ -21,7 +21,7 @@ t.create('No query specified') t.create('YAML from url') .get( - '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.name' + '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.name', ) .expectBadge({ label: 'custom badge', @@ -31,7 +31,7 @@ t.create('YAML from url') t.create('YAML from uri (support uri query parameter)') .get( - '.json?uri=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.name' + '.json?uri=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.name', ) .expectBadge({ label: 'custom badge', @@ -41,25 +41,25 @@ t.create('YAML from uri (support uri query parameter)') t.create('YAML from url | multiple results') .get( - '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$..keywords[0:2:1]' + '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$..keywords[0:2:1]', ) .expectBadge({ label: 'custom badge', message: 'coredns, dns' }) t.create('YAML from url | caching with new query params') .get( - '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.version' + '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.version', ) .expectBadge({ label: 'custom badge', message: '0.8.0' }) t.create('YAML from url | with prefix & suffix & label') .get( - '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.version&prefix=v&suffix= dev&label=Shields' + '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.version&prefix=v&suffix= dev&label=Shields', ) .expectBadge({ label: 'Shields', message: 'v0.8.0 dev' }) t.create('YAML from url | object doesnt exist') .get( - '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.does_not_exist' + '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.does_not_exist', ) .expectBadge({ label: 'custom badge', @@ -69,7 +69,7 @@ t.create('YAML from url | object doesnt exist') t.create('YAML from url | invalid url') .get( - '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/notafile.yaml&query=$.version' + '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/notafile.yaml&query=$.version', ) .expectBadge({ label: 'custom badge', @@ -79,13 +79,13 @@ t.create('YAML from url | invalid url') t.create('YAML from url | user color overrides default') .get( - '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.name&color=10ADED' + '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/Chart.yaml&query=$.name&color=10ADED', ) .expectBadge({ label: 'custom badge', message: 'coredns', color: '#10aded' }) t.create('YAML from url | error color overrides default') .get( - '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/notafile.yaml&query=$.version' + '.json?url=https://raw.githubusercontent.com/kubernetes/charts/568291d6e476c39ca8322c30c3f601d0383d4760/stable/coredns/notafile.yaml&query=$.version', ) .expectBadge({ label: 'custom badge', @@ -104,7 +104,7 @@ t.create('YAML from url | error color overrides user specified') t.create('YAML contains a string') .get('.json?url=https://example.test/yaml&query=$.foo,') .intercept(nock => - nock('https://example.test').get('/yaml').reply(200, '"foo"') + nock('https://example.test').get('/yaml').reply(200, '"foo"'), ) .expectBadge({ label: 'custom badge', diff --git a/services/dynamic/json-path.js b/services/dynamic/json-path.js index 64c45d1578519328f2ce5f5336a036298cc99c35..4019dde84076edf7b9693e6640f70fdf2f80676a 100644 --- a/services/dynamic/json-path.js +++ b/services/dynamic/json-path.js @@ -32,7 +32,7 @@ export default superclass => */ async fetch({ schema, url, httpErrors }) { throw new Error( - `fetch() function not implemented for ${this.constructor.name}` + `fetch() function not implemented for ${this.constructor.name}`, ) } diff --git a/services/dynamic/json-path.spec.js b/services/dynamic/json-path.spec.js index 7e309dba653f69b408c5b89e8c20dc8d4e04ccba..6879f735950c3eab51f30378a480fab393926518 100644 --- a/services/dynamic/json-path.spec.js +++ b/services/dynamic/json-path.spec.js @@ -13,7 +13,7 @@ describe('JSON Path service factory', function () { return expect(jsonPathServiceInstance.fetch({})).to.be.rejectedWith( Error, - 'fetch() function not implemented for JsonPathService' + 'fetch() function not implemented for JsonPathService', ) }) }) diff --git a/services/eclipse-marketplace/eclipse-marketplace-license.tester.js b/services/eclipse-marketplace/eclipse-marketplace-license.tester.js index 471651696b29519cd0203b2783a7339daacfb305..d12cbe61817f19969b72bdfed515a79ee25c543d 100644 --- a/services/eclipse-marketplace/eclipse-marketplace-license.tester.js +++ b/services/eclipse-marketplace/eclipse-marketplace-license.tester.js @@ -17,8 +17,8 @@ t.create('unspecified license') <node id="3108021" name="Notepad4e" url="https://marketplace.eclipse.org/content/notepad4e"> <license/> </node> - </marketplace>` - ) + </marketplace>`, + ), ) .expectBadge({ label: 'license', diff --git a/services/ecologi/ecologi-trees.tester.js b/services/ecologi/ecologi-trees.tester.js index 01d776263a396e81a67b3cee6fb32512d217245b..4aafb00ffb58e7f37e638d06742595b8f98daea1 100644 --- a/services/ecologi/ecologi-trees.tester.js +++ b/services/ecologi/ecologi-trees.tester.js @@ -12,7 +12,7 @@ t.create('request for existing username') .intercept(nock => nock('https://public.ecologi.com') .get('/users/ecologi/trees') - .reply(200, { total: 50 }) + .reply(200, { total: 50 }), ) .expectBadge({ label: 'trees', diff --git a/services/endpoint-common.js b/services/endpoint-common.js index 164762fd82b308162e28c28bc21e4c2ffd12f8c5..fa51d390a162141108fa0e37ed8ad813c33ce58b 100644 --- a/services/endpoint-common.js +++ b/services/endpoint-common.js @@ -13,7 +13,7 @@ const optionalStringWhenNamedLogoPresent = Joi.alternatives().conditional( { is: Joi.string().required(), then: Joi.string(), - } + }, ) const optionalNumberWhenAnyLogoPresent = Joi.alternatives() @@ -58,7 +58,7 @@ const endpointSchema = Joi.object({ */ function validateEndpointData( data, - { prettyErrorMessage = 'invalid response data', includeKeys = false } = {} + { prettyErrorMessage = 'invalid response data', includeKeys = false } = {}, ) { return validate( { @@ -70,7 +70,7 @@ function validateEndpointData( allowAndStripUnknownKeys: false, }, data, - endpointSchema + endpointSchema, ) } @@ -89,7 +89,7 @@ const anySchema = Joi.any() */ async function fetchEndpointData( serviceInstance, - { url, httpErrors, validationPrettyErrorMessage, includeKeys } + { url, httpErrors, validationPrettyErrorMessage, includeKeys }, ) { const json = await serviceInstance._requestJson({ schema: anySchema, diff --git a/services/endpoint/endpoint.service.js b/services/endpoint/endpoint.service.js index c4dcf7d2b4eff14f13897ebcafa2da3c7f5ab5c5..46bc6c8412615d4cae0931611e124b596a28e357 100644 --- a/services/endpoint/endpoint.service.js +++ b/services/endpoint/endpoint.service.js @@ -180,7 +180,7 @@ export default class Endpoint extends BaseJsonService { style, // don't allow the user to set cacheSeconds any shorter than this._cacheLength cacheSeconds: Math.max( - ...[this._cacheLength, cacheSeconds].filter(x => x !== undefined) + ...[this._cacheLength, cacheSeconds].filter(x => x !== undefined), ), } } diff --git a/services/endpoint/endpoint.tester.js b/services/endpoint/endpoint.tester.js index 3b5fc9d53d08d41d25bb5141f2465355a069982c..2fb43865b1a7a2d679d52070498a98a115ecddf4 100644 --- a/services/endpoint/endpoint.tester.js +++ b/services/endpoint/endpoint.tester.js @@ -11,7 +11,7 @@ t.create('Valid schema') schemaVersion: 1, label: '', message: 'yo', - }) + }), ) .expectBadge({ label: '', message: 'yo' }) @@ -24,7 +24,7 @@ t.create('color and labelColor') message: 'yo', color: '#f0dcc3', labelColor: '#e6e6fa', - }) + }), ) .expectBadge({ label: 'hey', @@ -41,7 +41,7 @@ t.create('style') label: 'hey', message: 'yo', color: '#99c', - }) + }), ) .expectBadge({ label: 'hey', @@ -59,7 +59,7 @@ t.create('named logo') label: 'hey', message: 'yo', namedLogo: 'npm', - }) + }), ) .after((err, res, body) => { expect(err).not.to.be.ok @@ -75,7 +75,7 @@ t.create('named logo with color') message: 'yo', namedLogo: 'github', logoColor: 'blue', - }) + }), ) .after((err, res, body) => { expect(err).not.to.be.ok @@ -84,7 +84,7 @@ t.create('named logo with color') const logoSvg = Buffer.from( getShieldsIcon({ name: 'npm' }).replace('data:image/svg+xml;base64,', ''), - 'base64' + 'base64', ).toString('ascii') t.create('custom svg logo') @@ -95,7 +95,7 @@ t.create('custom svg logo') label: 'hey', message: 'yo', logoSvg, - }) + }), ) .after((err, res, body) => { expect(err).not.to.be.ok @@ -111,7 +111,7 @@ t.create('logoWidth') message: 'yo', logoSvg, logoWidth: 30, - }) + }), ) .expectBadge({ label: 'hey', @@ -124,7 +124,7 @@ t.create('Invalid schema') .intercept(nock => nock('https://example.com/').get('/badge').reply(200, { schemaVersion: -1, - }) + }), ) .expectBadge({ label: 'custom badge', @@ -140,7 +140,7 @@ t.create('Invalid schema') message: 'yo', extra: 'keys', bogus: true, - }) + }), ) .expectBadge({ label: 'custom badge', @@ -155,7 +155,7 @@ t.create('User color overrides success color') label: '', message: 'yo', color: 'blue', - }) + }), ) .expectBadge({ label: '', message: 'yo', color: '#101010' }) @@ -167,7 +167,7 @@ t.create('User legacy color overrides success color') label: '', message: 'yo', color: 'blue', - }) + }), ) .expectBadge({ label: '', message: 'yo', color: '#101010' }) @@ -180,7 +180,7 @@ t.create('User color does not override error color') label: 'something is', message: 'not right', color: 'red', - }) + }), ) .expectBadge({ label: 'something is', message: 'not right', color: 'red' }) @@ -193,7 +193,7 @@ t.create('User legacy color does not override error color') label: 'something is', message: 'not right', color: 'red', - }) + }), ) .expectBadge({ label: 'something is', message: 'not right', color: 'red' }) @@ -205,7 +205,7 @@ t.create('cacheSeconds') label: '', message: 'yo', cacheSeconds: 500, - }) + }), ) .expectHeader('cache-control', 'max-age=500, s-maxage=500') @@ -217,7 +217,7 @@ t.create('user can override service cacheSeconds') label: '', message: 'yo', cacheSeconds: 500, - }) + }), ) .expectHeader('cache-control', 'max-age=1000, s-maxage=1000') @@ -229,7 +229,7 @@ t.create('user does not override longer service cacheSeconds') label: '', message: 'yo', cacheSeconds: 500, - }) + }), ) .expectHeader('cache-control', 'max-age=500, s-maxage=500') @@ -241,7 +241,7 @@ t.create('cacheSeconds does not override longer Shields default') label: '', message: 'yo', cacheSeconds: 10, - }) + }), ) .expectHeader('cache-control', 'max-age=300, s-maxage=300') @@ -275,9 +275,9 @@ t.create('gzipped endpoint') .reply( 200, zlib.gzipSync( - JSON.stringify({ schemaVersion: 1, label: '', message: 'yo' }) + JSON.stringify({ schemaVersion: 1, label: '', message: 'yo' }), ), - { 'Content-Encoding': 'gzip' } - ) + { 'Content-Encoding': 'gzip' }, + ), ) .expectBadge({ label: '', message: 'yo' }) diff --git a/services/f-droid/f-droid.service.js b/services/f-droid/f-droid.service.js index 33de6915336927cd9348921b962471d1c2fe30d0..66af156f093a3a1656e406c1ac0cccb2bcef9afe 100644 --- a/services/f-droid/f-droid.service.js +++ b/services/f-droid/f-droid.service.js @@ -63,13 +63,13 @@ export default class FDroid extends BaseJsonService { transform({ json, suggested }) { const svc = suggested && json.suggestedVersionCode const packages = (json.packages || []).filter( - ({ versionCode }) => !svc || versionCode <= svc + ({ versionCode }) => !svc || versionCode <= svc, ) if (packages.length === 0) { throw new NotFound({ prettyMessage: 'no packages found' }) } const version = packages.reduce((a, b) => - a.versionCode > b.versionCode ? a : b + a.versionCode > b.versionCode ? a : b, ).versionName return { version } } diff --git a/services/f-droid/f-droid.tester.js b/services/f-droid/f-droid.tester.js index ea63f06ee635d306499dcd3db9a1c423b4d4c077..5dde646939987a11790877c48ffb41753d56e9a1 100644 --- a/services/f-droid/f-droid.tester.js +++ b/services/f-droid/f-droid.tester.js @@ -55,14 +55,14 @@ t.create('Package is not found with no packages available (empty array)"') .intercept(nock => nock(base) .get(path) - .reply(200, `{"packageName":"${testPkg}","packages":[]}`) + .reply(200, `{"packageName":"${testPkg}","packages":[]}`), ) .expectBadge({ label: 'f-droid', message: 'no packages found' }) t.create('Package is not found with no packages available (missing array)"') .get(`/v/${testPkg}.json`) .intercept(nock => - nock(base).get(path).reply(200, `{"packageName":"${testPkg}"}`) + nock(base).get(path).reply(200, `{"packageName":"${testPkg}"}`), ) .expectBadge({ label: 'f-droid', message: 'no packages found' }) diff --git a/services/factorio-mod-portal/factorio-mod-portal.service.js b/services/factorio-mod-portal/factorio-mod-portal.service.js index c43bac015e0cba9500bb3927d3f2e3689132aaf0..4000f78c565907f720c4bfcf843ce2f9b023cedd 100644 --- a/services/factorio-mod-portal/factorio-mod-portal.service.js +++ b/services/factorio-mod-portal/factorio-mod-portal.service.js @@ -16,7 +16,7 @@ const schema = Joi.object({ info_json: Joi.object({ factorio_version: Joi.string().required(), }).required(), - }) + }), ) .min(1) .required(), diff --git a/services/fedora/fedora.service.js b/services/fedora/fedora.service.js index 10c7ee0163caceed7ce345440e2d3450bdd54f02..be6d424a159325610b8d8fd9a63b86cd8862f9d9 100644 --- a/services/fedora/fedora.service.js +++ b/services/fedora/fedora.service.js @@ -28,7 +28,7 @@ export default class Fedora extends BaseJsonService { const data = await this._requestJson({ schema, url: `https://apps.fedoraproject.org/mdapi/${encodeURIComponent( - branch + branch, )}/pkg/${encodeURIComponent(packageName)}`, httpErrors: { 400: 'branch not found', diff --git a/services/feedz/feedz.service.js b/services/feedz/feedz.service.js index 8bd2309194c9cd4eeb893dee39795d35229d73da..aea4d3e69775de9ed3f1d1fb3ec31eb24190ec0b 100644 --- a/services/feedz/feedz.service.js +++ b/services/feedz/feedz.service.js @@ -15,7 +15,7 @@ const singlePageSchema = Joi.object({ catalogEntry: Joi.object({ version: Joi.string().required(), }).required(), - }) + }), ) .default([]), }).required() @@ -70,7 +70,7 @@ class FeedzVersionService extends BaseJsonService { async fetch({ baseUrl, packageName }) { const registrationsBaseUrl = await searchServiceUrl( baseUrl, - 'RegistrationsBaseUrl' + 'RegistrationsBaseUrl', ) return await this._requestJson({ schema: packageSchema, @@ -93,8 +93,8 @@ class FeedzVersionService extends BaseJsonService { httpErrors: { 404: 'repository or package not found', }, - }) - ) + }), + ), ) return { items } } @@ -102,7 +102,7 @@ class FeedzVersionService extends BaseJsonService { transform({ json, includePrereleases }) { const versions = json.items.flatMap(tl => - tl.items.map(i => stripBuildMetadata(i.catalogEntry.version)) + tl.items.map(i => stripBuildMetadata(i.catalogEntry.version)), ) if (versions.length >= 1) { return selectVersion(versions, includePrereleases) diff --git a/services/feedz/feedz.service.spec.js b/services/feedz/feedz.service.spec.js index c6f1444c39f8cdafd5e16ad466f16d7903e6eeeb..68f7f04df866d586041d104e43e1d7fefdfae76d 100644 --- a/services/feedz/feedz.service.spec.js +++ b/services/feedz/feedz.service.spec.js @@ -22,13 +22,13 @@ function noItemsJson() { describe('Feedz service', function () { test(FeedzVersionService.prototype.apiUrl, () => { given({ organization: 'shieldstests', repository: 'public' }).expect( - 'https://f.feedz.io/shieldstests/public/nuget' + 'https://f.feedz.io/shieldstests/public/nuget', ) }) test(FeedzVersionService.prototype.transform, () => { given({ json: json([['1.0.0']]), includePrereleases: false }).expect( - '1.0.0' + '1.0.0', ) given({ json: json([['1.0.0', '1.0.1']]), @@ -48,10 +48,10 @@ describe('Feedz service', function () { includePrereleases: false, }).expect('1.0.1') given({ json: json([['1.0.1'], []]), includePrereleases: false }).expect( - '1.0.1' + '1.0.1', ) given({ json: json([[], ['1.0.1']]), includePrereleases: false }).expect( - '1.0.1' + '1.0.1', ) given({ json: json([['1.0.0'], ['1.0.1-beta1']]), @@ -72,25 +72,25 @@ describe('Feedz service', function () { }).expect('1.0.1-beta1') given({ json: json([]), includePrereleases: false }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: json([[]]), includePrereleases: false }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: json([[], []]), includePrereleases: false }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: json([]), includePrereleases: true }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: json([[]]), includePrereleases: true }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: noItemsJson(), includePrereleases: false }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: noItemsJson(), includePrereleases: true }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) }) }) diff --git a/services/flathub/flathub-downloads.service.js b/services/flathub/flathub-downloads.service.js index 6f62bdd8217ea3de4f3358a8b74076273ce27e5e..5ba4ed278df1d596d0e954033101f48093df4194 100644 --- a/services/flathub/flathub-downloads.service.js +++ b/services/flathub/flathub-downloads.service.js @@ -25,7 +25,7 @@ export default class FlathubDownloads extends BaseJsonService { const data = await this._requestJson({ schema, url: `https://flathub.org/api/v2/stats/${encodeURIComponent( - packageName + packageName, )}`, }) return renderDownloadsBadge({ downloads: data.installs_total }) diff --git a/services/flathub/flathub.service.js b/services/flathub/flathub.service.js index c161aa147689632764ea68c53bdaa389ba611adf..69bf99429a2ef403aa791cfebe0cac4bbcf681f0 100644 --- a/services/flathub/flathub.service.js +++ b/services/flathub/flathub.service.js @@ -7,7 +7,7 @@ const schema = Joi.alternatives() Joi.object({ currentReleaseVersion: Joi.string().required(), }).required(), - Joi.valid(null).required() + Joi.valid(null).required(), ) .required() diff --git a/services/flathub/flathub.tester.js b/services/flathub/flathub.tester.js index 727497013dea64cc9d9c573c4e15d6f7dbaf4bca..def023284d8c5c70b3c54539110ad8e260174245 100644 --- a/services/flathub/flathub.tester.js +++ b/services/flathub/flathub.tester.js @@ -15,7 +15,7 @@ t.create('Flathub (valid)') .reply(200, { flatpakAppId: 'org.mozilla.firefox', currentReleaseVersion: '78.0.1', - }) + }), ) .expectBadge({ label: 'flathub', message: 'v78.0.1' }) diff --git a/services/galaxytoolshed/galaxytoolshed-base.js b/services/galaxytoolshed/galaxytoolshed-base.js index 964e2b17c4d0ad7a6b8d11027c78263b275dfe97..145f98b5d87d621d2b109278cf3de6bc1eb15964 100644 --- a/services/galaxytoolshed/galaxytoolshed-base.js +++ b/services/galaxytoolshed/galaxytoolshed-base.js @@ -11,7 +11,7 @@ const repositoryRevisionInstallInfoSchema = Joi.array() Joi.object({ create_time: Joi.date().required(), times_downloaded: nonNegativeInteger, - }).required() + }).required(), ) .items(Joi.any()) diff --git a/services/gem/gem-downloads.service.js b/services/gem/gem-downloads.service.js index 6944fe406beaba8c76a0a208a58f46a589ea44b6..7d5ddfb78d878ca4eeef088681b442583c498618 100644 --- a/services/gem/gem-downloads.service.js +++ b/services/gem/gem-downloads.service.js @@ -18,7 +18,7 @@ const versionSchema = Joi.array() prerelease: Joi.boolean().required(), number: Joi.string().required(), downloads_count: nonNegativeInteger, - }) + }), ) .min(1) .required() @@ -96,7 +96,9 @@ export default class GemDownloads extends BaseJsonService { let wantedVersion if (version === 'stable') { wantedVersion = latestVersion( - json.filter(({ prerelease }) => !prerelease).map(({ number }) => number) + json + .filter(({ prerelease }) => !prerelease) + .map(({ number }) => number), ) } else { wantedVersion = version diff --git a/services/gem/gem-rank.service.js b/services/gem/gem-rank.service.js index de46d4933649d5834652e5eea508d3bfef03c39e..18cc5633d8299c47d0793fdde2c3aaf7c3111575 100644 --- a/services/gem/gem-rank.service.js +++ b/services/gem/gem-rank.service.js @@ -9,7 +9,7 @@ const totalSchema = Joi.array() .items( Joi.object({ total_ranking: Joi.number().integer().min(0).allow(null), - }) + }), ) .min(1) .required() @@ -17,7 +17,7 @@ const dailySchema = Joi.array() .items( Joi.object({ daily_ranking: Joi.number().integer().min(0).allow(null), - }) + }), ) .min(1) .required() diff --git a/services/gem/gem-rank.tester.js b/services/gem/gem-rank.tester.js index 778564c257e97f7678ad1f6f3865f931a082207a..ca70f15e6a79c8883fea71b0e596439825521c2c 100644 --- a/services/gem/gem-rank.tester.js +++ b/services/gem/gem-rank.tester.js @@ -26,6 +26,6 @@ t.create('rank is null') date: '2019-01-06', daily_ranking: null, }, - ]) + ]), ) .expectBadge({ label: 'rank', message: 'invalid rank' }) diff --git a/services/gem/gem-version.service.js b/services/gem/gem-version.service.js index 358146f66bbca0934995437ca1302283a33c6427..c5753cb3b71d65a6dab6079befa9354038c3c307 100644 --- a/services/gem/gem-version.service.js +++ b/services/gem/gem-version.service.js @@ -13,7 +13,7 @@ const versionSchema = Joi.array() .items( Joi.object({ number: Joi.string().required(), - }) + }), ) .min(1) .required() diff --git a/services/gem/gem-version.tester.js b/services/gem/gem-version.tester.js index 0043e2ff9be924dc82186046837dabdf158c2bb8..fbc75abcb312927f69fdea0bb3b60f95124bc781 100644 --- a/services/gem/gem-version.tester.js +++ b/services/gem/gem-version.tester.js @@ -17,7 +17,7 @@ t.create('version (not found)') // this is the same as isVPlusDottedVersionNClausesWithOptionalSuffix from test-validators.js // except that it also accepts regexes like 5.0.0.rc5 - the . before the rc5 is not accepted in the original const isVPlusDottedVersionNClausesWithOptionalSuffix = withRegex( - /^v\d+(\.\d+)*([-+~.].*)?$/ + /^v\d+(\.\d+)*([-+~.].*)?$/, ) t.create('version including prereleases (valid)') .get('/flame.json?include_prereleases') diff --git a/services/github/auth/acceptor.js b/services/github/auth/acceptor.js index 643c07a600653fc651c20ac9ab223cb0a22ded3e..7b258a67265a165611b8443071a514f2adffb8ec 100644 --- a/services/github/auth/acceptor.js +++ b/services/github/auth/acceptor.js @@ -17,7 +17,7 @@ function setRoutes({ server, authHelper, onTokenAccepted }) { }) ask.res.setHeader( 'Location', - `https://github.com/login/oauth/authorize?${query}` + `https://github.com/login/oauth/authorize?${query}`, ) end('') }) @@ -73,7 +73,7 @@ function setRoutes({ server, authHelper, onTokenAccepted }) { 'therefore more robust.</p>' + '<p>Thanks for contributing to a smoother experience for ' + 'everyone!</p>' + - '<p><a href="/">Back to the website</a></p>' + '<p><a href="/">Back to the website</a></p>', ) onTokenAccepted(token) diff --git a/services/github/auth/acceptor.spec.js b/services/github/auth/acceptor.spec.js index 1d9690c1f862e35fbdc2bb7352291e8dd8c9e73d..e9d11895a52870ec43a7492a4afe1308f12e7858 100644 --- a/services/github/auth/acceptor.spec.js +++ b/services/github/auth/acceptor.spec.js @@ -63,7 +63,7 @@ describe('Github token acceptor', function () { it('should return an error', async function () { const res = await got(`${baseUrl}/github-auth/done`) expect(res.body).to.equal( - 'GitHub OAuth authentication failed to provide a code.' + 'GitHub OAuth authentication failed to provide a code.', ) }) }) @@ -115,7 +115,7 @@ describe('Github token acceptor', function () { body: form, }) expect(res.body).to.startWith( - '<p>Shields.io has received your app-specific GitHub user token.' + '<p>Shields.io has received your app-specific GitHub user token.', ) expect(onTokenAccepted).to.have.been.calledWith(fakeAccessToken) diff --git a/services/github/gist/github-gist-last-commit-redirect.tester.js b/services/github/gist/github-gist-last-commit-redirect.tester.js index a200cf0e8ac4e02410b77b63e9cfd40c6da4b506..1b8ea1722be44306a407924e6ed6934bef6980b5 100644 --- a/services/github/gist/github-gist-last-commit-redirect.tester.js +++ b/services/github/gist/github-gist-last-commit-redirect.tester.js @@ -13,5 +13,5 @@ t.create('Last Commit redirect') .expectStatus(301) .expectHeader( 'Location', - '/github/gist/last-commit/a8b8c979d200ffde13cc08505f7a6436.svg' + '/github/gist/last-commit/a8b8c979d200ffde13cc08505f7a6436.svg', ) diff --git a/services/github/gist/github-gist-stars-redirect.tester.js b/services/github/gist/github-gist-stars-redirect.tester.js index 8317855a6adf8151e12d7d6970a8df23b2fd3d33..88394a47ae229255a9fe949185527092aaf8416d 100644 --- a/services/github/gist/github-gist-stars-redirect.tester.js +++ b/services/github/gist/github-gist-stars-redirect.tester.js @@ -12,5 +12,5 @@ t.create('Stars redirect') .expectStatus(301) .expectHeader( 'Location', - '/github/gist/stars/a8b8c979d200ffde13cc08505f7a6436.svg' + '/github/gist/stars/a8b8c979d200ffde13cc08505f7a6436.svg', ) diff --git a/services/github/github-api-provider.integration.js b/services/github/github-api-provider.integration.js index 9c3435ce5da9a252391ae7b3d5bc36d4cd0002af..4e5832c90ef069a4ad1edc8779f78b407bd7c589 100644 --- a/services/github/github-api-provider.integration.js +++ b/services/github/github-api-provider.integration.js @@ -51,7 +51,7 @@ describe('Github API provider', function () { const { res } = await githubApiProvider.fetch( fetch, '/repos/rust-lang/rust', - {} + {}, ) expect(res.statusCode).to.equal(200) headers.push(res.headers) @@ -69,7 +69,7 @@ describe('Github API provider', function () { const current = headers[i] const previous = headers[i - 1] expect(+current['x-ratelimit-remaining']).to.be.lessThan( - +previous['x-ratelimit-remaining'] + +previous['x-ratelimit-remaining'], ) } }) diff --git a/services/github/github-api-provider.js b/services/github/github-api-provider.js index 0c28521d8548ec149465f134a362bc66faf43b02..a37513761b1a96887cd7f4afbeb549371118b3f9 100644 --- a/services/github/github-api-provider.js +++ b/services/github/github-api-provider.js @@ -104,7 +104,7 @@ class GithubApiProvider { this.getV4RateLimitFromBody(parsedBody)) } catch (e) { console.error( - `Could not extract rate limit info from response body ${res.body}` + `Could not extract rate limit info from response body ${res.body}`, ) log.error(e) return @@ -123,8 +123,8 @@ class GithubApiProvider { `Invalid GitHub rate limit headers ${JSON.stringify( logHeaders, undefined, - 2 - )}` + 2, + )}`, ) log.error(e) return diff --git a/services/github/github-api-provider.spec.js b/services/github/github-api-provider.spec.js index 6e9542b7f62da39aa39b93a914236686034364e5..ae9b9fdaff06b495825f33256bc54023171ea824 100644 --- a/services/github/github-api-provider.spec.js +++ b/services/github/github-api-provider.spec.js @@ -81,7 +81,7 @@ describe('Github API provider', function () { remaining - Math.ceil(reserveFraction * rateLimit) expect(mockStandardToken.update).to.have.been.calledWith( expectedUsesRemaining, - nextReset + nextReset, ) expect(mockStandardToken.invalidate).not.to.have.been.called }) @@ -120,7 +120,7 @@ describe('Github API provider', function () { remaining - Math.ceil(reserveFraction * rateLimit) expect(mockGraphqlToken.update).to.have.been.calledWith( expectedUsesRemaining, - nextReset + nextReset, ) expect(mockGraphqlToken.invalidate).not.to.have.been.called }) @@ -164,7 +164,7 @@ describe('Github API provider', function () { const mockRequest = sinon.stub().rejects(requestError) return expect(provider.fetch(mockRequest, '/foo', {})).to.be.rejectedWith( Error, - 'connection timeout' + 'connection timeout', ) }) }) diff --git a/services/github/github-auth-service.js b/services/github/github-auth-service.js index 3fd0fd269c7835dcbbddebf673f97fe8d27299ec..b26bec191cb6726f82c4f13f777df6f9888886e2 100644 --- a/services/github/github-auth-service.js +++ b/services/github/github-auth-service.js @@ -60,7 +60,7 @@ class GithubAuthV4Service extends BaseGraphqlService { resetAt } } - ` + `, ) return super._requestGraphql({ ...attrs, ...{ url, query } }) diff --git a/services/github/github-auth-service.spec.js b/services/github/github-auth-service.spec.js index 0e931bd4bbc68bcffec8e0f26bf76beb6e49e3ac..378d5034f6cf6e3d41827d4066c1e81ae5804c56 100644 --- a/services/github/github-auth-service.spec.js +++ b/services/github/github-auth-service.spec.js @@ -37,7 +37,7 @@ describe('GithubAuthV3Service', function () { 'x-ratelimit-reset': 123456789, }, }, - }) + }), ) const githubApiProvider = new GithubApiProvider({ baseUrl: 'https://github-api.example.com', @@ -60,7 +60,7 @@ describe('GithubAuthV3Service', function () { Authorization: 'token undefined', 'X-GitHub-Api-Version': '2022-11-28', }, - } + }, ) }) }) diff --git a/services/github/github-commit-activity.spec.js b/services/github/github-commit-activity.spec.js index 1815bf2dd90c1146025c4573abcee0f7de9b0de8..8096b841964379d3b4685c15f9bf611450be0ee5 100644 --- a/services/github/github-commit-activity.spec.js +++ b/services/github/github-commit-activity.spec.js @@ -9,7 +9,7 @@ describe('GitHubCommitActivity', function () { expect(() => GitHubCommitActivity.transform({ data: { repository: { object: null } }, - }) + }), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'invalid branch') @@ -30,7 +30,7 @@ describe('GitHubCommitActivity', function () { expect( GitHubCommitActivity.getIntervalQueryStartDate({ interval: 'y', - }) + }), ).to.equal('2020-08-28T02:21:34.000Z') }) @@ -39,7 +39,7 @@ describe('GitHubCommitActivity', function () { expect( GitHubCommitActivity.getIntervalQueryStartDate({ interval: 'm', - }) + }), ).to.equal('2021-03-01T02:21:34.000Z') }) @@ -48,7 +48,7 @@ describe('GitHubCommitActivity', function () { expect( GitHubCommitActivity.getIntervalQueryStartDate({ interval: '4w', - }) + }), ).to.equal('2021-02-05T02:21:34.000Z') }) @@ -57,7 +57,7 @@ describe('GitHubCommitActivity', function () { expect( GitHubCommitActivity.getIntervalQueryStartDate({ interval: 'w', - }) + }), ).to.equal('2021-12-24T23:59:34.000Z') }) }) diff --git a/services/github/github-commit-activity.tester.js b/services/github/github-commit-activity.tester.js index b1e95470b8f14b8635ae28fedc832f19a2eb05fb..1dc5af49239bb889b8c95a58a4b4bda1ce7a11e5 100644 --- a/services/github/github-commit-activity.tester.js +++ b/services/github/github-commit-activity.tester.js @@ -9,7 +9,7 @@ export const t = await createServiceTester() const isCommitActivity = Joi.alternatives().try( isMetricOverTimePeriod, - isZeroOverTimePeriod + isZeroOverTimePeriod, ) const authorFilterUser = 'jnullj' diff --git a/services/github/github-commit-status.tester.js b/services/github/github-commit-status.tester.js index 5e6f9f9fdc19d5c40a5390691675828b36cfcf96..c7718c75382c86b0acc621b8b39498dbbe50e59a 100644 --- a/services/github/github-commit-status.tester.js +++ b/services/github/github-commit-status.tester.js @@ -11,15 +11,15 @@ t.create('commit status - commit in branch') }) t.create( - 'commit status - checked commit is identical with the newest commit in branch' + 'commit status - checked commit is identical with the newest commit in branch', ) .get('/badges/shields/master/5d4ab86b1b5ddfb3c4a70a70bd19932c52603b8c.json') .intercept(nock => nock('https://api.github.com') .get( - '/repos/badges/shields/compare/master...5d4ab86b1b5ddfb3c4a70a70bd19932c52603b8c' + '/repos/badges/shields/compare/master...5d4ab86b1b5ddfb3c4a70a70bd19932c52603b8c', ) - .reply(200, { status: 'identical' }) + .reply(200, { status: 'identical' }), ) .expectBadge({ label: 'commit status', @@ -45,7 +45,7 @@ t.create('commit status - unknown commit id') t.create('commit status - unknown branch') .get( - '/badges/shields/this-branch-does-not-exist/b551a3a8daf1c48dba32a3eab1edf99b10c28863.json' + '/badges/shields/this-branch-does-not-exist/b551a3a8daf1c48dba32a3eab1edf99b10c28863.json', ) .expectBadge({ label: 'commit status', @@ -68,9 +68,9 @@ t.create('commit status - 404 with invalid JSON form github') .intercept(nock => nock('https://api.github.com') .get( - '/repos/badges/shields/compare/master...5d4ab86b1b5ddfb3c4a70a70bd19932c52603b8c' + '/repos/badges/shields/compare/master...5d4ab86b1b5ddfb3c4a70a70bd19932c52603b8c', ) - .reply(404, invalidJSONString) + .reply(404, invalidJSONString), ) .expectBadge({ label: 'commit status', diff --git a/services/github/github-commits-since.service.js b/services/github/github-commits-since.service.js index 8ea3300253bc1bf9e8089c4b48828bce97fd8682..f74b6140a30e2b638e52bf181c7bcdabe93aee9f 100644 --- a/services/github/github-commits-since.service.js +++ b/services/github/github-commits-since.service.js @@ -141,7 +141,7 @@ export default class GithubCommitsSince extends GithubAuthV3Service { user, repo, }, - queryParams + queryParams, )) } diff --git a/services/github/github-commits-since.tester.js b/services/github/github-commits-since.tester.js index a16a093d9cebbe48703e0d28164f022ca0ff86fa..35d325cdeb244accec1ea509c1aa0d3a5ebad5e4 100644 --- a/services/github/github-commits-since.tester.js +++ b/services/github/github-commits-since.tester.js @@ -14,7 +14,7 @@ t.create('Commits since') t.create('Commits since (branch)') .get( - '/badges/shields/8b87fac3a1538ec20ff20983faf4b6f7e722ef87/historical.json' + '/badges/shields/8b87fac3a1538ec20ff20983faf4b6f7e722ef87/historical.json', ) .expectBadge({ label: isCommitsSince, @@ -58,7 +58,7 @@ t.create('Commits since (version not found)') t.create('Commits since (branch not found)') .get( - '/badges/shields/a0663d8da53fb712472c02665e6ff7547ba945b7/not-a-branch.json' + '/badges/shields/a0663d8da53fb712472c02665e6ff7547ba945b7/not-a-branch.json', ) .expectBadge({ label: 'github', diff --git a/services/github/github-common-fetch.js b/services/github/github-common-fetch.js index 40784b4694f7a0a73df4e62096f9b796793b68db..9c1611a7eefa58a5963e6f894260be8b0f0c35fc 100644 --- a/services/github/github-common-fetch.js +++ b/services/github/github-common-fetch.js @@ -24,10 +24,10 @@ const contentSchema = Joi.object({ async function fetchRepoContent( serviceInstance, - { user, repo, branch = 'HEAD', filename } + { user, repo, branch = 'HEAD', filename }, ) { const httpErrors = httpErrorsFor( - `repo not found, branch not found, or ${filename} missing` + `repo not found, branch not found, or ${filename} missing`, ) if (serviceInstance.staticAuthConfigured) { const { content } = await serviceInstance._requestJson({ @@ -53,7 +53,7 @@ async function fetchRepoContent( async function fetchJsonFromRepo( serviceInstance, - { schema, user, repo, branch = 'HEAD', filename } + { schema, user, repo, branch = 'HEAD', filename }, ) { if (serviceInstance.staticAuthConfigured) { const buffer = await fetchRepoContent(serviceInstance, { @@ -69,7 +69,7 @@ async function fetchJsonFromRepo( schema, url: `https://raw.githubusercontent.com/${user}/${repo}/${branch}/${filename}`, httpErrors: httpErrorsFor( - `repo not found, branch not found, or ${filename} missing` + `repo not found, branch not found, or ${filename} missing`, ), }) } diff --git a/services/github/github-common-release.js b/services/github/github-common-release.js index 7a77bb68989ca735eff7b6b4867da540252c9569..4a5ded129c4c2f8da2e4729c6338908a98e017a9 100644 --- a/services/github/github-common-release.js +++ b/services/github/github-common-release.js @@ -32,7 +32,7 @@ async function fetchLatestGitHubRelease(serviceInstance, { user, repo }) { const releaseInfoArraySchema = Joi.alternatives().try( Joi.array().items(releaseInfoSchema), - Joi.array().length(0) + Joi.array().length(0), ) async function fetchReleases(serviceInstance, { user, repo }) { @@ -51,7 +51,7 @@ function getLatestRelease({ releases, sort, includePrereleases }) { if (sort === 'semver') { const latestTagName = latest( releases.map(release => release.tag_name), - { pre: includePrereleases } + { pre: includePrereleases }, ) return releases.find(({ tag_name: tagName }) => tagName === latestTagName) } @@ -89,15 +89,15 @@ function applyFilter({ releases, filter, displayName }) { if (displayName === 'tag') { const filteredTagNames = matcher( releases.map(release => release.tag_name), - filter + filter, ) return releases.filter(release => - filteredTagNames.includes(release.tag_name) + filteredTagNames.includes(release.tag_name), ) } const filteredReleaseNames = matcher( releases.map(release => release.name), - filter + filter, ) return releases.filter(release => filteredReleaseNames.includes(release.name)) } @@ -106,7 +106,7 @@ function applyFilter({ releases, filter, displayName }) { async function fetchLatestRelease( serviceInstance, { user, repo }, - queryParams + queryParams, ) { const sort = queryParams.sort const includePrereleases = queryParams.include_prereleases !== undefined diff --git a/services/github/github-constellation.js b/services/github/github-constellation.js index 9e7b1a4a44926349333ab357df5f0d6b420e4652..75754b6c2bcd07b92dcde19864e60a7ecce418a2 100644 --- a/services/github/github-constellation.js +++ b/services/github/github-constellation.js @@ -15,7 +15,7 @@ class GithubConstellation { authorizedOrigins: ['https://api.github.com'], isRequired: true, }, - config + config, ) } diff --git a/services/github/github-deployments.service.js b/services/github/github-deployments.service.js index 08bda95c8cdfcc90fa89c44b08a000c6c330405f..29ba2e4384d32052be28afa6cc5c05d4477f280a 100644 --- a/services/github/github-deployments.service.js +++ b/services/github/github-deployments.service.js @@ -34,7 +34,7 @@ const schema = Joi.object({ }), null, ]), - }) + }), ) .required(), }).required(), diff --git a/services/github/github-deployments.tester.js b/services/github/github-deployments.tester.js index 325ae34faad9bafcb06f2e6ebee3cde86c16afca..18fca305c9db845a622721454ea74630565e2d6a 100644 --- a/services/github/github-deployments.tester.js +++ b/services/github/github-deployments.tester.js @@ -37,7 +37,7 @@ t.create('Deployments (status not yet available)') data: { repository: { deployments: { nodes: [{ latestStatus: null }] } }, }, - }) + }), ) .expectBadge({ label: 'state', diff --git a/services/github/github-directory-file-count.service.js b/services/github/github-directory-file-count.service.js index 47da024c661de9b747978820b525f96b8a76172d..73733732da539fe2e7fae4d8e23b3d27258853da 100644 --- a/services/github/github-directory-file-count.service.js +++ b/services/github/github-directory-file-count.service.js @@ -30,7 +30,7 @@ const schema = Joi.object({ Joi.object({ type: Joi.string().required(), extension: Joi.string().allow('').required(), - }) + }), ), }) .allow(null) diff --git a/services/github/github-directory-file-count.spec.js b/services/github/github-directory-file-count.spec.js index cfb3cb6eeefe73cfcd05af30170cf6414d2cb734..112ceff6e0574e980d66d149ae51f527c5b83399 100644 --- a/services/github/github-directory-file-count.spec.js +++ b/services/github/github-directory-file-count.spec.js @@ -43,23 +43,23 @@ describe('GithubDirectoryFileCount', function () { GithubDirectoryFileCount.transform(contents, { type: 'dir', extension: 'js', - }) + }), ) .to.throw(InvalidParameter) .with.property( 'prettyMessage', - 'extension is applicable for type file only' + 'extension is applicable for type file only', ) }) it('throws InvalidParameter on receving no type and extension', function () { expect(() => - GithubDirectoryFileCount.transform(contents, { extension: 'js' }) + GithubDirectoryFileCount.transform(contents, { extension: 'js' }), ) .to.throw(InvalidParameter) .with.property( 'prettyMessage', - 'extension is applicable for type file only' + 'extension is applicable for type file only', ) }) }) diff --git a/services/github/github-discussions-custom-search.tester.js b/services/github/github-discussions-custom-search.tester.js index c48b7fe4c019699e8f1d043d5dfa8df1b9c0a7af..213b69e4990b3375baaa826684304e56fecfc9fc 100644 --- a/services/github/github-discussions-custom-search.tester.js +++ b/services/github/github-discussions-custom-search.tester.js @@ -8,7 +8,7 @@ export const t = new ServiceTester({ t.create('GitHub discussions search (valid query string)') .get( - '/discussions-search.json?query=repo%3Abadges%2Fshields%20is%3Aanswered%20author%3Achris48s' + '/discussions-search.json?query=repo%3Abadges%2Fshields%20is%3Aanswered%20author%3Achris48s', ) .expectBadge({ label: 'query', @@ -24,7 +24,7 @@ t.create('GitHub discussions search (invalid query string)') t.create('GitHub Repo discussions search (valid query string)') .get( - '/discussions-search/badges/shields.json?query=is%3Aanswered%20author%3Achris48s' + '/discussions-search/badges/shields.json?query=is%3Aanswered%20author%3Achris48s', ) .expectBadge({ label: 'query', @@ -40,7 +40,7 @@ t.create('GitHub Repo discussions search (invalid query string)') t.create('GitHub Repo discussions search (invalid repo)') .get( - '/discussions-search/badges/helmets.json?query=is%3Aanswered%20author%3Achris48s' + '/discussions-search/badges/helmets.json?query=is%3Aanswered%20author%3Achris48s', ) .expectBadge({ label: 'query', diff --git a/services/github/github-downloads.service.js b/services/github/github-downloads.service.js index afe597b50b3c2012bc7dd1bd04852393cf50d88d..346f55298a9944ea613613327f8a9506027e21d7 100644 --- a/services/github/github-downloads.service.js +++ b/services/github/github-downloads.service.js @@ -21,7 +21,7 @@ const releaseSchema = Joi.object({ const releaseArraySchema = Joi.alternatives().try( Joi.array().items(releaseSchema), - Joi.array().length(0) + Joi.array().length(0), ) export default class GithubDownloads extends GithubAuthV3Service { @@ -206,13 +206,13 @@ export default class GithubDownloads extends GithubAuthV3Service { assetName === 'total' ? assets : assets.filter( - ({ name }) => name.toLowerCase() === assetName.toLowerCase() + ({ name }) => name.toLowerCase() === assetName.toLowerCase(), ) return ( accum1 + filteredAssets.reduce( (accum2, { download_count: downloads }) => accum2 + downloads, - 0 + 0, ) ) }, 0) @@ -226,7 +226,7 @@ export default class GithubDownloads extends GithubAuthV3Service { const latestRelease = await fetchLatestRelease( this, { user, repo }, - { sort, include_prereleases: includePre } + { sort, include_prereleases: includePre }, ) releases = [latestRelease] } else if (tag) { diff --git a/services/github/github-downloads.tester.js b/services/github/github-downloads.tester.js index e002516906684d8114e2c34778b08bf4cf2f73d4..dfee08ad7aea5d6a0b71b98d61c9ba0c22ce5dab 100644 --- a/services/github/github-downloads.tester.js +++ b/services/github/github-downloads.tester.js @@ -47,7 +47,7 @@ t.create('downloads for latest release (sort by date)') ], tag_name: 'v3.15.1', prerelease: false, - }) + }), ) .expectBadge({ label: 'downloads@latest', message: '12' }) @@ -79,7 +79,7 @@ t.create('downloads for latest release (sort by SemVer)') tag_name: 'v3.15.1', prerelease: false, }, - ]) + ]), ) .expectBadge({ label: 'downloads@latest', message: '20' }) @@ -111,7 +111,7 @@ t.create('downloads for latest release (sort by date including pre-releases)') tag_name: 'v3.15.1', prerelease: false, }, - ]) + ]), ) .expectBadge({ label: 'downloads@latest', message: '4' }) @@ -143,7 +143,7 @@ t.create('downloads for latest release (sort by SemVer including pre-releases)') tag_name: 'v3.15.0', prerelease: false, }, - ]) + ]), ) .expectBadge({ label: 'downloads@latest', message: '4' }) @@ -165,7 +165,7 @@ t.create('downloads for specific asset without slash') .expectBadge({ label: 'downloads@v0.190.0', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) \[atom-amd64\.deb\]$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) \[atom-amd64\.deb\]$/, ), }) @@ -174,7 +174,7 @@ t.create('downloads for specific asset from latest release') .expectBadge({ label: 'downloads@latest', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) \[atom-amd64\.deb\]$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) \[atom-amd64\.deb\]$/, ), }) @@ -183,7 +183,7 @@ t.create('downloads-pre for specific asset from latest release') .expectBadge({ label: 'downloads@latest', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) \[atom-amd64\.deb\]$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) \[atom-amd64\.deb\]$/, ), }) @@ -196,7 +196,7 @@ t.create('downloads for specific asset with slash') .expectBadge({ label: 'downloads@stable/v2.2.8', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) \[dban-2\.2\.8_i586\.iso\]$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) \[dban-2\.2\.8_i586\.iso\]$/, ), }) diff --git a/services/github/github-hacktoberfest.service.js b/services/github/github-hacktoberfest.service.js index cb8139b69a19bc3cd27b805a34e264f78122d2cf..5be80dd2bc31839ebfe119861b9d660e15370008 100644 --- a/services/github/github-hacktoberfest.service.js +++ b/services/github/github-hacktoberfest.service.js @@ -104,7 +104,7 @@ export default class GithubHacktoberfestCombinedStatus extends GithubAuthV4Servi return { message: `${daysToStart} ${maybePluralize( 'day', - daysToStart + daysToStart, )} till kickoff!`, } } @@ -118,7 +118,7 @@ export default class GithubHacktoberfestCombinedStatus extends GithubAuthV4Servi return { message: `is over! (${metric(contributionCount)} ${maybePluralize( 'PR', - contributionCount + contributionCount, )} opened)`, } } @@ -127,13 +127,13 @@ export default class GithubHacktoberfestCombinedStatus extends GithubAuthV4Servi suggestedIssueCount ? `${metric(suggestedIssueCount)} ${maybePluralize( 'open issue', - suggestedIssueCount + suggestedIssueCount, )}` : '', contributionCount ? `${metric(contributionCount)} ${maybePluralize( 'PR', - contributionCount + contributionCount, )}` : '', daysLeft > 0 @@ -203,7 +203,7 @@ export default class GithubHacktoberfestCombinedStatus extends GithubAuthV4Servi async handle({ user, repo, year }, { suggestion_label: suggestionLabel }) { const { isBefore, daysToStart } = this.constructor.getCalendarPosition( - +year + +year, ) if (isBefore) { return this.constructor.render({ hasStarted: false, daysToStart, year }) diff --git a/services/github/github-hacktoberfest.tester.js b/services/github/github-hacktoberfest.tester.js index 5fb0212a9f7104fea611dbf7699b786f543c9160..6192fee41ceeb5bf4c6b61c5f70ad1890e439092 100644 --- a/services/github/github-hacktoberfest.tester.js +++ b/services/github/github-hacktoberfest.tester.js @@ -3,19 +3,19 @@ import { createServiceTester } from '../tester.js' export const t = await createServiceTester() const isHacktoberfestNoIssuesStatus = Joi.string().regex( - /^[0-9]+ PRs?(, [0-9]+ days? left)?$/ + /^[0-9]+ PRs?(, [0-9]+ days? left)?$/, ) const isHacktoberfestNoPRsStatus = Joi.string().regex( - /^([0-9]+ open issues?)?[0-9]+ days? left$/ + /^([0-9]+ open issues?)?[0-9]+ days? left$/, ) const isHacktoberfestCombinedStatus = Joi.string().regex( - /^[0-9]+ open issues?(, [0-9]+ PRs?)?(, [0-9]+ days? left)?$/ + /^[0-9]+ open issues?(, [0-9]+ PRs?)?(, [0-9]+ days? left)?$/, ) const isHacktoberfestStatus = Joi.alternatives().try( isHacktoberfestNoIssuesStatus, isHacktoberfestNoPRsStatus, isHacktoberfestCombinedStatus, - /^is over! \([0-9]+ PRs? opened\)$/ + /^is over! \([0-9]+ PRs? opened\)$/, ) t.create('GitHub Hacktoberfest combined status') @@ -28,8 +28,8 @@ t.create('GitHub Hacktoberfest combined status') t.create('GitHub Hacktoberfest combined status (suggestion label override)') .get( `/2019/badges/shields.json?suggestion_label=${encodeURIComponent( - 'good first issue' - )}` + 'good first issue', + )}`, ) .expectBadge({ label: 'hacktoberfest', diff --git a/services/github/github-issue-detail.service.js b/services/github/github-issue-detail.service.js index be8cce32be68d1d9dbaea897b83ad8a7a0d71256..c391c15bb86e32279414c3bd69c691ce5fdb8b40 100644 --- a/services/github/github-issue-detail.service.js +++ b/services/github/github-issue-detail.service.js @@ -86,7 +86,7 @@ const labelMap = { Joi.object({ name: Joi.string().required(), color: Joi.string().required(), - }) + }), ) .required(), }).required(), diff --git a/services/github/github-issue-detail.tester.js b/services/github/github-issue-detail.tester.js index 3fbdbf4c0c59859b318d7be74f8bfd299e16a2af..f22bd27b7611aaf5680f21eac9afc1899b6f0149 100644 --- a/services/github/github-issue-detail.tester.js +++ b/services/github/github-issue-detail.tester.js @@ -34,7 +34,7 @@ t.create('github issue label') label: 'label', message: Joi.equal( 'bug | developer-experience', - 'developer-experience | bug' + 'developer-experience | bug', ), }) diff --git a/services/github/github-issues-search.tester.js b/services/github/github-issues-search.tester.js index 57bd0c11a778b4f6ee1bbfde91d3efc7e3f2713e..d83acfdf7a55a59cd642ed4d46fe727c31bd7d1d 100644 --- a/services/github/github-issues-search.tester.js +++ b/services/github/github-issues-search.tester.js @@ -8,7 +8,7 @@ export const t = new ServiceTester({ t.create('GitHub issue search (valid query string)') .get( - '/issues-search.json?query=repo%3Abadges%2Fshields%20is%3Aclosed%20label%3Ablocker%20' + '/issues-search.json?query=repo%3Abadges%2Fshields%20is%3Aclosed%20label%3Ablocker%20', ) .expectBadge({ label: 'query', @@ -24,7 +24,7 @@ t.create('GitHub issue search (invalid query string)') t.create('GitHub Repo issue search (valid query string)') .get( - '/issues-search/badges/shields.json?query=is%3Aclosed%20label%3Ablocker%20' + '/issues-search/badges/shields.json?query=is%3Aclosed%20label%3Ablocker%20', ) .expectBadge({ label: 'query', @@ -40,7 +40,7 @@ t.create('GitHub Repo issue search (invalid query string)') t.create('GitHub Repo issue search (invalid repo)') .get( - '/issues-search/badges/helmets.json?query=is%3Aclosed%20label%3Ablocker%20' + '/issues-search/badges/helmets.json?query=is%3Aclosed%20label%3Ablocker%20', ) .expectBadge({ label: 'query', diff --git a/services/github/github-issues.tester.js b/services/github/github-issues.tester.js index f84a99f432ac596bb2983ef5503d43d1295cfc1d..fc39641dba15aea35e0965cebd27f0d2d414ee5c 100644 --- a/services/github/github-issues.tester.js +++ b/services/github/github-issues.tester.js @@ -8,7 +8,7 @@ t.create('GitHub closed pull requests') .expectBadge({ label: 'pull requests', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) closed$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) closed$/, ), }) @@ -38,7 +38,7 @@ t.create('GitHub closed issues') .expectBadge({ label: 'issues', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) closed$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) closed$/, ), }) diff --git a/services/github/github-last-commit.service.js b/services/github/github-last-commit.service.js index b5ea3b087c304345b406ad886a2502aab6d5252c..100a2c9fe3a0eecc2a4e481b3217df2b42a110ee 100644 --- a/services/github/github-last-commit.service.js +++ b/services/github/github-last-commit.service.js @@ -19,7 +19,7 @@ const schema = Joi.array() date: Joi.string().required(), }).required(), }).required(), - }).required() + }).required(), ) .required() .min(1) diff --git a/services/github/github-license.tester.js b/services/github/github-license.tester.js index 0cef52f4c75b8e9f4bf26d4254d6211f4a970052..cb36d7b3dbb5e885279f964ba6280f8c18d689b2 100644 --- a/services/github/github-license.tester.js +++ b/services/github/github-license.tester.js @@ -44,7 +44,7 @@ t.create('License with SPDX id not appearing in configuration') url: 'https://api.github.com/licenses/efl-1.0', featured: true, }, - }) + }), ) .expectBadge({ label: 'license', diff --git a/services/github/github-manifest.tester.js b/services/github/github-manifest.tester.js index a1e9849f9779e08a5c9a3dceb84dd89e239f9a79..2f162e0dc5934bf5b82b752f2e53ad1a24d1166b 100644 --- a/services/github/github-manifest.tester.js +++ b/services/github/github-manifest.tester.js @@ -24,7 +24,7 @@ t.create('Manifest version (path)') t.create('Manifest version (path not found)') .get( - '/v/RedSparr0w/IndieGala-Helper.json?filename=invalid-directory/manifest.json' + '/v/RedSparr0w/IndieGala-Helper.json?filename=invalid-directory/manifest.json', ) .expectBadge({ label: 'version', @@ -38,7 +38,7 @@ t.create('Manifest name (path)') t.create('Manifest array (path)') .get( - '/permissions/RedSparr0w/IndieGala-Helper.json?filename=extension/manifest.json' + '/permissions/RedSparr0w/IndieGala-Helper.json?filename=extension/manifest.json', ) .expectBadge({ label: 'permissions', @@ -47,7 +47,7 @@ t.create('Manifest array (path)') t.create('Manifest object (path)') .get( - '/background/RedSparr0w/IndieGala-Helper.json?filename=extension/manifest.json' + '/background/RedSparr0w/IndieGala-Helper.json?filename=extension/manifest.json', ) .expectBadge({ label: 'manifest', message: 'invalid key value' }) diff --git a/services/github/github-milestone-detail.service.js b/services/github/github-milestone-detail.service.js index 775a6e3278386d48b5de1b080c1f4282c832d41f..fe37ffb1f89fc41570a2c89c75352505879f8c3d 100644 --- a/services/github/github-milestone-detail.service.js +++ b/services/github/github-milestone-detail.service.js @@ -69,7 +69,7 @@ export default class GithubMilestoneDetail extends GithubAuthV3Service { milestoneMetric = `${Math.floor( (milestone.closed_issues / (milestone.open_issues + milestone.closed_issues)) * - 100 + 100, )}%` color = 'blue' } diff --git a/services/github/github-milestone.service.js b/services/github/github-milestone.service.js index 81f2b5961e78a6720f132ab3aa01b777342f4be1..973bb6649eae493016e2613900de3a646b8ba461 100644 --- a/services/github/github-milestone.service.js +++ b/services/github/github-milestone.service.js @@ -7,7 +7,7 @@ const schema = Joi.array() .items( Joi.object({ state: Joi.string().required(), - }) + }), ) .required() diff --git a/services/github/github-package-json.service.js b/services/github/github-package-json.service.js index d9ddbd28f743afc88d31a65f4f00a7661fa7a2fe..b1ea3175178e8dcb447b07bbb121a244fa2d9ab9 100644 --- a/services/github/github-package-json.service.js +++ b/services/github/github-package-json.service.js @@ -159,7 +159,7 @@ class GithubPackageJsonDependencyVersion extends ConditionalGithubAuthV3Service async handle( { user, repo, kind, branch = 'HEAD', scope, packageName }, - { filename = 'package.json' } + { filename = 'package.json' }, ) { const { dependencies, diff --git a/services/github/github-package-json.tester.js b/services/github/github-package-json.tester.js index ebbaf0bd132b305e41ad777ddaacaf31cf155f2f..7ba422d534da5be83631518e4abb94598e50ef5c 100644 --- a/services/github/github-package-json.tester.js +++ b/services/github/github-package-json.tester.js @@ -24,8 +24,8 @@ t.create('Package version (repo not found)') t.create('Package version (monorepo)') .get( `/v/metabolize/anafanafo.json?filename=${encodeURIComponent( - 'packages/char-width-table-builder/package.json' - )}` + 'packages/char-width-table-builder/package.json', + )}`, ) .expectBadge({ label: 'version', @@ -67,7 +67,7 @@ t.create('Optional dependency version') t.create('Dev dependency version') .get( - '/dependency-version/paulmelnikow/react-boxplot/dev/react.json?label=react%20tested' + '/dependency-version/paulmelnikow/react-boxplot/dev/react.json?label=react%20tested', ) .expectBadge({ label: 'react tested', @@ -84,8 +84,8 @@ t.create('Prod dependency version') t.create('Prod dependency version (monorepo)') .get( `/dependency-version/metabolize/anafanafo/puppeteer.json?filename=${encodeURIComponent( - 'packages/char-width-table-builder/package.json' - )}` + 'packages/char-width-table-builder/package.json', + )}`, ) .expectBadge({ label: 'puppeteer', diff --git a/services/github/github-pipenv.tester.js b/services/github/github-pipenv.tester.js index 236c311b962cb8fc766b89cebd741d4793098bd0..50b74f12b9356ca7f79f2da1ee0f17ebb031d500 100644 --- a/services/github/github-pipenv.tester.js +++ b/services/github/github-pipenv.tester.js @@ -38,7 +38,7 @@ t.create('Locked Python version (pipfile.lock has no python version)') t.create('Locked version of default dependency') .get( - '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/rq-dashboard.json' + '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/rq-dashboard.json', ) .expectBadge({ label: 'rq-dashboard', @@ -47,7 +47,7 @@ t.create('Locked version of default dependency') t.create('Locked version of default dependency (branch)') .get( - '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/rq-dashboard/main.json' + '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/rq-dashboard/main.json', ) .expectBadge({ label: 'rq-dashboard', @@ -56,7 +56,7 @@ t.create('Locked version of default dependency (branch)') t.create('Locked version of dev dependency') .get( - '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/dev/black.json' + '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/dev/black.json', ) .expectBadge({ label: 'black', @@ -65,7 +65,7 @@ t.create('Locked version of dev dependency') t.create('Locked version of dev dependency (branch)') .get( - '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/dev/black/main.json' + '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/dev/black/main.json', ) .expectBadge({ label: 'black', @@ -74,7 +74,7 @@ t.create('Locked version of dev dependency (branch)') t.create('Locked version of unknown dependency') .get( - '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/dev/i-made-this-up.json' + '/locked/dependency-version/metabolize/rq-dashboard-on-heroku/dev/i-made-this-up.json', ) .expectBadge({ label: 'dependency', diff --git a/services/github/github-pull-request-check-state.service.js b/services/github/github-pull-request-check-state.service.js index 4e2d2c9426fb1092bffea1ddf5bfe026670dfe65..d9cecd86efcfb1f81afa141a0a83df57d50e5307 100644 --- a/services/github/github-pull-request-check-state.service.js +++ b/services/github/github-pull-request-check-state.service.js @@ -10,7 +10,7 @@ const schema = Joi.object({ .items( Joi.object({ state: Joi.equal('error', 'failure', 'pending', 'success').required(), - }) + }), ) .default([]), }).required() diff --git a/services/github/github-pull-request-check-state.tester.js b/services/github/github-pull-request-check-state.tester.js index 5de2302e29806624b44f6daf51960dbbffa5aa03..6ee4d8142e4a19f9f64481f29c79a4603515a2b1 100644 --- a/services/github/github-pull-request-check-state.tester.js +++ b/services/github/github-pull-request-check-state.tester.js @@ -10,14 +10,14 @@ t.create('github pull request check state (pull request not found)') .expectBadge({ label: 'checks', message: 'pull request or repo not found' }) t.create( - "github pull request check state (ref returned by github doesn't exist)" + "github pull request check state (ref returned by github doesn't exist)", ) .get('/s/pulls/badges/shields/1110.json') .intercept( nock => nock('https://api.github.com', { allowUnmocked: true }) .get('/repos/badges/shields/pulls/1110') - .reply(200, JSON.stringify({ head: { sha: 'abc123' } })) // Looks like a real ref, but isn't. + .reply(200, JSON.stringify({ head: { sha: 'abc123' } })), // Looks like a real ref, but isn't. ) .networkOn() .expectBadge({ diff --git a/services/github/github-r-package.spec.js b/services/github/github-r-package.spec.js index cc6516685e4411de32f0d1e61eb3d905a7a7f2e8..23828d5b745cc4f3c531fe751bd6e9eecab7806d 100644 --- a/services/github/github-r-package.spec.js +++ b/services/github/github-r-package.spec.js @@ -20,7 +20,7 @@ describe('GithubRPackageVersion', function () { it('throws InvalidResponse if a file does not contain version specification', function () { expect(() => - GithubRPackageVersion.transform(content('Versio: 6.10.9'), 'DESCRIPTION') + GithubRPackageVersion.transform(content('Versio: 6.10.9'), 'DESCRIPTION'), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'Version missing in DESCRIPTION') diff --git a/services/github/github-r-package.tester.js b/services/github/github-r-package.tester.js index 18247e1918a2d551de6a3fa95f695503943456fa..7f499b651d072595aea4a2d95c80e6972a22c1a1 100644 --- a/services/github/github-r-package.tester.js +++ b/services/github/github-r-package.tester.js @@ -17,8 +17,8 @@ t.create('R package version (from branch)') t.create('R package version (monorepo)') .get( `/wch/r-source.json?filename=${encodeURIComponent( - 'src/gnuwin32/windlgs/DESCRIPTION' - )}` + 'src/gnuwin32/windlgs/DESCRIPTION', + )}`, ) .expectBadge({ label: 'R', diff --git a/services/github/github-release-date.service.js b/services/github/github-release-date.service.js index 6e382884ab114b42434b3b4e2f812e627dca3427..913c080fc139e37384bb67fd5bb2a397e62158cd 100644 --- a/services/github/github-release-date.service.js +++ b/services/github/github-release-date.service.js @@ -15,9 +15,9 @@ const schema = Joi.alternatives( Joi.object({ created_at: Joi.date().required(), published_at: Joi.date().required(), - }).required() + }).required(), ) - .min(1) + .min(1), ) const queryParamSchema = Joi.object({ diff --git a/services/github/github-release-date.tester.js b/services/github/github-release-date.tester.js index 82a22e5dffc46a9c51b613f606ec09103d55eaaf..eb0033d637f9cf4aa661e44848c5089e92b7df09 100644 --- a/services/github/github-release-date.tester.js +++ b/services/github/github-release-date.tester.js @@ -31,7 +31,7 @@ t.create('Release Date - display_date by `published_at`, incorrect query param') }) t.create( - 'Release Date - Should return `no releases or repo not found` for invalid repo' + 'Release Date - Should return `no releases or repo not found` for invalid repo', ) .get('/release-date/not-valid-name/not-valid-repo.json') .expectBadge({ @@ -47,7 +47,7 @@ t.create('(Pre-)Release Date. e.g release date|today') }) t.create( - '(Pre-)Release Date - Should return `no releases or repo not found` for invalid repo' + '(Pre-)Release Date - Should return `no releases or repo not found` for invalid repo', ) .get('/release-date-pre/not-valid-name/not-valid-repo.json') .expectBadge({ diff --git a/services/github/github-release.service.js b/services/github/github-release.service.js index 1d64170705a00e6c2b225f8059a3d4771649541d..4d92384625c3dcfcae9a140e4a7998a5c9c8dcd1 100644 --- a/services/github/github-release.service.js +++ b/services/github/github-release.service.js @@ -125,11 +125,11 @@ class GithubRelease extends GithubAuthV3Service { const latestRelease = await fetchLatestRelease( this, { user, repo }, - queryParams + queryParams, ) const { version, isPrerelease } = this.constructor.transform( latestRelease, - queryParams.display_name + queryParams.display_name, ) return this.constructor.render({ version, diff --git a/services/github/github-release.spec.js b/services/github/github-release.spec.js index 123a5ce0de108c90f61571912f3cebb17cd18755..dc63a4921618941a5ea1c842624c6450f42377ce 100644 --- a/services/github/github-release.spec.js +++ b/services/github/github-release.spec.js @@ -9,14 +9,14 @@ describe('GithubRelease', function () { }) given( { name: null, tag_name: '0.1.3', prerelease: true }, - 'release' + 'release', ).expect({ version: '0.1.3', isPrerelease: true, }) given( { name: 'fun name', tag_name: '1.0.0', prerelease: false }, - 'release' + 'release', ).expect({ version: 'fun name', isPrerelease: false, diff --git a/services/github/github-release.tester.js b/services/github/github-release.tester.js index 6e908da379988b4caf6e60b8ea21e7de3f577b4a..50e88a2f7d6d0e516f59926e43e65042122dd430 100644 --- a/services/github/github-release.tester.js +++ b/services/github/github-release.tester.js @@ -46,11 +46,11 @@ t.create('Release (legacy route: release)') t.create('(pre-)Release (legacy route: release/all)') .get('/release/photonstorm/phaser/all.svg') .expectRedirect( - '/github/v/release/photonstorm/phaser.svg?include_prereleases' + '/github/v/release/photonstorm/phaser.svg?include_prereleases', ) t.create('(pre-)Release (legacy route: release-pre)') .get('/release-pre/photonstorm/phaser.svg') .expectRedirect( - '/github/v/release/photonstorm/phaser.svg?include_prereleases' + '/github/v/release/photonstorm/phaser.svg?include_prereleases', ) diff --git a/services/github/github-size.service.js b/services/github/github-size.service.js index 850a1e77d1e118fa34062477eacc10900635b257..af5bf0f870d5afaea5cbdad3c97399c9920365bc 100644 --- a/services/github/github-size.service.js +++ b/services/github/github-size.service.js @@ -13,7 +13,7 @@ const schema = Joi.alternatives( Joi.object({ size: nonNegativeInteger, }).required(), - Joi.array().required() + Joi.array().required(), ) export default class GithubSize extends GithubAuthV3Service { diff --git a/services/github/github-tag.tester.js b/services/github/github-tag.tester.js index 1a804c288621d0a6a44b193f552ff015e99f930d..eb8aadadac7c83bfa00d42126addb0ad11972745 100644 --- a/services/github/github-tag.tester.js +++ b/services/github/github-tag.tester.js @@ -36,7 +36,7 @@ t.create('Tag (legacy route: tag)') t.create('Tag (legacy route: tag-pre)') .get('/tag-pre/photonstorm/phaser.svg') .expectRedirect( - '/github/v/tag/photonstorm/phaser.svg?include_prereleases&sort=semver' + '/github/v/tag/photonstorm/phaser.svg?include_prereleases&sort=semver', ) t.create('Tag (legacy route: tag-date)') diff --git a/services/github/github-top-language.service.js b/services/github/github-top-language.service.js index 21aac8211353141fe5fe8ed5908dff087ebde5fa..e75bf6658a07ab50104348a6130617af916807e7 100644 --- a/services/github/github-top-language.service.js +++ b/services/github/github-top-language.service.js @@ -41,7 +41,7 @@ export default class GithubTopLanguage extends BaseGithubLanguage { const data = await this.fetch({ user, repo }) const language = Object.keys(data).reduce( (a, b) => (data[a] > data[b] ? a : b), - 'language' + 'language', ) return this.constructor.render({ language, diff --git a/services/github/github-total-star.service.js b/services/github/github-total-star.service.js index a53e0ff4a4892d3c2ddb156f5a48f62729562a05..fca0be35d8a6d9e93d08c79a978d73ac1547115d 100644 --- a/services/github/github-total-star.service.js +++ b/services/github/github-total-star.service.js @@ -37,7 +37,7 @@ const nodesSchema = Joi.array() stargazers: Joi.object({ totalCount: nonNegativeInteger, }).required(), - }) + }), ) .default([]) @@ -57,7 +57,7 @@ const schema = Joi.object({ organization: Joi.object({ repositories: repositoriesSchema, }).required(), - }).required() + }).required(), ).required(), }).required() diff --git a/services/gitlab/gitlab-base.js b/services/gitlab/gitlab-base.js index 76d0f6b8a4abb4e0898c32f2345f85aa8622b9e6..605285483415bdf240d38af067ba0460f7a002f0 100644 --- a/services/gitlab/gitlab-base.js +++ b/services/gitlab/gitlab-base.js @@ -13,7 +13,7 @@ export default class GitLabBase extends BaseJsonService { url, options, httpErrors, - }) + }), ) } @@ -22,7 +22,7 @@ export default class GitLabBase extends BaseJsonService { this.authHelper.withBearerAuthHeader({ ...requestParams, ...{ options: { searchParams: { page } } }, - }) + }), ) const json = this._parseJson(buffer) @@ -59,8 +59,8 @@ export default class GitLabBase extends BaseJsonService { const pageData = await Promise.all( [...Array(numberOfPages - 1).keys()].map((_, i) => - this.fetchPage({ page: ++i + 1, requestParams, schema }) - ) + this.fetchPage({ page: ++i + 1, requestParams, schema }), + ), ) return [...data].concat(...pageData) } diff --git a/services/gitlab/gitlab-contributors.service.js b/services/gitlab/gitlab-contributors.service.js index e93a8ce0345202780c112a77216dfc9898fad000..76415edf4652c6c91a10ea815f02655905131563 100644 --- a/services/gitlab/gitlab-contributors.service.js +++ b/services/gitlab/gitlab-contributors.service.js @@ -49,11 +49,11 @@ export default class GitlabContributors extends GitLabBase { const { res } = await this._request( this.authHelper.withBearerAuthHeader({ url: `${baseUrl}/api/v4/projects/${encodeURIComponent( - project + project, )}/repository/contributors`, options: { searchParams: { page: '1', per_page: '1' } }, httpErrors: httpErrorsFor('project not found'), - }) + }), ) const data = this.constructor._validate(res.headers, schema) // The total number of contributors is in the `x-total` field in the headers. diff --git a/services/gitlab/gitlab-contributors.tester.js b/services/gitlab/gitlab-contributors.tester.js index ddd48d1fbd617ee997861b711e29174488c4661b..1d93b88be64265d4a4205e18620750ba6cf5c83d 100644 --- a/services/gitlab/gitlab-contributors.tester.js +++ b/services/gitlab/gitlab-contributors.tester.js @@ -24,9 +24,9 @@ t.create('Mocking the missing x-total header') .intercept(nock => nock('https://gitlab.com') .get( - '/api/v4/projects/group%2Fproject/repository/contributors?page=1&per_page=1' + '/api/v4/projects/group%2Fproject/repository/contributors?page=1&per_page=1', ) - .reply(200) + .reply(200), ) .expectBadge({ label: 'contributors', diff --git a/services/gitlab/gitlab-coverage-redirect.tester.js b/services/gitlab/gitlab-coverage-redirect.tester.js index c82a2e67041a25dfdd989ff293ec756a357cf321..997eb520adeafdf8c96ae19e4f35ed0340b12d42 100644 --- a/services/gitlab/gitlab-coverage-redirect.tester.js +++ b/services/gitlab/gitlab-coverage-redirect.tester.js @@ -4,19 +4,19 @@ export const t = await createServiceTester() t.create('Coverage redirect (with branch)') .get('/gitlab-org/gitlab-runner/master.json') .expectRedirect( - '/gitlab/pipeline-coverage/gitlab-org/gitlab-runner.json?branch=master' + '/gitlab/pipeline-coverage/gitlab-org/gitlab-runner.json?branch=master', ) t.create('Coverage redirect (with branch and job_name)') .get('/gitlab-org/gitlab-runner/master.json?job_name=test coverage report') .expectRedirect( - '/gitlab/pipeline-coverage/gitlab-org/gitlab-runner.json?branch=master&job_name=test%20coverage%20report' + '/gitlab/pipeline-coverage/gitlab-org/gitlab-runner.json?branch=master&job_name=test%20coverage%20report', ) t.create('Coverage redirect (with branch and gitlab_url)') .get( - '/gitlab-org/gitlab-runner/master.json?gitlab_url=https://gitlab.gnome.org' + '/gitlab-org/gitlab-runner/master.json?gitlab_url=https://gitlab.gnome.org', ) .expectRedirect( - '/gitlab/pipeline-coverage/gitlab-org/gitlab-runner.json?branch=master&gitlab_url=https%3a%2f%2fgitlab.gnome.org' + '/gitlab/pipeline-coverage/gitlab-org/gitlab-runner.json?branch=master&gitlab_url=https%3a%2f%2fgitlab.gnome.org', ) diff --git a/services/gitlab/gitlab-issues.service.js b/services/gitlab/gitlab-issues.service.js index 3f88d66519c42c6a433429de8bd6d42683c6994d..d3488a3b50da32619e825d864bd25606dd394b3a 100644 --- a/services/gitlab/gitlab-issues.service.js +++ b/services/gitlab/gitlab-issues.service.js @@ -234,7 +234,7 @@ export default class GitlabIssues extends GitLabBase { return super.fetch({ schema, url: `${baseUrl}/api/v4/projects/${encodeURIComponent( - project + project, )}/issues_statistics`, options: labels ? { searchParams: { labels } } : undefined, httpErrors: httpErrorsFor('project not found'), @@ -261,7 +261,7 @@ export default class GitlabIssues extends GitLabBase { async handle( { variant, raw, project }, - { gitlab_url: baseUrl = 'https://gitlab.com', labels } + { gitlab_url: baseUrl = 'https://gitlab.com', labels }, ) { const { statistics } = await this.fetch({ project, diff --git a/services/gitlab/gitlab-issues.tester.js b/services/gitlab/gitlab-issues.tester.js index a06a1d5394c6b22e88bf6c27c96e39cb2c11e930..511fa51d181202262426e834749076821fb719e6 100644 --- a/services/gitlab/gitlab-issues.tester.js +++ b/services/gitlab/gitlab-issues.tester.js @@ -41,7 +41,7 @@ t.create('Open issues by label is > zero') t.create('Open issues by multi-word label is > zero') .get( - '/open/guoxudong.io/shields-test/issue-test.json?labels=discussion,enhancement' + '/open/guoxudong.io/shields-test/issue-test.json?labels=discussion,enhancement', ) .expectBadge({ label: 'discussion,enhancement issues', @@ -108,7 +108,7 @@ t.create('All issues') .expectBadge({ label: 'issues', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/, ), }) @@ -124,18 +124,18 @@ t.create('All issues by label is > zero') .expectBadge({ label: 'discussion issues', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/, ), }) t.create('All issues by multi-word label is > zero') .get( - '/all/guoxudong.io/shields-test/issue-test.json?labels=discussion,enhancement' + '/all/guoxudong.io/shields-test/issue-test.json?labels=discussion,enhancement', ) .expectBadge({ label: 'discussion,enhancement issues', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/, ), }) diff --git a/services/gitlab/gitlab-languages-count.service.js b/services/gitlab/gitlab-languages-count.service.js index 4d08f13b6786a408d9c21269a3b9deee6179b708..686003f252c014a73c02b7c4cd10654fa9642801 100644 --- a/services/gitlab/gitlab-languages-count.service.js +++ b/services/gitlab/gitlab-languages-count.service.js @@ -52,7 +52,7 @@ export default class GitlabLanguageCount extends GitLabBase { return super.fetch({ schema, url: `${baseUrl}/api/v4/projects/${encodeURIComponent( - project + project, )}/languages`, httpErrors: httpErrorsFor('project not found'), }) diff --git a/services/gitlab/gitlab-last-commit.service.js b/services/gitlab/gitlab-last-commit.service.js index c69050dfe47d4e733e1cd3483d14ed4ddd8c3c75..72bd745a3fdd5b4916e44ebbb93737c21ba070b1 100644 --- a/services/gitlab/gitlab-last-commit.service.js +++ b/services/gitlab/gitlab-last-commit.service.js @@ -9,7 +9,7 @@ const schema = Joi.array() .items( Joi.object({ committed_date: Joi.string().required(), - }).required() + }).required(), ) .required() .min(1) @@ -61,7 +61,7 @@ export default class GitlabLastCommit extends GitLabBase { // https://docs.gitlab.com/ee/api/commits.html#list-repository-commits return super.fetch({ url: `${baseUrl}/api/v4/projects/${encodeURIComponent( - project + project, )}/repository/commits`, options: { searchParams: { ref_name: ref } }, schema, @@ -71,7 +71,7 @@ export default class GitlabLastCommit extends GitLabBase { async handle( { project }, - { gitlab_url: baseUrl = 'https://gitlab.com', ref } + { gitlab_url: baseUrl = 'https://gitlab.com', ref }, ) { const data = await this.fetch({ project, baseUrl, ref }) return this.constructor.render({ commitDate: data[0].committed_date }) diff --git a/services/gitlab/gitlab-license.tester.js b/services/gitlab/gitlab-license.tester.js index 9769a625f3b504d8f95c29c0be72ceb1a9d01c99..e9caceb74f810276490182395557e68aa27eaa9d 100644 --- a/services/gitlab/gitlab-license.tester.js +++ b/services/gitlab/gitlab-license.tester.js @@ -51,7 +51,7 @@ t.create('Mocking License') html_url: 'http://choosealicense.com/licenses/apache-2.0/', source_url: '', }, - }) + }), ) .expectBadge({ label: 'license', diff --git a/services/gitlab/gitlab-merge-requests.service.js b/services/gitlab/gitlab-merge-requests.service.js index 5db63bcb6e29e282fb0d6e880f469a91a614ede1..3ba340331da164537dcfeddbd6f753a6f6c9b750 100644 --- a/services/gitlab/gitlab-merge-requests.service.js +++ b/services/gitlab/gitlab-merge-requests.service.js @@ -290,7 +290,7 @@ export default class GitlabMergeRequests extends GitLabBase { messageSuffix = state } const message = `${mergeRequestCount > 10000 ? 'more than ' : ''}${metric( - mergeRequestCount + mergeRequestCount, )}${messageSuffix ? ' ' : ''}${messageSuffix}` return { label: `${labelPrefix}${labelText}merge requests`, @@ -304,7 +304,7 @@ export default class GitlabMergeRequests extends GitLabBase { const { res } = await this._request( this.authHelper.withBearerAuthHeader({ url: `${baseUrl}/api/v4/projects/${encodeURIComponent( - project + project, )}/merge_requests`, options: { searchParams: { @@ -315,7 +315,7 @@ export default class GitlabMergeRequests extends GitLabBase { }, }, httpErrors: httpErrorsFor('project not found'), - }) + }), ) return this.constructor._validate(res.headers, schema) } @@ -333,7 +333,7 @@ export default class GitlabMergeRequests extends GitLabBase { async handle( { variant, raw, project }, - { gitlab_url: baseUrl = 'https://gitlab.com', labels } + { gitlab_url: baseUrl = 'https://gitlab.com', labels }, ) { const data = await this.fetch({ project, diff --git a/services/gitlab/gitlab-merge-requests.spec.js b/services/gitlab/gitlab-merge-requests.spec.js index dde1292568415128526b91a99ff7cd1bf883e7e5..cb809ed17fc3b39f8b75b7af93a54ac92d8e52eb 100644 --- a/services/gitlab/gitlab-merge-requests.spec.js +++ b/services/gitlab/gitlab-merge-requests.spec.js @@ -66,7 +66,7 @@ describe('GitlabMergeRequests', function () { it('sends the auth information as configured', async function () { const scope = nock('https://gitlab.com/') .get( - '/api/v4/projects/foo%2Fbar/merge_requests?state=opened&page=1&per_page=1' + '/api/v4/projects/foo%2Fbar/merge_requests?state=opened&page=1&per_page=1', ) // This ensures that the expected credentials are actually being sent with the HTTP request. // Without this the request wouldn't match and the test would fail. @@ -78,8 +78,8 @@ describe('GitlabMergeRequests', function () { defaultContext, config, { project: 'foo/bar', variant: 'open' }, - {} - ) + {}, + ), ).to.deep.equal({ label: 'merge requests', message: '100 open', diff --git a/services/gitlab/gitlab-merge-requests.tester.js b/services/gitlab/gitlab-merge-requests.tester.js index 0b8c40478f3389893c13777725ff3639acdb351c..2a72e501d622f2870a5dedb3ad17cb980050023c 100644 --- a/services/gitlab/gitlab-merge-requests.tester.js +++ b/services/gitlab/gitlab-merge-requests.tester.js @@ -41,7 +41,7 @@ t.create('Open merge requests by label is > zero') t.create('Open merge requests by multi-word label is > zero') .get( - '/open/guoxudong.io/shields-test/issue-test.json?labels=discussion,enhancement' + '/open/guoxudong.io/shields-test/issue-test.json?labels=discussion,enhancement', ) .expectBadge({ label: 'discussion,enhancement merge requests', @@ -95,7 +95,7 @@ t.create('Closed merge requests by multi-word label is > zero') t.create('Closed merge requests by label (raw)') .get( - '/closed-raw/guoxudong.io/shields-test/issue-test.json?labels=enhancement' + '/closed-raw/guoxudong.io/shields-test/issue-test.json?labels=enhancement', ) .expectBadge({ label: 'closed enhancement merge requests', @@ -110,7 +110,7 @@ t.create('All merge requests') .expectBadge({ label: 'merge requests', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/, ), }) @@ -126,18 +126,18 @@ t.create('All merge requests by label is > zero') .expectBadge({ label: 'discussion merge requests', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/, ), }) t.create('All merge requests by multi-word label is > zero') .get( - '/all/guoxudong.io/shields-test/issue-test.json?labels=discussion,enhancement' + '/all/guoxudong.io/shields-test/issue-test.json?labels=discussion,enhancement', ) .expectBadge({ label: 'discussion,enhancement merge requests', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) all$/, ), }) @@ -160,7 +160,7 @@ t.create('locked merge requests') .expectBadge({ label: 'merge requests', message: Joi.string().regex( - /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) locked$/ + /^([0-9]+[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY]) locked$/, ), }) diff --git a/services/gitlab/gitlab-pipeline-coverage.service.js b/services/gitlab/gitlab-pipeline-coverage.service.js index e0a332907b34d65f88c5756cbd09a40857bdfb3b..e844f43fb7615cc2953d3abf52f646215a4a55e6 100644 --- a/services/gitlab/gitlab-pipeline-coverage.service.js +++ b/services/gitlab/gitlab-pipeline-coverage.service.js @@ -96,7 +96,7 @@ export default class GitlabPipelineCoverage extends BaseSvgScrapingService { // it is recommended to not use the query param at all if not required jobName = jobName ? `?job=${jobName}` : '' const url = `${baseUrl}/${decodeURIComponent( - project + project, )}/badges/${branch}/coverage.svg${jobName}` const httpErrors = httpErrorsFor('project not found') return this._requestSvg({ @@ -115,7 +115,7 @@ export default class GitlabPipelineCoverage extends BaseSvgScrapingService { async handle( { project }, - { gitlab_url: baseUrl, job_name: jobName, branch } + { gitlab_url: baseUrl, job_name: jobName, branch }, ) { const { message: coverage } = await this.fetch({ project, diff --git a/services/gitlab/gitlab-pipeline-coverage.tester.js b/services/gitlab/gitlab-pipeline-coverage.tester.js index 10b2fecc52687c28f350def0ff5007da7a3f6f7a..c200646d24399386f66c0deac9b246e2e264f7b9 100644 --- a/services/gitlab/gitlab-pipeline-coverage.tester.js +++ b/services/gitlab/gitlab-pipeline-coverage.tester.js @@ -32,7 +32,7 @@ t.create('Coverage (nonexistent repo)') t.create('Coverage (custom job)') .get( - '/gitlab-org/gitlab-runner.json?branch=12-0-stable&job_name=test coverage report' + '/gitlab-org/gitlab-runner.json?branch=12-0-stable&job_name=test coverage report', ) .expectBadge({ label: 'coverage', @@ -41,7 +41,7 @@ t.create('Coverage (custom job)') t.create('Coverage (custom invalid job)') .get( - '/gitlab-org/gitlab-runner.json?branch=12-0-stable&job_name=i dont exist' + '/gitlab-org/gitlab-runner.json?branch=12-0-stable&job_name=i dont exist', ) .expectBadge({ label: 'coverage', @@ -50,7 +50,7 @@ t.create('Coverage (custom invalid job)') t.create('Coverage (custom gitlab URL)') .get( - '/GNOME/at-spi2-core.json?gitlab_url=https://gitlab.gnome.org&branch=master' + '/GNOME/at-spi2-core.json?gitlab_url=https://gitlab.gnome.org&branch=master', ) .expectBadge({ label: 'coverage', @@ -59,7 +59,7 @@ t.create('Coverage (custom gitlab URL)') t.create('Coverage (custom gitlab URL and job)') .get( - '/GNOME/libhandy.json?gitlab_url=https://gitlab.gnome.org&branch=master&job_name=unit-test' + '/GNOME/libhandy.json?gitlab_url=https://gitlab.gnome.org&branch=master&job_name=unit-test', ) .expectBadge({ label: 'coverage', diff --git a/services/gitlab/gitlab-pipeline-status.service.js b/services/gitlab/gitlab-pipeline-status.service.js index 49246f861d92201d6f6ccc8d9212fdad6d7d4f2a..2b9a5ced8f0dfe73bcc6351fbc77cbfa172a33b1 100644 --- a/services/gitlab/gitlab-pipeline-status.service.js +++ b/services/gitlab/gitlab-pipeline-status.service.js @@ -71,7 +71,7 @@ class GitlabPipelineStatus extends BaseSvgScrapingService { return this._requestSvg({ schema: badgeSchema, url: `${baseUrl}/${decodeURIComponent( - project + project, )}/badges/${branch}/pipeline.svg`, httpErrors: httpErrorsFor('project not found'), }) @@ -87,7 +87,7 @@ class GitlabPipelineStatus extends BaseSvgScrapingService { async handle( { project }, - { gitlab_url: baseUrl = 'https://gitlab.com', branch = 'main' } + { gitlab_url: baseUrl = 'https://gitlab.com', branch = 'main' }, ) { const data = await this.fetch({ project, diff --git a/services/gitlab/gitlab-pipeline-status.tester.js b/services/gitlab/gitlab-pipeline-status.tester.js index b579b2c5b745451b281b6343d76f41bac158368f..56e8f15ac35bbf6109d09bbc97adf1af00d20e3a 100644 --- a/services/gitlab/gitlab-pipeline-status.tester.js +++ b/services/gitlab/gitlab-pipeline-status.tester.js @@ -15,7 +15,7 @@ t.create('Pipeline status') t.create('Pipeline status (nested groups)') .get( - '/pipeline-status/megabyte-labs/docker/ci-pipeline/ansible.json?branch=master' + '/pipeline-status/megabyte-labs/docker/ci-pipeline/ansible.json?branch=master', ) .expectBadge({ label: 'build', @@ -57,5 +57,5 @@ t.create('Pipeline no branch redirect') t.create('Pipeline legacy route with branch redirect') .get('/pipeline/gitlab-org/gitlab/v10.7.6?style=flat') .expectRedirect( - '/gitlab/pipeline-status/gitlab-org/gitlab.svg?branch=v10.7.6&style=flat' + '/gitlab/pipeline-status/gitlab-org/gitlab.svg?branch=v10.7.6&style=flat', ) diff --git a/services/gitlab/gitlab-release.service.js b/services/gitlab/gitlab-release.service.js index 28e3872b0cfcbb20bd35be062c610d0cdf35f3dc..96dccdc47c89a418b248c1416dfaf16ccf6ab73d 100644 --- a/services/gitlab/gitlab-release.service.js +++ b/services/gitlab/gitlab-release.service.js @@ -9,7 +9,7 @@ const schema = Joi.array().items( Joi.object({ name: Joi.string().required(), tag_name: Joi.string().required(), - }) + }), ) const queryParamSchema = Joi.object({ @@ -119,7 +119,7 @@ export default class GitLabRelease extends GitLabBase { return latest( releases.map(t => t[displayKey]), - { pre: includePrereleases } + { pre: includePrereleases }, ) } @@ -131,7 +131,7 @@ export default class GitLabRelease extends GitLabBase { sort, display_name: displayName, date_order_by: orderBy, - } + }, ) { const isSemver = sort === 'semver' const releases = await this.fetch({ project, baseUrl, isSemver, orderBy }) diff --git a/services/gitlab/gitlab-release.spec.js b/services/gitlab/gitlab-release.spec.js index c3a41a9022e51dfa165a683d3d810ec430fb9381..676e4ef74cd3e78b225a72e413cc8877d4f8be25 100644 --- a/services/gitlab/gitlab-release.spec.js +++ b/services/gitlab/gitlab-release.spec.js @@ -34,8 +34,8 @@ describe('GitLabRelease', function () { defaultContext, config, { project: 'foo/bar' }, - {} - ) + {}, + ), ).to.deep.equal({ label: undefined, message: 'v1.9', diff --git a/services/gitlab/gitlab-tag.service.js b/services/gitlab/gitlab-tag.service.js index 10f7bd62ed7a1d19902ddc2e8ccb75bc25593c0a..650a7d40a5e9ef26beded59ecd5db1b06f7ccac2 100644 --- a/services/gitlab/gitlab-tag.service.js +++ b/services/gitlab/gitlab-tag.service.js @@ -10,7 +10,7 @@ import GitLabBase from './gitlab-base.js' const schema = Joi.array().items( Joi.object({ name: Joi.string().required(), - }) + }), ) const queryParamSchema = Joi.object({ @@ -89,7 +89,7 @@ export default class GitlabTag extends GitLabBase { return super.fetch({ schema, url: `${baseUrl}/api/v4/projects/${encodeURIComponent( - project + project, )}/repository/tags`, options: { searchParams: { order_by: 'updated' } }, httpErrors: httpErrorsFor('project not found'), @@ -107,7 +107,7 @@ export default class GitlabTag extends GitLabBase { return latest( tags.map(t => t.name), - { pre: includePrereleases } + { pre: includePrereleases }, ) } @@ -117,7 +117,7 @@ export default class GitlabTag extends GitLabBase { gitlab_url: baseUrl = 'https://gitlab.com', include_prereleases: pre, sort, - } + }, ) { const tags = await this.fetch({ project, baseUrl }) const version = this.constructor.transform({ diff --git a/services/gitlab/gitlab-tag.spec.js b/services/gitlab/gitlab-tag.spec.js index 7565cbc4e81bcf11e338d0eaf91a9a1ffa990d19..dddc97a7ce174499ba99bc28c23c46ba40bb1816 100644 --- a/services/gitlab/gitlab-tag.spec.js +++ b/services/gitlab/gitlab-tag.spec.js @@ -34,8 +34,8 @@ describe('GitLabTag', function () { defaultContext, config, { project: 'foo/bar' }, - {} - ) + {}, + ), ).to.deep.equal({ message: 'v1.9', color: 'blue', diff --git a/services/gradle-plugin-portal/gradle-plugin-portal.tester.js b/services/gradle-plugin-portal/gradle-plugin-portal.tester.js index a662dc4f197e241b73a8f2ba01a06e766462e5b1..3b1cc7b1184560a8269e055f5425fceafd70ac8e 100644 --- a/services/gradle-plugin-portal/gradle-plugin-portal.tester.js +++ b/services/gradle-plugin-portal/gradle-plugin-portal.tester.js @@ -5,22 +5,22 @@ t.create('gradle plugin portal') .get('/com.gradle.plugin-publish') .expectRedirect( `/maven-metadata/v.svg?label=plugin%20portal&metadataUrl=${encodeURIComponent( - 'https://plugins.gradle.org/m2/com/gradle/plugin-publish/com.gradle.plugin-publish.gradle.plugin/maven-metadata.xml' - )}` + 'https://plugins.gradle.org/m2/com/gradle/plugin-publish/com.gradle.plugin-publish.gradle.plugin/maven-metadata.xml', + )}`, ) t.create('gradle plugin portal with custom labels') .get('/com.gradle.plugin-publish?label=custom%20label') .expectRedirect( `/maven-metadata/v.svg?label=custom%20label&metadataUrl=${encodeURIComponent( - 'https://plugins.gradle.org/m2/com/gradle/plugin-publish/com.gradle.plugin-publish.gradle.plugin/maven-metadata.xml' - )}` + 'https://plugins.gradle.org/m2/com/gradle/plugin-publish/com.gradle.plugin-publish.gradle.plugin/maven-metadata.xml', + )}`, ) t.create('gradle plugin portal with custom color') .get('/com.gradle.plugin-publish?color=gray') .expectRedirect( `/maven-metadata/v.svg?color=gray&label=plugin%20portal&metadataUrl=${encodeURIComponent( - 'https://plugins.gradle.org/m2/com/gradle/plugin-publish/com.gradle.plugin-publish.gradle.plugin/maven-metadata.xml' - )}` + 'https://plugins.gradle.org/m2/com/gradle/plugin-publish/com.gradle.plugin-publish.gradle.plugin/maven-metadata.xml', + )}`, ) diff --git a/services/hackage/hackage-version.tester.js b/services/hackage/hackage-version.tester.js index f4074ec9c1a99cfb98594622586d0b6b437ac66b..5f66211a3774e1ce8f5dbba53c524d9b59c9eeba 100644 --- a/services/hackage/hackage-version.tester.js +++ b/services/hackage/hackage-version.tester.js @@ -16,6 +16,6 @@ t.create('hackage version (unexpected response)') .intercept(nock => nock('https://hackage.haskell.org') .get('/package/lens/lens.cabal') - .reply(200, '') + .reply(200, ''), ) .expectBadge({ label: 'hackage', message: 'invalid response data' }) diff --git a/services/hackernews/hackernews-user-karma.tester.js b/services/hackernews/hackernews-user-karma.tester.js index 0afaeeb317759e46d6cc64f600f5209ee180ca39..d4eb227bfaa9055c52457291ad7a7fe1fdaa08a4 100644 --- a/services/hackernews/hackernews-user-karma.tester.js +++ b/services/hackernews/hackernews-user-karma.tester.js @@ -13,7 +13,7 @@ t.create('valid repo -- negative karma') .intercept(nock => nock('https://hacker-news.firebaseio.com/v0/user') .get('/negative.json') - .reply(200, { karma: -1234 }) + .reply(200, { karma: -1234 }), ) .expectBadge({ label: 'U/negative karma', diff --git a/services/hexpm/hexpm.tester.js b/services/hexpm/hexpm.tester.js index c086e2c6c000bfb5f2b79bd555fdffe86ed09231..8927771881036a7df048a518fc4745e74de513fa 100644 --- a/services/hexpm/hexpm.tester.js +++ b/services/hexpm/hexpm.tester.js @@ -26,7 +26,7 @@ t.create('downloads (zero for period)') latest_stable_version: '1.0', latest_version: '1.0', meta: { licenses: ['MIT'] }, - }) + }), ) .expectBadge({ label: 'downloads', message: '0/day' }) @@ -52,7 +52,7 @@ t.create('version (no stable version)') downloads: { all: 100 }, latest_version: '1.0.0-rc.3', meta: { licenses: ['MIT'] }, - }) + }), ) .expectBadge({ label: 'hex', @@ -79,7 +79,7 @@ t.create('license (multiple licenses)') latest_stable_version: '1.0', latest_version: '1.0', meta: { licenses: ['GPLv2', 'MIT'] }, - }) + }), ) .expectBadge({ label: 'licenses', @@ -97,7 +97,7 @@ t.create('license (no license)') latest_stable_version: '1.0', latest_version: '1.0', meta: { licenses: [] }, - }) + }), ) .expectBadge({ label: 'license', diff --git a/services/homebrew/homebrew-cask.tester.js b/services/homebrew/homebrew-cask.tester.js index 7535c3a8e5cc1b99345a9770e489ce745d92eb53..2d3918e3716b45d3ef286b0b795a268285e4f7d8 100644 --- a/services/homebrew/homebrew-cask.tester.js +++ b/services/homebrew/homebrew-cask.tester.js @@ -12,7 +12,7 @@ t.create('homebrew cask (valid)') .intercept(nock => nock('https://formulae.brew.sh') .get('/api/cask/iterm2.json') - .reply(200, { version: '3.3.6' }) + .reply(200, { version: '3.3.6' }), ) .expectBadge({ label: 'homebrew cask', message: 'v3.3.6' }) diff --git a/services/homebrew/homebrew-version.tester.js b/services/homebrew/homebrew-version.tester.js index 1e69f15cfb6b98d7b6db316e46085ce68306cbc1..54414041517956d8458b39bd6267b01dcdd032c4 100644 --- a/services/homebrew/homebrew-version.tester.js +++ b/services/homebrew/homebrew-version.tester.js @@ -12,7 +12,7 @@ t.create('homebrew (valid)') .intercept(nock => nock('https://formulae.brew.sh') .get('/api/formula/cake.json') - .reply(200, { versions: { stable: '0.23.0', devel: null, head: null } }) + .reply(200, { versions: { stable: '0.23.0', devel: null, head: null } }), ) .expectBadge({ label: 'homebrew', message: 'v0.23.0' }) diff --git a/services/hsts/hsts.tester.js b/services/hsts/hsts.tester.js index 0f55a07b79359185181f979a3f222d637d136be9..215e3d3379c93a43523e7e83e7ec502f32798b95 100644 --- a/services/hsts/hsts.tester.js +++ b/services/hsts/hsts.tester.js @@ -29,7 +29,7 @@ t.create('gets the hsts status of github (mock)') .intercept(nock => nock('https://hstspreload.org') .get('/api/v2/status?domain=github.com') - .reply(200, { status: 'preloaded' }) + .reply(200, { status: 'preloaded' }), ) .expectBadge({ label, @@ -42,7 +42,7 @@ t.create('gets the hsts status of httpforever (mock)') .intercept(nock => nock('https://hstspreload.org') .get('/api/v2/status?domain=httpforever.com') - .reply(200, { status: 'unknown' }) + .reply(200, { status: 'unknown' }), ) .expectBadge({ label, @@ -55,7 +55,7 @@ t.create('gets the hsts status of a pending site (mock)') .intercept(nock => nock('https://hstspreload.org') .get('/api/v2/status?domain=pending.mock') - .reply(200, { status: 'pending' }) + .reply(200, { status: 'pending' }), ) .expectBadge({ label, @@ -68,7 +68,7 @@ t.create('gets the status of an invalid uri (mock)') .intercept(nock => nock('https://hstspreload.org') .get('/api/v2/status?domain=does-not-exist') - .reply(200, { status: 'unknown' }) + .reply(200, { status: 'unknown' }), ) .expectBadge({ label, diff --git a/services/jenkins/jenkins-base.js b/services/jenkins/jenkins-base.js index 2a52b2d47640b154fbdce766020f40ec38dfa2f4..942c3bf567acdcde2d3dca45d1f2619059de08c2 100644 --- a/services/jenkins/jenkins-base.js +++ b/services/jenkins/jenkins-base.js @@ -19,7 +19,7 @@ export default class JenkinsBase extends BaseJsonService { options: { searchParams }, schema, httpErrors, - }) + }), ) } } diff --git a/services/jenkins/jenkins-build-redirect.tester.js b/services/jenkins/jenkins-build-redirect.tester.js index 3e5e76aa0cf2d12a3415b9cc549c6cad1be8f367..ed740750685d7e4952b2d44e320947cf49769b1d 100644 --- a/services/jenkins/jenkins-build-redirect.tester.js +++ b/services/jenkins/jenkins-build-redirect.tester.js @@ -10,22 +10,22 @@ t.create('old jenkins ci prefix + job url in path') .get('jenkins-ci/s/https/updates.jenkins-ci.org/job/foo.svg') .expectRedirect( `/jenkins/build.svg?jobUrl=${encodeURIComponent( - 'https://updates.jenkins-ci.org/job/foo' - )}` + 'https://updates.jenkins-ci.org/job/foo', + )}`, ) t.create('old jenkins shorthand prefix + job url in path') .get('jenkins/s/https/updates.jenkins-ci.org/job/foo.svg') .expectRedirect( `/jenkins/build.svg?jobUrl=${encodeURIComponent( - 'https://updates.jenkins-ci.org/job/foo' - )}` + 'https://updates.jenkins-ci.org/job/foo', + )}`, ) t.create('new jenkins build prefix + job url in path') .get('jenkins/build/https/updates.jenkins-ci.org/job/foo.svg') .expectRedirect( `/jenkins/build.svg?jobUrl=${encodeURIComponent( - 'https://updates.jenkins-ci.org/job/foo' - )}` + 'https://updates.jenkins-ci.org/job/foo', + )}`, ) diff --git a/services/jenkins/jenkins-build.spec.js b/services/jenkins/jenkins-build.spec.js index a821f272709f346254d71ea02c37aec2e55ec243..4bba9b389fd68e2e8c1f7690c733b6ae18324e0e 100644 --- a/services/jenkins/jenkins-build.spec.js +++ b/services/jenkins/jenkins-build.spec.js @@ -43,16 +43,16 @@ describe('JenkinsBuild', function () { color: 'yellow', }) given({ status: 'passing' }).expect( - renderBuildStatusBadge({ status: 'passing' }) + renderBuildStatusBadge({ status: 'passing' }), ) given({ status: 'failing' }).expect( - renderBuildStatusBadge({ status: 'failing' }) + renderBuildStatusBadge({ status: 'failing' }), ) given({ status: 'building' }).expect( - renderBuildStatusBadge({ status: 'building' }) + renderBuildStatusBadge({ status: 'building' }), ) given({ status: 'not built' }).expect( - renderBuildStatusBadge({ status: 'not built' }) + renderBuildStatusBadge({ status: 'not built' }), ) }) @@ -91,8 +91,8 @@ describe('JenkinsBuild', function () { { jobUrl: 'https://jenkins.ubuntu.com/server/job/curtin-vmtest-daily-x', - } - ) + }, + ), ).to.deep.equal({ label: undefined, message: 'passing', diff --git a/services/jenkins/jenkins-build.tester.js b/services/jenkins/jenkins-build.tester.js index 7ebfb5df861f5c900a5113f55a5866aa8dd9170a..573530a6d183f1f97639285884112bce8b2fefa5 100644 --- a/services/jenkins/jenkins-build.tester.js +++ b/services/jenkins/jenkins-build.tester.js @@ -5,7 +5,7 @@ export const t = await createServiceTester() const isJenkinsBuildStatus = Joi.alternatives( isBuildStatus, - Joi.string().allow('unstable') + Joi.string().allow('unstable'), ) t.create('build job not found') @@ -15,8 +15,8 @@ t.create('build job not found') t.create('build found (view)') .get( `/build.json?jobUrl=${encodeURIComponent( - 'https://wso2.org/jenkins/view/All Builds/job/archetypes' - )}` + 'https://wso2.org/jenkins/view/All Builds/job/archetypes', + )}`, ) .expectBadge({ label: 'build', message: isJenkinsBuildStatus }) diff --git a/services/jenkins/jenkins-common.spec.js b/services/jenkins/jenkins-common.spec.js index ae1e2e998359febd0ef672607677ce2409932314..f9ead5dc4f32c0e6a469f33efc827b029b851f46 100644 --- a/services/jenkins/jenkins-common.spec.js +++ b/services/jenkins/jenkins-common.spec.js @@ -9,7 +9,7 @@ describe('jenkins-common', function () { }) expect(actualResult).to.equal( - 'https://ci.eclipse.org/jgit/job/jgit/lastCompletedBuild/api/json' + 'https://ci.eclipse.org/jgit/job/jgit/lastCompletedBuild/api/json', ) }) @@ -20,7 +20,7 @@ describe('jenkins-common', function () { }) expect(actualResult).to.equal( - 'https://ci.eclipse.org/jgit/job/jgit/lastCompletedBuild/cobertura/api/json' + 'https://ci.eclipse.org/jgit/job/jgit/lastCompletedBuild/cobertura/api/json', ) }) @@ -31,7 +31,7 @@ describe('jenkins-common', function () { }) expect(actualResult).to.equal( - 'https://ci.eclipse.org/jgit/job/jgit/api/json' + 'https://ci.eclipse.org/jgit/job/jgit/api/json', ) }) }) @@ -45,7 +45,7 @@ describe('jenkins-common', function () { }) expect(actualResult).to.equal( - 'https://jenkins.sqlalchemy.org/job/alembic_coverage' + 'https://jenkins.sqlalchemy.org/job/alembic_coverage', ) }) @@ -57,7 +57,7 @@ describe('jenkins-common', function () { }) expect(actualResult).to.equal( - 'https://jenkins.sqlalchemy.org/job/alembic_coverage' + 'https://jenkins.sqlalchemy.org/job/alembic_coverage', ) }) }) diff --git a/services/jenkins/jenkins-coverage-redirector.tester.js b/services/jenkins/jenkins-coverage-redirector.tester.js index e43cfabea8843b15bd81f99ee19289f97b7fcdd6..86920ca195c2544c161922fae256b29e74ae7626 100644 --- a/services/jenkins/jenkins-coverage-redirector.tester.js +++ b/services/jenkins/jenkins-coverage-redirector.tester.js @@ -8,56 +8,56 @@ export const t = new ServiceTester({ t.create('old Jacoco prefix + job url in path') .get( - '/j/https/wso2.org/jenkins/view/All%20Builds/job/sonar/job/sonar-carbon-dashboards.svg' + '/j/https/wso2.org/jenkins/view/All%20Builds/job/sonar/job/sonar-carbon-dashboards.svg', ) .expectRedirect( `/jenkins/coverage/jacoco.svg?jobUrl=${encodeURIComponent( - 'https://wso2.org/jenkins/view/All Builds/job/sonar/job/sonar-carbon-dashboards' - )}` + 'https://wso2.org/jenkins/view/All Builds/job/sonar/job/sonar-carbon-dashboards', + )}`, ) t.create('new Jacoco prefix + job url in path') .get( - '/coverage/jacoco/https/wso2.org/jenkins/view/All%20Builds/job/sonar/job/sonar-carbon-dashboards.svg' + '/coverage/jacoco/https/wso2.org/jenkins/view/All%20Builds/job/sonar/job/sonar-carbon-dashboards.svg', ) .expectRedirect( `/jenkins/coverage/jacoco.svg?jobUrl=${encodeURIComponent( - 'https://wso2.org/jenkins/view/All Builds/job/sonar/job/sonar-carbon-dashboards' - )}` + 'https://wso2.org/jenkins/view/All Builds/job/sonar/job/sonar-carbon-dashboards', + )}`, ) t.create('old Cobertura prefix + job url in path') .get('/c/https/jenkins.sqlalchemy.org/job/alembic_coverage.svg') .expectRedirect( `/jenkins/coverage/cobertura.svg?jobUrl=${encodeURIComponent( - 'https://jenkins.sqlalchemy.org/job/alembic_coverage' - )}` + 'https://jenkins.sqlalchemy.org/job/alembic_coverage', + )}`, ) t.create('new Cobertura prefix + job url in path') .get( - '/coverage/cobertura/https/jenkins.sqlalchemy.org/job/alembic_coverage.svg' + '/coverage/cobertura/https/jenkins.sqlalchemy.org/job/alembic_coverage.svg', ) .expectRedirect( `/jenkins/coverage/cobertura.svg?jobUrl=${encodeURIComponent( - 'https://jenkins.sqlalchemy.org/job/alembic_coverage' - )}` + 'https://jenkins.sqlalchemy.org/job/alembic_coverage', + )}`, ) t.create('api prefix + job url in path') .get( - '/coverage/api/https/jenkins.library.illinois.edu/job/OpenSourceProjects/job/Speedwagon/job/master.svg' + '/coverage/api/https/jenkins.library.illinois.edu/job/OpenSourceProjects/job/Speedwagon/job/master.svg', ) .expectRedirect( `/jenkins/coverage/api.svg?jobUrl=${encodeURIComponent( - 'https://jenkins.library.illinois.edu/job/OpenSourceProjects/job/Speedwagon/job/master' - )}` + 'https://jenkins.library.illinois.edu/job/OpenSourceProjects/job/Speedwagon/job/master', + )}`, ) t.create('old v1 api prefix to new prefix') .get( - '/coverage/api.svg?jobUrl=http://loneraver.duckdns.org:8082/job/github/job/VisVid/job/master' + '/coverage/api.svg?jobUrl=http://loneraver.duckdns.org:8082/job/github/job/VisVid/job/master', ) .expectRedirect( - '/jenkins/coverage/apiv1.svg?jobUrl=http://loneraver.duckdns.org:8082/job/github/job/VisVid/job/master' + '/jenkins/coverage/apiv1.svg?jobUrl=http://loneraver.duckdns.org:8082/job/github/job/VisVid/job/master', ) diff --git a/services/jenkins/jenkins-coverage.service.js b/services/jenkins/jenkins-coverage.service.js index c072abe7c2c01ec5454cc60eb603bf93e6fd6f86..11fef840b1cb759ce675030f460ab10e5d7e96fd 100644 --- a/services/jenkins/jenkins-coverage.service.js +++ b/services/jenkins/jenkins-coverage.service.js @@ -26,7 +26,7 @@ const formatMap = { Joi.object({ name: Joi.string().required(), ratio: Joi.number().min(0).max(100).required(), - }) + }), ) .has(Joi.object({ name: 'Lines' })) .min(1) @@ -36,7 +36,7 @@ const formatMap = { treeQueryParam: 'results[elements[name,ratio]]', transform: json => { const lineCoverage = json.results.elements.find( - element => element.name === 'Lines' + element => element.name === 'Lines', ) return { coverage: lineCoverage.ratio } }, @@ -50,7 +50,7 @@ const formatMap = { Joi.object({ name: Joi.string().required(), ratio: Joi.number().min(0).max(100).required(), - }) + }), ) .has(Joi.object({ name: 'Line' })) .min(1) @@ -60,7 +60,7 @@ const formatMap = { treeQueryParam: 'results[elements[name,ratio]]', transform: json => { const lineCoverage = json.results.elements.find( - element => element.name === 'Line' + element => element.name === 'Line', ) return { coverage: lineCoverage.ratio } }, @@ -79,7 +79,7 @@ const formatMap = { const lineCoverageStr = json.projectStatistics.line const lineCoverage = lineCoverageStr.substring( 0, - lineCoverageStr.length - 1 + lineCoverageStr.length - 1, ) return { coverage: Number.parseFloat(lineCoverage) } }, diff --git a/services/jenkins/jenkins-coverage.tester.js b/services/jenkins/jenkins-coverage.tester.js index 45cf0303060a916fddcd6bc47c94f00ba8547969..f494e014e6162bd7e0971edef407187e0a814cac 100644 --- a/services/jenkins/jenkins-coverage.tester.js +++ b/services/jenkins/jenkins-coverage.tester.js @@ -10,8 +10,8 @@ export const t = await createServiceTester() t.create('jacoco: job found') .get( `/jacoco.json?jobUrl=${encodeURIComponent( - 'https://wso2.org/jenkins/view/All%20Builds/job/archetypes' - )}` + 'https://wso2.org/jenkins/view/All%20Builds/job/archetypes', + )}`, ) .expectBadge({ label: 'coverage', message: isIntegerPercentage }) @@ -21,19 +21,19 @@ t.create('jacoco: job not found') t.create('cobertura: job not found') .get( - '/cobertura.json?jobUrl=https://jenkins.sqlalchemy.org/job/does-not-exist' + '/cobertura.json?jobUrl=https://jenkins.sqlalchemy.org/job/does-not-exist', ) .expectBadge({ label: 'coverage', message: 'job or coverage not found' }) t.create('cobertura: job found') .get( - '/cobertura.json?jobUrl=https://jenkins.sqlalchemy.org/job/alembic_coverage' + '/cobertura.json?jobUrl=https://jenkins.sqlalchemy.org/job/alembic_coverage', ) .expectBadge({ label: 'coverage', message: isIntegerPercentage }) t.create('code coverage API v1: job not found') .get( - '/apiv1.json?jobUrl=https://jenkins.library.illinois.edu/job/does-not-exist' + '/apiv1.json?jobUrl=https://jenkins.library.illinois.edu/job/does-not-exist', ) .expectBadge({ label: 'coverage', message: 'job or coverage not found' }) @@ -54,26 +54,26 @@ const coverageApiV1Response = { t.create('code coverage API v1: job found') .get( - '/apiv1.json?jobUrl=http://loneraver.duckdns.org:8082/job/github/job/VisVid/job/master' + '/apiv1.json?jobUrl=http://loneraver.duckdns.org:8082/job/github/job/VisVid/job/master', ) .intercept(nock => nock( - 'http://loneraver.duckdns.org:8082/job/github/job/VisVid/job/master/lastCompletedBuild' + 'http://loneraver.duckdns.org:8082/job/github/job/VisVid/job/master/lastCompletedBuild', ) .get('/coverage/result/api/json') .query(true) - .reply(200, coverageApiV1Response) + .reply(200, coverageApiV1Response), ) .expectBadge({ label: 'coverage', message: isIntegerPercentage }) t.create('code coverage API v4+: job not found') .get( - '/apiv4.json?jobUrl=https://jenkins.library.illinois.edu/job/does-not-exist' + '/apiv4.json?jobUrl=https://jenkins.library.illinois.edu/job/does-not-exist', ) .expectBadge({ label: 'coverage', message: 'job or coverage not found' }) t.create('code coverage API v4+: job found') .get( - '/apiv4.json?jobUrl=https://jenkins.mm12.xyz/jenkins/job/nmfu/job/master' + '/apiv4.json?jobUrl=https://jenkins.mm12.xyz/jenkins/job/nmfu/job/master', ) .expectBadge({ label: 'coverage', message: isIntegerPercentage }) diff --git a/services/jenkins/jenkins-plugin-version.tester.js b/services/jenkins/jenkins-plugin-version.tester.js index f9c4d2dfc946086a1fe5b13bc99e97603e6be560..da1eee8349d7989dc4aab527a6482506b9fba83b 100644 --- a/services/jenkins/jenkins-plugin-version.tester.js +++ b/services/jenkins/jenkins-plugin-version.tester.js @@ -12,7 +12,7 @@ t.create('latest version') .intercept(nock => nock('https://updates.jenkins-ci.org') .get('/current/update-center.actual.json') - .reply(200, { plugins: { blueocean: { version: '1.1.6' } } }) + .reply(200, { plugins: { blueocean: { version: '1.1.6' } } }), ) .expectBadge({ label: 'plugin', @@ -24,7 +24,7 @@ t.create('version 0') .intercept(nock => nock('https://updates.jenkins-ci.org') .get('/current/update-center.actual.json') - .reply(200, { plugins: { blueocean: { version: '0' } } }) + .reply(200, { plugins: { blueocean: { version: '0' } } }), ) .expectBadge({ label: 'plugin', @@ -36,6 +36,6 @@ t.create('inexistent artifact') .intercept(nock => nock('https://updates.jenkins-ci.org') .get('/current/update-center.actual.json') - .reply(200, { plugins: { blueocean: { version: '1.1.6' } } }) + .reply(200, { plugins: { blueocean: { version: '1.1.6' } } }), ) .expectBadge({ label: 'plugin', message: 'plugin not found' }) diff --git a/services/jenkins/jenkins-tests-redirector.tester.js b/services/jenkins/jenkins-tests-redirector.tester.js index 837c9f4b1394d5f0f616574983fcd92fd8b371b3..29ec83d0d44aa4ce3bfe8ab03f937bed43716769 100644 --- a/services/jenkins/jenkins-tests-redirector.tester.js +++ b/services/jenkins/jenkins-tests-redirector.tester.js @@ -8,20 +8,20 @@ export const t = new ServiceTester({ t.create('old tests prefix + job url in path') .get( - '/t/https/jenkins.qa.ubuntu.com/view/Trusty/view/Smoke Testing/job/trusty-touch-flo-smoke-daily.svg' + '/t/https/jenkins.qa.ubuntu.com/view/Trusty/view/Smoke Testing/job/trusty-touch-flo-smoke-daily.svg', ) .expectRedirect( `/jenkins/tests.svg?jobUrl=${encodeURIComponent( - 'https://jenkins.qa.ubuntu.com/view/Trusty/view/Smoke Testing/job/trusty-touch-flo-smoke-daily' - )}` + 'https://jenkins.qa.ubuntu.com/view/Trusty/view/Smoke Testing/job/trusty-touch-flo-smoke-daily', + )}`, ) t.create('new tests prefix + job url in path') .get( - '/tests/https/jenkins.qa.ubuntu.com/view/Trusty/view/Smoke Testing/job/trusty-touch-flo-smoke-daily.svg' + '/tests/https/jenkins.qa.ubuntu.com/view/Trusty/view/Smoke Testing/job/trusty-touch-flo-smoke-daily.svg', ) .expectRedirect( `/jenkins/tests.svg?jobUrl=${encodeURIComponent( - 'https://jenkins.qa.ubuntu.com/view/Trusty/view/Smoke Testing/job/trusty-touch-flo-smoke-daily' - )}` + 'https://jenkins.qa.ubuntu.com/view/Trusty/view/Smoke Testing/job/trusty-touch-flo-smoke-daily', + )}`, ) diff --git a/services/jenkins/jenkins-tests.service.js b/services/jenkins/jenkins-tests.service.js index 810cf614bb12c9d6d08322dc644ea7db066761e8..667e70534b90b69ed8ddb75910f318bf68fffb76 100644 --- a/services/jenkins/jenkins-tests.service.js +++ b/services/jenkins/jenkins-tests.service.js @@ -28,7 +28,7 @@ const schema = Joi.object({ totalCount: optionalNonNegativeInteger, failCount: optionalNonNegativeInteger, skipCount: optionalNonNegativeInteger, - }) + }), ) .required(), }).required() @@ -111,13 +111,13 @@ export default class JenkinsTests extends JenkinsBase { passed_label: passedLabel, failed_label: failedLabel, skipped_label: skippedLabel, - } + }, ) { const json = await this.fetch({ url: buildUrl({ jobUrl }), schema, searchParams: buildTreeParamQueryString( - 'actions[failCount,skipCount,totalCount]' + 'actions[failCount,skipCount,totalCount]', ), }) const { passed, failed, skipped, total } = this.transform({ json }) diff --git a/services/jetbrains/jetbrains-downloads.service.js b/services/jetbrains/jetbrains-downloads.service.js index 7db2403e28ca239868c644571f2064e4bfe86b0a..5d2bcf6962df41205f1689a67fa985c2f1433ecd 100644 --- a/services/jetbrains/jetbrains-downloads.service.js +++ b/services/jetbrains/jetbrains-downloads.service.js @@ -11,7 +11,7 @@ const intelliJschema = Joi.object({ .items( Joi.object({ '@_downloads': nonNegativeInteger, - }) + }), ) .single() .required(), @@ -54,7 +54,7 @@ export default class JetbrainsDownloads extends JetbrainsBase { const jetbrainsPluginData = await this._requestJson({ schema: jetbrainsSchema, url: `https://plugins.jetbrains.com/api/plugins/${this.constructor._cleanPluginId( - pluginId + pluginId, )}`, httpErrors: { 400: 'not found' }, }) diff --git a/services/jetbrains/jetbrains-downloads.tester.js b/services/jetbrains/jetbrains-downloads.tester.js index 06c30636474e289cb9371251443ebe45c3b36e69..03090600936dd739721328dcbfdd9a34d7b99122 100644 --- a/services/jetbrains/jetbrains-downloads.tester.js +++ b/services/jetbrains/jetbrains-downloads.tester.js @@ -19,7 +19,7 @@ t.create('downloads (numeric id)') .intercept(nock => nock('https://plugins.jetbrains.com') .get('/api/plugins/9435') - .reply(200, { downloads: 2 }) + .reply(200, { downloads: 2 }), ) .expectBadge({ label: 'downloads', message: '2' }) @@ -36,11 +36,11 @@ t.create('downloads (string id)') <category name="Code editing"> <idea-plugin downloads="2" size="13159" date="1485601807000" url=""></idea-plugin> </category> - </plugin-repository>` + </plugin-repository>`, ), { 'Content-Type': 'text/xml;charset=UTF-8', - } + }, ) .expectBadge({ label: 'downloads', message: '2' }) diff --git a/services/jetbrains/jetbrains-rating.service.js b/services/jetbrains/jetbrains-rating.service.js index 5c3fd2d7573faac8b79a6b08874de96f6ccf09c5..3649ecd95086c97a05ba870edfbfeb20a5bcb72c 100644 --- a/services/jetbrains/jetbrains-rating.service.js +++ b/services/jetbrains/jetbrains-rating.service.js @@ -14,7 +14,7 @@ const intelliJschema = Joi.object({ .items( Joi.object({ rating: Joi.string().required(), - }) + }), ) .single() .required(), @@ -90,7 +90,7 @@ export default class JetbrainsRating extends JetbrainsBase { const jetbrainsPluginData = await this._requestJson({ schema: jetbrainsSchema, url: `https://plugins.jetbrains.com/api/plugins/${this.constructor._cleanPluginId( - pluginId + pluginId, )}/rating`, httpErrors: { 400: 'not found' }, }) diff --git a/services/jetbrains/jetbrains-rating.tester.js b/services/jetbrains/jetbrains-rating.tester.js index 3992456553a2b05ae72d86567103af6200e05011..14cdc2b222c4ee92a2a1b99c219a5748f626526d 100644 --- a/services/jetbrains/jetbrains-rating.tester.js +++ b/services/jetbrains/jetbrains-rating.tester.js @@ -64,7 +64,7 @@ t.create('rating number (numeric id)') }, meanVotes: 2, meanRating: 4.15669, - }) + }), ) .expectBadge({ label: 'rating', message: '4.6/5' }) @@ -77,7 +77,7 @@ t.create('rating number for "no vote" plugin (numeric id)') votes: {}, meanVotes: 2, meanRating: 4.15669, - }) + }), ) .expectBadge({ label: 'rating', message: 'No Plugin Ratings' }) @@ -87,7 +87,7 @@ t.create('rating number (string id)') nock => nock('https://plugins.jetbrains.com') .get( - '/plugins/list?pluginId=com.chriscarini.jetbrains.jetbrains-auto-power-saver' + '/plugins/list?pluginId=com.chriscarini.jetbrains.jetbrains-auto-power-saver', ) .reply( 200, @@ -98,11 +98,11 @@ t.create('rating number (string id)') <rating>4.4848</rating> </idea-plugin> </category> - </plugin-repository>` + </plugin-repository>`, ), { 'Content-Type': 'text/xml;charset=UTF-8', - } + }, ) .expectBadge({ label: 'rating', message: '4.5/5' }) @@ -118,7 +118,7 @@ t.create('rating stars (numeric id)') }, meanVotes: 2, meanRating: 4.15669, - }) + }), ) .expectBadge({ label: 'rating', message: '★★★★½' }) @@ -128,7 +128,7 @@ t.create('rating stars (string id)') nock => nock('https://plugins.jetbrains.com') .get( - '/plugins/list?pluginId=com.chriscarini.jetbrains.jetbrains-auto-power-saver' + '/plugins/list?pluginId=com.chriscarini.jetbrains.jetbrains-auto-power-saver', ) .reply( 200, @@ -139,10 +139,10 @@ t.create('rating stars (string id)') <rating>4.4848</rating> </idea-plugin> </category> - </plugin-repository>` + </plugin-repository>`, ), { 'Content-Type': 'text/xml;charset=UTF-8', - } + }, ) .expectBadge({ label: 'rating', message: '★★★★½' }) diff --git a/services/jetbrains/jetbrains-version.service.js b/services/jetbrains/jetbrains-version.service.js index dad18b10a9b3ef7caeafee14d3708b22cdcb35a7..252f611bef647bea876103dceba701d56f976314 100644 --- a/services/jetbrains/jetbrains-version.service.js +++ b/services/jetbrains/jetbrains-version.service.js @@ -10,7 +10,7 @@ const intelliJschema = Joi.object({ .items( Joi.object({ version: Joi.string().required(), - }) + }), ) .single() .required(), @@ -23,7 +23,7 @@ const jetbrainsSchema = Joi.array() .items( Joi.object({ version: Joi.string().required(), - }).required() + }).required(), ) .required() @@ -65,7 +65,7 @@ export default class JetbrainsVersion extends JetbrainsBase { const jetbrainsPluginData = await this._requestJson({ schema: jetbrainsSchema, url: `https://plugins.jetbrains.com/api/plugins/${this.constructor._cleanPluginId( - pluginId + pluginId, )}/updates`, httpErrors: { 400: 'not found' }, }) diff --git a/services/jetbrains/jetbrains-version.tester.js b/services/jetbrains/jetbrains-version.tester.js index 5a4d477e62cd6e64d1e3e2a4c4afb6af0f68156e..8c2dbf962be4f99a3578d87be38282ec66fa09c3 100644 --- a/services/jetbrains/jetbrains-version.tester.js +++ b/services/jetbrains/jetbrains-version.tester.js @@ -26,7 +26,7 @@ t.create('version (numeric id)') .intercept(nock => nock('https://plugins.jetbrains.com') .get('/api/plugins/9435/updates') - .reply(200, [{ version: '1.0' }]) + .reply(200, [{ version: '1.0' }]), ) .expectBadge({ label: 'jetbrains plugin', message: 'v1.0' }) @@ -45,11 +45,11 @@ t.create('version (strong id)') <version>1.0</version> </idea-plugin> </category> - </plugin-repository>` + </plugin-repository>`, ), { 'Content-Type': 'text/xml;charset=UTF-8', - } + }, ) .expectBadge({ label: 'jetbrains plugin', message: 'v1.0' }) diff --git a/services/jira/jira-issue-redirect.tester.js b/services/jira/jira-issue-redirect.tester.js index b414839c47ac3bbf54660fc26af1194dc6b4c2fc..ad9585bf47871252629e5ad105894b84eb5adc2e 100644 --- a/services/jira/jira-issue-redirect.tester.js +++ b/services/jira/jira-issue-redirect.tester.js @@ -10,6 +10,6 @@ t.create('jira issue') .get('/https/issues.apache.org/jira/kafka-2896.svg') .expectRedirect( `/jira/issue/kafka-2896.svg?baseUrl=${encodeURIComponent( - 'https://issues.apache.org/jira' - )}` + 'https://issues.apache.org/jira', + )}`, ) diff --git a/services/jira/jira-issue.service.js b/services/jira/jira-issue.service.js index 609c81dd1df1193252d23fb1c14aa6bafcb0ae34..b35b864dfbaec47dd28776174646f17740ed9d85 100644 --- a/services/jira/jira-issue.service.js +++ b/services/jira/jira-issue.service.js @@ -76,7 +76,7 @@ export default class JiraIssue extends BaseJsonService { schema, url: `${baseUrl}/rest/api/2/issue/${encodeURIComponent(issueKey)}`, httpErrors: { 404: 'issue not found' }, - }) + }), ) const issueStatus = json.fields.status diff --git a/services/jira/jira-issue.spec.js b/services/jira/jira-issue.spec.js index 10ff23efd37625c5662b0bd15644edcc8d8145fb..4d3cbfdd3911fcc69c95d4539151049d0bd36561 100644 --- a/services/jira/jira-issue.spec.js +++ b/services/jira/jira-issue.spec.js @@ -22,8 +22,8 @@ describe('JiraIssue', function () { { issueKey: 'secure-234', }, - { baseUrl: `https://${host}` } - ) + { baseUrl: `https://${host}` }, + ), ).to.deep.equal({ label: 'secure-234', message: 'in progress', diff --git a/services/jira/jira-issue.tester.js b/services/jira/jira-issue.tester.js index faab0a4ebbcfc2c4cb436cef2db1df02a60011c1..d76028b3ee3c64a91172b1381cc806d7b70776d3 100644 --- a/services/jira/jira-issue.tester.js +++ b/services/jira/jira-issue.tester.js @@ -20,7 +20,7 @@ t.create('no status color') name: 'pending', }, }, - }) + }), ) .expectBadge({ label: 'foo-123', @@ -42,7 +42,7 @@ t.create('green status color') }, }, }, - }) + }), ) .expectBadge({ label: 'bar-345', @@ -64,7 +64,7 @@ t.create('medium-gray status color') }, }, }, - }) + }), ) .expectBadge({ label: 'abc-123', @@ -86,7 +86,7 @@ t.create('yellow status color') }, }, }, - }) + }), ) .expectBadge({ label: 'test-001', @@ -108,7 +108,7 @@ t.create('brown status color') }, }, }, - }) + }), ) .expectBadge({ label: 'zzz-789', @@ -130,7 +130,7 @@ t.create('warm-red status color') }, }, }, - }) + }), ) .expectBadge({ label: 'fire-321', @@ -152,7 +152,7 @@ t.create('blue-gray status color') }, }, }, - }) + }), ) .expectBadge({ label: 'sky-775', diff --git a/services/jira/jira-sprint-redirect.tester.js b/services/jira/jira-sprint-redirect.tester.js index 86c417106a0e6d498156202bc677052e6ba05976..5fb609d02728798fb1291d62880d5cf099d2e89d 100644 --- a/services/jira/jira-sprint-redirect.tester.js +++ b/services/jira/jira-sprint-redirect.tester.js @@ -10,6 +10,6 @@ t.create('jira sprint') .get('/https/jira.spring.io/94.svg') .expectRedirect( `/jira/sprint/94.svg?baseUrl=${encodeURIComponent( - 'https://jira.spring.io' - )}` + 'https://jira.spring.io', + )}`, ) diff --git a/services/jira/jira-sprint.service.js b/services/jira/jira-sprint.service.js index 40a6bc85f69c9971a437ffad5f74b99684b2962a..64f2403ce7af705be2e7f70c6c4e78ff0b3c4d8e 100644 --- a/services/jira/jira-sprint.service.js +++ b/services/jira/jira-sprint.service.js @@ -17,7 +17,7 @@ const schema = Joi.object({ name: Joi.string(), }).allow(null), }).required(), - }) + }), ) .required(), }).required() @@ -94,7 +94,7 @@ export default class JiraSprint extends BaseJsonService { 400: 'sprint not found', 404: 'sprint not found', }, - }) + }), ) const numTotalIssues = json.total diff --git a/services/jira/jira-sprint.spec.js b/services/jira/jira-sprint.spec.js index 8bcead5bb2e27ed09dd562a222288630d69c8fc9..33a647ed7c371d1954f8336a7a056aa73a3568f0 100644 --- a/services/jira/jira-sprint.spec.js +++ b/services/jira/jira-sprint.spec.js @@ -36,8 +36,8 @@ describe('JiraSprint', function () { { sprintId, }, - { baseUrl: `https://${host}/jira` } - ) + { baseUrl: `https://${host}/jira` }, + ), ).to.deep.equal({ label: 'completion', message: '50%', diff --git a/services/jira/jira-sprint.tester.js b/services/jira/jira-sprint.tester.js index 997b3aaf55c2f91d996b716391fb75321cc0fc6a..eb2d568e78e54a89a86c9a98294448058d10655f 100644 --- a/services/jira/jira-sprint.tester.js +++ b/services/jira/jira-sprint.tester.js @@ -38,7 +38,7 @@ t.create('100% completion') }, }, ], - }) + }), ) .expectBadge({ label: 'completion', @@ -63,7 +63,7 @@ t.create('0% completion') }, }, ], - }) + }), ) .expectBadge({ label: 'completion', @@ -80,7 +80,7 @@ t.create('no issues in sprint') .reply(200, { total: 0, issues: [], - }) + }), ) .expectBadge({ label: 'completion', @@ -110,7 +110,7 @@ t.create('issue with null resolution value') }, }, ], - }) + }), ) .expectBadge({ label: 'completion', diff --git a/services/jsdelivr/jsdelivr-hits-github.tester.js b/services/jsdelivr/jsdelivr-hits-github.tester.js index 48231e1fd84363a19bb9ba958cb00330f5b93814..319b3ef99f6856adc62a0dd95b3b3981a32a3290 100644 --- a/services/jsdelivr/jsdelivr-hits-github.tester.js +++ b/services/jsdelivr/jsdelivr-hits-github.tester.js @@ -8,7 +8,7 @@ export const t = await createServiceTester() const isDownloadsOverTimePeriod = Joi.alternatives().try( isMetricOverTimePeriod, - isZeroOverTimePeriod + isZeroOverTimePeriod, ) t.create('jquery/jquery hits/day') diff --git a/services/jsdelivr/jsdelivr-hits-npm.tester.js b/services/jsdelivr/jsdelivr-hits-npm.tester.js index 2c41ed9fe828bf96f9dc9b85f5746b446dd71fda..747c08ef464b91638314e9cd4f863e84920e431b 100644 --- a/services/jsdelivr/jsdelivr-hits-npm.tester.js +++ b/services/jsdelivr/jsdelivr-hits-npm.tester.js @@ -8,7 +8,7 @@ export const t = await createServiceTester() const isDownloadsOverTimePeriod = Joi.alternatives().try( isMetricOverTimePeriod, - isZeroOverTimePeriod + isZeroOverTimePeriod, ) t.create('jquery hits/day').timeout(10000).get('/hd/ky.json').expectBadge({ diff --git a/services/keybase/keybase-btc.service.js b/services/keybase/keybase-btc.service.js index f761169f2186aa823f30705ea68d10fed6d887ea..1ac8d87658a4b44ef60866bf38f29e20818d673d 100644 --- a/services/keybase/keybase-btc.service.js +++ b/services/keybase/keybase-btc.service.js @@ -13,14 +13,14 @@ const bitcoinAddressSchema = Joi.object({ bitcoin: Joi.array().items( Joi.object({ address: Joi.string().required(), - }).required() + }).required(), ), }) .required() .allow(null), }) .required() - .allow(null) + .allow(null), ) .min(0) .max(1), diff --git a/services/keybase/keybase-pgp.service.js b/services/keybase/keybase-pgp.service.js index 5f585a8d73d10055075c6392cb378fe1bc1fa6b0..a6330ea373f004e0ef7bedb6720ec544296cdaea 100644 --- a/services/keybase/keybase-pgp.service.js +++ b/services/keybase/keybase-pgp.service.js @@ -16,7 +16,7 @@ const keyFingerprintSchema = Joi.object({ }, }) .required() - .allow(null) + .allow(null), ) .min(0) .max(1), diff --git a/services/keybase/keybase-xlm.service.js b/services/keybase/keybase-xlm.service.js index 1cde6d6663e6ec8635877270762e06572ef2ad7f..11fe7a5ca530ef45ae653c00915cc7add061c608 100644 --- a/services/keybase/keybase-xlm.service.js +++ b/services/keybase/keybase-xlm.service.js @@ -18,7 +18,7 @@ const stellarAddressSchema = Joi.object({ }).required(), }) .required() - .allow(null) + .allow(null), ) .min(0) .max(1), diff --git a/services/keybase/keybase-zec.service.js b/services/keybase/keybase-zec.service.js index 8cb57461452aed0cd213643eb1fd1df22b66acd3..d8fdfd7236c1f35e0133570f13fb08dbb76d8a3c 100644 --- a/services/keybase/keybase-zec.service.js +++ b/services/keybase/keybase-zec.service.js @@ -13,14 +13,14 @@ const zcachAddressSchema = Joi.object({ zcash: Joi.array().items( Joi.object({ address: Joi.string().required(), - }).required() + }).required(), ), }) .required() .allow(null), }) .required() - .allow(null) + .allow(null), ) .min(0) .max(1), diff --git a/services/liberapay/liberapay-base.js b/services/liberapay/liberapay-base.js index a044844150ccd4df1ecb1c16039ba655b0889c2f..1603a1a3a1f1189407793179bcc5f1c5ad43261d 100644 --- a/services/liberapay/liberapay-base.js +++ b/services/liberapay/liberapay-base.js @@ -28,7 +28,7 @@ const schema = Joi.object({ }).required() const isCurrencyOverTime = Joi.string().regex( - /^([0-9]*[1-9][0-9]*(\.[0-9]+)?|[0]+\.[0-9]*[1-9][0-9]*)[ A-Za-z]{4}\/week/ + /^([0-9]*[1-9][0-9]*(\.[0-9]+)?|[0]+\.[0-9]*[1-9][0-9]*)[ A-Za-z]{4}\/week/, ) function renderCurrencyBadge({ label, amount, currency }) { diff --git a/services/liberapay/liberapay-gives.tester.js b/services/liberapay/liberapay-gives.tester.js index daf77a689f0c34c00d04a7e94a8a8c65c92a46b2..1231fd632f88faa646032f5225efb37503f827c8 100644 --- a/services/liberapay/liberapay-gives.tester.js +++ b/services/liberapay/liberapay-gives.tester.js @@ -20,7 +20,7 @@ t.create('Giving (missing goal key)') npatrons: 0, giving: { amount: '3.71', currency: 'EUR' }, receiving: null, - }) + }), ) .expectBadge({ label: 'gives', message: isCurrencyOverTime }) @@ -32,6 +32,6 @@ t.create('Giving (null)') giving: null, receiving: null, goal: null, - }) + }), ) .expectBadge({ label: 'liberapay', message: 'no public giving stats' }) diff --git a/services/liberapay/liberapay-goal.spec.js b/services/liberapay/liberapay-goal.spec.js index ace4d40c45576a73ae084417b1e373e7ef3adf37..d0f38677514ee6e3d380fed4313bf4ee2ff53f23 100644 --- a/services/liberapay/liberapay-goal.spec.js +++ b/services/liberapay/liberapay-goal.spec.js @@ -15,7 +15,7 @@ describe('LiberapayGoal', function () { it('throws InvalidResponse on missing goals', function () { expect(() => - LiberapayGoal.prototype.transform({ goal: null, receiving: null }) + LiberapayGoal.prototype.transform({ goal: null, receiving: null }), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'no public goals') diff --git a/services/liberapay/liberapay-goal.tester.js b/services/liberapay/liberapay-goal.tester.js index 518a84b0041077cf76a03d3316735e029305d990..e8ae6433b1dc1761df3679e5eb7674b0b12fabc8 100644 --- a/services/liberapay/liberapay-goal.tester.js +++ b/services/liberapay/liberapay-goal.tester.js @@ -14,7 +14,7 @@ t.create('Goal (missing goal key)') npatrons: 0, giving: null, receiving: null, - }) + }), ) .expectBadge({ label: 'liberapay', message: 'no public goals' }) diff --git a/services/liberapay/liberapay-receives.tester.js b/services/liberapay/liberapay-receives.tester.js index 17988abc7c7a63a71908d751665934b1695adda8..765f57e6a1c3b5df9f21587fecbcaa96a05b626c 100644 --- a/services/liberapay/liberapay-receives.tester.js +++ b/services/liberapay/liberapay-receives.tester.js @@ -19,6 +19,6 @@ t.create('Receiving (null)') giving: null, receiving: null, goal: null, - }) + }), ) .expectBadge({ label: 'liberapay', message: 'no public receiving stats' }) diff --git a/services/librariesio/librariesio-api-provider.spec.js b/services/librariesio/librariesio-api-provider.spec.js index 45b8be2acd58e743353c5db8d8d9abbbc435f879..52841d5d2dad8c1badb7cbe4baaf939bae184a00 100644 --- a/services/librariesio/librariesio-api-provider.spec.js +++ b/services/librariesio/librariesio-api-provider.spec.js @@ -55,7 +55,7 @@ describe('LibrariesIoApiProvider', function () { } catch (e) { expect(e).to.be.an.instanceof(ImproperlyConfigured) expect(e.prettyMessage).to.equal( - 'Unable to select next Libraries.io token from pool' + 'Unable to select next Libraries.io token from pool', ) } }) @@ -80,7 +80,7 @@ describe('LibrariesIoApiProvider', function () { expect(token.update).to.have.been.calledWith( remaining, - nextReset * 1000 + tickTime + nextReset * 1000 + tickTime, ) expect(token.invalidate).not.to.have.been.called }) @@ -121,7 +121,7 @@ describe('LibrariesIoApiProvider', function () { it('should throw an exception', async function () { return expect( - provider.fetch(mockRequest, '/npm/badge-maker', {}) + provider.fetch(mockRequest, '/npm/badge-maker', {}), ).to.be.rejectedWith(Error, 'connection timeout') }) }) diff --git a/services/librariesio/librariesio-base.js b/services/librariesio/librariesio-base.js index 850db1e63be8c81ed3d62256cc10b5e4482d69d5..8d221c0a35051dbb48f7cef7475021e2d8dad333 100644 --- a/services/librariesio/librariesio-base.js +++ b/services/librariesio/librariesio-base.js @@ -16,7 +16,7 @@ export default class LibrariesIoBase extends BaseJsonService { const { requestFetcher, librariesIoApiProvider } = context this._requestFetcher = librariesIoApiProvider.fetch.bind( librariesIoApiProvider, - requestFetcher + requestFetcher, ) } diff --git a/services/librariesio/librariesio-dependencies.service.js b/services/librariesio/librariesio-dependencies.service.js index 5e12a480332a5c4cfcdb56e2b6aacc578bc15a8f..10ed50202b6cc75dc83ae13a2b596d6c5455e330 100644 --- a/services/librariesio/librariesio-dependencies.service.js +++ b/services/librariesio/librariesio-dependencies.service.js @@ -11,7 +11,7 @@ const schema = Joi.object({ Joi.object({ deprecated: Joi.boolean().allow(null).required(), outdated: Joi.boolean().allow(null).required(), - }) + }), ) .default([]), }).required() @@ -87,7 +87,7 @@ class LibrariesIoProjectDependencies extends LibrariesIoBase { const url = `/${encodeURIComponent(platform)}/${ scope ? encodeURIComponent(`${scope}/`) : '' }${encodeURIComponent(packageName)}/${encodeURIComponent( - version + version, )}/dependencies` const json = await this._requestJson({ url, @@ -122,7 +122,7 @@ class LibrariesIoRepoDependencies extends LibrariesIoBase { async handle({ user, repo }) { const url = `/github/${encodeURIComponent(user)}/${encodeURIComponent( - repo + repo, )}/dependencies` const json = await this._requestJson({ url, diff --git a/services/librariesio/librariesio-sourcerank.spec.js b/services/librariesio/librariesio-sourcerank.spec.js index 3ddb815b160252c96b7bfdfe66dfbda15bf06fed..6e48f675dce8479d40719fe6e106290424633900 100644 --- a/services/librariesio/librariesio-sourcerank.spec.js +++ b/services/librariesio/librariesio-sourcerank.spec.js @@ -40,8 +40,8 @@ describe('LibrariesIoSourcerank', function () { { platform: 'npm', packageName: 'badge-maker', - } - ) + }, + ), ).to.deep.equal({ message: 100, color: 'brightgreen', diff --git a/services/localizely/localizely.service.js b/services/localizely/localizely.service.js index 1dc13f94780212b1b14fe230c31b5affd134c702..9d0019845722c765ff59a5764440a8be48bcf83e 100644 --- a/services/localizely/localizely.service.js +++ b/services/localizely/localizely.service.js @@ -39,7 +39,7 @@ const schema = Joi.object({ strings: Joi.number().required(), reviewed: Joi.number().required(), reviewedProgress: Joi.number().required(), - }) + }), ) .required(), }).required() @@ -136,7 +136,7 @@ export default class Localizely extends BaseJsonService { const json = await this.fetch({ projectId, branch, apiToken }) const { langName, reviewedProgress } = this.constructor.transform( json, - languageCode + languageCode, ) return this.constructor.render({ langName, reviewedProgress }) diff --git a/services/localizely/localizely.tester.js b/services/localizely/localizely.tester.js index 9f996e287de166ea92bf784c0b85df39d48d215e..39eb9f0fbf1123a41ebef5853627c5b96cb31ab6 100644 --- a/services/localizely/localizely.tester.js +++ b/services/localizely/localizely.tester.js @@ -4,19 +4,19 @@ export const t = await createServiceTester() t.create('Overall progress') .get( - '/5cc34208-0418-40b1-8353-acc70c95f802.json?token=0f4d5e31a44f48dcbab966c52cfb0a67c5f1982186c14b85ab389a031dbc225a' + '/5cc34208-0418-40b1-8353-acc70c95f802.json?token=0f4d5e31a44f48dcbab966c52cfb0a67c5f1982186c14b85ab389a031dbc225a', ) .expectBadge({ label: 'localized', message: isIntegerPercentage }) t.create('Overall progress on specific branch') .get( - '/5cc34208-0418-40b1-8353-acc70c95f802/Version_1.0.json?token=0f4d5e31a44f48dcbab966c52cfb0a67c5f1982186c14b85ab389a031dbc225a' + '/5cc34208-0418-40b1-8353-acc70c95f802/Version_1.0.json?token=0f4d5e31a44f48dcbab966c52cfb0a67c5f1982186c14b85ab389a031dbc225a', ) .expectBadge({ label: 'localized', message: isIntegerPercentage }) t.create('Overall progress with invalid token') .get( - '/1349592f-8d05-4317-9f46-bddc5def11fe/main.json?token=312045388bfb4d2591cfe1d60868ea52b63ac6daa6dc406b9bab682f4d9ab715' + '/1349592f-8d05-4317-9f46-bddc5def11fe/main.json?token=312045388bfb4d2591cfe1d60868ea52b63ac6daa6dc406b9bab682f4d9ab715', ) .intercept(nock => nock('https://api.localizely.com', { @@ -30,25 +30,25 @@ t.create('Overall progress with invalid token') .reply(403, { errorCode: 'forbidden', errorMessage: 'Tried to access unauthorized project', - }) + }), ) .expectBadge({ label: 'localized', message: 'not authorized for project' }) t.create('Language progress') .get( - '/5cc34208-0418-40b1-8353-acc70c95f802.json?languageCode=en-US&token=0f4d5e31a44f48dcbab966c52cfb0a67c5f1982186c14b85ab389a031dbc225a' + '/5cc34208-0418-40b1-8353-acc70c95f802.json?languageCode=en-US&token=0f4d5e31a44f48dcbab966c52cfb0a67c5f1982186c14b85ab389a031dbc225a', ) .expectBadge({ label: 'English (US)', message: isIntegerPercentage }) t.create('Language progress on specific branch') .get( - '/5cc34208-0418-40b1-8353-acc70c95f802/Version_1.0.json?languageCode=en-US&token=0f4d5e31a44f48dcbab966c52cfb0a67c5f1982186c14b85ab389a031dbc225a' + '/5cc34208-0418-40b1-8353-acc70c95f802/Version_1.0.json?languageCode=en-US&token=0f4d5e31a44f48dcbab966c52cfb0a67c5f1982186c14b85ab389a031dbc225a', ) .expectBadge({ label: 'English (US)', message: isIntegerPercentage }) t.create('Language progress with invalid token') .get( - '/1349592f-8d05-4317-9f46-bddc5def11fe/main.json?languageCode=en-US&token=312045388bfb4d2591cfe1d60868ea52b63ac6daa6dc406b9bab682f4d9ab715' + '/1349592f-8d05-4317-9f46-bddc5def11fe/main.json?languageCode=en-US&token=312045388bfb4d2591cfe1d60868ea52b63ac6daa6dc406b9bab682f4d9ab715', ) .intercept(nock => nock('https://api.localizely.com', { @@ -62,13 +62,13 @@ t.create('Language progress with invalid token') .reply(403, { errorCode: 'forbidden', errorMessage: 'Tried to access unauthorized project', - }) + }), ) .expectBadge({ label: 'localized', message: 'not authorized for project' }) t.create('Language progress for unsupported language code') .get( - '/1349592f-8d05-4317-9f46-bddc5def11fe/main.json?languageCode=fr&token=312045388bfb4d2591cfe1d60868ea52b63ac6daa6dc406b9bab682f4d9ab715' + '/1349592f-8d05-4317-9f46-bddc5def11fe/main.json?languageCode=fr&token=312045388bfb4d2591cfe1d60868ea52b63ac6daa6dc406b9bab682f4d9ab715', ) .intercept(nock => nock('https://api.localizely.com', { @@ -91,13 +91,13 @@ t.create('Language progress for unsupported language code') reviewedProgress: 85, }, ], - }) + }), ) .expectBadge({ label: 'localized', message: 'Unsupported language' }) t.create('Language progress for supported language code') .get( - '/1349592f-8d05-4317-9f46-bddc5def11fe/main.json?languageCode=en-US&token=312045388bfb4d2591cfe1d60868ea52b63ac6daa6dc406b9bab682f4d9ab715' + '/1349592f-8d05-4317-9f46-bddc5def11fe/main.json?languageCode=en-US&token=312045388bfb4d2591cfe1d60868ea52b63ac6daa6dc406b9bab682f4d9ab715', ) .intercept(nock => nock('https://api.localizely.com', { @@ -127,6 +127,6 @@ t.create('Language progress for supported language code') reviewedProgress: 60, }, ], - }) + }), ) .expectBadge({ label: 'English (US)', message: '60%' }) diff --git a/services/luarocks/luarocks.service.js b/services/luarocks/luarocks.service.js index 49d75fbe4b6e7553e509ba31faf52fde2ea9db32..15ed4501932e65fcbfadbacd858a3401ad45d141 100644 --- a/services/luarocks/luarocks.service.js +++ b/services/luarocks/luarocks.service.js @@ -7,7 +7,7 @@ const schema = Joi.object({ repository: Joi.object() .pattern( Joi.string(), - Joi.object().pattern(Joi.string(), Joi.array().strip()) + Joi.object().pattern(Joi.string(), Joi.array().strip()), ) .required(), }).required() @@ -57,7 +57,7 @@ export default class Luarocks extends BaseJsonService { async fetch({ user, moduleName }) { const { repository } = await this._requestJson({ url: `https://luarocks.org/manifests/${encodeURIComponent( - user + user, )}/manifest.json`, schema, httpErrors: { diff --git a/services/matrix/matrix.service.js b/services/matrix/matrix.service.js index 8371388e02d56b5739b5df289d90eb2791841508..ee455c239df0426b64fe50ff87b73ef453fceb05 100644 --- a/services/matrix/matrix.service.js +++ b/services/matrix/matrix.service.js @@ -22,7 +22,7 @@ const matrixStateSchema = Joi.array() type: Joi.string().required(), sender: Joi.string().required(), state_key: Joi.string().allow('').required(), - }) + }), ) .required() @@ -126,7 +126,7 @@ export default class Matrix extends BaseJsonService { async lookupRoomAlias({ host, roomAlias, accessToken }) { return this._requestJson({ url: `https://${host}/_matrix/client/r0/directory/room/${encodeURIComponent( - `#${roomAlias}` + `#${roomAlias}`, )}`, schema: matrixAliasLookupSchema, options: { @@ -164,7 +164,7 @@ export default class Matrix extends BaseJsonService { const lookup = await this.lookupRoomAlias({ host, roomAlias, accessToken }) const data = await this._requestJson({ url: `https://${host}/_matrix/client/r0/rooms/${encodeURIComponent( - lookup.room_id + lookup.room_id, )}/state`, schema: matrixStateSchema, options: { @@ -183,7 +183,7 @@ export default class Matrix extends BaseJsonService { m => m.type === 'm.room.member' && m.sender === m.state_key && - m.content.membership === 'join' + m.content.membership === 'join', ).length : 0 } diff --git a/services/matrix/matrix.tester.js b/services/matrix/matrix.tester.js index d87857497a2fc6a2202a8ea3867d9cedf0d78461..9bf0cadedf48b2efe30a543b0b2106a1f6f35067 100644 --- a/services/matrix/matrix.tester.js +++ b/services/matrix/matrix.tester.js @@ -11,19 +11,19 @@ t.create('get room state as guest') 200, JSON.stringify({ access_token: 'TOKEN', - }) + }), ) .get( - '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN' + '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN', ) .reply( 200, JSON.stringify({ room_id: 'ROOM:DUMMY.dumb', - }) + }), ) .get( - '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN' + '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN', ) .reply( 200, @@ -64,8 +64,8 @@ t.create('get room state as guest') membership: 'fake room', }, }, - ]) - ) + ]), + ), ) .expectBadge({ label: 'chat', @@ -83,26 +83,26 @@ t.create('get room state as member (backup method)') JSON.stringify({ errcode: 'M_GUEST_ACCESS_FORBIDDEN', error: 'Guest access not allowed', - }) + }), ) .post('/_matrix/client/r0/register') .reply( 200, JSON.stringify({ access_token: 'TOKEN', - }) + }), ) .get( - '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN' + '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN', ) .reply( 200, JSON.stringify({ room_id: 'ROOM:DUMMY.dumb', - }) + }), ) .get( - '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN' + '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN', ) .reply( 200, @@ -143,8 +143,8 @@ t.create('get room state as member (backup method)') membership: 'fake room', }, }, - ]) - ) + ]), + ), ) .expectBadge({ label: 'chat', @@ -170,27 +170,27 @@ t.create('non-world readable room') 200, JSON.stringify({ access_token: 'TOKEN', - }) + }), ) .get( - '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN' + '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN', ) .reply( 200, JSON.stringify({ room_id: 'ROOM:DUMMY.dumb', - }) + }), ) .get( - '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN' + '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN', ) .reply( 403, JSON.stringify({ errcode: 'M_GUEST_ACCESS_FORBIDDEN', error: 'Guest access not allowed', - }) - ) + }), + ), ) .expectBadge({ label: 'chat', @@ -207,18 +207,18 @@ t.create('invalid token') 200, JSON.stringify({ access_token: 'TOKEN', - }) + }), ) .get( - '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN' + '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN', ) .reply( 401, JSON.stringify({ errcode: 'M_UNKNOWN_TOKEN', error: 'Unrecognised access token.', - }) - ) + }), + ), ) .expectBadge({ label: 'chat', @@ -235,27 +235,27 @@ t.create('unknown request') 200, JSON.stringify({ access_token: 'TOKEN', - }) + }), ) .get( - '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN' + '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN', ) .reply( 200, JSON.stringify({ room_id: 'ROOM:DUMMY.dumb', - }) + }), ) .get( - '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN' + '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN', ) .reply( 400, JSON.stringify({ errcode: 'M_UNRECOGNIZED', error: 'Unrecognized request', - }) - ) + }), + ), ) .expectBadge({ label: 'chat', @@ -272,18 +272,18 @@ t.create('unknown alias') 200, JSON.stringify({ access_token: 'TOKEN', - }) + }), ) .get( - '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN' + '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN', ) .reply( 404, JSON.stringify({ errcode: 'M_NOT_FOUND', error: 'Room alias #ALIAS%3ADUMMY.dumb not found.', - }) - ) + }), + ), ) .expectBadge({ label: 'chat', @@ -306,19 +306,19 @@ t.create('server uses a custom port') 200, JSON.stringify({ access_token: 'TOKEN', - }) + }), ) .get( - '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb%3A5555?access_token=TOKEN' + '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb%3A5555?access_token=TOKEN', ) .reply( 200, JSON.stringify({ room_id: 'ROOM:DUMMY.dumb:5555', - }) + }), ) .get( - '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb%3A5555/state?access_token=TOKEN' + '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb%3A5555/state?access_token=TOKEN', ) .reply( 200, @@ -359,8 +359,8 @@ t.create('server uses a custom port') membership: 'fake room', }, }, - ]) - ) + ]), + ), ) .expectBadge({ label: 'chat', @@ -377,19 +377,19 @@ t.create('specify the homeserver fqdn') 200, JSON.stringify({ access_token: 'TOKEN', - }) + }), ) .get( - '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN' + '/_matrix/client/r0/directory/room/%23ALIAS%3ADUMMY.dumb?access_token=TOKEN', ) .reply( 200, JSON.stringify({ room_id: 'ROOM:DUMMY.dumb', - }) + }), ) .get( - '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN' + '/_matrix/client/r0/rooms/ROOM%3ADUMMY.dumb/state?access_token=TOKEN', ) .reply( 200, @@ -430,8 +430,8 @@ t.create('specify the homeserver fqdn') membership: 'fake room', }, }, - ]) - ) + ]), + ), ) .expectBadge({ label: 'chat', diff --git a/services/maven-central/maven-central.tester.js b/services/maven-central/maven-central.tester.js index ef09147dd50bbd7cb3c5b382bda9e9e2b3698274..00574f0beaff51a90d2b16b9b187afbebb383e52 100644 --- a/services/maven-central/maven-central.tester.js +++ b/services/maven-central/maven-central.tester.js @@ -5,14 +5,14 @@ t.create('latest version redirection') .get('/com.github.fabriziocucci/yacl4j.json') // http://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/ .expectRedirect( `/maven-metadata/v.json?label=maven-central&metadataUrl=${encodeURIComponent( - 'https://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/maven-metadata.xml' - )}` + 'https://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/maven-metadata.xml', + )}`, ) t.create('latest 0.8 version redirection') .get('/com.github.fabriziocucci/yacl4j/0.8.json') // http://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/ .expectRedirect( `/maven-metadata/v.json?label=maven-central&metadataUrl=${encodeURIComponent( - 'https://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/maven-metadata.xml' - )}&versionPrefix=0.8` + 'https://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/maven-metadata.xml', + )}&versionPrefix=0.8`, ) diff --git a/services/maven-metadata/maven-metadata-redirect.tester.js b/services/maven-metadata/maven-metadata-redirect.tester.js index ddd053e8bd1298bda96522b7e05fce71e624f6d5..0f3452497974093293b2aea312fe817d94d5c7bb 100644 --- a/services/maven-metadata/maven-metadata-redirect.tester.js +++ b/services/maven-metadata/maven-metadata-redirect.tester.js @@ -3,20 +3,20 @@ export const t = await createServiceTester() t.create('maven metadata (badge extension)') .get( - '/http/central.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml.json' + '/http/central.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml.json', ) .expectRedirect( `/maven-metadata/v.json?metadataUrl=${encodeURIComponent( - 'http://central.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml' - )}` + 'http://central.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml', + )}`, ) t.create('maven metadata (no badge extension)') .get( - '/http/central.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml' + '/http/central.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml', ) .expectRedirect( `/maven-metadata/v.svg?metadataUrl=${encodeURIComponent( - 'http://central.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml' - )}` + 'http://central.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml', + )}`, ) diff --git a/services/maven-metadata/maven-metadata.tester.js b/services/maven-metadata/maven-metadata.tester.js index 4115bd7cdd1365d55b465be5347b6cb1a29da251..6c6cc2af7cdb3435b6f26d08f05d5b21c790b69d 100644 --- a/services/maven-metadata/maven-metadata.tester.js +++ b/services/maven-metadata/maven-metadata.tester.js @@ -5,7 +5,7 @@ export const t = await createServiceTester() t.create('valid maven-metadata.xml uri') .get( - '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml' + '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/code/gson/gson/maven-metadata.xml', ) .expectBadge({ label: 'maven', @@ -14,7 +14,7 @@ t.create('valid maven-metadata.xml uri') t.create('with version prefix') .get( - '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/guava/guava/maven-metadata.xml&versionPrefix=27.' + '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/guava/guava/maven-metadata.xml&versionPrefix=27.', ) .expectBadge({ label: 'maven', @@ -23,7 +23,7 @@ t.create('with version prefix') t.create('with version suffix') .get( - '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/guava/guava/maven-metadata.xml&versionSuffix=-android' + '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/guava/guava/maven-metadata.xml&versionSuffix=-android', ) .expectBadge({ label: 'maven', @@ -32,7 +32,7 @@ t.create('with version suffix') t.create('with version prefix and suffix') .get( - '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/guava/guava/maven-metadata.xml&versionPrefix=27.&versionSuffix=-android' + '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/guava/guava/maven-metadata.xml&versionPrefix=27.&versionSuffix=-android', ) .expectBadge({ label: 'maven', @@ -41,7 +41,7 @@ t.create('with version prefix and suffix') t.create('version ending with zero') .get( - '/v.json?metadataUrl=https://repo1.maven.org/maven2/mocked-group-id/mocked-artifact-id/maven-metadata.xml' + '/v.json?metadataUrl=https://repo1.maven.org/maven2/mocked-group-id/mocked-artifact-id/maven-metadata.xml', ) .intercept(nock => nock('https://repo1.maven.org/maven2') @@ -61,20 +61,20 @@ t.create('version ending with zero') <lastUpdated>20190902002617</lastUpdated> </versioning> </metadata> - ` - ) + `, + ), ) .expectBadge({ label: 'maven', message: 'v1.30' }) t.create('invalid maven-metadata.xml uri') .get( - '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/code/gson/gson/foobar.xml' + '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/google/code/gson/gson/foobar.xml', ) .expectBadge({ label: 'maven', message: 'not found' }) t.create('inexistent version prefix') .get( - '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/maven-metadata.xml&versionPrefix=99' + '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/maven-metadata.xml&versionPrefix=99', ) .expectBadge({ label: 'maven', @@ -83,7 +83,7 @@ t.create('inexistent version prefix') t.create('inexistent version suffix') .get( - '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/maven-metadata.xml&versionSuffix=test' + '/v.json?metadataUrl=https://repo1.maven.org/maven2/com/github/fabriziocucci/yacl4j/maven-metadata.xml&versionSuffix=test', ) .expectBadge({ label: 'maven', diff --git a/services/modrinth/modrinth-base.js b/services/modrinth/modrinth-base.js index a26a95ce4b56ab11a42b7fa4bb34e2a1db7b3078..d5867e88e80bcf80bff79935eb9e40c88633c7ba 100644 --- a/services/modrinth/modrinth-base.js +++ b/services/modrinth/modrinth-base.js @@ -12,7 +12,7 @@ const versionSchema = Joi.array() Joi.object({ version_number: Joi.string().required(), game_versions: Joi.array().items(Joi.string()).min(1).required(), - }).required() + }).required(), ) .required() diff --git a/services/mozilla-observatory/mozilla-observatory.tester.js b/services/mozilla-observatory/mozilla-observatory.tester.js index b3f73f658d51217362a2034eb7585955b436264a..e5e3b1e99d788c8010c341a3873947149fc23aff 100644 --- a/services/mozilla-observatory/mozilla-observatory.tester.js +++ b/services/mozilla-observatory/mozilla-observatory.tester.js @@ -5,7 +5,7 @@ export const t = await createServiceTester() const isMessage = Joi.alternatives() .try( Joi.string().regex(/^[ABCDEF][+-]? \([0-9]{1,3}\/100\)$/), - Joi.string().allow('pending') + Joi.string().allow('pending'), ) .required() @@ -30,7 +30,7 @@ t.create('grade without score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'A', score: 115 }) + .reply(200, { state: 'FINISHED', grade: 'A', score: 115 }), ) .expectBadge({ label: 'observatory', @@ -43,7 +43,7 @@ t.create('grade A with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'A', score: 115 }) + .reply(200, { state: 'FINISHED', grade: 'A', score: 115 }), ) .expectBadge({ label: 'observatory', @@ -56,7 +56,7 @@ t.create('grade A+ with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'A+', score: 115 }) + .reply(200, { state: 'FINISHED', grade: 'A+', score: 115 }), ) .expectBadge({ label: 'observatory', @@ -69,7 +69,7 @@ t.create('grade A- with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'A-', score: 115 }) + .reply(200, { state: 'FINISHED', grade: 'A-', score: 115 }), ) .expectBadge({ label: 'observatory', @@ -82,7 +82,7 @@ t.create('grade B with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'B', score: 115 }) + .reply(200, { state: 'FINISHED', grade: 'B', score: 115 }), ) .expectBadge({ label: 'observatory', @@ -95,7 +95,7 @@ t.create('grade B+ with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'B+', score: 115 }) + .reply(200, { state: 'FINISHED', grade: 'B+', score: 115 }), ) .expectBadge({ label: 'observatory', @@ -108,7 +108,7 @@ t.create('grade B- with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'B-', score: 115 }) + .reply(200, { state: 'FINISHED', grade: 'B-', score: 115 }), ) .expectBadge({ label: 'observatory', @@ -121,7 +121,7 @@ t.create('grade C with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'C', score: 80 }) + .reply(200, { state: 'FINISHED', grade: 'C', score: 80 }), ) .expectBadge({ label: 'observatory', @@ -134,7 +134,7 @@ t.create('grade C+ with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'C+', score: 80 }) + .reply(200, { state: 'FINISHED', grade: 'C+', score: 80 }), ) .expectBadge({ label: 'observatory', @@ -147,7 +147,7 @@ t.create('grade C- with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'C-', score: 80 }) + .reply(200, { state: 'FINISHED', grade: 'C-', score: 80 }), ) .expectBadge({ label: 'observatory', @@ -160,7 +160,7 @@ t.create('grade D with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'D', score: 15 }) + .reply(200, { state: 'FINISHED', grade: 'D', score: 15 }), ) .expectBadge({ label: 'observatory', @@ -173,7 +173,7 @@ t.create('grade D+ with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'D+', score: 15 }) + .reply(200, { state: 'FINISHED', grade: 'D+', score: 15 }), ) .expectBadge({ label: 'observatory', @@ -186,7 +186,7 @@ t.create('grade D- with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'D-', score: 15 }) + .reply(200, { state: 'FINISHED', grade: 'D-', score: 15 }), ) .expectBadge({ label: 'observatory', @@ -199,7 +199,7 @@ t.create('grade E with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'E', score: 15 }) + .reply(200, { state: 'FINISHED', grade: 'E', score: 15 }), ) .expectBadge({ label: 'observatory', @@ -212,7 +212,7 @@ t.create('grade E+ with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'E+', score: 15 }) + .reply(200, { state: 'FINISHED', grade: 'E+', score: 15 }), ) .expectBadge({ label: 'observatory', @@ -225,7 +225,7 @@ t.create('grade E- with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'E-', score: 15 }) + .reply(200, { state: 'FINISHED', grade: 'E-', score: 15 }), ) .expectBadge({ label: 'observatory', @@ -238,7 +238,7 @@ t.create('grade F with score (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FINISHED', grade: 'F', score: 0 }) + .reply(200, { state: 'FINISHED', grade: 'F', score: 0 }), ) .expectBadge({ label: 'observatory', @@ -251,7 +251,7 @@ t.create('aborted (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'ABORTED', grade: null, score: null }) + .reply(200, { state: 'ABORTED', grade: null, score: null }), ) .expectBadge({ label: 'observatory', @@ -264,7 +264,7 @@ t.create('failed (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'FAILED', grade: null, score: null }) + .reply(200, { state: 'FAILED', grade: null, score: null }), ) .expectBadge({ label: 'observatory', @@ -277,7 +277,7 @@ t.create('pending (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'PENDING', grade: null, score: null }) + .reply(200, { state: 'PENDING', grade: null, score: null }), ) .expectBadge({ label: 'observatory', @@ -290,7 +290,7 @@ t.create('starting (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'STARTING', grade: null, score: null }) + .reply(200, { state: 'STARTING', grade: null, score: null }), ) .expectBadge({ label: 'observatory', @@ -303,7 +303,7 @@ t.create('running (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'RUNNING', grade: null, score: null }) + .reply(200, { state: 'RUNNING', grade: null, score: null }), ) .expectBadge({ label: 'observatory', @@ -316,7 +316,7 @@ t.create('invalid response with grade and score but not finished (mock)') .intercept(nock => nock('https://http-observatory.security.mozilla.org') .post('/api/v1/analyze?host=foo.bar') - .reply(200, { state: 'RUNNING', grade: 'A+', score: 135 }) + .reply(200, { state: 'RUNNING', grade: 'A+', score: 135 }), ) .expectBadge({ label: 'observatory', diff --git a/services/myget/myget.tester.js b/services/myget/myget.tester.js index c3db938a2dd1f4364a9d40f4c79c862564ef9256..48dc842207429f9a9ce6ff6986ddc65d241cdfaf 100644 --- a/services/myget/myget.tester.js +++ b/services/myget/myget.tester.js @@ -52,7 +52,7 @@ t.create('total downloads (unexpected first response)') .intercept(nock => nock('https://www.myget.org') .get('/F/mongodb/api/v3/index.json') - .reply(invalidJSON) + .reply(invalidJSON), ) .expectBadge({ label: 'downloads', @@ -80,14 +80,14 @@ t.create('version (yellow badge)') .intercept(nock => nock('https://www.myget.org') .get('/F/mongodb/api/v3/index.json') - .reply(200, queryIndex) + .reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonWithDash) + .reply(200, nuGetV3VersionJsonWithDash), ) .expectBadge({ label: 'mongodb', @@ -100,14 +100,14 @@ t.create('version (orange badge)') .intercept(nock => nock('https://www.myget.org') .get('/F/mongodb/api/v3/index.json') - .reply(200, queryIndex) + .reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonFirstCharZero) + .reply(200, nuGetV3VersionJsonFirstCharZero), ) .expectBadge({ label: 'mongodb', @@ -120,14 +120,14 @@ t.create('version (blue badge)') .intercept(nock => nock('https://www.myget.org') .get('/F/mongodb/api/v3/index.json') - .reply(200, queryIndex) + .reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonFirstCharNotZero) + .reply(200, nuGetV3VersionJsonFirstCharNotZero), ) .expectBadge({ label: 'mongodb', @@ -153,14 +153,14 @@ t.create('version (pre) (yellow badge)') .intercept(nock => nock('https://www.myget.org') .get('/F/mongodb/api/v3/index.json') - .reply(200, queryIndex) + .reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonWithDash) + .reply(200, nuGetV3VersionJsonWithDash), ) .expectBadge({ label: 'mongodb', @@ -173,14 +173,14 @@ t.create('version (pre) (orange badge)') .intercept(nock => nock('https://www.myget.org') .get('/F/mongodb/api/v3/index.json') - .reply(200, queryIndex) + .reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonFirstCharZero) + .reply(200, nuGetV3VersionJsonFirstCharZero), ) .expectBadge({ label: 'mongodb', @@ -193,14 +193,14 @@ t.create('version (pre) (blue badge)') .intercept(nock => nock('https://www.myget.org') .get('/F/mongodb/api/v3/index.json') - .reply(200, queryIndex) + .reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amongodb.driver.core&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonFirstCharNotZero) + .reply(200, nuGetV3VersionJsonFirstCharNotZero), ) .expectBadge({ label: 'mongodb', diff --git a/services/nexus/nexus-redirect.tester.js b/services/nexus/nexus-redirect.tester.js index 294b0f67143ad00a310871f909336f4095ce5e76..a9dea59fb80d694756085d8243f6e3f3cafd4b00 100644 --- a/services/nexus/nexus-redirect.tester.js +++ b/services/nexus/nexus-redirect.tester.js @@ -10,24 +10,24 @@ t.create('Nexus release') .get('/r/https/oss.sonatype.org/com.google.guava/guava.svg') .expectRedirect( `/nexus/r/com.google.guava/guava.svg?server=${encodeURIComponent( - 'https://oss.sonatype.org' - )}` + 'https://oss.sonatype.org', + )}`, ) t.create('Nexus snapshot') .get('/s/https/oss.sonatype.org/com.google.guava/guava.svg') .expectRedirect( `/nexus/s/com.google.guava/guava.svg?server=${encodeURIComponent( - 'https://oss.sonatype.org' - )}` + 'https://oss.sonatype.org', + )}`, ) t.create('Nexus repository with query opts') .get( - '/fs-public-snapshots/https/repository.jboss.org/nexus/com.progress.fuse/fusehq:p=tar.gz:c=agent-apple-osx.svg' + '/fs-public-snapshots/https/repository.jboss.org/nexus/com.progress.fuse/fusehq:p=tar.gz:c=agent-apple-osx.svg', ) .expectRedirect( `/nexus/fs-public-snapshots/com.progress.fuse/fusehq.svg?queryOpt=${encodeURIComponent( - ':p=tar.gz:c=agent-apple-osx' - )}&server=${encodeURIComponent('https://repository.jboss.org/nexus')}` + ':p=tar.gz:c=agent-apple-osx', + )}&server=${encodeURIComponent('https://repository.jboss.org/nexus')}`, ) diff --git a/services/nexus/nexus.service.js b/services/nexus/nexus.service.js index b2b166a719731379b45dab03a43b2a2321fcd587..fe03670dbc48824b0234d368808518c25ea1ae33 100644 --- a/services/nexus/nexus.service.js +++ b/services/nexus/nexus.service.js @@ -20,7 +20,7 @@ const nexus2SearchApiSchema = Joi.object({ // the entire history of each published version for the artifact. // Example artifact that includes such a historical version: https://oss.sonatype.org/service/local/lucene/search?g=com.google.guava&a=guava version: Joi.string(), - }) + }), ) .required(), }).required() @@ -31,7 +31,7 @@ const nexus3SearchApiSchema = Joi.object({ Joi.object({ // This schema is relaxed similarly to nexux2SearchApiSchema version: Joi.string().required(), - }) + }), ) .required(), }).required() @@ -223,7 +223,7 @@ export default class Nexus extends BaseJsonService { httpErrors: { 404: 'artifact not found', }, - }) + }), ) return { actualNexusVersion: '2', json } @@ -264,7 +264,7 @@ export default class Nexus extends BaseJsonService { httpErrors: { 404: 'artifact not found', }, - }) + }), ) return { actualNexusVersion: '3', json } @@ -319,7 +319,7 @@ export default class Nexus extends BaseJsonService { async handle( { repo, groupId, artifactId }, - { server, queryOpt, nexusVersion } + { server, queryOpt, nexusVersion }, ) { const { actualNexusVersion, json } = await this.fetch({ repo, diff --git a/services/nexus/nexus.spec.js b/services/nexus/nexus.spec.js index 43104b8307da86587d30c2042bf4509d7a164a04..1f4114bfdc61abd0b59ae2afd08443fc8f662453 100644 --- a/services/nexus/nexus.spec.js +++ b/services/nexus/nexus.spec.js @@ -92,7 +92,7 @@ describe('Nexus', function () { } catch (e) { expect(e).to.be.an.instanceof(NotFound) expect(e.prettyMessage).to.equal( - 'artifact or snapshot version not found' + 'artifact or snapshot version not found', ) } }) @@ -151,8 +151,8 @@ describe('Nexus', function () { }, { server: 'https://repository.jboss.org/nexus', - } - ) + }, + ), ).to.deep.equal({ message: 'v2.3.4', color: 'blue', diff --git a/services/nexus/nexus.tester.js b/services/nexus/nexus.tester.js index aa802c541373754002b5905c16af5d0933e6c495..a5f6e7f1e17b836c14b250fcd0f045180e636b9f 100644 --- a/services/nexus/nexus.tester.js +++ b/services/nexus/nexus.tester.js @@ -13,7 +13,7 @@ t.create('Nexus 2 - search release version valid artifact') t.create('Nexus 2 - search release version of an nonexistent artifact') .timeout(15000) .get( - '/r/com.google.guava/nonexistent-artifact-id.json?server=https://oss.sonatype.org' + '/r/com.google.guava/nonexistent-artifact-id.json?server=https://oss.sonatype.org', ) .expectBadge({ label: 'nexus', @@ -23,7 +23,7 @@ t.create('Nexus 2 - search release version of an nonexistent artifact') t.create('Nexus 2 - search snapshot version valid snapshot artifact') .timeout(15000) .get( - '/s/org.fusesource.apollo/apollo-karaf-feature.json?server=https://repository.jboss.org/nexus' + '/s/org.fusesource.apollo/apollo-karaf-feature.json?server=https://repository.jboss.org/nexus', ) .expectBadge({ label: 'nexus', @@ -33,7 +33,7 @@ t.create('Nexus 2 - search snapshot version valid snapshot artifact') t.create('Nexus 2 - search snapshot version of an nonexistent artifact') .timeout(15000) .get( - '/s/com.google.guava/nonexistent-artifact-id.json?server=https://oss.sonatype.org' + '/s/com.google.guava/nonexistent-artifact-id.json?server=https://oss.sonatype.org', ) .expectBadge({ label: 'nexus', @@ -43,7 +43,7 @@ t.create('Nexus 2 - search snapshot version of an nonexistent artifact') t.create('Nexus 2 - repository version') .get( - '/developer/ai.h2o/h2o-automl.json?server=https://repository.jboss.org/nexus' + '/developer/ai.h2o/h2o-automl.json?server=https://repository.jboss.org/nexus', ) .expectBadge({ label: 'nexus', @@ -54,8 +54,8 @@ t.create('Nexus 2 - repository version with query') .timeout(15000) .get( `/fs-public-snapshots/com.progress.fuse/fusehq.json?server=https://repository.jboss.org/nexus&queryOpt=${encodeURIComponent( - ':p=tar.gz:c=agent-apple-osx' - )}` + ':p=tar.gz:c=agent-apple-osx', + )}`, ) .expectBadge({ label: 'nexus', @@ -65,7 +65,7 @@ t.create('Nexus 2 - repository version with query') t.create('Nexus 2 - repository version of an nonexistent artifact') .timeout(15000) .get( - '/developer/jboss/nonexistent-artifact-id.json?server=https://repository.jboss.org/nexus' + '/developer/jboss/nonexistent-artifact-id.json?server=https://repository.jboss.org/nexus', ) .expectBadge({ label: 'nexus', @@ -74,13 +74,13 @@ t.create('Nexus 2 - repository version of an nonexistent artifact') t.create('Nexus 2 - snapshot version with + in version') .get( - '/s/com.progress.fuse/fusehq.json?server=https://repository.jboss.org/nexus' + '/s/com.progress.fuse/fusehq.json?server=https://repository.jboss.org/nexus', ) .intercept(nock => nock('https://repository.jboss.org/nexus') .get('/service/local/lucene/search') .query({ g: 'com.progress.fuse', a: 'fusehq' }) - .reply(200, { data: [{ version: '7.0.1+19-8844c122-SNAPSHOT' }] }) + .reply(200, { data: [{ version: '7.0.1+19-8844c122-SNAPSHOT' }] }), ) .expectBadge({ label: 'nexus', @@ -90,13 +90,13 @@ t.create('Nexus 2 - snapshot version with + in version') t.create('Nexus 2 - snapshot version with + and hex hash in version') .get( - '/s/com.typesafe.akka/akka-stream-kafka_2.13.json?server=https://repository.jboss.org/nexus' + '/s/com.typesafe.akka/akka-stream-kafka_2.13.json?server=https://repository.jboss.org/nexus', ) .intercept(nock => nock('https://repository.jboss.org/nexus') .get('/service/local/lucene/search') .query({ g: 'com.typesafe.akka', a: 'akka-stream-kafka_2.13' }) - .reply(200, { data: [{ version: '2.1.0-M1+58-f25047fc-SNAPSHOT' }] }) + .reply(200, { data: [{ version: '2.1.0-M1+58-f25047fc-SNAPSHOT' }] }), ) .expectBadge({ label: 'nexus', @@ -106,13 +106,13 @@ t.create('Nexus 2 - snapshot version with + and hex hash in version') t.create('Nexus 2 - search snapshot version not in latestSnapshot') .get( - '/s/com.progress.fuse/fusehq.json?server=https://repository.jboss.org/nexus' + '/s/com.progress.fuse/fusehq.json?server=https://repository.jboss.org/nexus', ) .intercept(nock => nock('https://repository.jboss.org/nexus') .get('/service/local/lucene/search') .query({ g: 'com.progress.fuse', a: 'fusehq' }) - .reply(200, { data: [{ version: '7.0.1-SNAPSHOT' }] }) + .reply(200, { data: [{ version: '7.0.1-SNAPSHOT' }] }), ) .expectBadge({ label: 'nexus', @@ -122,13 +122,13 @@ t.create('Nexus 2 - search snapshot version not in latestSnapshot') t.create('Nexus 2 - search snapshot no snapshot versions') .get( - '/s/com.progress.fuse/fusehq.json?server=https://repository.jboss.org/nexus' + '/s/com.progress.fuse/fusehq.json?server=https://repository.jboss.org/nexus', ) .intercept(nock => nock('https://repository.jboss.org/nexus') .get('/service/local/lucene/search') .query({ g: 'com.progress.fuse', a: 'fusehq' }) - .reply(200, { data: [{ version: '1.2.3' }] }) + .reply(200, { data: [{ version: '1.2.3' }] }), ) .expectBadge({ label: 'nexus', @@ -142,7 +142,7 @@ t.create('Nexus 2 - search release version') nock('https://repository.jboss.org/nexus') .get('/service/local/lucene/search') .query({ g: 'jboss', a: 'jboss-client' }) - .reply(200, { data: [{ latestRelease: '1.0.0' }] }) + .reply(200, { data: [{ latestRelease: '1.0.0' }] }), ) .expectBadge({ label: 'nexus', @@ -152,7 +152,7 @@ t.create('Nexus 2 - search release version') t.create('Nexus 2 - repository release version') .get( - '/developer/ai.h2o/h2o-automl.json?server=https://repository.jboss.org/nexus' + '/developer/ai.h2o/h2o-automl.json?server=https://repository.jboss.org/nexus', ) .intercept(nock => nock('https://repository.jboss.org/nexus') @@ -168,7 +168,7 @@ t.create('Nexus 2 - repository release version') baseVersion: '1.2.3', version: '1.0.0', }, - }) + }), ) .expectBadge({ label: 'nexus', @@ -178,7 +178,7 @@ t.create('Nexus 2 - repository release version') t.create('Nexus 2 - repository release version') .get( - '/developer/ai.h2o/h2o-automl.json?server=https://repository.jboss.org/nexus' + '/developer/ai.h2o/h2o-automl.json?server=https://repository.jboss.org/nexus', ) .intercept(nock => nock('https://repository.jboss.org/nexus') @@ -193,7 +193,7 @@ t.create('Nexus 2 - repository release version') data: { version: '1.0.0', }, - }) + }), ) .expectBadge({ label: 'nexus', @@ -203,7 +203,7 @@ t.create('Nexus 2 - repository release version') t.create('Nexus 2 - user query params') .get( - '/fs-public-snapshots/com.progress.fuse/fusehq.json?queryOpt=:c=agent-apple-osx:p=tar.gz&server=https://repository.jboss.org/nexus' + '/fs-public-snapshots/com.progress.fuse/fusehq.json?queryOpt=:c=agent-apple-osx:p=tar.gz&server=https://repository.jboss.org/nexus', ) .intercept(nock => nock('https://repository.jboss.org/nexus') @@ -220,7 +220,7 @@ t.create('Nexus 2 - user query params') data: { version: '3.2.1', }, - }) + }), ) .expectBadge({ label: 'nexus', @@ -230,7 +230,7 @@ t.create('Nexus 2 - user query params') t.create('Nexus 3 - search release version valid artifact') .get( - '/r/org.apache.commons/commons-lang3.json?server=https://nexus.pentaho.org&nexusVersion=3' + '/r/org.apache.commons/commons-lang3.json?server=https://nexus.pentaho.org&nexusVersion=3', ) .expectBadge({ label: 'nexus', @@ -238,11 +238,11 @@ t.create('Nexus 3 - search release version valid artifact') }) t.create( - 'Nexus 3 - search release version valid artifact without explicit nexusVersion parameter' + 'Nexus 3 - search release version valid artifact without explicit nexusVersion parameter', ) .timeout(15000) .get( - '/r/org.apache.commons/commons-lang3.json?server=https://nexus.pentaho.org' + '/r/org.apache.commons/commons-lang3.json?server=https://nexus.pentaho.org', ) .expectBadge({ label: 'nexus', @@ -251,7 +251,7 @@ t.create( t.create('Nexus 3 - search release version of an nonexistent artifact') .get( - '/r/org.apache.commons/nonexistent-artifact-id.json?server=https://nexus.pentaho.org&nexusVersion=3' + '/r/org.apache.commons/nonexistent-artifact-id.json?server=https://nexus.pentaho.org&nexusVersion=3', ) .expectBadge({ label: 'nexus', @@ -260,7 +260,7 @@ t.create('Nexus 3 - search release version of an nonexistent artifact') t.create('Nexus 3 - search snapshot version valid snapshot artifact') .get( - '/s/org.pentaho/pentaho-registry.json?server=https://nexus.pentaho.org&nexusVersion=3' + '/s/org.pentaho/pentaho-registry.json?server=https://nexus.pentaho.org&nexusVersion=3', ) .expectBadge({ label: 'nexus', @@ -269,7 +269,7 @@ t.create('Nexus 3 - search snapshot version valid snapshot artifact') t.create('Nexus 3 - search snapshot version for artifact without snapshots') .get( - '/s/javax.inject/javax.inject.json?server=https://nexus.pentaho.org&nexusVersion=3' + '/s/javax.inject/javax.inject.json?server=https://nexus.pentaho.org&nexusVersion=3', ) .expectBadge({ label: 'nexus', @@ -279,7 +279,7 @@ t.create('Nexus 3 - search snapshot version for artifact without snapshots') t.create('Nexus 3 - repository version') .get( - '/proxy-public-3rd-party-release/com.h2database/h2.json?server=https://nexus.pentaho.org&nexusVersion=3' + '/proxy-public-3rd-party-release/com.h2database/h2.json?server=https://nexus.pentaho.org&nexusVersion=3', ) .expectBadge({ label: 'nexus', @@ -287,11 +287,11 @@ t.create('Nexus 3 - repository version') }) t.create( - 'Nexus 3 - repository version valid artifact without explicit nexusVersion parameter' + 'Nexus 3 - repository version valid artifact without explicit nexusVersion parameter', ) .timeout(15000) .get( - '/proxy-public-3rd-party-release/com.h2database/h2.json?server=https://nexus.pentaho.org' + '/proxy-public-3rd-party-release/com.h2database/h2.json?server=https://nexus.pentaho.org', ) .expectBadge({ label: 'nexus', @@ -301,8 +301,8 @@ t.create( t.create('Nexus 3 - repository version with query') .get( `/proxy-public-3rd-party-release/org.junit.jupiter/junit-jupiter.json?server=https://nexus.pentaho.org&nexusVersion=3&queryOpt=${encodeURIComponent( - ':maven.extension=jar:direction=asc' - )}` + ':maven.extension=jar:direction=asc', + )}`, ) .expectBadge({ label: 'nexus', @@ -313,8 +313,8 @@ t.create('Nexus 3 - search release version without snapshots') .get( // Limit the version from above, so that any later artifacts don't break this test. `/r/org.pentaho.adaptive/pdi-engines.json?server=https://nexus.pentaho.org&nexusVersion=3&queryOpt=${encodeURIComponent( - ':maven.baseVersion=<8.0.0.1' - )}` + ':maven.baseVersion=<8.0.0.1', + )}`, ) .expectBadge({ label: 'nexus', diff --git a/services/node/node-current.tester.js b/services/node/node-current.tester.js index 4734070c28f4f83d3c83d1fddfb91324ce88c348..e82d24743679d6f2c3ddce024271b987d78a2083 100644 --- a/services/node/node-current.tester.js +++ b/services/node/node-current.tester.js @@ -22,7 +22,7 @@ t.create('engines satisfies current node version') mockPackageData({ packageName: 'passport', engines: '>=0.4.0', - }) + }), ) .intercept(mockCurrentSha(13)) .expectBadge({ label: 'node', message: '>=0.4.0', color: 'brightgreen' }) @@ -33,7 +33,7 @@ t.create('engines does not satisfy current node version') mockPackageData({ packageName: 'passport', engines: '12', - }) + }), ) .intercept(mockCurrentSha(13)) .expectBadge({ label: 'node', message: '12', color: 'yellow' }) @@ -54,7 +54,7 @@ t.create('engines satisfies current node version - scoped') scope: '@stdlib', tag: '', registry: '', - }) + }), ) .intercept(mockCurrentSha(13)) .expectBadge({ label: 'node', message: '>=0.4.0', color: 'brightgreen' }) @@ -68,7 +68,7 @@ t.create('engines does not satisfy current node version - scoped') scope: '@stdlib', tag: '', registry: '', - }) + }), ) .intercept(mockCurrentSha(13)) .expectBadge({ label: 'node', message: '12', color: 'yellow' }) @@ -87,7 +87,7 @@ t.create('engines satisfies current node version - tagged') packageName: 'ionic', engines: '>=0.4.0', tag: 'testing', - }) + }), ) .intercept(mockCurrentSha(13)) .expectBadge({ @@ -103,7 +103,7 @@ t.create('engines does not satisfy current node version - tagged') packageName: 'ionic', engines: '12', tag: 'testing', - }) + }), ) .intercept(mockCurrentSha(13)) .expectBadge({ label: 'node@testing', message: '12', color: 'yellow' }) @@ -123,7 +123,7 @@ t.create('engines satisfies current node version - scoped and tagged') engines: '>=0.4.0', scope: '@cycle', tag: 'canary', - }) + }), ) .intercept(mockCurrentSha(13)) .expectBadge({ @@ -140,7 +140,7 @@ t.create('engines does not satisfy current node version - scoped and tagged') engines: '12', scope: '@cycle', tag: 'canary', - }) + }), ) .intercept(mockCurrentSha(13)) .expectBadge({ label: 'node@canary', message: '12', color: 'yellow' }) diff --git a/services/node/node-lts.tester.js b/services/node/node-lts.tester.js index e4d55ba84107e99ddca2d93774cb937cf6055a26..0592b1b5aebc4a71b8392d786bd7644dec9b8ac9 100644 --- a/services/node/node-lts.tester.js +++ b/services/node/node-lts.tester.js @@ -27,7 +27,7 @@ t.create('engines satisfies all lts node versions') mockPackageData({ packageName: 'passport', engines: '10 - 12', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts', message: '10 - 12', color: 'brightgreen' }) @@ -39,7 +39,7 @@ t.create('engines does not satisfy all lts node versions') mockPackageData({ packageName: 'passport', engines: '8', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts', message: '8', color: 'orange' }) @@ -51,7 +51,7 @@ t.create('engines satisfies some lts node versions') mockPackageData({ packageName: 'passport', engines: '10', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts', message: '10', color: 'yellow' }) @@ -71,7 +71,7 @@ t.create('engines satisfies all lts node versions - scoped') packageName: 'stdlib', engines: '10 - 12', scope: '@stdlib', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts', message: '10 - 12', color: 'brightgreen' }) @@ -84,7 +84,7 @@ t.create('engines does not satisfy all lts node versions - scoped') packageName: 'stdlib', engines: '8', scope: '@stdlib', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts', message: '8', color: 'orange' }) @@ -97,7 +97,7 @@ t.create('engines satisfies some lts node versions - scoped') packageName: 'stdlib', engines: '10', scope: '@stdlib', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts', message: '10', color: 'yellow' }) @@ -117,7 +117,7 @@ t.create('engines satisfies all lts node versions - tagged') packageName: 'ionic', engines: '10 - 12', tag: 'testing', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ @@ -134,7 +134,7 @@ t.create('engines does not satisfy all lts node versions - tagged') packageName: 'ionic', engines: '8', tag: 'testing', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts@testing', message: '8', color: 'orange' }) @@ -147,7 +147,7 @@ t.create('engines satisfies some lts node versions - tagged') packageName: 'ionic', engines: '10', tag: 'testing', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts@testing', message: '10', color: 'yellow' }) @@ -168,7 +168,7 @@ t.create('engines satisfies all lts node versions - scoped and tagged') engines: '10 - 12', scope: '@cycle', tag: 'canary', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ @@ -186,7 +186,7 @@ t.create('engines does not satisfy all lts node versions - scoped and tagged') engines: '8', scope: '@cycle', tag: 'canary', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts@canary', message: '8', color: 'orange' }) @@ -200,7 +200,7 @@ t.create('engines satisfies some lts node versions - scoped and tagged') engines: '10', scope: '@cycle', tag: 'canary', - }) + }), ) .intercept(mockVersionsSha()) .expectBadge({ label: 'node-lts@canary', message: '10', color: 'yellow' }) diff --git a/services/node/testUtils/test-utils.js b/services/node/testUtils/test-utils.js index b1a904856469650d938d158e1e4067b0791ebbe5..d6ee3a6a3e673452011dba8cb593a9d7544bd3e2 100644 --- a/services/node/testUtils/test-utils.js +++ b/services/node/testUtils/test-utils.js @@ -9,16 +9,16 @@ const templates = { packageJsonVersionsTemplate: fs.readFileSync( path.join( path.dirname(fileURLToPath(import.meta.url)), - 'packageJsonVersionsTemplate.json' + 'packageJsonVersionsTemplate.json', ), - 'utf-8' + 'utf-8', ), packageJsonTemplate: fs.readFileSync( path.join( path.dirname(fileURLToPath(import.meta.url)), - 'packageJsonTemplate.json' + 'packageJsonTemplate.json', ), - 'utf-8' + 'utf-8', ), } diff --git a/services/nodeping/nodeping-status.service.js b/services/nodeping/nodeping-status.service.js index 65ead9a6490079a8879a45006b9adb726227e302..3a57957731f096fe4776d6a7168b461ed75494af 100644 --- a/services/nodeping/nodeping-status.service.js +++ b/services/nodeping/nodeping-status.service.js @@ -56,7 +56,7 @@ export default class NodePingStatus extends BaseJsonService { down_message: downMessage, up_color: upColor, down_color: downColor, - } + }, ) { const { isUp } = await this.fetch({ checkUuid }) return renderWebsiteStatus({ diff --git a/services/nodeping/nodeping-status.tester.js b/services/nodeping/nodeping-status.tester.js index 6361cb99ce305d0ba3a96ca0a2eeef28af2a059b..9cc586322bd6658eb453dd38b5f1467e75138bc3 100644 --- a/services/nodeping/nodeping-status.tester.js +++ b/services/nodeping/nodeping-status.tester.js @@ -11,9 +11,9 @@ t.create('NodePing status - up') .intercept(nock => nock('https://nodeping.com') .get( - '/reports/results/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei/1?format=json' + '/reports/results/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei/1?format=json', ) - .reply(200, [{ su: true }]) + .reply(200, [{ su: true }]), ) .expectBadge({ label: 'status', message: 'up' }) @@ -22,34 +22,34 @@ t.create('NodePing status - down') .intercept(nock => nock('https://nodeping.com') .get( - '/reports/results/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei/1?format=json' + '/reports/results/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei/1?format=json', ) - .reply(200, [{ su: false }]) + .reply(200, [{ su: false }]), ) .expectBadge({ label: 'status', message: 'down' }) t.create('NodePing status - custom up color/message') .get( - '/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei.json?up_color=blue&up_message=happy' + '/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei.json?up_color=blue&up_message=happy', ) .intercept(nock => nock('https://nodeping.com') .get( - '/reports/results/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei/1?format=json' + '/reports/results/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei/1?format=json', ) - .reply(200, [{ su: true }]) + .reply(200, [{ su: true }]), ) .expectBadge({ label: 'status', message: 'happy', color: 'blue' }) t.create('NodePing status - custom down color/message') .get( - '/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei.json?down_color=yellow&down_message=sad' + '/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei.json?down_color=yellow&down_message=sad', ) .intercept(nock => nock('https://nodeping.com') .get( - '/reports/results/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei/1?format=json' + '/reports/results/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei/1?format=json', ) - .reply(200, [{ su: false }]) + .reply(200, [{ su: false }]), ) .expectBadge({ label: 'status', message: 'sad', color: 'yellow' }) diff --git a/services/nodeping/nodeping-uptime.service.js b/services/nodeping/nodeping-uptime.service.js index fa1e2d9a63015ac6c7219263e49de97725672e76..3131cf3e9a8582a1c26e44b8c3adffdd4d50ad2d 100644 --- a/services/nodeping/nodeping-uptime.service.js +++ b/services/nodeping/nodeping-uptime.service.js @@ -52,7 +52,7 @@ export default class NodePingUptime extends BaseJsonService { async fetch({ checkUuid }) { const thirtyDaysAgo = new Date( - new Date().getTime() - 30 * 24 * 60 * 60 * 1000 + new Date().getTime() - 30 * 24 * 60 * 60 * 1000, ) .toISOString() .slice(0, 10) diff --git a/services/nodeping/nodeping-uptime.tester.js b/services/nodeping/nodeping-uptime.tester.js index 5e09a52eca4aca8023a3ad4f5e5b24825044b099..fc3367336e249643a36321542de07b99032e7cc6 100644 --- a/services/nodeping/nodeping-uptime.tester.js +++ b/services/nodeping/nodeping-uptime.tester.js @@ -12,12 +12,12 @@ t.create('NodePing uptime - 100%') nock('https://nodeping.com') .get( `/reports/uptime/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei?format=json&interval=days&start=${new Date( - new Date().getTime() - 30 * 24 * 60 * 60 * 1000 + new Date().getTime() - 30 * 24 * 60 * 60 * 1000, ) .toISOString() - .slice(0, 10)}` + .slice(0, 10)}`, ) - .reply(200, [{ uptime: 100 }]) + .reply(200, [{ uptime: 100 }]), ) .expectBadge({ label: 'uptime', message: '100%', color: 'brightgreen' }) @@ -27,12 +27,12 @@ t.create('NodePing uptime - 99.999%') nock('https://nodeping.com') .get( `/reports/uptime/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei?format=json&interval=days&start=${new Date( - new Date().getTime() - 30 * 24 * 60 * 60 * 1000 + new Date().getTime() - 30 * 24 * 60 * 60 * 1000, ) .toISOString() - .slice(0, 10)}` + .slice(0, 10)}`, ) - .reply(200, [{ uptime: 99.999 }]) + .reply(200, [{ uptime: 99.999 }]), ) .expectBadge({ label: 'uptime', message: '99.999%', color: 'green' }) @@ -42,12 +42,12 @@ t.create('NodePing uptime - 99.001%') nock('https://nodeping.com') .get( `/reports/uptime/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei?format=json&interval=days&start=${new Date( - new Date().getTime() - 30 * 24 * 60 * 60 * 1000 + new Date().getTime() - 30 * 24 * 60 * 60 * 1000, ) .toISOString() - .slice(0, 10)}` + .slice(0, 10)}`, ) - .reply(200, [{ uptime: 99.001 }]) + .reply(200, [{ uptime: 99.001 }]), ) .expectBadge({ label: 'uptime', message: '99.001%', color: 'yellow' }) @@ -57,11 +57,11 @@ t.create('NodePing uptime - 90.001%') nock('https://nodeping.com') .get( `/reports/uptime/jkiwn052-ntpp-4lbb-8d45-ihew6d9ucoei?format=json&interval=days&start=${new Date( - new Date().getTime() - 30 * 24 * 60 * 60 * 1000 + new Date().getTime() - 30 * 24 * 60 * 60 * 1000, ) .toISOString() - .slice(0, 10)}` + .slice(0, 10)}`, ) - .reply(200, [{ uptime: 90.001 }]) + .reply(200, [{ uptime: 90.001 }]), ) .expectBadge({ label: 'uptime', message: '90.001%', color: 'red' }) diff --git a/services/npm/npm-base.js b/services/npm/npm-base.js index b4dc250d620cb14bc1013432c88d51383acfb930..ab2f5a72854099a8bc0680f46c142ee9dbaf369e 100644 --- a/services/npm/npm-base.js +++ b/services/npm/npm-base.js @@ -15,8 +15,8 @@ const packageDataSchema = Joi.object({ Joi.string(), deprecatedLicenseObjectSchema, Joi.array().items( - Joi.alternatives(Joi.string(), deprecatedLicenseObjectSchema) - ) + Joi.alternatives(Joi.string(), deprecatedLicenseObjectSchema), + ), ), maintainers: Joi.array() // We don't need the keys here, just the length. @@ -60,7 +60,7 @@ export default class NpmBase extends BaseJsonService { static unpackParams( { scope, packageName, tag }, - { registry_uri: registryUrl = 'https://registry.npmjs.org' } + { registry_uri: registryUrl = 'https://registry.npmjs.org' }, ) { return { scope, @@ -88,7 +88,7 @@ export default class NpmBase extends BaseJsonService { Accept: '*/*', }, }, - }) + }), ) } diff --git a/services/npm/npm-base.spec.js b/services/npm/npm-base.spec.js index 1d68e226d027cdd16e62d3482b0242581d1c22f0..4ec6301601b7e3f2d6dc0b3c5f31d40107bd8f7d 100644 --- a/services/npm/npm-base.spec.js +++ b/services/npm/npm-base.spec.js @@ -31,7 +31,7 @@ describe('npm', function () { } expect( - await NpmVersion.invoke(defaultContext, config, { packageName: 'npm' }) + await NpmVersion.invoke(defaultContext, config, { packageName: 'npm' }), ).to.deep.equal({ color: 'orange', label: undefined, diff --git a/services/npm/npm-collaborators.service.js b/services/npm/npm-collaborators.service.js index 3c277b58c6f0fe0e3744a3c55fca123bd796d28c..629f5fcfee87053001f4d968758e7564f4abf766 100644 --- a/services/npm/npm-collaborators.service.js +++ b/services/npm/npm-collaborators.service.js @@ -37,7 +37,7 @@ export default class NpmCollaborators extends NpmBase { async handle(namedParams, queryParams) { const { scope, packageName, registryUrl } = this.constructor.unpackParams( namedParams, - queryParams + queryParams, ) const { maintainers } = await this.fetchPackageData({ scope, diff --git a/services/npm/npm-dependency-version.service.js b/services/npm/npm-dependency-version.service.js index 115b5cc5be352430c89b8bc5094ff95fe2a22980..cf491c3d3cb9ebe05413c3d47d996070b6ee23e2 100644 --- a/services/npm/npm-dependency-version.service.js +++ b/services/npm/npm-dependency-version.service.js @@ -113,7 +113,7 @@ export default class NpmDependencyVersion extends NpmBase { async handle(namedParams, queryParams) { const { scope, packageName, registryUrl } = this.constructor.unpackParams( namedParams, - queryParams + queryParams, ) const { kind, dependency, dependencyScope } = namedParams const wantedDependency = `${ diff --git a/services/npm/npm-license.service.js b/services/npm/npm-license.service.js index ed354e28b8e0330bb2d15e0bda4b0f33b90fbbe5..7bc5b802e8ae514a5e30305096903dc5e80d5aef 100644 --- a/services/npm/npm-license.service.js +++ b/services/npm/npm-license.service.js @@ -32,7 +32,7 @@ export default class NpmLicense extends NpmBase { async handle(namedParams, queryParams) { const { scope, packageName, registryUrl } = this.constructor.unpackParams( namedParams, - queryParams + queryParams, ) const { license } = await this.fetchPackageData({ scope, @@ -40,7 +40,7 @@ export default class NpmLicense extends NpmBase { registryUrl, }) const licenses = toArray(license).map(license => - typeof license === 'string' ? license : license.type + typeof license === 'string' ? license : license.type, ) return this.constructor.render({ licenses }) } diff --git a/services/npm/npm-license.tester.js b/services/npm/npm-license.tester.js index a06aef4774ae153989762bc9f1c4875058908050..076a02830e35f6a3959ea67b61e94aa7b554d918 100644 --- a/services/npm/npm-license.tester.js +++ b/services/npm/npm-license.tester.js @@ -26,7 +26,7 @@ t.create('permissive license for scoped package') .expectBadge({ label: 'license', message: 'MIT', color: 'green' }) t.create( - 'permissive and copyleft licenses (SPDX license expression syntax version 2.0)' + 'permissive and copyleft licenses (SPDX license expression syntax version 2.0)', ) .get('/rho-cc-promise.json') .expectBadge({ @@ -43,7 +43,7 @@ t.create('license for package without a license property') .reply(200, { label: 'package-without-license', maintainers: [], - }) + }), ) .expectBadge({ label: 'license', message: 'missing', color: 'red' }) @@ -59,7 +59,7 @@ t.create('license for package with a license object') url: 'https://www.opensource.org/licenses/mit-license.php', }, maintainers: [], - }) + }), ) .expectBadge({ label: 'license', message: 'MIT', color: 'green' }) @@ -72,7 +72,7 @@ t.create('license for package with a license array') label: 'package-license-object', license: ['MPL-2.0', 'MIT'], maintainers: [], - }) + }), ) .expectBadge({ label: 'license', @@ -99,7 +99,7 @@ t.create('when json is malformed for scoped package') latest: '1.2.3', }, versions: null, - }) + }), ) .expectBadge({ label: 'license', diff --git a/services/npm/npm-type-definitions.service.js b/services/npm/npm-type-definitions.service.js index 9120b24593cae32442990aee200becd591afaf55..5c588d1b6f1473c5fad8d241963502d396e445b9 100644 --- a/services/npm/npm-type-definitions.service.js +++ b/services/npm/npm-type-definitions.service.js @@ -60,7 +60,7 @@ export default class NpmTypeDefinitions extends NpmBase { async handle(namedParams, queryParams) { const { scope, packageName, registryUrl } = this.constructor.unpackParams( namedParams, - queryParams + queryParams, ) const json = await this.fetchPackageData({ scope, diff --git a/services/npm/npm-type-definitions.tester.js b/services/npm/npm-type-definitions.tester.js index 84aff89701264a128400b290a29730e420b874ed..0029bdb36d9aaebd88f97e0c1af069898b2a2e79 100644 --- a/services/npm/npm-type-definitions.tester.js +++ b/services/npm/npm-type-definitions.tester.js @@ -3,7 +3,7 @@ import { createServiceTester } from '../tester.js' export const t = await createServiceTester() const isTypeDefinition = Joi.string().regex( - /^((Flow|TypeScript)|(Flow \| TypeScript))$/ + /^((Flow|TypeScript)|(Flow \| TypeScript))$/, ) t.create('types (from dev dependencies)') @@ -18,7 +18,7 @@ t.create('types (from files)') .reply(200, { maintainers: [], files: ['index.js', 'index.d.ts'], - }) + }), ) .expectBadge({ label: 'types', message: isTypeDefinition }) diff --git a/services/npm/npm-version.tester.js b/services/npm/npm-version.tester.js index 6afd23473c439b9a1e201701a98cc00baca2c2e3..0a2683ff982fe79028d233254154ceaf0139bd7c 100644 --- a/services/npm/npm-version.tester.js +++ b/services/npm/npm-version.tester.js @@ -22,7 +22,7 @@ t.create('gets the correct tagged package version of npm') .intercept(nock => nock('https://registry.npmjs.org') .get('/-/package/npm/dist-tags') - .reply(200, { latest: '1.2.3', next: '4.5.6' }) + .reply(200, { latest: '1.2.3', next: '4.5.6' }), ) .get('/npm/next.json') .expectBadge({ label: 'npm@next', message: 'v4.5.6' }) @@ -39,7 +39,7 @@ t.create('gets the tagged package version with a "/" in the tag name') .intercept(nock => nock('https://registry.npmjs.org') .get('/-/package/npm/dist-tags') - .reply(200, { 'release/1.0': '1.0.3', latest: '2.0.1' }) + .reply(200, { 'release/1.0': '1.0.3', latest: '2.0.1' }), ) .get('/npm/release/1.0.json') .expectBadge({ label: 'npm@release/1.0', message: 'v1.0.3' }) @@ -49,7 +49,7 @@ t.create('gets the tagged package version of @cycle/core') .expectBadge({ label: 'npm@canary', message: isSemver }) t.create( - 'gets the tagged package version of @cycle/core from a custom registry' + 'gets the tagged package version of @cycle/core from a custom registry', ) .get('/@cycle/core/canary.json?registry_uri=https://registry.npmjs.com') .expectBadge({ label: 'npm@canary', message: isSemver }) @@ -62,7 +62,7 @@ t.create("Response doesn't include a 'latest' key") .intercept(nock => nock('https://registry.npmjs.org') .get('/-/package/npm/dist-tags') - .reply(200, { next: 'v4.5.6' }) + .reply(200, { next: 'v4.5.6' }), ) .get('/npm.json') .expectBadge({ diff --git a/services/nuget/nuget-v2-service-family.js b/services/nuget/nuget-v2-service-family.js index 17bfc851ea9dd9c19b940b3cec9979f7d4bc0d48..e6c730ab99656ed12e47197c4684580cdc6e8be8 100644 --- a/services/nuget/nuget-v2-service-family.js +++ b/services/nuget/nuget-v2-service-family.js @@ -29,7 +29,7 @@ const jsonSchema = Joi.object({ Version: versionSchema, NormalizedVersion: Joi.string(), DownloadCount: nonNegativeInteger, - }) + }), ) .max(1) .default([]), @@ -55,7 +55,7 @@ const queryParamSchema = Joi.object({ async function fetch( serviceInstance, - { odataFormat, baseUrl, packageName, includePrereleases = false } + { odataFormat, baseUrl, packageName, includePrereleases = false }, ) { const url = `${baseUrl}/Packages()` const searchParams = { diff --git a/services/nuget/nuget-v3-service-family.js b/services/nuget/nuget-v3-service-family.js index ff4f37545c304e16ebfd3e5264c68f69a75bd8a7..3a82e7b41d1d7ebb8c78d6b3e73e848540f2736f 100644 --- a/services/nuget/nuget-v3-service-family.js +++ b/services/nuget/nuget-v3-service-family.js @@ -56,12 +56,12 @@ const schema = Joi.object({ .items( Joi.object({ version: Joi.string().required(), - }) + }), ) .default([]), totalDownloads: Joi.number().integer(), totaldownloads: Joi.number().integer(), - }) + }), ) .max(1) .default([]), @@ -72,7 +72,7 @@ const schema = Joi.object({ */ async function fetch( serviceInstance, - { baseUrl, packageName, includePrereleases = false } + { baseUrl, packageName, includePrereleases = false }, ) { return serviceInstance._requestJson({ schema, @@ -138,7 +138,7 @@ function createServiceFamily({ if (json.data.length === 1 && json.data[0].versions.length > 0) { const { versions: packageVersions } = json.data[0] const versions = packageVersions.map(item => - stripBuildMetadata(item.version) + stripBuildMetadata(item.version), ) return selectVersion(versions, includePrereleases) } else { diff --git a/services/nuget/nuget-v3-service-family.spec.js b/services/nuget/nuget-v3-service-family.spec.js index a6e49f6b6cb4608ed8562a82394b973c4db28e5e..f2f0bcd0ffde9642b6eb90b444e74c5521ac98ea 100644 --- a/services/nuget/nuget-v3-service-family.spec.js +++ b/services/nuget/nuget-v3-service-family.spec.js @@ -31,7 +31,7 @@ const tooMuchDataJson = { data: [{}, {}] } describe('Nuget Version service', function () { test(NugetVersionService.prototype.transform, () => { given({ json: versionJson(['1.0.0']), includePrereleases: false }).expect( - '1.0.0' + '1.0.0', ) given({ json: versionJson(['1.0.0', '1.0.1']), @@ -56,22 +56,22 @@ describe('Nuget Version service', function () { }).expect('1.0.1-beta1') given({ json: versionJson([]), includePrereleases: false }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: versionJson([]), includePrereleases: true }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: noDataJson, includePrereleases: false }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: noDataJson, includePrereleases: true }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: tooMuchDataJson, includePrereleases: false }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) given({ json: tooMuchDataJson, includePrereleases: true }).expectError( - 'Not Found: package not found' + 'Not Found: package not found', ) }) }) diff --git a/services/nuget/nuget.tester.js b/services/nuget/nuget.tester.js index 65878d6a11edd1dcf26ce8967fec6210282fd36b..db04852b1f7544a1f3b872c687f31cb856c8930a 100644 --- a/services/nuget/nuget.tester.js +++ b/services/nuget/nuget.tester.js @@ -31,14 +31,14 @@ t.create('total downloads (not found)') t.create('total downloads (unexpected second response)') .get('/dt/Microsoft.AspNetCore.Mvc.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2', ) - .reply(invalidJSON) + .reply(invalidJSON), ) .expectBadge({ label: 'downloads', message: 'unparseable json response' }) @@ -54,14 +54,14 @@ t.create('version (valid)') t.create('version (yellow badge)') .get('/v/Microsoft.AspNetCore.Mvc.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonWithDash) + .reply(200, nuGetV3VersionJsonWithDash), ) .expectBadge({ label: 'nuget', @@ -72,14 +72,14 @@ t.create('version (yellow badge)') t.create('version (orange badge)') .get('/v/Microsoft.AspNetCore.Mvc.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonFirstCharZero) + .reply(200, nuGetV3VersionJsonFirstCharZero), ) .expectBadge({ label: 'nuget', @@ -90,14 +90,14 @@ t.create('version (orange badge)') t.create('version (blue badge)') .get('/v/Microsoft.AspNetCore.Mvc.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonFirstCharNotZero) + .reply(200, nuGetV3VersionJsonFirstCharNotZero), ) .expectBadge({ label: 'nuget', @@ -109,12 +109,12 @@ t.create('version (blue badge)') t.create('version (build metadata with -)') .get('/v/MongoFramework.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get('/query?q=packageid%3Amongoframework&prerelease=true&semVerLevel=2') - .reply(200, nuGetV3VersionJsonBuildMetadataWithDash) + .reply(200, nuGetV3VersionJsonBuildMetadataWithDash), ) .expectBadge({ label: 'nuget', @@ -129,14 +129,14 @@ t.create('version (not found)') t.create('version (unexpected second response)') .get('/v/Microsoft.AspNetCore.Mvc.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2', ) - .reply(invalidJSON) + .reply(invalidJSON), ) .expectBadge({ label: 'nuget', message: 'unparseable json response' }) @@ -152,14 +152,14 @@ t.create('version (pre) (valid)') t.create('version (pre) (yellow badge)') .get('/vpre/Microsoft.AspNetCore.Mvc.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonWithDash) + .reply(200, nuGetV3VersionJsonWithDash), ) .expectBadge({ label: 'nuget', @@ -170,14 +170,14 @@ t.create('version (pre) (yellow badge)') t.create('version (pre) (orange badge)') .get('/vpre/Microsoft.AspNetCore.Mvc.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonFirstCharZero) + .reply(200, nuGetV3VersionJsonFirstCharZero), ) .expectBadge({ label: 'nuget', @@ -188,14 +188,14 @@ t.create('version (pre) (orange badge)') t.create('version (pre) (blue badge)') .get('/vpre/Microsoft.AspNetCore.Mvc.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2', ) - .reply(200, nuGetV3VersionJsonFirstCharNotZero) + .reply(200, nuGetV3VersionJsonFirstCharNotZero), ) .expectBadge({ label: 'nuget', @@ -210,13 +210,13 @@ t.create('version (pre) (not found)') t.create('version (pre) (unexpected second response)') .get('/vpre/Microsoft.AspNetCore.Mvc.json') .intercept(nock => - nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex) + nock('https://api.nuget.org').get('/v3/index.json').reply(200, queryIndex), ) .intercept(nock => nock('https://api-v2v3search-0.nuget.org') .get( - '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2' + '/query?q=packageid%3Amicrosoft.aspnetcore.mvc&prerelease=true&semVerLevel=2', ) - .reply(invalidJSON) + .reply(invalidJSON), ) .expectBadge({ label: 'nuget', message: 'unparseable json response' }) diff --git a/services/nycrc/nycrc.service.js b/services/nycrc/nycrc.service.js index 7afafc428fa178a90c4820b33ddf008cbd08bbe2..eb6a225d569c4742f6bbff4a6bc9d77f75e0b9f2 100644 --- a/services/nycrc/nycrc.service.js +++ b/services/nycrc/nycrc.service.js @@ -123,7 +123,7 @@ export default class Nycrc extends ConditionalGithubAuthV3Service { branch: 'HEAD', filename: config, }), - preferredThreshold + preferredThreshold, ) } return this.constructor.render({ coverage }) diff --git a/services/nycrc/nycrc.tester.js b/services/nycrc/nycrc.tester.js index 66894780a8df997c2ca1da02e11c05fa894c25b1..f9e4398d69118e6dd8b82b3d624091e35249b775 100644 --- a/services/nycrc/nycrc.tester.js +++ b/services/nycrc/nycrc.tester.js @@ -30,10 +30,10 @@ t.create('.nycrc in monorepo') content: Buffer.from( JSON.stringify({ lines: 99, - }) + }), ).toString('base64'), encoding: 'base64', - }) + }), ) .expectBadge({ label: 'min coverage', message: isIntegerPercentage }) @@ -46,10 +46,10 @@ t.create('.nycrc with no thresholds') content: Buffer.from( JSON.stringify({ reporter: 'foo', - }) + }), ).toString('base64'), encoding: 'base64', - }) + }), ) .expectBadge({ label: 'min coverage', @@ -67,10 +67,10 @@ t.create('package.json with nyc stanza') nyc: { lines: 99, }, - }) + }), ).toString('base64'), encoding: 'base64', - }) + }), ) .expectBadge({ label: 'min coverage', message: isIntegerPercentage }) @@ -83,10 +83,10 @@ t.create('package.json with nyc stanza, but no thresholds') content: Buffer.from( JSON.stringify({ nyc: {}, - }) + }), ).toString('base64'), encoding: 'base64', - }) + }), ) .expectBadge({ label: 'min coverage', diff --git a/services/obs/obs-build-status.js b/services/obs/obs-build-status.js index 0be8d3fd2553ffc642931af7eefed6881d69e4eb..834177c06478b1175cbb0308b8883f05a7a82d5e 100644 --- a/services/obs/obs-build-status.js +++ b/services/obs/obs-build-status.js @@ -16,7 +16,7 @@ const localStatuses = { const isBuildStatus = Joi.alternatives().try( gIsBuildStatus, - Joi.equal(...Object.keys(localStatuses)) + Joi.equal(...Object.keys(localStatuses)), ) function renderBuildStatusBadge({ repository, status }) { diff --git a/services/obs/obs.service.js b/services/obs/obs.service.js index d6c6304eeeb173c434a862342174ff1863a00550..f45f60cfdf9e769cddedb63f52ba3eda520e7c46 100644 --- a/services/obs/obs.service.js +++ b/services/obs/obs.service.js @@ -58,13 +58,13 @@ export default class ObsService extends BaseXmlService { parserOptions: { ignoreAttributes: false, }, - }) + }), ) } async handle( { project, packageName, repository, arch }, - { instance = 'https://api.opensuse.org' } + { instance = 'https://api.opensuse.org' }, ) { const resp = await this.fetch({ instance, diff --git a/services/opencollective/opencollective-all.tester.js b/services/opencollective/opencollective-all.tester.js index d827313c509ad088cd7c0c6d312fa0edff5f6881..b31ac58ec00cee3230d636591fe566f8fefccf9a 100644 --- a/services/opencollective/opencollective-all.tester.js +++ b/services/opencollective/opencollective-all.tester.js @@ -14,7 +14,7 @@ t.create('renders correctly') yearlyIncome: 157371, backersCount: 35, contributorsCount: 276, - }) + }), ) .expectBadge({ label: 'backers and sponsors', @@ -33,7 +33,7 @@ t.create('renders not found correctly') .intercept(nock => nock('https://opencollective.com/') .get('/nonexistent-collective.json') - .reply(404, 'Not found') + .reply(404, 'Not found'), ) .expectBadge({ label: 'backers and sponsors', diff --git a/services/opencollective/opencollective-backers.service.js b/services/opencollective/opencollective-backers.service.js index 3f2b7da4d7541fbd77095d101e7b7190ab973bb4..8c1f7321e76e074e97b21adae801d42e3345ddb4 100644 --- a/services/opencollective/opencollective-backers.service.js +++ b/services/opencollective/opencollective-backers.service.js @@ -19,7 +19,7 @@ export default class OpencollectiveBackers extends OpencollectiveBase { async handle({ collective }) { const { backersCount } = await this.fetchCollectiveBackersCount( collective, - { userType: 'users' } + { userType: 'users' }, ) return this.constructor.render(backersCount) } diff --git a/services/opencollective/opencollective-backers.tester.js b/services/opencollective/opencollective-backers.tester.js index 7163f9a5da4ceb37bf838d0e6767d755eb53a0d3..b69901cb1821df1269e2f0e1bdb8bc90fcc02166 100644 --- a/services/opencollective/opencollective-backers.tester.js +++ b/services/opencollective/opencollective-backers.tester.js @@ -68,7 +68,7 @@ t.create('renders correctly') { MemberId: 26404, type: 'USER', role: 'BACKER', tier: 'backer' }, { MemberId: 27026, type: 'USER', role: 'BACKER', tier: 'backer' }, { MemberId: 27132, type: 'USER', role: 'CONTRIBUTOR' }, - ]) + ]), ) .expectBadge({ label: 'backers', diff --git a/services/opencollective/opencollective-by-tier.tester.js b/services/opencollective/opencollective-by-tier.tester.js index c2179fef409a240885df345bfd8c583d2e43e9f1..0b5bb68c5427d65a863e0d0830002ff058e21d5d 100644 --- a/services/opencollective/opencollective-by-tier.tester.js +++ b/services/opencollective/opencollective-by-tier.tester.js @@ -56,7 +56,7 @@ t.create('renders correctly') role: 'BACKER', tier: 'monthly backer', }, - ]) + ]), ) .expectBadge({ label: 'monthly backers', @@ -70,7 +70,7 @@ t.create('shows 0 when given a non existent tier') .intercept(nock => nock('https://opencollective.com/') .get('/shields/members/all.json?TierId=1234567890') - .reply(200, []) + .reply(200, []), ) .expectBadge({ label: 'new tier', diff --git a/services/opencollective/opencollective-sponsors.service.js b/services/opencollective/opencollective-sponsors.service.js index 0f41df6f036577ae7f9a241f387faaaf9302aae1..30d486dbdceccb890f62a79f50c41f7019a379af 100644 --- a/services/opencollective/opencollective-sponsors.service.js +++ b/services/opencollective/opencollective-sponsors.service.js @@ -19,7 +19,7 @@ export default class OpencollectiveSponsors extends OpencollectiveBase { async handle({ collective }) { const { backersCount } = await this.fetchCollectiveBackersCount( collective, - { userType: 'organizations' } + { userType: 'organizations' }, ) return this.constructor.render(backersCount) } diff --git a/services/opencollective/opencollective-sponsors.tester.js b/services/opencollective/opencollective-sponsors.tester.js index 300af584c42ce190d3aae33a33e045c36c0fe25f..db6c97d4d323f783e65249d4979b5392815be096 100644 --- a/services/opencollective/opencollective-sponsors.tester.js +++ b/services/opencollective/opencollective-sponsors.tester.js @@ -60,7 +60,7 @@ t.create('renders correctly') role: 'BACKER', tier: 'monthly backer', }, - ]) + ]), ) .expectBadge({ label: 'sponsors', diff --git a/services/ore/ore-sponge-versions.spec.js b/services/ore/ore-sponge-versions.spec.js index b6c7accd798ce3213ed593206bb5dfa4423d81e0..9489c95b2aa5b8b01cc0541c7ae0753524788a7b 100644 --- a/services/ore/ore-sponge-versions.spec.js +++ b/services/ore/ore-sponge-versions.spec.js @@ -32,7 +32,7 @@ describe('OreSpongeVersions', function () { ], }, }), - ] + ], ).expect({ versions: ['1.23', '4.56'] }) }) diff --git a/services/ossf-scorecard/ossf-scorecard.service.js b/services/ossf-scorecard/ossf-scorecard.service.js index 9d17322943de42325d36fc691871b6078203ebcc..b729f52c13b5c2583047e45d9d7be9b244fa0364 100644 --- a/services/ossf-scorecard/ossf-scorecard.service.js +++ b/services/ossf-scorecard/ossf-scorecard.service.js @@ -8,7 +8,7 @@ const schema = Joi.object({ const ossfScorecardColorScale = colorScale( [2, 5, 8, 10], - ['red', 'yellow', 'yellowgreen', 'green', 'brightgreen'] + ['red', 'yellow', 'yellowgreen', 'green', 'brightgreen'], ) export default class OSSFScorecard extends BaseJsonService { diff --git a/services/ossf-scorecard/ossf-scorecard.tester.js b/services/ossf-scorecard/ossf-scorecard.tester.js index 853d97c520a53a1472cd83e27872ef62aa8063ea..7a953a18dbbd3be68ad8aca8a0026dd52a128e5f 100644 --- a/services/ossf-scorecard/ossf-scorecard.tester.js +++ b/services/ossf-scorecard/ossf-scorecard.tester.js @@ -12,7 +12,7 @@ t.create('score valid') 'yellow', 'yellowgreen', 'green', - 'brightgreen' + 'brightgreen', ), }) diff --git a/services/osslifecycle/osslifecycle.tester.js b/services/osslifecycle/osslifecycle.tester.js index 61420f85fcff6ca9a6a8a0f0889a5b06db894ed2..829af85f03c24648f6adc5ecf40a2a5799eec158 100644 --- a/services/osslifecycle/osslifecycle.tester.js +++ b/services/osslifecycle/osslifecycle.tester.js @@ -49,7 +49,7 @@ t.create('oss metadata in unexpected format') .reply(200, 'wrongkey=active'), { 'Content-Type': 'text/plain;charset=UTF-8', - } + }, ) .expectBadge({ label: 'oss lifecycle', diff --git a/services/package-json-helpers.js b/services/package-json-helpers.js index d6423de4827add4581cd06e8d727b91201c2dc02..1c913e1362e56e19aa0cdddf1f5f1519f5b88f20 100644 --- a/services/package-json-helpers.js +++ b/services/package-json-helpers.js @@ -16,7 +16,7 @@ const isDependencyMap = Joi.object() .pattern( /./, // This accepts a semver range, a URL, and many other possible values. - Joi.string().min(1).required() + Joi.string().min(1).required(), ) .default({}) diff --git a/services/packagecontrol/packagecontrol.service.js b/services/packagecontrol/packagecontrol.service.js index 58bf9e9f081881c1883d9e6239d4eb82256c142b..1753b93eeed6c546a3d06f1f7a4ef440f57c2a4e 100644 --- a/services/packagecontrol/packagecontrol.service.js +++ b/services/packagecontrol/packagecontrol.service.js @@ -13,7 +13,7 @@ const schema = Joi.object({ .items( Joi.object({ totals: Joi.array().items(nonNegativeInteger).required(), - }).required() + }).required(), ) .required(), }).required(), diff --git a/services/packagist/packagist-base.js b/services/packagist/packagist-base.js index a1b96934e634e93e6eca6e86901a65d37d5631d1..72b18bf391b92242eb42243eb50ab9ce72eb182f 100644 --- a/services/packagist/packagist-base.js +++ b/services/packagist/packagist-base.js @@ -7,9 +7,9 @@ const packageSchema = Joi.array().items( version: Joi.string().required(), require: Joi.alternatives( Joi.object().pattern(Joi.string(), Joi.string()).required(), - Joi.string().valid('__unset') + Joi.string().valid('__unset'), ), - }) + }), ) const allVersionsSchema = Joi.object({ @@ -150,7 +150,7 @@ class BasePackagistService extends BaseJsonService { .filter( version => typeof version.version === 'string' || - version.version instanceof String + version.version instanceof String, ) .map(version => version.version) if (versionStrings.length < 1) { diff --git a/services/packagist/packagist-base.spec.js b/services/packagist/packagist-base.spec.js index f528891bec2ce0ddf90fe9f5cc97a2a059abb09a..1b6f1ec462393466a2a2094b2e07357cb254a4db 100644 --- a/services/packagist/packagist-base.spec.js +++ b/services/packagist/packagist-base.spec.js @@ -64,13 +64,13 @@ describe('BasePackagistService', function () { 'foobar/foobar': minifiedSample, }, }, - 'foobar/foobar' + 'foobar/foobar', ) it('should expand the minified package array to match the expanded sample', function () { assert.deepStrictEqual( expanded, expandedSample, - 'The expanded array should match the sample' + 'The expanded array should match the sample', ) }) }) diff --git a/services/packagist/packagist-dependency-version.service.js b/services/packagist/packagist-dependency-version.service.js index 832f9c46a985b06fdc5ce3fbbe5a0f158dc60a3e..e772510876f5783a88ea1ccaab0dc97a0b38224e 100644 --- a/services/packagist/packagist-dependency-version.service.js +++ b/services/packagist/packagist-dependency-version.service.js @@ -102,7 +102,7 @@ export default class PackagistDependencyVersion extends BasePackagistService { let packageVersion const versions = BasePackagistService.expandPackageVersions( json, - this.getPackageName(user, repo) + this.getPackageName(user, repo), ) if (version === '') { @@ -114,7 +114,7 @@ export default class PackagistDependencyVersion extends BasePackagistService { user, repo, version, - server + server, ) } catch (e) { packageVersion = null @@ -188,7 +188,7 @@ export default class PackagistDependencyVersion extends BasePackagistService { const versions = BasePackagistService.expandPackageVersions( allData, - this.getPackageName(user, repo) + this.getPackageName(user, repo), ) return versions[this.findVersionIndex(versions, version)] diff --git a/services/packagist/packagist-dependency-version.spec.js b/services/packagist/packagist-dependency-version.spec.js index b03b2e39e6ee56d6a12e1c748b13567b20aec9ea..1ceb589825f806aaf87d099a4ab74f9a17db1b45 100644 --- a/services/packagist/packagist-dependency-version.spec.js +++ b/services/packagist/packagist-dependency-version.spec.js @@ -38,7 +38,7 @@ describe('PackagistDependencyVersion', function () { user: 'frodo', repo: 'the-one-package', version: 'v4.0.0', - }) + }), ).to.be.rejectedWith('invalid version') }) @@ -49,7 +49,7 @@ describe('PackagistDependencyVersion', function () { user: 'frodo', repo: 'the-one-package', version: 'v2.4.0', - }) + }), ).to.be.rejectedWith('version requirement not found') }) @@ -60,7 +60,7 @@ describe('PackagistDependencyVersion', function () { user: 'frodo', repo: 'the-one-package', version: 'v2.5.0', - }) + }), ).to.be.rejectedWith('version requirement not found') }) @@ -71,7 +71,7 @@ describe('PackagistDependencyVersion', function () { user: 'frodo', repo: 'the-one-package', dependency: 'twig/twig', - }) + }), ) .to.have.property('dependencyVersion') .that.equals('~1.28|~2.0') @@ -85,7 +85,7 @@ describe('PackagistDependencyVersion', function () { repo: 'the-one-package', version: 'v2.0.0', dependency: 'twig/twig', - }) + }), ) .to.have.property('dependencyVersion') .that.equals('~1.20|~1.30') diff --git a/services/packagist/packagist-downloads.tester.js b/services/packagist/packagist-downloads.tester.js index ee76c04e3f3cb059c3459228bf56c3bfb53954cb..fa0a255ae21fb32241588d41491e10b980eb1cd8 100644 --- a/services/packagist/packagist-downloads.tester.js +++ b/services/packagist/packagist-downloads.tester.js @@ -17,7 +17,7 @@ t.create('daily downloads (valid, no package version specified, custom server)') }) t.create( - 'daily downloads (invalid, no package version specified, invalid custom server)' + 'daily downloads (invalid, no package version specified, invalid custom server)', ) .get('/dd/doctrine/orm.json?server=https%3A%2F%2Fpackagist.com') .expectBadge({ @@ -33,7 +33,7 @@ t.create('monthly downloads (valid, no package version specified)') }) t.create( - 'monthly downloads (valid, no package version specified, custom server)' + 'monthly downloads (valid, no package version specified, custom server)', ) .get('/dm/doctrine/orm.json?server=https%3A%2F%2Fpackagist.org') .expectBadge({ @@ -42,7 +42,7 @@ t.create( }) t.create( - 'monthly downloads (valid, no package version specified, invalid custom server)' + 'monthly downloads (valid, no package version specified, invalid custom server)', ) .get('/dm/doctrine/orm.json?server=https%3A%2F%2Fpackagist.com') .expectBadge({ @@ -65,7 +65,7 @@ t.create('total downloads (valid, no package version specified, custom server)') }) t.create( - 'total downloads (valid, no package version specified, invalid custom server)' + 'total downloads (valid, no package version specified, invalid custom server)', ) .get('/dt/doctrine/orm.json?server=https%3A%2F%2Fpackagist.com') .expectBadge({ @@ -87,7 +87,7 @@ t.create('monthly downloads (invalid, package version in request)') .expectBadge({ label: '404', message: 'badge not found' }) t.create( - 'monthly downloads (invalid, package version in request, custom server)' + 'monthly downloads (invalid, package version in request, custom server)', ) .get('/dm/symfony/symfony/v2.8.0.json?server=https%3A%2F%2Fpackagist.org') .expectBadge({ label: '404', message: 'badge not found' }) diff --git a/services/packagist/packagist-license.service.js b/services/packagist/packagist-license.service.js index 4e48ea800ebbfe75dcfda5b1f3611a3d300ba1c1..0511d4cbc912ad8963e14ed11613bbc210ec23e5 100644 --- a/services/packagist/packagist-license.service.js +++ b/services/packagist/packagist-license.service.js @@ -13,7 +13,7 @@ const packageSchema = Joi.array() Joi.object({ version: Joi.string(), license: Joi.array(), - }).required() + }).required(), ) .required() @@ -60,7 +60,7 @@ export default class PackagistLicense extends BasePackagistService { const versions = BasePackagistService.expandPackageVersions( json, - packageName + packageName, ) const version = this.findLatestRelease(versions) diff --git a/services/packagist/packagist-license.spec.js b/services/packagist/packagist-license.spec.js index 063a8b9eec2a8cfa9e785ebb1e2e3dd522e54cad..5355681f2175e603a608d17fbb53003d29534d87 100644 --- a/services/packagist/packagist-license.spec.js +++ b/services/packagist/packagist-license.spec.js @@ -24,7 +24,7 @@ describe('PackagistLicense', function () { json, user: 'frodo', repo: 'the-one-package', - }) + }), ) .to.have.property('license') .that.equals('MIT-latest') @@ -51,7 +51,7 @@ describe('PackagistLicense', function () { json, user: 'frodo', repo: 'the-one-package', - }) + }), ) .to.have.property('license') .that.equals('MIT') @@ -78,7 +78,7 @@ describe('PackagistLicense', function () { json, user: 'frodo', repo: 'the-one-package', - }) + }), ) .to.have.property('license') .that.equals('MIT-latest') @@ -103,7 +103,7 @@ describe('PackagistLicense', function () { json, user: 'frodo', repo: 'the-one-package', - }) + }), ) .to.throw(NotFound) .with.property('prettyMessage', 'license not found') diff --git a/services/packagist/packagist-php-version.tester.js b/services/packagist/packagist-php-version.tester.js index 24d4c73e9f671b673cf1563c1f9c7ec925eeb2fe..1f131b9db4fd5bad6ec40341ebb0ab925715e52d 100644 --- a/services/packagist/packagist-php-version.tester.js +++ b/services/packagist/packagist-php-version.tester.js @@ -2,23 +2,23 @@ import { createServiceTester } from '../tester.js' export const t = await createServiceTester() t.create( - 'redirect getting required php version for the dependency from packagist (valid, package version not specified in request)' + 'redirect getting required php version for the dependency from packagist (valid, package version not specified in request)', ) .get('/symfony/symfony.json') .expectRedirect('/packagist/dependency-v/symfony/symfony/php.json?') t.create( - 'redirect getting required php version for the dependency from packagist (valid, package version specified in request)' + 'redirect getting required php version for the dependency from packagist (valid, package version specified in request)', ) .get('/symfony/symfony/v3.2.8.json') .expectRedirect( - '/packagist/dependency-v/symfony/symfony/php.json?version=v3.2.8' + '/packagist/dependency-v/symfony/symfony/php.json?version=v3.2.8', ) t.create( - 'redirect getting required php version for the dependency from packagist (valid, package version and server specified in request)' + 'redirect getting required php version for the dependency from packagist (valid, package version and server specified in request)', ) .get('/symfony/symfony/v3.2.8.json?server=https://packagist.org') .expectRedirect( - '/packagist/dependency-v/symfony/symfony/php.json?server=https%3A%2F%2Fpackagist.org&version=v3.2.8' + '/packagist/dependency-v/symfony/symfony/php.json?server=https%3A%2F%2Fpackagist.org&version=v3.2.8', ) diff --git a/services/packagist/packagist-version.service.js b/services/packagist/packagist-version.service.js index 5a62afd146c7941c99a3f29a8e76bea19d8c8005..ae78b0e4049788fbab325a4d55e99e70a8545974 100644 --- a/services/packagist/packagist-version.service.js +++ b/services/packagist/packagist-version.service.js @@ -11,7 +11,7 @@ import { const packageSchema = Joi.array().items( Joi.object({ version: Joi.string().required(), - }) + }), ) const schema = Joi.object({ @@ -77,7 +77,7 @@ class PackagistVersion extends BasePackagistService { async handle( { user, repo }, - { include_prereleases: includePrereleases, server } + { include_prereleases: includePrereleases, server }, ) { includePrereleases = includePrereleases !== undefined const json = await this.fetch({ diff --git a/services/packagist/packagist-version.tester.js b/services/packagist/packagist-version.tester.js index ba2c2797448f2864e547eeaef9733cee1e686599..facd21ddd7957400af84ab8d53071882d9a9adae 100644 --- a/services/packagist/packagist-version.tester.js +++ b/services/packagist/packagist-version.tester.js @@ -56,5 +56,5 @@ t.create('version (legacy redirect: vpre)') t.create('version (legacy redirect: vpre) (custom server)') .get('/vpre/symfony/symfony.svg?server=https%3A%2F%2Fpackagist.org') .expectRedirect( - '/packagist/v/symfony/symfony.svg?include_prereleases&server=https%3A%2F%2Fpackagist.org' + '/packagist/v/symfony/symfony.svg?include_prereleases&server=https%3A%2F%2Fpackagist.org', ) diff --git a/services/php-version.js b/services/php-version.js index 037fa2465856be3af41c3f46969b005ee38656d8..4bc2aef889964fcdae574c1683e17fcc3666d85b 100644 --- a/services/php-version.js +++ b/services/php-version.js @@ -279,11 +279,11 @@ async function getPhpReleases(githubApiProvider) { tags // only releases .filter( - tag => tag.ref.match(/^refs\/tags\/php-\d+\.\d+\.\d+$/) != null + tag => tag.ref.match(/^refs\/tags\/php-\d+\.\d+\.\d+$/) != null, ) // get minor version of release - .map(tag => tag.ref.match(/^refs\/tags\/php-(\d+\.\d+)\.\d+$/)[1]) - ) + .map(tag => tag.ref.match(/^refs\/tags\/php-(\d+\.\d+)\.\d+$/)[1]), + ), ), requestFetcher: githubApiProvider.fetch.bind(githubApiProvider, fetch), }) diff --git a/services/php-version.spec.js b/services/php-version.spec.js index 2ccd237dd3b253ee5be5953bc7275185d3eed0c2..3a6d2e4124a0f3f63d2aa1d549f6c60459389f6a 100644 --- a/services/php-version.spec.js +++ b/services/php-version.spec.js @@ -37,7 +37,7 @@ describe('Text PHP version', function () { given(['7.0', '7.1', '7.2'], phpReleases).expect(['>= 7']) given( ['5.0', '5.1', '5.2', '5.3', '5.4', '5.5', '5.6', '7.0', '7.1', '7.2'], - phpReleases + phpReleases, ).expect(['>= 5']) given(['7.1', '7.2'], phpReleases).expect(['>= 7.1']) given(['7.1'], phpReleases).expect(['7.1']) diff --git a/services/pingpong/pingpong-status.tester.js b/services/pingpong/pingpong-status.tester.js index 021e6c18978541833e8438293efcaa9639c441da..fe147a63f9d7623a6aa79847a9d7f13d17996eee 100644 --- a/services/pingpong/pingpong-status.tester.js +++ b/services/pingpong/pingpong-status.tester.js @@ -6,7 +6,7 @@ const isCorrectStatus = Joi.string().valid( 'up', 'issues', 'down', - 'maintenance' + 'maintenance', ) t.create('PingPong: Status (valid)') @@ -23,6 +23,6 @@ t.create('PingPong: Status (unexpected response)') nock => nock('https://api.pingpong.one') .get('/widget/shields/status/sp_key') - .reply(200, '{"status": "up"}') // unexpected status message + .reply(200, '{"status": "up"}'), // unexpected status message ) .expectBadge({ label: 'status', message: 'Unknown status received' }) diff --git a/services/pipenv-helpers.spec.js b/services/pipenv-helpers.spec.js index c126ace5dc2f06afe729b05c697476f67063cc80..af7244ac6401383c1735504a95601808c51c6619 100644 --- a/services/pipenv-helpers.spec.js +++ b/services/pipenv-helpers.spec.js @@ -34,7 +34,7 @@ describe('getDependencyVersion', function () { default: packages, develop: {}, }, - }) + }), ) .to.throw(InvalidParameter) .with.property('prettyMessage', 'default dependency not found') @@ -49,7 +49,7 @@ describe('getDependencyVersion', function () { default: packages, develop: {}, }, - }) + }), ) .to.throw(InvalidParameter) .with.property('prettyMessage', 'dev dependency not found') @@ -62,7 +62,7 @@ describe('getDependencyVersion', function () { lockfileData: { default: packages, }, - }) + }), ).to.deep.equal({ version: '3.0.4' }) }) @@ -75,7 +75,7 @@ describe('getDependencyVersion', function () { default: {}, develop: packages, }, - }) + }), ).to.deep.equal({ version: '3.0.4' }) }) @@ -87,7 +87,7 @@ describe('getDependencyVersion', function () { default: packages, develop: {}, }, - }) + }), ).to.deep.equal({ version: '3.0.4' }) }) @@ -99,7 +99,7 @@ describe('getDependencyVersion', function () { default: packages, develop: {}, }, - }) + }), ).to.deep.equal({ ref: '1.11.4001' }) }) @@ -111,7 +111,7 @@ describe('getDependencyVersion', function () { default: packages, develop: {}, }, - }) + }), ).to.deep.equal({ ref: '2df5a2b' }) }) @@ -123,7 +123,7 @@ describe('getDependencyVersion', function () { default: packages, develop: {}, }, - }) + }), ) .to.throw(InvalidParameter) .with.property('prettyMessage', 'No version or ref for django-cms') diff --git a/services/piwheels/piwheels-version.service.js b/services/piwheels/piwheels-version.service.js index b83e341c03a08e90e82bd9005d798de980d2620d..96b815e0c4353d6480eda7c5eafb7cd387a511a3 100644 --- a/services/piwheels/piwheels-version.service.js +++ b/services/piwheels/piwheels-version.service.js @@ -11,7 +11,7 @@ const schema = Joi.object({ prerelease: Joi.boolean().required(), yanked: Joi.boolean().required(), files: Joi.object().required(), - }) + }), ) .required(), }).required() @@ -69,7 +69,7 @@ export default class PiWheelsVersion extends BaseJsonService { yanked: releases[key].yanked, hasFiles: Object.keys(releases[key].files).length > 0, }), - [] + [], ) .filter(release => !release.yanked) // exclude any yanked releases .filter(release => release.hasFiles) // exclude any releases with no wheels diff --git a/services/piwheels/piwheels-version.spec.js b/services/piwheels/piwheels-version.spec.js index de69409f3e46ef9347aaa60e8237f1e86460ae51..70a9ee85c0373422506047143315b10d7091fe85 100644 --- a/services/piwheels/piwheels-version.spec.js +++ b/services/piwheels/piwheels-version.spec.js @@ -10,42 +10,42 @@ describe('PiWheelsVersion', function () { '2.0.0rc1': { prerelease: true, yanked: false, files: { foobar: {} } }, '1.9.0': { prerelease: false, yanked: false, files: { foobar: {} } }, }, - false + false, ).expect('1.9.0') given( { '2.0.0rc1': { prerelease: true, yanked: false, files: { foobar: {} } }, '1.9.0': { prerelease: false, yanked: false, files: { foobar: {} } }, }, - true + true, ).expect('2.0.0rc1') given( { '2.0.0': { prerelease: false, yanked: true, files: { foobar: {} } }, '1.9.0': { prerelease: false, yanked: false, files: { foobar: {} } }, }, - false + false, ).expect('1.9.0') given( { '2.0.0': { prerelease: false, yanked: false, files: {} }, '1.9.0': { prerelease: false, yanked: false, files: { foobar: {} } }, }, - false + false, ).expect('1.9.0') given( { '2.0.0': { prerelease: false, yanked: false, files: { foobar: {} } }, '1.9.0': { prerelease: false, yanked: false, files: { foobar: {} } }, }, - false + false, ).expect('2.0.0') given( { '2.0.0rc2': { prerelease: true, yanked: false, files: { foobar: {} } }, '2.0.0rc1': { prerelease: true, yanked: false, files: { foobar: {} } }, }, - false + false, ).expect('2.0.0rc2') }) @@ -56,8 +56,8 @@ describe('PiWheelsVersion', function () { '1.0.1': { prerelease: false, yanked: false, files: {} }, '1.0.0': { prerelease: false, yanked: true, files: { foobar: {} } }, }, - false - ) + false, + ), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'no versions found') diff --git a/services/poeditor/poeditor.tester.js b/services/poeditor/poeditor.tester.js index 691f4d816fa4cd97313b4f1ad72a59a7635b4981..1797ae78acda0d2897613cbfaefbd7b1bf400fde 100644 --- a/services/poeditor/poeditor.tester.js +++ b/services/poeditor/poeditor.tester.js @@ -51,7 +51,7 @@ t.create('gets mock POEditor progress') id: '1234', api_token: 'abc123def456', }) - .reply(200, apiResponse) + .reply(200, apiResponse), ) .expectBadge({ label: 'French', @@ -66,7 +66,7 @@ t.create('handles requests for missing languages') id: '1234', api_token: 'abc123def456', }) - .reply(200, apiResponse) + .reply(200, apiResponse), ) .expectBadge({ label: 'other', @@ -87,7 +87,7 @@ t.create('handles requests for wrong keys') code: '403', message: "You don't have permission to access this resource", }, - }) + }), ) .expectBadge({ label: 'other', diff --git a/services/polymart/polymart-base.js b/services/polymart/polymart-base.js index 9eec32824368c1a9294608bdaa5e5c6db4bb246d..205a2a3e90a4dfd329af0708b445ae685016d66a 100644 --- a/services/polymart/polymart-base.js +++ b/services/polymart/polymart-base.js @@ -28,7 +28,7 @@ const notFoundResourceSchema = Joi.object({ const resourceFoundOrNotSchema = Joi.alternatives( resourceSchema, - notFoundResourceSchema + notFoundResourceSchema, ) const documentation = ` diff --git a/services/powershellgallery/powershellgallery.tester.js b/services/powershellgallery/powershellgallery.tester.js index 77bffac138806d40ca5fcd87084c56bf3281ead4..82d1a5baffc12c7b82dba2bd27be8d75a49167d9 100644 --- a/services/powershellgallery/powershellgallery.tester.js +++ b/services/powershellgallery/powershellgallery.tester.js @@ -6,7 +6,7 @@ import { isVPlusDottedVersionNClausesWithOptionalSuffix, } from '../test-validators.js' const isPlatform = Joi.string().regex( - /^(windows|linux|macos)( \| (windows|linux|macos))*$/ + /^(windows|linux|macos)( \| (windows|linux|macos))*$/, ) export const t = new ServiceTester({ diff --git a/services/puppetforge/puppetforge-base.js b/services/puppetforge/puppetforge-base.js index 8adb266bec92aac8182a713f7b793580ee3cb077..2065bd70be444dd8e5a6bf337305994684656626 100644 --- a/services/puppetforge/puppetforge-base.js +++ b/services/puppetforge/puppetforge-base.js @@ -20,7 +20,7 @@ const modulesSchema = Joi.object({ Joi.object({ pdk: Joi.boolean().valid(false).required(), version: semver, - }).required() + }).required(), ), }).required() diff --git a/services/puppetforge/puppetforge-module-endorsement.tester.js b/services/puppetforge/puppetforge-module-endorsement.tester.js index 2f03a591fbbfd27a5806fd9826c884778ba3f003..1b369d75d6bfc969badcf3007bc4c7d05da5171c 100644 --- a/services/puppetforge/puppetforge-module-endorsement.tester.js +++ b/services/puppetforge/puppetforge-module-endorsement.tester.js @@ -19,7 +19,7 @@ t.create('module endorsement (no ratings)') feedback_score: null, downloads: 0, current_release: { pdk: false, version: '1.0.0' }, - }) + }), ) .expectBadge({ label: 'endorsement', diff --git a/services/puppetforge/puppetforge-module-feedback.tester.js b/services/puppetforge/puppetforge-module-feedback.tester.js index 24128bd7e1d9746c41a8c54c2f74027a3b94a0ed..ebd60fef9773b37979f715781656ae5b0b507ffe 100644 --- a/services/puppetforge/puppetforge-module-feedback.tester.js +++ b/services/puppetforge/puppetforge-module-feedback.tester.js @@ -17,7 +17,7 @@ t.create('module feedback (no ratings)') feedback_score: null, downloads: 0, current_release: { pdk: false, version: '1.0.0' }, - }) + }), ) .expectBadge({ label: 'score', diff --git a/services/pypi/pypi-base.js b/services/pypi/pypi-base.js index 48f7e43f8394b3d27cc55e1ba0cab9ffb88a2dd8..df4a38eb0f4f92981478c960ca318a95141db0c0 100644 --- a/services/pypi/pypi-base.js +++ b/services/pypi/pypi-base.js @@ -13,7 +13,7 @@ const schema = Joi.object({ .items( Joi.object({ packagetype: Joi.string().required(), - }) + }), ) .required(), }).required() diff --git a/services/pypi/pypi-django-versions.tester.js b/services/pypi/pypi-django-versions.tester.js index adba0a5e2b8927f2cf258a752358a6dcf054c8de..c3901a3a0854c0d7663d8968c0b554e621f64cc5 100644 --- a/services/pypi/pypi-django-versions.tester.js +++ b/services/pypi/pypi-django-versions.tester.js @@ -2,15 +2,15 @@ import { createServiceTester } from '../tester.js' export const t = await createServiceTester() t.create( - 'redirect supported django versions (valid, package version in request)' + 'redirect supported django versions (valid, package version in request)', ) .get('/djangorestframework/3.7.3.json') .expectRedirect( - '/pypi/frameworkversions/django/djangorestframework/3.7.3.json' + '/pypi/frameworkversions/django/djangorestframework/3.7.3.json', ) t.create( - 'redirect supported django versions (valid, no package version specified)' + 'redirect supported django versions (valid, no package version specified)', ) .get('/djangorestframework.json') .expectRedirect('/pypi/frameworkversions/django/djangorestframework.json') diff --git a/services/pypi/pypi-framework-versions.service.js b/services/pypi/pypi-framework-versions.service.js index 4f8d6fbd8171dfb37ace2a623bea275d7d523e93..dcaee14b235641f6efb981d09b0704ca5112014f 100644 --- a/services/pypi/pypi-framework-versions.service.js +++ b/services/pypi/pypi-framework-versions.service.js @@ -49,7 +49,7 @@ export default class PypiFrameworkVersion extends PypiBase { static route = { base: 'pypi/frameworkversions', pattern: `:frameworkName(${Object.keys(frameworkNameMap).join( - '|' + '|', )})/:packageName+`, } diff --git a/services/pypi/pypi-framework-versions.tester.js b/services/pypi/pypi-framework-versions.tester.js index 89d2f9821b7a76d1756cbb325d22a3d285d6e95c..e65cb73e36d274b79a505901a4cd89afd18297b7 100644 --- a/services/pypi/pypi-framework-versions.tester.js +++ b/services/pypi/pypi-framework-versions.tester.js @@ -3,7 +3,7 @@ import { createServiceTester } from '../tester.js' export const t = await createServiceTester() const isPipeSeparatedFrameworkVersions = Joi.string().regex( - /^([1-9]+(\.[0-9]+)?(?: \| )?)+$/ + /^([1-9]+(\.[0-9]+)?(?: \| )?)+$/, ) t.create('supported django versions (valid, package version in request)') diff --git a/services/pypi/pypi-helpers.js b/services/pypi/pypi-helpers.js index a57ea9c4f77af5155d24036e06b5653228061ec2..4a5f212c0f773aa7d9f2d4496f5d6c00488d10bc 100644 --- a/services/pypi/pypi-helpers.js +++ b/services/pypi/pypi-helpers.js @@ -72,7 +72,7 @@ function getLicenses(packageData) { } let licenses = parseClassifiers(packageData, /^License :: (.+)$/, true) .map(classifier => - classifier in spdxAliases ? spdxAliases[classifier] : classifier + classifier in spdxAliases ? spdxAliases[classifier] : classifier, ) .map(classifier => classifier.split(' :: ').pop()) .map(license => license.replace(' License', '')) @@ -95,10 +95,10 @@ function getPackageFormats(packageData) { const { urls } = packageData return { hasWheel: urls.some(({ packagetype }) => - ['wheel', 'bdist_wheel'].includes(packagetype) + ['wheel', 'bdist_wheel'].includes(packagetype), ), hasEgg: urls.some(({ packagetype }) => - ['egg', 'bdist_egg'].includes(packagetype) + ['egg', 'bdist_egg'].includes(packagetype), ), } } diff --git a/services/pypi/pypi-helpers.spec.js b/services/pypi/pypi-helpers.spec.js index b12b61ac46597ffcc48c9f036f5f5e6a537c1b78..1fe20ffc4903a8f0d895541b9d5a35426c895bf3 100644 --- a/services/pypi/pypi-helpers.spec.js +++ b/services/pypi/pypi-helpers.spec.js @@ -38,7 +38,7 @@ describe('PyPI helpers', function () { test(parseClassifiers, function () { given( classifiersFixture, - /^Programming Language :: Python :: ([\d.]+)$/ + /^Programming Language :: Python :: ([\d.]+)$/, ).expect(['2', '2.7', '3', '3.4', '3.5', '3.6']) given(classifiersFixture, /^Framework :: Django :: ([\d.]+)$/).expect([ @@ -48,12 +48,12 @@ describe('PyPI helpers', function () { given( classifiersFixture, - /^Programming Language :: Python :: Implementation :: (\S+)$/ + /^Programming Language :: Python :: Implementation :: (\S+)$/, ).expect(['cpython', 'pypy']) // regex that matches everything given(classifiersFixture, /^([\S\s+]+)$/).expect( - classifiersFixture.info.classifiers.map(e => e.toLowerCase()) + classifiersFixture.info.classifiers.map(e => e.toLowerCase()), ) // regex that matches nothing diff --git a/services/pypi/pypi-implementation.service.js b/services/pypi/pypi-implementation.service.js index b5a050fecdd37e1ab00d01babcbcb97c19a16885..bf03542989e032a21c1161150645fb85bdb717ee 100644 --- a/services/pypi/pypi-implementation.service.js +++ b/services/pypi/pypi-implementation.service.js @@ -30,7 +30,7 @@ export default class PypiImplementation extends PypiBase { let implementations = parseClassifiers( packageData, - /^Programming Language :: Python :: Implementation :: (\S+)$/ + /^Programming Language :: Python :: Implementation :: (\S+)$/, ) if (implementations.length === 0) { // Assume CPython. diff --git a/services/pypi/pypi-license.tester.js b/services/pypi/pypi-license.tester.js index 6567a90c2f4e71ace1f2e10524d87b20f1c472f2..f6332446fc4749a47c27e8d03679f48863e24418 100644 --- a/services/pypi/pypi-license.tester.js +++ b/services/pypi/pypi-license.tester.js @@ -25,7 +25,7 @@ t.create('license (from trove classifier)') classifiers: ['License :: OSI Approved :: MIT License'], }, urls: [], - }) + }), ) .expectBadge({ label: 'license', @@ -47,7 +47,7 @@ t.create('license (as acronym from trove classifier)') ], }, urls: [], - }) + }), ) .expectBadge({ label: 'license', diff --git a/services/pypi/pypi-python-versions.service.js b/services/pypi/pypi-python-versions.service.js index 569fc7aa993ecef3a923a48cc21d2678b145de7c..58651ab3d3a134b9b19958fbbceccf7852a092c4 100644 --- a/services/pypi/pypi-python-versions.service.js +++ b/services/pypi/pypi-python-versions.service.js @@ -31,7 +31,7 @@ export default class PypiPythonVersions extends PypiBase { return { message: Array.from(versionSet) .sort((v1, v2) => - semver.compare(semver.coerce(v1), semver.coerce(v2)) + semver.compare(semver.coerce(v1), semver.coerce(v2)), ) .join(' | '), color: 'blue', @@ -49,15 +49,15 @@ export default class PypiPythonVersions extends PypiBase { const versions = parseClassifiers( packageData, - /^Programming Language :: Python :: ([\d.]+)$/ + /^Programming Language :: Python :: ([\d.]+)$/, ) // If no versions are found yet, check "X :: Only" as a fallback. if (versions.length === 0) { versions.push( ...parseClassifiers( packageData, - /^Programming Language :: Python :: (\d+) :: Only$/ - ) + /^Programming Language :: Python :: (\d+) :: Only$/, + ), ) } diff --git a/services/pypi/pypi-python-versions.tester.js b/services/pypi/pypi-python-versions.tester.js index 36146ddf92a9777e5d370f156994ce7ff58e6695..ce39ddcd426f7630450a1781934058666c8bf8c4 100644 --- a/services/pypi/pypi-python-versions.tester.js +++ b/services/pypi/pypi-python-versions.tester.js @@ -3,7 +3,7 @@ import { createServiceTester } from '../tester.js' export const t = await createServiceTester() const isPipeSeparatedPythonVersions = Joi.string().regex( - /^([1-9]\.[0-9]+(?: \| )?)+$/ + /^([1-9]\.[0-9]+(?: \| )?)+$/, ) t.create('python versions (valid, package version in request)') diff --git a/services/pypi/pypi-status.service.js b/services/pypi/pypi-status.service.js index 77bff049aace18a544e8c2bef6446dfcede2523e..41586a90a5680ef8fe6dd0cdd436f50566676d67 100644 --- a/services/pypi/pypi-status.service.js +++ b/services/pypi/pypi-status.service.js @@ -51,7 +51,7 @@ export default class PypiStatus extends PypiBase { // https://pypi.org/pypi?%3Aaction=list_classifiers const status = parseClassifiers( packageData, - /^Development Status :: (\d - \S+)$/ + /^Development Status :: (\d - \S+)$/, ) .sort() .map(classifier => classifier.split(' - ').pop()) diff --git a/services/pypi/pypi-version.tester.js b/services/pypi/pypi-version.tester.js index 97d1bb0470b20fb1fff52155eea8526b465db721..d2b9c1c54142f971ab5e0a6b5671ec17f1e6a890 100644 --- a/services/pypi/pypi-version.tester.js +++ b/services/pypi/pypi-version.tester.js @@ -44,7 +44,7 @@ t.create('no trove classifiers') classifiers: [], }, urls: [], - }) + }), ) .expectBadge({ label: 'pypi', diff --git a/services/readthedocs/readthedocs.service.js b/services/readthedocs/readthedocs.service.js index 9b75e04cec90643fcb70635d6649c5b582ab0d69..6792e8cb35d539849ce1a11ff5153d300c546be9 100644 --- a/services/readthedocs/readthedocs.service.js +++ b/services/readthedocs/readthedocs.service.js @@ -47,7 +47,7 @@ export default class ReadTheDocs extends BaseSvgScrapingService { const { message: status } = await this._requestSvg({ schema, url: `https://readthedocs.org/projects/${encodeURIComponent( - project + project, )}/badge/`, options: { searchParams: { version } }, }) diff --git a/services/reddit/subreddit-subscribers.tester.js b/services/reddit/subreddit-subscribers.tester.js index 1038718d523c8bfec4675053d88fc2a8a5253fc4..1a9f5518b4b0d73fe6b399d141b25056bc9a9e51 100644 --- a/services/reddit/subreddit-subscribers.tester.js +++ b/services/reddit/subreddit-subscribers.tester.js @@ -35,7 +35,7 @@ t.create('subreddit-subscribers (private sub)') .intercept(nock => nock('https://www.reddit.com/r') .get('/centuryclub/about.json') - .reply(200, { kind: 't5', data: {} }) + .reply(200, { kind: 't5', data: {} }), ) .expectBadge({ label: 'reddit', diff --git a/services/reddit/user-karma.tester.js b/services/reddit/user-karma.tester.js index a7eb8d83c000257ac97a29209fb71f813b99dcd0..4bf9b828d9f95121f7a639f3969e264218ec63a5 100644 --- a/services/reddit/user-karma.tester.js +++ b/services/reddit/user-karma.tester.js @@ -35,7 +35,7 @@ t.create('user-karma (link - math check)') .intercept(nock => nock('https://www.reddit.com/u') .get('/user_simulator/about.json') - .reply(200, { kind: 't2', data: { link_karma: 20, comment_karma: 80 } }) + .reply(200, { kind: 't2', data: { link_karma: 20, comment_karma: 80 } }), ) .expectBadge({ label: 'u/user_simulator karma (link)', @@ -47,7 +47,7 @@ t.create('user-karma (comment - math check)') .intercept(nock => nock('https://www.reddit.com/u') .get('/user_simulator/about.json') - .reply(200, { kind: 't2', data: { link_karma: 20, comment_karma: 80 } }) + .reply(200, { kind: 't2', data: { link_karma: 20, comment_karma: 80 } }), ) .expectBadge({ label: 'u/user_simulator karma (comment)', @@ -59,7 +59,7 @@ t.create('user-karma (combined - math check)') .intercept(nock => nock('https://www.reddit.com/u') .get('/user_simulator/about.json') - .reply(200, { kind: 't2', data: { link_karma: 20, comment_karma: 80 } }) + .reply(200, { kind: 't2', data: { link_karma: 20, comment_karma: 80 } }), ) .expectBadge({ label: 'u/user_simulator karma', @@ -71,7 +71,7 @@ t.create('user-karma (combined - missing data)') .intercept(nock => nock('https://www.reddit.com/u') .get('/user_simulator/about.json') - .reply(200, { kind: 't2', data: { link_karma: 20 } }) + .reply(200, { kind: 't2', data: { link_karma: 20 } }), ) .expectBadge({ label: 'reddit karma', diff --git a/services/reuse/reuse-compliance.tester.js b/services/reuse/reuse-compliance.tester.js index 65394aec5e9f4407eb61a6e724a1b598499caf71..e3c559149ab8c8656deeae9968260ba2d1d81d3f 100644 --- a/services/reuse/reuse-compliance.tester.js +++ b/services/reuse/reuse-compliance.tester.js @@ -15,7 +15,7 @@ t.create('valid repo -- compliant') .intercept(nock => nock('https://api.reuse.software/status') .get('/github.com/username/repo') - .reply(200, { status: 'compliant' }) + .reply(200, { status: 'compliant' }), ) .expectBadge({ label: 'reuse', @@ -28,7 +28,7 @@ t.create('valid repo -- non-compliant') .intercept(nock => nock('https://api.reuse.software/status') .get('/github.com/username/repo') - .reply(200, { status: 'non-compliant' }) + .reply(200, { status: 'non-compliant' }), ) .expectBadge({ label: 'reuse', @@ -41,7 +41,7 @@ t.create('valid repo -- checking') .intercept(nock => nock('https://api.reuse.software/status') .get('/github.com/username/repo') - .reply(200, { status: 'checking' }) + .reply(200, { status: 'checking' }), ) .expectBadge({ label: 'reuse', @@ -54,7 +54,7 @@ t.create('valid repo -- unregistered') .intercept(nock => nock('https://api.reuse.software/status') .get('/github.com/username/repo') - .reply(200, { status: 'unregistered' }) + .reply(200, { status: 'unregistered' }), ) .expectBadge({ label: 'reuse', diff --git a/services/ros/ros-version.service.js b/services/ros/ros-version.service.js index 7e2d02ff043c0e7d2ca570d469fc7f30e185c793..1bb288084b2182f4fba2b393f37f1355353408a2 100644 --- a/services/ros/ros-version.service.js +++ b/services/ros/ros-version.service.js @@ -128,7 +128,7 @@ export default class RosVersion extends GithubAuthV4Service { } const version = this.constructor._parseReleaseVersionFromDistro( contentJson.data.repository.object.text, - repoName + repoName, ) return { ...renderVersionBadge({ version }), label: `ros | ${distro}` } @@ -157,7 +157,7 @@ export default class RosVersion extends GithubAuthV4Service { repoSchema, { prettyErrorMessage: `invalid section for ${repoName} in distribution.yml`, - } + }, ) // Strip off "release inc" suffix diff --git a/services/ros/ros-version.service.spec.js b/services/ros/ros-version.service.spec.js index f221198745f28e6a7c4f2d4f11ae931c87613124..c6c2d34956ec517d09ef3831b97236fdc14f658d 100644 --- a/services/ros/ros-version.service.spec.js +++ b/services/ros/ros-version.service.spec.js @@ -37,8 +37,8 @@ repositories: type: distribution version: 2 `, - 'vision_msgs' - ) + 'vision_msgs', + ), ).to.equal('4.0.0') }) }) diff --git a/services/scrutinizer/scrutinizer-build.service.js b/services/scrutinizer/scrutinizer-build.service.js index 44c1f54e44b9e1364dd566554db0c0f9b6ea0718..a48a3ada7c14211f945b8e111a4cf74c848eefde 100644 --- a/services/scrutinizer/scrutinizer-build.service.js +++ b/services/scrutinizer/scrutinizer-build.service.js @@ -11,7 +11,7 @@ const schema = Joi.object({ build_status: Joi.object({ status: Joi.alternatives().try(isBuildStatus, Joi.equal('unknown')), }).required(), - }) + }), ) .required(), }).required() diff --git a/services/scrutinizer/scrutinizer-build.tester.js b/services/scrutinizer/scrutinizer-build.tester.js index 37185bf16ba527c7c09a2e1396ef76efaa2d9f86..00223515061fe7021147fc108c2b9d566bb4e4a6 100644 --- a/services/scrutinizer/scrutinizer-build.tester.js +++ b/services/scrutinizer/scrutinizer-build.tester.js @@ -42,7 +42,7 @@ t.create('build - unknown status') }, }, }, - }) + }), ) .expectBadge({ label: 'build', diff --git a/services/scrutinizer/scrutinizer-coverage.service.js b/services/scrutinizer/scrutinizer-coverage.service.js index cedd137e74203db796a130ff6935af886e9557b7..77bd5c73e17f7de0275a45f824f902739d07caec 100644 --- a/services/scrutinizer/scrutinizer-coverage.service.js +++ b/services/scrutinizer/scrutinizer-coverage.service.js @@ -18,7 +18,7 @@ const schema = Joi.object({ }).required(), }).required(), }), - }) + }), ) .required(), }).required() diff --git a/services/scrutinizer/scrutinizer-coverage.spec.js b/services/scrutinizer/scrutinizer-coverage.spec.js index 2928f54f5f690cb0ca0cf814a0aea4df6a022ee3..e83768d8ce6395159d48af32b43b92035cbf79d7 100644 --- a/services/scrutinizer/scrutinizer-coverage.spec.js +++ b/services/scrutinizer/scrutinizer-coverage.spec.js @@ -62,7 +62,7 @@ describe('ScrutinizerCoverage', function () { }, }, }, - }) + }), ) .to.throw(InvalidResponse) .with.property('prettyMessage', 'metrics missing for branch') diff --git a/services/scrutinizer/scrutinizer-quality.service.js b/services/scrutinizer/scrutinizer-quality.service.js index 93939a554da62febb7017ef17a9b595d62ad9f80..f0b69896fba605379624b991812af1ae8949c1df 100644 --- a/services/scrutinizer/scrutinizer-quality.service.js +++ b/services/scrutinizer/scrutinizer-quality.service.js @@ -17,14 +17,14 @@ const schema = Joi.object({ }).required(), }).required(), }), - }) + }), ) .required(), }).required() const scale = colorScale( [4, 5, 7, 9], - ['red', 'orange', 'yellow', 'green', 'brightgreen'] + ['red', 'orange', 'yellow', 'green', 'brightgreen'], ) class ScrutinizerQualityBase extends ScrutinizerBase { diff --git a/services/scrutinizer/scrutinizer-quality.tester.js b/services/scrutinizer/scrutinizer-quality.tester.js index 9009a9d1823a78ecf6938b647dcb4afdd3f71269..e4dfbe1e2f2cb128729215f7177c03e744304ce9 100644 --- a/services/scrutinizer/scrutinizer-quality.tester.js +++ b/services/scrutinizer/scrutinizer-quality.tester.js @@ -59,7 +59,7 @@ t.create('code quality data missing for default branch') }, }, }, - }) + }), ) .expectBadge({ label: 'code quality', diff --git a/services/scrutinizer/scrutinizer-redirect.tester.js b/services/scrutinizer/scrutinizer-redirect.tester.js index b1d8abc51083bd991544ac13b95f8c642ebf5b1c..d13a38bd2a547c34b7f6d83de7ac71d1897bd2f3 100644 --- a/services/scrutinizer/scrutinizer-redirect.tester.js +++ b/services/scrutinizer/scrutinizer-redirect.tester.js @@ -21,7 +21,7 @@ t.create('scrutinizer quality Bitbucket') t.create('scrutinizer quality Bitbucket (branch)') .get('/b/atlassian/python-bitbucket/develop.svg') .expectRedirect( - '/scrutinizer/quality/b/atlassian/python-bitbucket/develop.svg' + '/scrutinizer/quality/b/atlassian/python-bitbucket/develop.svg', ) t.create('scrutinizer quality GitLab') diff --git a/services/sonar/sonar-base.js b/services/sonar/sonar-base.js index aaa29d3346df3694f3f33a254b7d7b891dc9b6f8..9c4454a8419dad12d527fea6877b7f6b57f8b158 100644 --- a/services/sonar/sonar-base.js +++ b/services/sonar/sonar-base.js @@ -22,9 +22,9 @@ const modernSchema = Joi.object({ metric: Joi.string().required(), value: Joi.alternatives( Joi.number().min(0), - Joi.allow('OK', 'ERROR') + Joi.allow('OK', 'ERROR'), ).required(), - }) + }), ) .min(0) .required(), @@ -40,12 +40,12 @@ const legacySchema = Joi.array() key: Joi.string().required(), val: Joi.alternatives( Joi.number().min(0), - Joi.allow('OK', 'ERROR') + Joi.allow('OK', 'ERROR'), ).required(), - }) + }), ) .required(), - }).required() + }).required(), ) .required() @@ -87,7 +87,7 @@ export default class SonarBase extends BaseJsonService { httpErrors: { 404: 'component or metric not found, or legacy API not supported', }, - }) + }), ) } diff --git a/services/sonar/sonar-coverage.tester.js b/services/sonar/sonar-coverage.tester.js index ed360b0aae116621d1885133135db66dd6551b61..9e4b18cc4393d53eb3a8fb5324032d2671d8cbd0 100644 --- a/services/sonar/sonar-coverage.tester.js +++ b/services/sonar/sonar-coverage.tester.js @@ -24,7 +24,7 @@ t.create('Coverage (branch)') t.create('Coverage (legacy API supported)') .get( - '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -44,7 +44,7 @@ t.create('Coverage (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'coverage', diff --git a/services/sonar/sonar-documented-api-density.tester.js b/services/sonar/sonar-documented-api-density.tester.js index 6eb0ea74219dd339dbcd6a53a1bccfabd177bd5e..cde30fe3fc15b3aaee96d02975a45efb2c2571a0 100644 --- a/services/sonar/sonar-documented-api-density.tester.js +++ b/services/sonar/sonar-documented-api-density.tester.js @@ -20,7 +20,7 @@ t.create('Documented API Density (not found)') t.create('Documented API Density') .get( - '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.somewhatold.com&sonarVersion=6.1' + '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.somewhatold.com&sonarVersion=6.1', ) .intercept(nock => nock('http://sonar.somewhatold.com/api') @@ -38,7 +38,7 @@ t.create('Documented API Density') }, ], }, - }) + }), ) .expectBadge({ label: 'public documented api density', @@ -47,7 +47,7 @@ t.create('Documented API Density') t.create('Documented API Density (legacy API supported)') .get( - '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -67,7 +67,7 @@ t.create('Documented API Density (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'public documented api density', diff --git a/services/sonar/sonar-fortify-rating.spec.js b/services/sonar/sonar-fortify-rating.spec.js index ba5869b0dc88ebd50412e36db2e90f63ddcc2aed..4fa12729598b63b034ae027ccdfec1377cffb825 100644 --- a/services/sonar/sonar-fortify-rating.spec.js +++ b/services/sonar/sonar-fortify-rating.spec.js @@ -39,8 +39,8 @@ describe('SonarFortifyRating', function () { defaultContext, config, { component: 'org.ow2.petals:petals-se-ase' }, - { server: 'http://sonar.petalslink.com' } - ) + { server: 'http://sonar.petalslink.com' }, + ), ).to.deep.equal({ color: 'green', message: '4/5', diff --git a/services/sonar/sonar-fortify-rating.tester.js b/services/sonar/sonar-fortify-rating.tester.js index c6efb951777e9b665ee9e857fb3239d9e166ac34..653095cad5e4e1bfed1229d8fa69a8bb5d145651 100644 --- a/services/sonar/sonar-fortify-rating.tester.js +++ b/services/sonar/sonar-fortify-rating.tester.js @@ -29,7 +29,7 @@ t.create('Fortify Security Rating') }, ], }, - }) + }), ) .expectBadge({ label: 'fortify-security-rating', @@ -38,7 +38,7 @@ t.create('Fortify Security Rating') t.create('Fortify Security Rating (legacy API supported)') .get( - '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -58,7 +58,7 @@ t.create('Fortify Security Rating (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'fortify-security-rating', @@ -67,7 +67,7 @@ t.create('Fortify Security Rating (legacy API supported)') t.create('Fortify Security Rating (legacy API not supported)') .get( - '/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io&sonarVersion=4.2' + '/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io&sonarVersion=4.2', ) .expectBadge({ label: 'fortify-security-rating', @@ -83,7 +83,7 @@ t.create('Fortify Security Rating (nonexistent component)') t.create('Fortify Security Rating (legacy API metric not found)') .get( - '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -98,7 +98,7 @@ t.create('Fortify Security Rating (legacy API metric not found)') { msr: [], }, - ]) + ]), ) .expectBadge({ label: 'fortify-security-rating', diff --git a/services/sonar/sonar-generic.tester.js b/services/sonar/sonar-generic.tester.js index 6124eee2adc87d01b067ade5edb6bcc06d826081..66f47b266213a74ec75b5ca55eee81c90861d52f 100644 --- a/services/sonar/sonar-generic.tester.js +++ b/services/sonar/sonar-generic.tester.js @@ -5,7 +5,7 @@ export const t = await createServiceTester() t.create('Security Rating') .timeout(10000) .get( - '/security_rating/com.luckybox:luckybox.json?server=https://sonarcloud.io' + '/security_rating/com.luckybox:luckybox.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'security rating', @@ -16,7 +16,7 @@ t.create('Security Rating') t.create('Security Rating (branch)') .timeout(10000) .get( - '/security_rating/com.luckybox:luckybox/master.json?server=https://sonarcloud.io' + '/security_rating/com.luckybox:luckybox/master.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'security rating', diff --git a/services/sonar/sonar-helpers.js b/services/sonar/sonar-helpers.js index f27da1125d500d1b340842652195db1b7dedeab4..b9fb0d8da2680c8311cb5f269848cae8c8c686f0 100644 --- a/services/sonar/sonar-helpers.js +++ b/services/sonar/sonar-helpers.js @@ -12,12 +12,12 @@ const ratingScaleColors = [ ] const negativeMetricColorScale = colorScale( ratingPercentageScaleSteps, - ratingScaleColors + ratingScaleColors, ) const positiveMetricColorScale = colorScale( ratingPercentageScaleSteps, ratingScaleColors, - true + true, ) function isLegacyVersion({ sonarVersion }) { @@ -32,7 +32,7 @@ const sonarVersionSchema = Joi.alternatives( Joi.string() .regex(/[0-9.]+/) .optional(), - Joi.number().optional() + Joi.number().optional(), ) const queryParamSchema = Joi.object({ diff --git a/services/sonar/sonar-quality-gate.tester.js b/services/sonar/sonar-quality-gate.tester.js index 2deca1defc49e08de1b6381fb7b89d0e4686450f..1e74194b2a897ca4bf7363e0ca7cb574672a48be 100644 --- a/services/sonar/sonar-quality-gate.tester.js +++ b/services/sonar/sonar-quality-gate.tester.js @@ -12,7 +12,7 @@ const isQualityGateStatus = Joi.allow('passed', 'failed') t.create('Quality Gate') .get( - '/quality_gate/swellaby%3Aazdo-shellcheck.json?server=https://sonarcloud.io' + '/quality_gate/swellaby%3Aazdo-shellcheck.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'quality gate', @@ -21,7 +21,7 @@ t.create('Quality Gate') t.create('Quality Gate (branch)') .get( - '/quality_gate/swellaby%3Aazdo-shellcheck/master.json?server=https://sonarcloud.io' + '/quality_gate/swellaby%3Aazdo-shellcheck/master.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'quality gate', @@ -30,7 +30,7 @@ t.create('Quality Gate (branch)') t.create('Quality Gate (Alert Status)') .get( - '/alert_status/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/alert_status/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -50,7 +50,7 @@ t.create('Quality Gate (Alert Status)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'quality gate', @@ -61,7 +61,7 @@ t.create('Quality Gate (Alert Status)') // https://github.com/badges/shields/pull/6636#issuecomment-886172161 t.create('Quality Gate (version >= 6.6)') .get( - '/quality_gate/de.chkpnt%3Atruststorebuilder-gradle-plugin.json?server=https://sonar.chkpnt.de&sonarVersion=8.9' + '/quality_gate/de.chkpnt%3Atruststorebuilder-gradle-plugin.json?server=https://sonar.chkpnt.de&sonarVersion=8.9', ) .expectBadge({ label: 'quality gate', diff --git a/services/sonar/sonar-redirector.tester.js b/services/sonar/sonar-redirector.tester.js index 286d92be7a2dfb456402f0272057ef2036c76d33..9fe2fe2fe1f8be87b1367ea6f9e5407876b9a268 100644 --- a/services/sonar/sonar-redirector.tester.js +++ b/services/sonar/sonar-redirector.tester.js @@ -9,38 +9,38 @@ export const t = new ServiceTester({ t.create('sonar version') .get( - '/4.2/http/sonar.petalslink.com/org.ow2.petals:petals-se-ase/alert_status.svg' + '/4.2/http/sonar.petalslink.com/org.ow2.petals:petals-se-ase/alert_status.svg', ) .expectRedirect( `/sonar/alert_status/org.ow2.petals:petals-se-ase.svg?${queryString.stringify( { server: 'http://sonar.petalslink.com', sonarVersion: '4.2', - } - )}` + }, + )}`, ) t.create('sonar host parameter') .get( - '/http/sonar.petalslink.com/org.ow2.petals:petals-se-ase/alert_status.svg' + '/http/sonar.petalslink.com/org.ow2.petals:petals-se-ase/alert_status.svg', ) .expectRedirect( `/sonar/alert_status/org.ow2.petals:petals-se-ase.svg?${queryString.stringify( { server: 'http://sonar.petalslink.com', - } - )}` + }, + )}`, ) t.create('sonar host parameter with version') .get( - '/http/sonar.petalslink.com/org.ow2.petals:petals-se-ase/alert_status.svg?sonarVersion=4.2' + '/http/sonar.petalslink.com/org.ow2.petals:petals-se-ase/alert_status.svg?sonarVersion=4.2', ) .expectRedirect( `/sonar/alert_status/org.ow2.petals:petals-se-ase.svg?${queryString.stringify( { server: 'http://sonar.petalslink.com', sonarVersion: '4.2', - } - )}` + }, + )}`, ) diff --git a/services/sonar/sonar-tech-debt.tester.js b/services/sonar/sonar-tech-debt.tester.js index ace52b7d2ee00acfe53bb59c60c5c0acda6e0436..27da73743a66b5aa574f5711d4bbb12fe6a061a3 100644 --- a/services/sonar/sonar-tech-debt.tester.js +++ b/services/sonar/sonar-tech-debt.tester.js @@ -10,7 +10,7 @@ export const t = await createServiceTester() t.create('Tech Debt') .get( - '/tech_debt/brave_brave-core.json?server=https://sonarcloud.io&sonarVersion=9.0' + '/tech_debt/brave_brave-core.json?server=https://sonarcloud.io&sonarVersion=9.0', ) .expectBadge({ label: 'tech debt', @@ -26,7 +26,7 @@ t.create('Tech Debt (branch)') t.create('Tech Debt (legacy API supported)') .get( - '/tech_debt/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/tech_debt/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -46,7 +46,7 @@ t.create('Tech Debt (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'tech debt', diff --git a/services/sonar/sonar-tests.service.js b/services/sonar/sonar-tests.service.js index 90b5adbc1ac4bbe8922f2bc5ce3ab50319ed0fbf..6cbf153850a9ce30a4a34168b012978e784be3c9 100644 --- a/services/sonar/sonar-tests.service.js +++ b/services/sonar/sonar-tests.service.js @@ -102,7 +102,7 @@ class SonarTestsSummary extends SonarBase { passed_label: passedLabel, failed_label: failedLabel, skipped_label: skippedLabel, - } + }, ) { const json = await this.fetch({ sonarVersion, diff --git a/services/sonar/sonar-tests.tester.js b/services/sonar/sonar-tests.tester.js index b9315a266a0f1528259d57a586a895cbd60bb675..5e7762115a4d801237db81ed41ff75a78d972d98 100644 --- a/services/sonar/sonar-tests.tester.js +++ b/services/sonar/sonar-tests.tester.js @@ -15,7 +15,7 @@ export const t = new ServiceTester({ }) const isMetricAllowZero = Joi.alternatives( isMetric, - Joi.number().valid(0).required() + Joi.number().valid(0).required(), ) // The service tests targeting the legacy SonarQube API are mocked @@ -27,7 +27,7 @@ const isMetricAllowZero = Joi.alternatives( t.create('Tests') .timeout(10000) .get( - '/tests/swellaby:azure-pipelines-templates.json?server=https://sonarcloud.io' + '/tests/swellaby:azure-pipelines-templates.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'tests', @@ -37,7 +37,7 @@ t.create('Tests') t.create('Tests (branch)') .timeout(10000) .get( - '/tests/swellaby:azure-pipelines-templates/master.json?server=https://sonarcloud.io' + '/tests/swellaby:azure-pipelines-templates/master.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'tests', @@ -46,7 +46,7 @@ t.create('Tests (branch)') t.create('Tests (legacy API supported)') .get( - '/tests/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/tests/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -74,7 +74,7 @@ t.create('Tests (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'tests', @@ -122,7 +122,7 @@ t.create('Tests with compact message and custom labels') t.create('Total Test Count') .timeout(10000) .get( - '/total_tests/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io' + '/total_tests/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'total tests', @@ -132,7 +132,7 @@ t.create('Total Test Count') t.create('Total Test Count (branch)') .timeout(10000) .get( - '/total_tests/swellaby:azdo-shellcheck/master.json?server=https://sonarcloud.io' + '/total_tests/swellaby:azdo-shellcheck/master.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'total tests', @@ -141,7 +141,7 @@ t.create('Total Test Count (branch)') t.create('Total Test Count (legacy API supported)') .get( - '/total_tests/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/total_tests/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -161,7 +161,7 @@ t.create('Total Test Count (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'total tests', @@ -171,7 +171,7 @@ t.create('Total Test Count (legacy API supported)') t.create('Test Failures Count') .timeout(10000) .get( - '/test_failures/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io' + '/test_failures/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'test failures', @@ -180,7 +180,7 @@ t.create('Test Failures Count') t.create('Test Failures Count (legacy API supported)') .get( - '/test_failures/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/test_failures/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -200,7 +200,7 @@ t.create('Test Failures Count (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'test failures', @@ -210,7 +210,7 @@ t.create('Test Failures Count (legacy API supported)') t.create('Test Errors Count') .timeout(10000) .get( - '/test_errors/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io' + '/test_errors/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'test errors', @@ -219,7 +219,7 @@ t.create('Test Errors Count') t.create('Test Errors Count (legacy API supported)') .get( - '/test_errors/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/test_errors/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -239,7 +239,7 @@ t.create('Test Errors Count (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'test errors', @@ -249,7 +249,7 @@ t.create('Test Errors Count (legacy API supported)') t.create('Skipped Tests Count') .timeout(10000) .get( - '/skipped_tests/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io' + '/skipped_tests/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'skipped tests', @@ -258,7 +258,7 @@ t.create('Skipped Tests Count') t.create('Skipped Tests Count (legacy API supported)') .get( - '/skipped_tests/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/skipped_tests/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -278,7 +278,7 @@ t.create('Skipped Tests Count (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'skipped tests', @@ -288,7 +288,7 @@ t.create('Skipped Tests Count (legacy API supported)') t.create('Test Success Rate') .timeout(10000) .get( - '/test_success_density/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io' + '/test_success_density/swellaby:azdo-shellcheck.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'tests', @@ -297,7 +297,7 @@ t.create('Test Success Rate') t.create('Test Success Rate (legacy API supported)') .get( - '/test_success_density/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/test_success_density/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -317,7 +317,7 @@ t.create('Test Success Rate (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'tests', diff --git a/services/sonar/sonar-violations.service.js b/services/sonar/sonar-violations.service.js index 6675e6720a621d8f53d485861995f632d0cf554d..a8b20b76bc87876629cec67a7b3b593b8da1b385 100644 --- a/services/sonar/sonar-violations.service.js +++ b/services/sonar/sonar-violations.service.js @@ -10,7 +10,7 @@ import { const violationsColorScale = colorScale( [1, 2, 3, 5], - ['brightgreen', 'yellowgreen', 'yellow', 'orange', 'red'] + ['brightgreen', 'yellowgreen', 'yellow', 'orange', 'red'], ) const violationCategoryColorMap = { @@ -148,7 +148,7 @@ export default class SonarViolations extends SonarBase { async handle( { component, metric, branch }, - { server, sonarVersion, format } + { server, sonarVersion, format }, ) { // If the user has requested the long format for the violations badge // then we need to include each individual violation metric in the call to the API diff --git a/services/sonar/sonar-violations.tester.js b/services/sonar/sonar-violations.tester.js index f01e9e739455ec5c16c434fff2657726b765db04..3ed26326d5c20b8687ba8ffd8821da0df8e8eb72 100644 --- a/services/sonar/sonar-violations.tester.js +++ b/services/sonar/sonar-violations.tester.js @@ -5,8 +5,8 @@ export const t = await createServiceTester() const isViolationsLongFormMetric = Joi.alternatives( Joi.allow(0), withRegex( - /(([\d]+) (blocker|critical|major|minor|info))(,\s([\d]+) (critical|major|minor|info))?/ - ) + /(([\d]+) (blocker|critical|major|minor|info))(,\s([\d]+) (critical|major|minor|info))?/, + ), ) // The service tests targeting the legacy SonarQube API are mocked @@ -33,7 +33,7 @@ t.create('Violations (branch)') t.create('Violations (legacy API supported)') .get( - '/violations/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/violations/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -53,7 +53,7 @@ t.create('Violations (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'violations', @@ -63,7 +63,7 @@ t.create('Violations (legacy API supported)') t.create('Violations Long Format') .timeout(10000) .get( - '/violations/brave_brave-core.json?server=https://sonarcloud.io&format=long' + '/violations/brave_brave-core.json?server=https://sonarcloud.io&format=long', ) .expectBadge({ label: 'violations', @@ -72,7 +72,7 @@ t.create('Violations Long Format') t.create('Violations Long Format (legacy API supported)') .get( - '/violations/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2&format=long' + '/violations/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2&format=long', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -113,7 +113,7 @@ t.create('Violations Long Format (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'violations', @@ -130,7 +130,7 @@ t.create('Blocker Violations') t.create('Blocker Violations (legacy API supported)') .get( - '/blocker_violations/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/blocker_violations/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -150,7 +150,7 @@ t.create('Blocker Violations (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'blocker violations', @@ -160,7 +160,7 @@ t.create('Blocker Violations (legacy API supported)') t.create('Critical Violations') .timeout(10000) .get( - '/critical_violations/brave_brave-core.json?server=https://sonarcloud.io' + '/critical_violations/brave_brave-core.json?server=https://sonarcloud.io', ) .expectBadge({ label: 'critical violations', @@ -169,7 +169,7 @@ t.create('Critical Violations') t.create('Critical Violations (legacy API supported)') .get( - '/critical_violations/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2' + '/critical_violations/org.ow2.petals%3Apetals-se-ase.json?server=http://sonar.petalslink.com&sonarVersion=4.2', ) .intercept(nock => nock('http://sonar.petalslink.com/api') @@ -189,7 +189,7 @@ t.create('Critical Violations (legacy API supported)') }, ], }, - ]) + ]), ) .expectBadge({ label: 'critical violations', diff --git a/services/sourceforge/sourceforge-last-commit.service.js b/services/sourceforge/sourceforge-last-commit.service.js index 5b4315af6f347833414ccea88a54cdf3594be73f..ab9c910286a704e16237d68695ae4fd94563ff89 100644 --- a/services/sourceforge/sourceforge-last-commit.service.js +++ b/services/sourceforge/sourceforge-last-commit.service.js @@ -8,7 +8,7 @@ const schema = Joi.object({ .items( Joi.object({ committed_date: Joi.string().required(), - }).required() + }).required(), ) .required(), }).required() diff --git a/services/spiget/spiget-tested-versions.tester.js b/services/spiget/spiget-tested-versions.tester.js index 723164f118912ea4ff1955fea68d1c67017c1859..130fffa97d83212be69869e73877b7f8ac2ea0e0 100644 --- a/services/spiget/spiget-tested-versions.tester.js +++ b/services/spiget/spiget-tested-versions.tester.js @@ -33,7 +33,7 @@ t.create('Nock - single version supported') count: 1, average: 1, }, - }) + }), ) .expectBadge({ label: 'tested versions', @@ -57,7 +57,7 @@ t.create('Nock - multiple versions supported') count: 1, average: 1, }, - }) + }), ) .expectBadge({ label: 'tested versions', diff --git a/services/stackexchange/stackexchange-base.js b/services/stackexchange/stackexchange-base.js index e6a93889e9047223a4cd9e513c79905478349122..18c9ead9c24c2f3f306ea84044238dfbbdcd8d9e 100644 --- a/services/stackexchange/stackexchange-base.js +++ b/services/stackexchange/stackexchange-base.js @@ -31,7 +31,7 @@ export class StackExchangeBase extends BaseJsonService { async fetch(params) { return this._requestJson( - this.authHelper.withQueryStringAuth({ passKey: 'key' }, params) + this.authHelper.withQueryStringAuth({ passKey: 'key' }, params), ) } } diff --git a/services/stackexchange/stackexchange-base.spec.js b/services/stackexchange/stackexchange-base.spec.js index c61d3ccace9772926c57d99344767116eed18479..771cf7be32470a791e9025a96654915299df401a 100644 --- a/services/stackexchange/stackexchange-base.spec.js +++ b/services/stackexchange/stackexchange-base.spec.js @@ -29,7 +29,7 @@ describe('StackExchangeBase', function () { .reply(200, { message: 'fake message' }) expect( - await DummyStackExchangeService.invoke(defaultContext, config, {}) + await DummyStackExchangeService.invoke(defaultContext, config, {}), ).to.deep.equal({ message: 'fake message' }) scope.done() diff --git a/services/stackexchange/stackexchange-reputation.service.js b/services/stackexchange/stackexchange-reputation.service.js index b75f61e39ea2379f9f14329920929c19f23b2972..c99a1b9227a75db4f1fad64e27a282d676fe0402 100644 --- a/services/stackexchange/stackexchange-reputation.service.js +++ b/services/stackexchange/stackexchange-reputation.service.js @@ -9,7 +9,7 @@ const reputationSchema = Joi.object({ .items( Joi.object({ reputation: Joi.number().min(0).required(), - }) + }), ) .required(), }).required() diff --git a/services/stackexchange/stackexchange-taginfo.service.js b/services/stackexchange/stackexchange-taginfo.service.js index 1aa74e50ae3573e51880cc294c88b9afb89bc223..76a84297231e0cab361834a50ffbb7bdbbfc8d2f 100644 --- a/services/stackexchange/stackexchange-taginfo.service.js +++ b/services/stackexchange/stackexchange-taginfo.service.js @@ -10,7 +10,7 @@ const tagSchema = Joi.object({ .items( Joi.object({ count: Joi.number().min(0).required(), - }) + }), ) .required(), }).required() diff --git a/services/steam/steam-workshop.service.js b/services/steam/steam-workshop.service.js index e047b5cade2dcdc0a408323c4f657c280f83846f..4ff1c5158ff2877e85312619468ace143676d3ac 100644 --- a/services/steam/steam-workshop.service.js +++ b/services/steam/steam-workshop.service.js @@ -28,7 +28,7 @@ const steamCollectionSchema = Joi.object({ .items( Joi.object({ children: Joi.array().required(), - }).required() + }).required(), ) .required(), }) @@ -42,7 +42,7 @@ const steamCollectionNotFoundSchema = Joi.object({ .items( Joi.object({ result: Joi.number().integer().min(9).max(9).required(), - }).required() + }).required(), ) .required(), }) @@ -51,7 +51,7 @@ const steamCollectionNotFoundSchema = Joi.object({ const collectionFoundOrNotSchema = Joi.alternatives( steamCollectionSchema, - steamCollectionNotFoundSchema + steamCollectionNotFoundSchema, ) const steamFileSchema = Joi.object({ @@ -68,7 +68,7 @@ const steamFileSchema = Joi.object({ lifetime_subscriptions: Joi.number().integer().required(), lifetime_favorited: Joi.number().integer().required(), views: Joi.number().integer().required(), - }) + }), ) .min(1) .max(1) @@ -84,7 +84,7 @@ const steamFileNotFoundSchema = Joi.object({ .items( Joi.object({ result: Joi.number().integer().min(9).max(9).required(), - }).required() + }).required(), ) .min(1) .max(1) @@ -95,7 +95,7 @@ const steamFileNotFoundSchema = Joi.object({ const fileFoundOrNotSchema = Joi.alternatives( steamFileSchema, - steamFileNotFoundSchema + steamFileNotFoundSchema, ) class SteamCollectionSize extends BaseSteamAPI { diff --git a/services/swagger/swagger-redirect.tester.js b/services/swagger/swagger-redirect.tester.js index c4658882236c1e3613ff5a75e987037dd208f828..d688ae9bb5574964dcc372e24e0904bca5fe0141 100644 --- a/services/swagger/swagger-redirect.tester.js +++ b/services/swagger/swagger-redirect.tester.js @@ -10,22 +10,22 @@ t.create('swagger json') .get('/https/example.com/example.svg') .expectRedirect( `/swagger/valid/3.0.svg?specUrl=${encodeURIComponent( - 'https://example.com/example.json' - )}` + 'https://example.com/example.json', + )}`, ) t.create('swagger yml') .get('/https/example.com/example.yml') .expectRedirect( `/swagger/valid/3.0.svg?specUrl=${encodeURIComponent( - 'https://example.com/example.yml' - )}` + 'https://example.com/example.yml', + )}`, ) t.create('swagger yaml') .get('/https/example.com/example.yaml') .expectRedirect( `/swagger/valid/3.0.svg?specUrl=${encodeURIComponent( - 'https://example.com/example.yaml' - )}` + 'https://example.com/example.yaml', + )}`, ) diff --git a/services/swagger/swagger.service.js b/services/swagger/swagger.service.js index fff0edc2a22b94bc170b870ea5c0c180625a9f90..f26c626e14d320ab89130d846050420b18db4e05 100644 --- a/services/swagger/swagger.service.js +++ b/services/swagger/swagger.service.js @@ -8,7 +8,7 @@ const schema = Joi.object() Joi.object({ level: Joi.string().required(), message: Joi.string().required(), - }) + }), ), }) .required() diff --git a/services/swagger/swagger.tester.js b/services/swagger/swagger.tester.js index 6c154b6354223e4dabf9fa3b1c44928f53dc0b17..5dffab52e36951049752f8b4f438ee76ac94becd 100644 --- a/services/swagger/swagger.tester.js +++ b/services/swagger/swagger.tester.js @@ -22,7 +22,7 @@ t.create('Invalid') message: 'error', }, ], - }) + }), ) .expectBadge({ label: 'swagger', @@ -32,7 +32,7 @@ t.create('Invalid') t.create('Valid json 2.0') .get( - `${getURLBase}https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/examples/v2.0/json/petstore-expanded.json` + `${getURLBase}https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/examples/v2.0/json/petstore-expanded.json`, ) .expectBadge({ label: 'swagger', @@ -42,7 +42,7 @@ t.create('Valid json 2.0') t.create('Valid yaml 3.0') .get( - `${getURLBase}https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/examples/v3.0/petstore.yaml` + `${getURLBase}https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/examples/v3.0/petstore.yaml`, ) .expectBadge({ label: 'swagger', @@ -61,7 +61,7 @@ t.create('Valid with warnings') // Isn't a spec, but valid json t.create('Invalid') .get( - `${getURLBase}https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/schemas/v3.0/schema.json` + `${getURLBase}https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/schemas/v3.0/schema.json`, ) .expectBadge({ label: 'swagger', @@ -71,7 +71,7 @@ t.create('Invalid') t.create('Not found') .get( - `${getURLBase}https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/examples/v3.0/notFound.yaml` + `${getURLBase}https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/examples/v3.0/notFound.yaml`, ) .expectBadge({ label: 'swagger', diff --git a/services/symfony/symfony-insight-base.js b/services/symfony/symfony-insight-base.js index 95318439afd5707958fbc16269c07c96d923c5eb..90d64802825cc378d2c63eee5d49da9726a6ead3 100644 --- a/services/symfony/symfony-insight-base.js +++ b/services/symfony/symfony-insight-base.js @@ -13,7 +13,7 @@ const schema = Joi.object({ 'running', 'measured', 'analyzed', - 'finished' + 'finished', ) .allow('') .required(), @@ -70,7 +70,7 @@ class SymfonyInsightBase extends BaseXmlService { attributeNamePrefix: '', ignoreAttributes: false, }, - }) + }), ) } diff --git a/services/symfony/symfony-insight-grade.tester.js b/services/symfony/symfony-insight-grade.tester.js index 85d4be697c0bc840212bfee8258355df163d5c61..8b69c22633dbecb5b6360cd2f70f79c354b543f0 100644 --- a/services/symfony/symfony-insight-grade.tester.js +++ b/services/symfony/symfony-insight-grade.tester.js @@ -14,7 +14,7 @@ t.create('valid project grade') 'gold', 'silver', 'bronze', - 'no medal' + 'no medal', ).required(), }) diff --git a/services/symfony/symfony-insight-stars.tester.js b/services/symfony/symfony-insight-stars.tester.js index 0370fb01f205586002d2b7f95c59e62af89be961..0500bf49871e64c44f13824a61dcd358633e75bf 100644 --- a/services/symfony/symfony-insight-stars.tester.js +++ b/services/symfony/symfony-insight-stars.tester.js @@ -10,7 +10,7 @@ t.create('valid project stars') .expectBadge({ label: 'stars', message: withRegex( - /^(?=.{4}$)(\u2605{0,4}[\u00BC\u00BD\u00BE]?\u2606{0,4})$/ + /^(?=.{4}$)(\u2605{0,4}[\u00BC\u00BD\u00BE]?\u2606{0,4})$/, ), }) diff --git a/services/symfony/symfony-insight-violations.tester.js b/services/symfony/symfony-insight-violations.tester.js index f35a9bbc6376288264b2f5a42dca9f247455a813..c0b4795188e957dd9c3daf63414d264bf105ea72 100644 --- a/services/symfony/symfony-insight-violations.tester.js +++ b/services/symfony/symfony-insight-violations.tester.js @@ -10,6 +10,6 @@ t.create('valid project violations') .expectBadge({ label: 'violations', message: withRegex( - /0|\d* critical|\d* critical, \d* major|\d* critical, \d* major, \d* minor|\d* critical, \d* major, \d* minor, \d* info|\d* critical, \d* minor|\d* critical, \d* info|\d* major|\d* major, \d* minor|\d* major, \d* minor, \d* info|\d* major, \d* info|\d* minor|\d* minor, \d* info|\d* info/ + /0|\d* critical|\d* critical, \d* major|\d* critical, \d* major, \d* minor|\d* critical, \d* major, \d* minor, \d* info|\d* critical, \d* minor|\d* critical, \d* info|\d* major|\d* major, \d* minor|\d* major, \d* minor, \d* info|\d* major, \d* info|\d* minor|\d* minor, \d* info|\d* info/, ), }) diff --git a/services/symfony/symfony-insight.spec.js b/services/symfony/symfony-insight.spec.js index ea9855d96878beb07e549f9ec3cf201fb4f0a79d..46ddb28e49846d982f96929c7abe1e5a47de3d45 100644 --- a/services/symfony/symfony-insight.spec.js +++ b/services/symfony/symfony-insight.spec.js @@ -42,7 +42,7 @@ describe('SymfonyInsight[Grade|Stars|Violation]', function () { it('401 not authorized grade', async function () { const scope = createMock().reply(401) expect( - await SymfonyInsightGrade.invoke(defaultContext, config, { projectUuid }) + await SymfonyInsightGrade.invoke(defaultContext, config, { projectUuid }), ).to.deep.equal({ message: 'not authorized to access project', color: 'lightgray', @@ -70,7 +70,7 @@ describe('SymfonyInsight[Grade|Stars|Violation]', function () { expect( await SymfonyInsightGrade.invoke(defaultContext, config, { projectUuid, - }) + }), ).to.deep.equal(expectedGradeBadge) scope.done() }) @@ -82,7 +82,7 @@ describe('SymfonyInsight[Grade|Stars|Violation]', function () { expect( await SymfonyInsightStars.invoke(defaultContext, config, { projectUuid, - }) + }), ).to.deep.equal(expectedStarsBadge) scope.done() }) @@ -94,7 +94,7 @@ describe('SymfonyInsight[Grade|Stars|Violation]', function () { expect( await SymfonyInsightViolations.invoke(defaultContext, config, { projectUuid, - }) + }), ).to.deep.equal(expectedViolationsBadge) scope.done() }) diff --git a/services/tas/tas-tests.service.js b/services/tas/tas-tests.service.js index 70836b0f7c93127ed10bf347ad3ce1b3ac834520..2e857d8c69d9c4620ac2b7318e66b02366b05f15 100644 --- a/services/tas/tas-tests.service.js +++ b/services/tas/tas-tests.service.js @@ -94,7 +94,7 @@ export default class TasBuildStatus extends BaseJsonService { passed_label: passedLabel, failed_label: failedLabel, skipped_label: skippedLabel, - } + }, ) { const { badge } = await this.fetch({ provider, org, repo }) return this.constructor.render({ diff --git a/services/tas/tas-tests.tester.js b/services/tas/tas-tests.tester.js index 5c44b187af16a336c4e9c945b676b4077f64980e..c260cf1c9402bd4d518e87c976a9455c8132e861 100644 --- a/services/tas/tas-tests.tester.js +++ b/services/tas/tas-tests.tester.js @@ -53,7 +53,7 @@ t.create('Test status on private project') org: 'tasdemo', repo: 'nexe-private', }) - .reply(401) + .reply(401), ) .expectBadge({ label: 'tests', diff --git a/services/teamcity/teamcity-base.js b/services/teamcity/teamcity-base.js index 00b60da40b1cce6e8ab6d0defc2fe5022f0f5e34..d8abbf48c0051e7bc47b0cbada78292a1d08a7fd 100644 --- a/services/teamcity/teamcity-base.js +++ b/services/teamcity/teamcity-base.js @@ -20,7 +20,7 @@ export default class TeamCityBase extends BaseJsonService { schema, options, httpErrors: { 404: 'build not found', ...httpErrors }, - }) + }), ) } } diff --git a/services/teamcity/teamcity-build-redirect.tester.js b/services/teamcity/teamcity-build-redirect.tester.js index c3f20425bbf247475f9389800071ffac92318c1b..facd63f1d1b3260a2b50d21cd88cf547c2ddcc01 100644 --- a/services/teamcity/teamcity-build-redirect.tester.js +++ b/services/teamcity/teamcity-build-redirect.tester.js @@ -10,22 +10,22 @@ t.create('codebetter') .get('/codebetter/IntelliJIdeaCe_JavaDecompilerEngineTests.svg') .expectRedirect( `/teamcity/build/s/IntelliJIdeaCe_JavaDecompilerEngineTests.svg?server=${encodeURIComponent( - 'https://teamcity.jetbrains.com' - )}` + 'https://teamcity.jetbrains.com', + )}`, ) t.create('hostAndPath simple build') .get('/https/teamcity.jetbrains.com/s/bt345.svg') .expectRedirect( `/teamcity/build/s/bt345.svg?server=${encodeURIComponent( - 'https://teamcity.jetbrains.com' - )}` + 'https://teamcity.jetbrains.com', + )}`, ) t.create('hostAndPath full build') .get('/https/teamcity.jetbrains.com/e/bt345.svg') .expectRedirect( `/teamcity/build/e/bt345.svg?server=${encodeURIComponent( - 'https://teamcity.jetbrains.com' - )}` + 'https://teamcity.jetbrains.com', + )}`, ) diff --git a/services/teamcity/teamcity-build.service.js b/services/teamcity/teamcity-build.service.js index bf90c10979a8f817f4b6b615b1fb9c22d994be61..354f25f199befe537dfbe5aafbe11439b1c9ef92 100644 --- a/services/teamcity/teamcity-build.service.js +++ b/services/teamcity/teamcity-build.service.js @@ -77,7 +77,7 @@ export default class TeamCityBuild extends TeamCityBase { async handle( { verbosity, buildId }, - { server = 'https://teamcity.jetbrains.com' } + { server = 'https://teamcity.jetbrains.com' }, ) { // JetBrains Docs: https://confluence.jetbrains.com/display/TCD18/REST+API#RESTAPI-BuildStatusIcon const buildLocator = `buildType:(id:${buildId})` diff --git a/services/teamcity/teamcity-build.spec.js b/services/teamcity/teamcity-build.spec.js index f81599a62e3b7fde1569908a8f5678762e428fc2..1e207bce56370348d2deffd604fda501339d2484 100644 --- a/services/teamcity/teamcity-build.spec.js +++ b/services/teamcity/teamcity-build.spec.js @@ -27,8 +27,8 @@ describe('TeamCityBuild', function () { verbosity: 'e', buildId: 'bt678', }, - { server: `https://${host}` } - ) + { server: `https://${host}` }, + ), ).to.deep.equal({ message: 'tests failed: 1 (1 new), passed: 50246, ignored: 1, muted: 12', color: 'red', diff --git a/services/teamcity/teamcity-build.tester.js b/services/teamcity/teamcity-build.tester.js index 3fcbb217e8b1ecdec1fcfa8a1346ba4736a29321..85900fd4010632d209f1788c82883e872fdc3d3b 100644 --- a/services/teamcity/teamcity-build.tester.js +++ b/services/teamcity/teamcity-build.tester.js @@ -34,7 +34,7 @@ t.create('codebetter success build') .reply(200, { status: 'SUCCESS', statusText: 'Success', - }) + }), ) .expectBadge({ label: 'build', @@ -51,7 +51,7 @@ t.create('codebetter failure build') .reply(200, { status: 'FAILURE', statusText: 'Tests failed: 2', - }) + }), ) .expectBadge({ label: 'build', @@ -68,7 +68,7 @@ t.create('simple build status with passed build') .reply(200, { status: 'SUCCESS', statusText: 'Tests passed: 100', - }) + }), ) .expectBadge({ label: 'build', @@ -85,7 +85,7 @@ t.create('simple build status with failed build') .reply(200, { status: 'FAILURE', statusText: 'Tests failed: 10 (2 new)', - }) + }), ) .expectBadge({ label: 'build', @@ -102,7 +102,7 @@ t.create('full build status with passed build') .reply(200, { status: 'SUCCESS', statusText: 'Tests passed: 100, ignored: 3', - }) + }), ) .expectBadge({ label: 'build', @@ -119,7 +119,7 @@ t.create('full build status with failed build') .reply(200, { status: 'FAILURE', statusText: 'Tests failed: 10 (2 new), passed: 99', - }) + }), ) .expectBadge({ label: 'build', @@ -136,7 +136,7 @@ t.create('full build status with passed build chain') .reply(200, { status: 'SUCCESS', statusText: 'Build chain finished (success: 9)', - }) + }), ) .expectBadge({ label: 'build', diff --git a/services/teamcity/teamcity-coverage.service.js b/services/teamcity/teamcity-coverage.service.js index 8737da79e91c5174345c486e84731f19d5ae5b39..c89e3e1db4f16f01e60a2cfa641cbc74eb5a617e 100644 --- a/services/teamcity/teamcity-coverage.service.js +++ b/services/teamcity/teamcity-coverage.service.js @@ -10,7 +10,7 @@ const buildStatisticsSchema = Joi.object({ Joi.object({ name: Joi.string().required(), value: Joi.string().required(), - }) + }), ) .required(), }).required() @@ -77,7 +77,7 @@ export default class TeamCityCoverage extends TeamCityBase { // JetBrains Docs: https://confluence.jetbrains.com/display/TCD18/REST+API#RESTAPI-Statistics const buildLocator = `buildType:(id:${buildId})` const apiPath = `app/rest/builds/${encodeURIComponent( - buildLocator + buildLocator, )}/statistics` const data = await this.fetch({ url: `${server}/${apiPath}`, diff --git a/services/teamcity/teamcity-coverage.spec.js b/services/teamcity/teamcity-coverage.spec.js index f0fc578371af8cde6ebf4569c649cf518bb1c325..0e7bbae64d3da5edc0088a63c7ae13e930c614d9 100644 --- a/services/teamcity/teamcity-coverage.spec.js +++ b/services/teamcity/teamcity-coverage.spec.js @@ -11,8 +11,8 @@ describe('TeamCityCoverage', function () { const scope = nock(`https://${host}`) .get( `/app/rest/builds/${encodeURIComponent( - 'buildType:(id:bt678)' - )}/statistics` + 'buildType:(id:bt678)', + )}/statistics`, ) .query({}) // This ensures that the expected credentials are actually being sent with the HTTP request. @@ -32,8 +32,8 @@ describe('TeamCityCoverage', function () { { buildId: 'bt678', }, - { server: 'https://mycompany.teamcity.com' } - ) + { server: 'https://mycompany.teamcity.com' }, + ), ).to.deep.equal({ message: '82%', color: 'yellowgreen', diff --git a/services/teamcity/teamcity-coverage.tester.js b/services/teamcity/teamcity-coverage.tester.js index 7a0c0387baab761e1278ef6cb81b9d955ce51ea5..a7d6fcaedcc7d447bcd644ade191117d5ec67e06 100644 --- a/services/teamcity/teamcity-coverage.tester.js +++ b/services/teamcity/teamcity-coverage.tester.js @@ -24,7 +24,7 @@ t.create('no coverage data for build') nock('https://teamcity.jetbrains.com/app/rest/builds') .get(`/${encodeURIComponent('buildType:(id:bt234)')}/statistics`) .query({ guest: 1 }) - .reply(200, { property: [] }) + .reply(200, { property: [] }), ) .expectBadge({ label: 'coverage', message: 'no coverage data available' }) @@ -45,7 +45,7 @@ t.create('zero lines covered') value: '345', }, ], - }) + }), ) .expectBadge({ label: 'coverage', diff --git a/services/test-helpers.js b/services/test-helpers.js index 2976c339816ced7fe4ca2355443b38e5dd68a547..8fb099ba05b3aece68575275977f16b6debd39db 100644 --- a/services/test-helpers.js +++ b/services/test-helpers.js @@ -22,7 +22,7 @@ function noToken(serviceClass) { (passKey && !runnerConfig.private[passKey]) if (noToken && !hasLogged) { console.warn( - `${serviceClass.name}: no credentials configured, tests for this service will be skipped. Add credentials in local.yml to run them.` + `${serviceClass.name}: no credentials configured, tests for this service will be skipped. Add credentials in local.yml to run them.`, ) hasLogged = true } diff --git a/services/test-validators.js b/services/test-validators.js index 6c52ce8603b77eab04c6634e6d27ff62078b0806..489cce69f1ae64ff96c6315519afbbcaadaf8ebe 100644 --- a/services/test-validators.js +++ b/services/test-validators.js @@ -21,13 +21,13 @@ const isVPlusDottedVersionNClauses = withRegex(/^v\d+(\.\d+)*$/) // and an optional text suffix // e.g: -beta, -preview1, -release-candidate, +beta, ~pre9-12 etc const isVPlusDottedVersionNClausesWithOptionalSuffix = withRegex( - /^v\d+(\.\d+)*([-+~].*)?$/ + /^v\d+(\.\d+)*([-+~].*)?$/, ) // same as above, but also accepts an optional 'epoch' prefix that can be // found e.g. in distro package versions, like 4:6.3.0-4 const isVPlusDottedVersionNClausesWithOptionalSuffixAndEpoch = withRegex( - /^v(\d+:)?\d+(\.\d+)*([-+~].*)?$/ + /^v(\d+:)?\d+(\.\d+)*([-+~].*)?$/, ) // Simple regex for test Composer versions rule @@ -43,7 +43,7 @@ const isVPlusDottedVersionNClausesWithOptionalSuffixAndEpoch = withRegex( // https://getcomposer.org/doc/04-schema.md#package-links // https://getcomposer.org/doc/04-schema.md#minimum-stability const isComposerVersion = withRegex( - /^\*|(\s*(>=|>|<|<=|!=|\^|~)?\d+(\.(\*|(\d+(\.(\d+|\*))?)))?((\s*\|*)?\s*(>=|>|<|<=|!=|\^|~)?\d+(\.(\*|(\d+(\.(\d+|\*))?)))?)*\s*)$/ + /^\*|(\s*(>=|>|<|<=|!=|\^|~)?\d+(\.(\*|(\d+(\.(\d+|\*))?)))?((\s*\|*)?\s*(>=|>|<|<=|!=|\^|~)?\d+(\.(\*|(\d+(\.(\d+|\*))?)))?)*\s*)$/, ) // Regex for validate php-version.versionReduction() @@ -52,11 +52,11 @@ const isComposerVersion = withRegex( // 5.4, 5.6, 7.2 // 5.4 - 7.1, HHVM const isPhpVersionReduction = withRegex( - /^((>= \d+(\.\d+)?)|(\d+\.\d+(, \d+\.\d+)*)|(\d+\.\d+ - \d+\.\d+))(, HHVM)?$/ + /^((>= \d+(\.\d+)?)|(\d+\.\d+(, \d+\.\d+)*)|(\d+\.\d+ - \d+\.\d+))(, HHVM)?$/, ) const isStarRating = withRegex( - /^(?=.{5}$)(\u2605{0,5}[\u00BC\u00BD\u00BE]?\u2606{0,5})$/ + /^(?=.{5}$)(\u2605{0,5}[\u00BC\u00BD\u00BE]?\u2606{0,5})$/, ) // Required to be > 0, because accepting zero masks many problems. @@ -64,7 +64,7 @@ const isMetric = withRegex(/^([1-9][0-9]*[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY])$/) // Same as isMetric, but tests for negative numbers also. const isMetricAllowNegative = withRegex( - /^(0|-?[1-9][0-9]*[kMGTPEZY]?|-?[0-9]\.[0-9][kMGTPEZY])$/ + /^(0|-?[1-9][0-9]*[kMGTPEZY]?|-?[0-9]\.[0-9][kMGTPEZY])$/, ) /** @@ -82,15 +82,15 @@ const isMetricOpenIssues = isMetricWithPattern(/ open/) const isMetricClosedIssues = isMetricWithPattern(/ closed/) const isMetricOverMetric = isMetricWithPattern( - /\/([1-9][0-9]*[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY])/ + /\/([1-9][0-9]*[kMGTPEZY]?|[1-9]\.[1-9][kMGTPEZY])/, ) const isMetricOverTimePeriod = isMetricWithPattern( - /\/(year|month|four weeks|quarter|week|day)/ + /\/(year|month|four weeks|quarter|week|day)/, ) const isZeroOverTimePeriod = withRegex( - /^0\/(year|month|four weeks|quarter|week|day)$/ + /^0\/(year|month|four weeks|quarter|week|day)$/, ) const isIntegerPercentage = withRegex(/^[1-9][0-9]?%|^100%|^0%$/) @@ -101,41 +101,41 @@ const isPercentage = Joi.alternatives().try( isIntegerPercentage, isDecimalPercentage, isIntegerPercentageNegative, - isDecimalPercentageNegative + isDecimalPercentageNegative, ) const isFileSize = withRegex( - /^[0-9]*[.]?[0-9]+\s(B|kB|KB|MB|GB|TB|PB|EB|ZB|YB)$/ + /^[0-9]*[.]?[0-9]+\s(B|kB|KB|MB|GB|TB|PB|EB|ZB|YB)$/, ) const isFormattedDate = Joi.alternatives().try( Joi.equal('today', 'yesterday'), Joi.string().regex(/^last (sun|mon|tues|wednes|thurs|fri|satur)day$/), Joi.string().regex( - /^(january|february|march|april|may|june|july|august|september|october|november|december)( \d{4})?$/ - ) + /^(january|february|march|april|may|june|july|august|september|october|november|december)( \d{4})?$/, + ), ) const isRelativeFormattedDate = Joi.alternatives().try( Joi.string().regex( - /^(in |)([0-9]+|a few|a|an|)(| )(second|minute|hour|day|month|year)(s|)( ago|)$/ - ) + /^(in |)([0-9]+|a few|a|an|)(| )(second|minute|hour|day|month|year)(s|)( ago|)$/, + ), ) const isDependencyState = withRegex( - /^(\d+ out of date|\d+ deprecated|up to date)$/ + /^(\d+ out of date|\d+ deprecated|up to date)$/, ) const makeTestTotalsValidator = ({ passed, failed, skipped }) => withRegex( - new RegExp(`^[0-9]+ ${passed}(, [0-9]+ ${failed})?(, [0-9]+ ${skipped})?$`) + new RegExp(`^[0-9]+ ${passed}(, [0-9]+ ${failed})?(, [0-9]+ ${skipped})?$`), ) const makeCompactTestTotalsValidator = ({ passed, failed, skipped }) => withRegex( new RegExp( - `^${passed} [0-9]+( \\| ${failed} [0-9]+)?( \\| ${skipped} [0-9]+)?$` - ) + `^${passed} [0-9]+( \\| ${failed} [0-9]+)?( \\| ${skipped} [0-9]+)?$`, + ), ) const isDefaultTestTotals = makeTestTotalsValidator({ @@ -161,11 +161,11 @@ const isCustomCompactTestTotals = makeCompactTestTotalsValidator({ const isOrdinalNumber = Joi.string().regex(/^[1-9][0-9]*(ᵗʰ|ˢᵗ|ⁿᵈ|ʳᵈ)$/) const isOrdinalNumberDaily = Joi.string().regex( - /^[1-9][0-9]*(ᵗʰ|ˢᵗ|ⁿᵈ|ʳᵈ) daily$/ + /^[1-9][0-9]*(ᵗʰ|ˢᵗ|ⁿᵈ|ʳᵈ) daily$/, ) const isHumanized = Joi.string().regex( - /[0-9a-z]+ (second|seconds|minute|minutes|hour|hours|day|days|month|months|year|years)/ + /[0-9a-z]+ (second|seconds|minute|minutes|hour|hours|day|days|month|months|year|years)/, ) // $1,530,602.24 // true @@ -175,7 +175,7 @@ const isHumanized = Joi.string().regex( // 1.6.66,6 // false // .1555. // false const isCurrency = withRegex( - /(?=.*\d)^\$?(([1-9]\d{0,2}(,\d{3})*)|0)?(\.\d{1,2})?$/ + /(?=.*\d)^\$?(([1-9]\d{0,2}(,\d{3})*)|0)?(\.\d{1,2})?$/, ) export { diff --git a/services/testspace/testspace-base.js b/services/testspace/testspace-base.js index 556aaf2b7f87952a93e58bb89209ee911eee0352..7cb2f13eaf62f336b155cf715722188f5634cedc 100644 --- a/services/testspace/testspace-base.js +++ b/services/testspace/testspace-base.js @@ -15,7 +15,7 @@ const schema = Joi.array() .min(5) .max(5) .required(), - }) + }), ) .required() @@ -30,7 +30,7 @@ export default class TestspaceBase extends BaseJsonService { async fetch({ org, project, space }) { // https://help.testspace.com/docs/reference/web-api#list-results const url = `https://${org}.testspace.com/api/projects/${encodeURIComponent( - project + project, )}/spaces/${space}/results` return this._requestJson({ schema, diff --git a/services/testspace/testspace-test-count.tester.js b/services/testspace/testspace-test-count.tester.js index 59afe77adc51ed4e9cd8191f5913dbc60b9a69e6..ce5c03d56ac848f13003ec80e8763f3c4334a58e 100644 --- a/services/testspace/testspace-test-count.tester.js +++ b/services/testspace/testspace-test-count.tester.js @@ -4,7 +4,7 @@ import { isMetric } from '../test-validators.js' export const t = await createServiceTester() const isMetricAllowZero = Joi.alternatives( isMetric, - Joi.number().valid(0).required() + Joi.number().valid(0).required(), ) t.create('Total') diff --git a/services/testspace/testspace-test-summary.service.js b/services/testspace/testspace-test-summary.service.js index f5176012a815b1a963a41fa68cfe2a0ac52d8dcb..07d9584034d474fcbe8f2a4eb2cb00dc8760701d 100644 --- a/services/testspace/testspace-test-summary.service.js +++ b/services/testspace/testspace-test-summary.service.js @@ -83,7 +83,7 @@ export default class TestspaceTests extends TestspaceBase { passed_label: passedLabel, failed_label: failedLabel, skipped_label: skippedLabel, - } + }, ) { const json = await this.fetch({ org, project, space }) const { passed, failed, skipped, total } = this.transformCaseCounts(json) diff --git a/services/travis/travis-build.tester.js b/services/travis/travis-build.tester.js index 5a3802415fa19833ab5213098f597b06d44968d1..b3ff02c6986a9bf2ccafd6caf84aadee4aa07682 100644 --- a/services/travis/travis-build.tester.js +++ b/services/travis/travis-build.tester.js @@ -42,6 +42,6 @@ t.create('unknown repo') t.create('invalid svg response') .get('/com/foo/bar.json') .intercept(nock => - nock('https://api.travis-ci.com').get('/foo/bar.svg').reply(200) + nock('https://api.travis-ci.com').get('/foo/bar.svg').reply(200), ) .expectBadge({ label: 'build', message: 'unparseable svg response' }) diff --git a/services/treeware/treeware-trees.tester.js b/services/treeware/treeware-trees.tester.js index 07ada0cf8de39e17a06a21eed5c9a283ec8d00cc..a5d2b6962bcccf86da5fee842163d41e05f943e1 100644 --- a/services/treeware/treeware-trees.tester.js +++ b/services/treeware/treeware-trees.tester.js @@ -14,7 +14,7 @@ t.create('request for existing package (mock)') .intercept(nock => nock('https://public.offset.earth') .get('/users/treeware/trees?ref=65c6e3e942e7464b4591e0c8b70d11d5') - .reply(200, { total: 50 }) + .reply(200, { total: 50 }), ) .expectBadge({ label: 'trees', diff --git a/services/twitch/twitch-base.js b/services/twitch/twitch-base.js index 3ca2b135a011cf822aee40e0284f939e054a58a1..2c34ef075957ae68501a744b984724a8dd6cc92f 100644 --- a/services/twitch/twitch-base.js +++ b/services/twitch/twitch-base.js @@ -50,15 +50,15 @@ export default class TwitchBase extends BaseJsonService { 401: 'invalid token', 404: 'node not found', }, - } - ) + }, + ), ) // replace the token when we are 80% near the expire time // 2147483647 is the max 32-bit value that is accepted by setTimeout(), it's about 24.9 days const replaceTokenMs = Math.min( tokenRes.expires_in * 1000 * 0.8, - 2147483647 + 2147483647, ) const timeout = setTimeout(() => { TwitchBase.__twitchToken = this._getNewToken() diff --git a/services/twitch/twitch.spec.js b/services/twitch/twitch.spec.js index c3ec31522eb66b7397c7461760ca75100a06eeba..b1ad8e209eaef5eaffa08ee40e289b60d7784583 100644 --- a/services/twitch/twitch.spec.js +++ b/services/twitch/twitch.spec.js @@ -43,7 +43,7 @@ describe('TwitchStatus', function () { expect( await TwitchStatus.invoke(defaultContext, config, { status: 'andyonthewings', - }) + }), ).to.deep.equal({ message: 'offline', link: 'https://www.twitch.tv/undefined', diff --git a/services/twitter/twitter-redirect.tester.js b/services/twitter/twitter-redirect.tester.js index e777d9a5bee729c99f69605595cb0e245e0d7597..4ecefd8e0fa91d6ea8e950c34253653ba8deaa71 100644 --- a/services/twitter/twitter-redirect.tester.js +++ b/services/twitter/twitter-redirect.tester.js @@ -9,5 +9,5 @@ export const t = new ServiceTester({ t.create('twitter') .get('/https/shields.io.svg') .expectRedirect( - `/twitter/url.svg?url=${encodeURIComponent('https://shields.io')}` + `/twitter/url.svg?url=${encodeURIComponent('https://shields.io')}`, ) diff --git a/services/twitter/twitter.service.js b/services/twitter/twitter.service.js index f674a1a430dd768056519c941ec50f44454e5dcf..59bf05fd56ce73e354400aa2c01ed775e9ab21a5 100644 --- a/services/twitter/twitter.service.js +++ b/services/twitter/twitter.service.js @@ -103,7 +103,7 @@ class TwitterFollow extends BaseJsonService { style: 'social', link: [ `https://twitter.com/intent/follow?screen_name=${encodeURIComponent( - user + user, )}`, ], } diff --git a/services/ubuntu/ubuntu.service.js b/services/ubuntu/ubuntu.service.js index fae6f52837235fd44a9d1862a1aedd897b02050f..3b2553150388d32277359300434402a09c07cacb 100644 --- a/services/ubuntu/ubuntu.service.js +++ b/services/ubuntu/ubuntu.service.js @@ -7,7 +7,7 @@ const schema = Joi.object({ .items( Joi.object({ source_package_version: Joi.string().required(), - }) + }), ) .required(), }).required() @@ -36,7 +36,7 @@ export default class Ubuntu extends BaseJsonService { const seriesParam = series ? { distro_series: `https://api.launchpad.net/1.0/ubuntu/${encodeURIComponent( - series + series, )}`, } : {} diff --git a/services/ubuntu/ubuntu.tester.js b/services/ubuntu/ubuntu.tester.js index c622493075b08960b53d4028f23a858aa70d63ae..16f5228f5f67f03428d7a66dceecc51a3abe8d3e 100644 --- a/services/ubuntu/ubuntu.tester.js +++ b/services/ubuntu/ubuntu.tester.js @@ -3,7 +3,7 @@ import { createServiceTester } from '../tester.js' export const t = await createServiceTester() const isUbuntuVersion = Joi.string().regex( - /^v(\d+:)?\d+(\.\d+)*([\w\\.]*)?([-+~].*)?$/ + /^v(\d+:)?\d+(\.\d+)*([\w\\.]*)?([-+~].*)?$/, ) t.create('Ubuntu package (default distribution, valid)') @@ -18,7 +18,7 @@ t.create('Ubuntu package (valid)') .intercept(nock => nock('https://api.launchpad.net') .get( - '/1.0/ubuntu/+archive/primary?ws.op=getPublishedSources&exact_match=true&order_by_date=true&status=Published&source_name=ubuntu-wallpapers&distro_series=https%3A%2F%2Fapi.launchpad.net%2F1.0%2Fubuntu%2Fbionic' + '/1.0/ubuntu/+archive/primary?ws.op=getPublishedSources&exact_match=true&order_by_date=true&status=Published&source_name=ubuntu-wallpapers&distro_series=https%3A%2F%2Fapi.launchpad.net%2F1.0%2Fubuntu%2Fbionic', ) .reply(200, { entries: [ @@ -27,7 +27,7 @@ t.create('Ubuntu package (valid)') source_package_version: '18.04.1-0ubuntu1', }, ], - }) + }), ) .expectBadge({ label: 'ubuntu', message: 'v18.04.1-0ubuntu1' }) diff --git a/services/uptimerobot/uptimerobot-base.js b/services/uptimerobot/uptimerobot-base.js index 2afa607b9fa70aea0cf67c37eb39249feda79325..fbdae811d388e4e99f92b0193c14d1f4269e2607 100644 --- a/services/uptimerobot/uptimerobot-base.js +++ b/services/uptimerobot/uptimerobot-base.js @@ -25,7 +25,7 @@ const singleMonitorResponse = Joi.alternatives( Joi.object({ stat: Joi.equal('ok').required(), monitors: Joi.array().length(1).items(monitor).required(), - }).required() + }).required(), ) const singleMonitorResponseWithUptime = Joi.alternatives( @@ -33,7 +33,7 @@ const singleMonitorResponseWithUptime = Joi.alternatives( Joi.object({ stat: Joi.equal('ok').required(), monitors: Joi.array().length(1).items(monitorWithUptime).required(), - }).required() + }).required(), ) export default class UptimeRobotBase extends BaseJsonService { diff --git a/services/uptimerobot/uptimerobot-ratio.tester.js b/services/uptimerobot/uptimerobot-ratio.tester.js index db6b55c9da933bc2cb34ee6b0dd89c52e09d9e6e..d50c077df141d91ce6865ab2343d264bbdd17bc8 100644 --- a/services/uptimerobot/uptimerobot-ratio.tester.js +++ b/services/uptimerobot/uptimerobot-ratio.tester.js @@ -33,7 +33,7 @@ t.create('Uptime Robot: Percentage (unspecified error)') .intercept(nock => nock('https://api.uptimerobot.com') .post('/v2/getMonitors') - .reply(200, '{"stat": "fail"}') + .reply(200, '{"stat": "fail"}'), ) .expectBadge({ label: 'uptime', message: 'service error' }) @@ -42,14 +42,16 @@ t.create('Uptime Robot: Percentage (service unavailable)') .intercept(nock => nock('https://api.uptimerobot.com') .post('/v2/getMonitors') - .reply(503, '{"error": "oh noes!!"}') + .reply(503, '{"error": "oh noes!!"}'), ) .expectBadge({ label: 'uptime', message: 'inaccessible' }) t.create('Uptime Robot: Percentage (unexpected response, valid json)') .get('/m778918918-3e92c097147760ee39d02d36.json') .intercept(nock => - nock('https://api.uptimerobot.com').post('/v2/getMonitors').reply(200, '[]') + nock('https://api.uptimerobot.com') + .post('/v2/getMonitors') + .reply(200, '[]'), ) .expectBadge({ label: 'uptime', message: 'invalid response data' }) @@ -58,6 +60,6 @@ t.create('Uptime Robot: Percentage (unexpected response, invalid json)') .intercept(nock => nock('https://api.uptimerobot.com') .post('/v2/getMonitors') - .reply(invalidJSON) + .reply(invalidJSON), ) .expectBadge({ label: 'uptime', message: 'unparseable json response' }) diff --git a/services/uptimerobot/uptimerobot-status.tester.js b/services/uptimerobot/uptimerobot-status.tester.js index dca7e92554e3d0988f3d18b12587d36833c92cc0..1af85f668dc10812371c6b4d48b38ad30842e88c 100644 --- a/services/uptimerobot/uptimerobot-status.tester.js +++ b/services/uptimerobot/uptimerobot-status.tester.js @@ -8,7 +8,7 @@ const isUptimeStatus = Joi.string().valid( 'not checked yet', 'up', 'seems down', - 'down' + 'down', ) t.create('Uptime Robot: Status (valid)') @@ -34,7 +34,7 @@ t.create('Uptime Robot: Status (unspecified error)') .intercept(nock => nock('https://api.uptimerobot.com') .post('/v2/getMonitors') - .reply(200, '{"stat": "fail"}') + .reply(200, '{"stat": "fail"}'), ) .expectBadge({ label: 'status', message: 'service error' }) @@ -43,14 +43,16 @@ t.create('Uptime Robot: Status (service unavailable)') .intercept(nock => nock('https://api.uptimerobot.com') .post('/v2/getMonitors') - .reply(503, '{"error": "oh noes!!"}') + .reply(503, '{"error": "oh noes!!"}'), ) .expectBadge({ label: 'status', message: 'inaccessible' }) t.create('Uptime Robot: Status (unexpected response, valid json)') .get('/m778918918-3e92c097147760ee39d02d36.json') .intercept(nock => - nock('https://api.uptimerobot.com').post('/v2/getMonitors').reply(200, '[]') + nock('https://api.uptimerobot.com') + .post('/v2/getMonitors') + .reply(200, '[]'), ) .expectBadge({ label: 'status', message: 'invalid response data' }) @@ -59,6 +61,6 @@ t.create('Uptime Robot: Status (unexpected response, invalid json)') .intercept(nock => nock('https://api.uptimerobot.com') .post('/v2/getMonitors') - .reply(invalidJSON) + .reply(invalidJSON), ) .expectBadge({ label: 'status', message: 'unparseable json response' }) diff --git a/services/vcpkg/vcpkg-version-helpers.spec.js b/services/vcpkg/vcpkg-version-helpers.spec.js index 5c16de5f5439a9319e6ea00a3a4e2d80864fd496..c73e804b2ca1ab55e53ac468fa2b2dffe0f9d272 100644 --- a/services/vcpkg/vcpkg-version-helpers.spec.js +++ b/services/vcpkg/vcpkg-version-helpers.spec.js @@ -7,7 +7,7 @@ describe('parseVersionFromVcpkgManifest', function () { expect( parseVersionFromVcpkgManifest({ version: '2.12.1', - }) + }), ).to.equal('2.12.1') }) @@ -15,7 +15,7 @@ describe('parseVersionFromVcpkgManifest', function () { expect( parseVersionFromVcpkgManifest({ 'version-date': '2022-12-04', - }) + }), ).to.equal('2022-12-04') }) @@ -23,7 +23,7 @@ describe('parseVersionFromVcpkgManifest', function () { expect( parseVersionFromVcpkgManifest({ 'version-semver': '3.11.2', - }) + }), ).to.equal('3.11.2') }) @@ -31,7 +31,7 @@ describe('parseVersionFromVcpkgManifest', function () { expect( parseVersionFromVcpkgManifest({ 'version-string': '22.01', - }) + }), ).to.equal('22.01') }) diff --git a/services/vcpkg/vcpkg-version.service.js b/services/vcpkg/vcpkg-version.service.js index 0b2e0403083d827f4a25d87c8eae34bbd2dfc72e..6584acb56762b49bc485b4a022198a94686e831c 100644 --- a/services/vcpkg/vcpkg-version.service.js +++ b/services/vcpkg/vcpkg-version.service.js @@ -21,7 +21,7 @@ const vcpkgManifestSchema = Joi.alternatives() }).required(), Joi.object({ 'version-string': Joi.string().required(), - }).required() + }).required(), ) export default class VcpkgVersion extends ConditionalGithubAuthV3Service { diff --git a/services/version.js b/services/version.js index 7d3b3ff4ca089993d980e47ab508a017d00aa3f5..6d7f357b4844916ac47bb4d82ad43436b53a38b7 100644 --- a/services/version.js +++ b/services/version.js @@ -77,8 +77,8 @@ function latestMaybeSemVer(versions, pre) { semver.compareBuild( `${a}`.toLowerCase(), `${b}`.toLowerCase(), - /* loose */ true - ) + /* loose */ true, + ), )[versions.length - 1] } catch (e) { version = latestDottedVersion(versions) @@ -109,7 +109,7 @@ function latest(versions, { pre = false } = {}) { // fall back to a case-insensitive string comparison if (version == null) { origVersions = origVersions.sort((a, b) => - a.toLowerCase().localeCompare(b.toLowerCase()) + a.toLowerCase().localeCompare(b.toLowerCase()), ) version = origVersions[origVersions.length - 1] } diff --git a/services/version.spec.js b/services/version.spec.js index df6a4aa8e4426c6f6d7d5e4678b4179e9814af28..d4ecce758d22199fe7d12dd50695d1a9c9d5d388 100644 --- a/services/version.spec.js +++ b/services/version.spec.js @@ -54,7 +54,7 @@ describe('Version helpers', function () { 'v1.0.1-RC.2', 'v1.0.0', ], - { pre: includePre } + { pre: includePre }, ).expect('v1.0.1-RC.2') given( [ @@ -66,7 +66,7 @@ describe('Version helpers', function () { 'v1.0.1-RC.2', 'v1.0.1', ], - { pre: includePre } + { pre: includePre }, ).expect('v1.0.1') given( [ @@ -76,7 +76,7 @@ describe('Version helpers', function () { 'v1.0.1-beta.1', 'v1.0.1-RC.1', ], - { pre: includePre } + { pre: includePre }, ).expect('v1.0.1-RC.1') // Exclude pre-releases @@ -116,7 +116,7 @@ describe('Version helpers', function () { // Semver mixed with non semver versions given(['1.0.0', '1.0.2', '1.1', '1.0', 'notaversion2', '12bcde4']).expect( - '1.1' + '1.1', ) // build qualifiers - https://github.com/badges/shields/issues/4172 diff --git a/services/visual-studio-app-center/visual-studio-app-center-builds.tester.js b/services/visual-studio-app-center/visual-studio-app-center-builds.tester.js index 0a70d24e994d56d1f06084c154780049a69636eb..33699fe64b0ba6a9f3ac991ee5cd82e70906f4f4 100644 --- a/services/visual-studio-app-center/visual-studio-app-center-builds.tester.js +++ b/services/visual-studio-app-center/visual-studio-app-center-builds.tester.js @@ -11,7 +11,7 @@ t.create('Valid Build') { result: 'succeeded', }, - ]) + ]), ) .expectBadge({ label: 'build', diff --git a/services/visual-studio-app-center/visual-studio-app-center-releases-osversion.tester.js b/services/visual-studio-app-center/visual-studio-app-center-releases-osversion.tester.js index 826bcf1ad863bb2b400b430a94387edff47fe681..1b31221cda93a1ac708a9f9e295a05bc87f708b5 100644 --- a/services/visual-studio-app-center/visual-studio-app-center-releases-osversion.tester.js +++ b/services/visual-studio-app-center/visual-studio-app-center-releases-osversion.tester.js @@ -8,7 +8,7 @@ export const t = await createServiceTester() t.create('[fixed] Example Release') // This application will never have a new release created. .get( - '/jct/test-fixed-android-react/8c9b519a0750095b9fea3d40b2645d8a0c24a2f3.json' + '/jct/test-fixed-android-react/8c9b519a0750095b9fea3d40b2645d8a0c24a2f3.json', ) .expectBadge({ label: 'android', diff --git a/services/visual-studio-app-center/visual-studio-app-center-releases-size.tester.js b/services/visual-studio-app-center/visual-studio-app-center-releases-size.tester.js index 5a1681a79eab0739c129492affe26a46d012bd39..9f41c810f9e050b39952fe5fd0d949c25c94a06b 100644 --- a/services/visual-studio-app-center/visual-studio-app-center-releases-size.tester.js +++ b/services/visual-studio-app-center/visual-studio-app-center-releases-size.tester.js @@ -9,7 +9,7 @@ t.create('8368844 bytes to 8.37 megabytes') .get('/nock/nock/releases/latest') .reply(200, { size: 8368844, - }) + }), ) .expectBadge({ label: 'size', @@ -18,7 +18,7 @@ t.create('8368844 bytes to 8.37 megabytes') t.create('Valid Release') .get( - '/jct/test-fixed-android-react/8c9b519a0750095b9fea3d40b2645d8a0c24a2f3.json' + '/jct/test-fixed-android-react/8c9b519a0750095b9fea3d40b2645d8a0c24a2f3.json', ) .expectBadge({ label: 'size', diff --git a/services/visual-studio-app-center/visual-studio-app-center-releases-version.tester.js b/services/visual-studio-app-center/visual-studio-app-center-releases-version.tester.js index 49f528a0bfbe810501d5378cc669e845bbf346e6..e1afba88ff6b00f10b4f3712e46d52ffcb806de9 100644 --- a/services/visual-studio-app-center/visual-studio-app-center-releases-version.tester.js +++ b/services/visual-studio-app-center/visual-studio-app-center-releases-version.tester.js @@ -8,7 +8,7 @@ export const t = await createServiceTester() t.create('[fixed] Example Release') // This application will never have a new release created. .get( - '/jct/test-fixed-android-react/8c9b519a0750095b9fea3d40b2645d8a0c24a2f3.json' + '/jct/test-fixed-android-react/8c9b519a0750095b9fea3d40b2645d8a0c24a2f3.json', ) .expectBadge({ label: 'release', diff --git a/services/visual-studio-marketplace/visual-studio-marketplace-azure-devops-installs.tester.js b/services/visual-studio-marketplace/visual-studio-marketplace-azure-devops-installs.tester.js index 7cfa0618ab26c19d3af0e566fa52069e8f1cd4df..1a320ef539d3961c80cfa8bd16f810c8eb1f4a9e 100644 --- a/services/visual-studio-marketplace/visual-studio-marketplace-azure-devops-installs.tester.js +++ b/services/visual-studio-marketplace/visual-studio-marketplace-azure-devops-installs.tester.js @@ -63,7 +63,7 @@ t.create('total installs') .intercept(nock => nock('https://marketplace.visualstudio.com/_apis/public/gallery/') .post('/extensionquery/') - .reply(200, mockResponse) + .reply(200, mockResponse), ) .expectBadge({ label: 'installs', @@ -76,7 +76,7 @@ t.create('services installs') .intercept(nock => nock('https://marketplace.visualstudio.com/_apis/public/gallery/') .post('/extensionquery/') - .reply(200, mockResponse) + .reply(200, mockResponse), ) .expectBadge({ label: 'installs', @@ -89,7 +89,7 @@ t.create('onprem installs') .intercept(nock => nock('https://marketplace.visualstudio.com/_apis/public/gallery/') .post('/extensionquery/') - .reply(200, mockResponse) + .reply(200, mockResponse), ) .expectBadge({ label: 'installs', @@ -119,7 +119,7 @@ t.create('zero installs') ], }, ], - }) + }), ) .expectBadge({ label: 'installs', diff --git a/services/visual-studio-marketplace/visual-studio-marketplace-base.js b/services/visual-studio-marketplace/visual-studio-marketplace-base.js index 53456a91df334d3d9d004d588ad2d49bd519136c..ab12404c3f01c736a1ec78882c1b2b54ae52e44d 100644 --- a/services/visual-studio-marketplace/visual-studio-marketplace-base.js +++ b/services/visual-studio-marketplace/visual-studio-marketplace-base.js @@ -14,7 +14,7 @@ const extensionQuerySchema = Joi.object({ Joi.object({ statisticName: Joi.string().required(), value: Joi.number().required(), - }) + }), ) .default([]), versions: Joi.array() @@ -26,19 +26,19 @@ const extensionQuerySchema = Joi.object({ Joi.object({ key: Joi.string().required(), value: Joi.any().required(), - }) + }), ) .default([]), - }) + }), ) .min(1) .required(), releaseDate: Joi.string().required(), lastUpdated: Joi.string().required(), - }) + }), ) .required(), - }) + }), ) .required(), }).required() diff --git a/services/visual-studio-marketplace/visual-studio-marketplace-downloads.tester.js b/services/visual-studio-marketplace/visual-studio-marketplace-downloads.tester.js index e78ee4489bfe1dc44fceef65b5e7d68df74fe6ef..a964793362f257e2f301d2c89472c97876349ebe 100644 --- a/services/visual-studio-marketplace/visual-studio-marketplace-downloads.tester.js +++ b/services/visual-studio-marketplace/visual-studio-marketplace-downloads.tester.js @@ -63,7 +63,7 @@ t.create('installs') .intercept(nock => nock('https://marketplace.visualstudio.com/_apis/public/gallery/') .post('/extensionquery/') - .reply(200, mockResponse) + .reply(200, mockResponse), ) .expectBadge({ label: 'installs', @@ -93,7 +93,7 @@ t.create('zero installs') ], }, ], - }) + }), ) .expectBadge({ label: 'installs', @@ -122,7 +122,7 @@ t.create('missing statistics array') ], }, ], - }) + }), ) .expectBadge({ label: 'installs', @@ -135,7 +135,7 @@ t.create('downloads') .intercept(nock => nock('https://marketplace.visualstudio.com/_apis/public/gallery/') .post('/extensionquery/') - .reply(200, mockResponse) + .reply(200, mockResponse), ) .expectBadge({ label: 'downloads', diff --git a/services/visual-studio-marketplace/visual-studio-marketplace-last-updated.tester.js b/services/visual-studio-marketplace/visual-studio-marketplace-last-updated.tester.js index cd7e40745a4ff640082e2854064838cce3692ad9..997127064110dbdb94445ad5d8f87c0962b45a57 100644 --- a/services/visual-studio-marketplace/visual-studio-marketplace-last-updated.tester.js +++ b/services/visual-studio-marketplace/visual-studio-marketplace-last-updated.tester.js @@ -18,7 +18,7 @@ t.create('invalid extension id') t.create('non existent extension') .get( - '/visual-studio-marketplace/last-updated/yasht.terminal-all-in-one-fake.json' + '/visual-studio-marketplace/last-updated/yasht.terminal-all-in-one-fake.json', ) .expectBadge({ label: 'last updated', diff --git a/services/visual-studio-marketplace/visual-studio-marketplace-rating.tester.js b/services/visual-studio-marketplace/visual-studio-marketplace-rating.tester.js index ed6f987bbe7f398c12acb381eb04add2ab6b9fa8..36a66ee735730ad45eac89ccf8f9d5a6d66affb6 100644 --- a/services/visual-studio-marketplace/visual-studio-marketplace-rating.tester.js +++ b/services/visual-studio-marketplace/visual-studio-marketplace-rating.tester.js @@ -49,7 +49,7 @@ t.create('rating') ], }, ], - }) + }), ) .expectBadge({ label: 'rating', @@ -79,7 +79,7 @@ t.create('zero rating') ], }, ], - }) + }), ) .expectBadge({ label: 'rating', @@ -118,7 +118,7 @@ t.create('stars') ], }, ], - }) + }), ) .expectBadge({ label: 'rating', diff --git a/services/visual-studio-marketplace/visual-studio-marketplace-release-date.tester.js b/services/visual-studio-marketplace/visual-studio-marketplace-release-date.tester.js index acf9da220bd8ffa432a7d2ad26f8d7b7c40c7a13..47ead2faba84a6182505f1d32429b34d77d3e124 100644 --- a/services/visual-studio-marketplace/visual-studio-marketplace-release-date.tester.js +++ b/services/visual-studio-marketplace/visual-studio-marketplace-release-date.tester.js @@ -18,7 +18,7 @@ t.create('invalid extension id') t.create('non existent extension') .get( - '/visual-studio-marketplace/release-date/yasht.terminal-all-in-one-fake.json' + '/visual-studio-marketplace/release-date/yasht.terminal-all-in-one-fake.json', ) .expectBadge({ label: 'release date', diff --git a/services/visual-studio-marketplace/visual-studio-marketplace-version.service.js b/services/visual-studio-marketplace/visual-studio-marketplace-version.service.js index 9597d2880950323e5690a6fb347febc236eacfb0..c5883da02ca24c4a13f673e7eb7fcc381eccbff4 100644 --- a/services/visual-studio-marketplace/visual-studio-marketplace-version.service.js +++ b/services/visual-studio-marketplace/visual-studio-marketplace-version.service.js @@ -50,8 +50,8 @@ export default class VisualStudioMarketplaceVersion extends VisualStudioMarketpl version = extension.versions.find( obj => !obj.properties.find( - ({ key, value }) => key === preReleaseKey && value === 'true' - ) + ({ key, value }) => key === preReleaseKey && value === 'true', + ), )?.version } diff --git a/services/visual-studio-marketplace/visual-studio-marketplace-version.tester.js b/services/visual-studio-marketplace/visual-studio-marketplace-version.tester.js index 6c26e852292a34ad6def762b998ddb937e6893c2..cf53176636fd919b65b55a142b07202b6d743d2d 100644 --- a/services/visual-studio-marketplace/visual-studio-marketplace-version.tester.js +++ b/services/visual-studio-marketplace/visual-studio-marketplace-version.tester.js @@ -52,7 +52,7 @@ t.create('version') ], }, ], - }) + }), ) .expectBadge({ label: 'version', @@ -61,7 +61,7 @@ t.create('version') }) t.create( - 'version - includePrereleases flag is false and response has pre-release only' + 'version - includePrereleases flag is false and response has pre-release only', ) .get('/visual-studio-marketplace/v/lextudio.restructuredtext.json') .intercept(nock => @@ -120,7 +120,7 @@ t.create( ], }, ], - }) + }), ) .expectBadge({ label: 'version', @@ -186,7 +186,7 @@ t.create('version - prerelease key has false value') ], }, ], - }) + }), ) .expectBadge({ label: 'version', @@ -196,7 +196,7 @@ t.create('version - prerelease key has false value') t.create('pre-release version') .get( - '/visual-studio-marketplace/v/swellaby.vscode-rust-test-adapter.json?include_prereleases' + '/visual-studio-marketplace/v/swellaby.vscode-rust-test-adapter.json?include_prereleases', ) .intercept(nock => nock('https://marketplace.visualstudio.com/_apis/public/gallery/') @@ -237,7 +237,7 @@ t.create('pre-release version') ], }, ], - }) + }), ) .expectBadge({ label: 'version', diff --git a/services/vpm/vpm-version.service.js b/services/vpm/vpm-version.service.js index c33db47af4aacb842ad8de5e876efe938e0efd4f..6b5145eb1bd85d63cd605551de51c2bb12d263f3 100644 --- a/services/vpm/vpm-version.service.js +++ b/services/vpm/vpm-version.service.js @@ -14,7 +14,7 @@ const schema = Joi.object({ /./, Joi.object({ versions: Joi.object().pattern(/./, Joi.object()).min(1).required(), - }).required() + }).required(), ) .required(), }).required() @@ -65,7 +65,7 @@ export default class VpmVersion extends BaseJsonService { async handle( { packageId }, - { repository_url: repositoryUrl, include_prereleases: prereleases } + { repository_url: repositoryUrl, include_prereleases: prereleases }, ) { const data = await this.fetch({ repositoryUrl }) const pkg = data.packages[packageId] diff --git a/services/vpm/vpm-version.tester.js b/services/vpm/vpm-version.tester.js index 224fea0bb7d1ab21172efed48a706e4aa767eaaf..eb9827e67d58903099b1788723872199caaab88c 100644 --- a/services/vpm/vpm-version.tester.js +++ b/services/vpm/vpm-version.tester.js @@ -4,7 +4,7 @@ export const t = await createServiceTester() t.create('gets the package version of com.vrchat.udonsharp') .get( - '/com.vrchat.udonsharp.json?repository_url=https%3A%2F%2Fpackages.vrchat.com%2Fcurated%3Fdownload' + '/com.vrchat.udonsharp.json?repository_url=https%3A%2F%2Fpackages.vrchat.com%2Fcurated%3Fdownload', ) .expectBadge({ label: 'vpm', message: isSemver }) @@ -22,10 +22,10 @@ t.create('gets the latest version') }, }, }, - }) + }), ) .get( - '/com.vrchat.udonsharp.json?repository_url=https%3A%2F%2Fpackages.vrchat.com%2Fcurated%3Fdownload' + '/com.vrchat.udonsharp.json?repository_url=https%3A%2F%2Fpackages.vrchat.com%2Fcurated%3Fdownload', ) .expectBadge({ label: 'vpm', message: 'v2.0.0' }) @@ -43,9 +43,9 @@ t.create('gets the latest version including prerelease') }, }, }, - }) + }), ) .get( - '/com.vrchat.udonsharp.json?repository_url=https%3A%2F%2Fpackages.vrchat.com%2Fcurated%3Fdownload&include_prereleases' + '/com.vrchat.udonsharp.json?repository_url=https%3A%2F%2Fpackages.vrchat.com%2Fcurated%3Fdownload&include_prereleases', ) .expectBadge({ label: 'vpm', message: 'v2.1.0-rc1' }) diff --git a/services/w3c/w3c-validation-helper.js b/services/w3c/w3c-validation-helper.js index b9bb515097eaadafae1627c467971405f766d45f..60f5b78cca9c1f9af017809ea329f1eb6b8c49ca 100644 --- a/services/w3c/w3c-validation-helper.js +++ b/services/w3c/w3c-validation-helper.js @@ -8,7 +8,7 @@ const svgExpression = '^SVG\\s?1\\.1\\s?,\\s?URL\\s?,\\s?XHTML\\s?,\\s?MathML\\s?3\\.0$' const presetRegex = new RegExp( `(${html5Expression})|(${html4Expression})|(${xhtmlExpression})|(${svgExpression})`, - 'i' + 'i', ) const getMessage = messageTypes => { @@ -20,7 +20,7 @@ const getMessage = messageTypes => { } const messages = messageTypeKeys.map( - key => `${messageTypes[key]} ${key}${messageTypes[key] > 1 ? 's' : ''}` + key => `${messageTypes[key]} ${key}${messageTypes[key] > 1 ? 's' : ''}`, ) return messages.join(', ') } diff --git a/services/w3c/w3c-validation-helper.spec.js b/services/w3c/w3c-validation-helper.spec.js index 3c024c2bbc89be7e25edba92291f93a00a616a3f..516b5f644a5de57a57e514761fe9dd276db63392 100644 --- a/services/w3c/w3c-validation-helper.spec.js +++ b/services/w3c/w3c-validation-helper.spec.js @@ -167,7 +167,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/html5.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/' + 'http://s.validator.nu/html5.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/', ) }) @@ -177,7 +177,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/html5-its.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/' + 'http://s.validator.nu/html5-its.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/', ) }) @@ -187,7 +187,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/html5-rdfalite.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/' + 'http://s.validator.nu/html5-rdfalite.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/', ) }) @@ -197,7 +197,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/xhtml10/xhtml-strict.rnc http://c.validator.nu/all-html4/' + 'http://s.validator.nu/xhtml10/xhtml-strict.rnc http://c.validator.nu/all-html4/', ) }) @@ -207,7 +207,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/xhtml10/xhtml-transitional.rnc http://c.validator.nu/all-html4/' + 'http://s.validator.nu/xhtml10/xhtml-transitional.rnc http://c.validator.nu/all-html4/', ) }) @@ -217,7 +217,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/xhtml10/xhtml-frameset.rnc http://c.validator.nu/all-html4/' + 'http://s.validator.nu/xhtml10/xhtml-frameset.rnc http://c.validator.nu/all-html4/', ) }) @@ -227,7 +227,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/xhtml5.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/' + 'http://s.validator.nu/xhtml5.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/', ) }) @@ -237,7 +237,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/xhtml5-rdfalite.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/' + 'http://s.validator.nu/xhtml5-rdfalite.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/', ) }) @@ -247,7 +247,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/xhtml1-ruby-rdf-svg-mathml.rnc http://c.validator.nu/all-html4/' + 'http://s.validator.nu/xhtml1-ruby-rdf-svg-mathml.rnc http://c.validator.nu/all-html4/', ) }) @@ -257,7 +257,7 @@ describe('w3c-validation-helper', function () { const actualResult = getSchema(preset) expect(actualResult).to.equal( - 'http://s.validator.nu/svg-xhtml5-rdf-mathml.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/' + 'http://s.validator.nu/svg-xhtml5-rdf-mathml.rnc http://s.validator.nu/html5/assertions.sch http://c.validator.nu/all/', ) }) }) diff --git a/services/w3c/w3c-validation.service.js b/services/w3c/w3c-validation.service.js index 070b5cf3454dce21b99e3661aae6f738567a8316..6820ca62923843b65e75972426a1f003db7ec441 100644 --- a/services/w3c/w3c-validation.service.js +++ b/services/w3c/w3c-validation.service.js @@ -20,7 +20,7 @@ const schema = Joi.object({ .required(), subType: Joi.string().optional(), message: Joi.string().required(), - }) + }), ), }).required() diff --git a/services/w3c/w3c-validation.tester.js b/services/w3c/w3c-validation.tester.js index 75bbae578777565c7702926accb1c8bea43b2ca8..f7cc4880c62c8195204d6d6937485ccf47db4c3c 100644 --- a/services/w3c/w3c-validation.tester.js +++ b/services/w3c/w3c-validation.tester.js @@ -7,21 +7,21 @@ const isErrorOnly = Joi.string().regex(/^[0-9]+ errors?$/) const isWarningOnly = Joi.string().regex(/^[0-9]+ warnings?$/) const isErrorAndWarning = Joi.string().regex( - /^[0-9]+ errors?, [0-9]+ warnings?$/ + /^[0-9]+ errors?, [0-9]+ warnings?$/, ) const isW3CMessage = Joi.alternatives().try( 'validated', isErrorOnly, isWarningOnly, - isErrorAndWarning + isErrorAndWarning, ) const isW3CColors = Joi.alternatives().try('brightgreen', 'red', 'yellow') t.create( - 'W3C Validation page conforms to standards with no preset and parser with brightgreen badge' + 'W3C Validation page conforms to standards with no preset and parser with brightgreen badge', ) .get( - '/default.json?targetUrl=https://hsivonen.com/test/moz/messages-types/no-message.html' + '/default.json?targetUrl=https://hsivonen.com/test/moz/messages-types/no-message.html', ) .expectBadge({ label: 'w3c', @@ -30,10 +30,10 @@ t.create( }) t.create( - 'W3C Validation page conforms to standards with no HTML4 preset and HTML parser with brightgreen badge' + 'W3C Validation page conforms to standards with no HTML4 preset and HTML parser with brightgreen badge', ) .get( - '/html.json?targetUrl=https://hsivonen.com/test/moz/messages-types/no-message.html&preset=HTML,%20SVG%201.1,%20MathML%203.0' + '/html.json?targetUrl=https://hsivonen.com/test/moz/messages-types/no-message.html&preset=HTML,%20SVG%201.1,%20MathML%203.0', ) .expectBadge({ label: 'w3c', @@ -43,7 +43,7 @@ t.create( t.create('W3C Validation target url not found error') .get( - '/default.json?targetUrl=http://hsivonen.com/test/moz/messages-types/404.html' + '/default.json?targetUrl=http://hsivonen.com/test/moz/messages-types/404.html', ) .expectBadge({ label: 'w3c', @@ -59,7 +59,7 @@ t.create('W3C Validation target url host not found error') t.create('W3C Validation page has 1 validation error with red badge') .get( - '/default.json?targetUrl=http://hsivonen.com/test/moz/messages-types/warning.html' + '/default.json?targetUrl=http://hsivonen.com/test/moz/messages-types/warning.html', ) .expectBadge({ label: 'w3c', @@ -68,10 +68,10 @@ t.create('W3C Validation page has 1 validation error with red badge') }) t.create( - 'W3C Validation page has 3 validation error using HTML 4.01 Frameset preset with red badge' + 'W3C Validation page has 3 validation error using HTML 4.01 Frameset preset with red badge', ) .get( - '/html.json?targetUrl=http://hsivonen.com/test/moz/messages-types/warning.html&preset=HTML 4.01 Frameset, URL / XHTML 1.0 Frameset, URL' + '/html.json?targetUrl=http://hsivonen.com/test/moz/messages-types/warning.html&preset=HTML 4.01 Frameset, URL / XHTML 1.0 Frameset, URL', ) .expectBadge({ label: 'w3c', @@ -81,7 +81,7 @@ t.create( t.create('W3C Validation page has 1 validation warning with yellow badge') .get( - '/default.json?targetUrl=http://hsivonen.com/test/moz/messages-types/info.svg' + '/default.json?targetUrl=http://hsivonen.com/test/moz/messages-types/info.svg', ) .expectBadge({ label: 'w3c', @@ -91,7 +91,7 @@ t.create('W3C Validation page has 1 validation warning with yellow badge') t.create('W3C Validation page has multiple of validation errors with red badge') .get( - '/default.json?targetUrl=http://hsivonen.com/test/moz/messages-types/range-error.html' + '/default.json?targetUrl=http://hsivonen.com/test/moz/messages-types/range-error.html', ) .expectBadge({ label: 'w3c', diff --git a/services/weblate/weblate-base.js b/services/weblate/weblate-base.js index 857344bf31cd745c8f1de64bf1caca80bb3fc6f3..9128e753fa995a245d7e1847fd8a8606bcb70415 100644 --- a/services/weblate/weblate-base.js +++ b/services/weblate/weblate-base.js @@ -17,8 +17,8 @@ export default class WeblateBase extends BaseJsonService { return this._requestJson( this.authHelper.withBearerAuthHeader( requestParams, - 'Token' // lgtm [js/hardcoded-credentials] - ) + 'Token', // lgtm [js/hardcoded-credentials] + ), ) } } diff --git a/services/website/website-redirect.tester.js b/services/website/website-redirect.tester.js index 0aeba6b5bc629f7241c5ccf2d3d7d307ea1b5dab..b0840ec02fca4e19c335fd59f9f703010053da2d 100644 --- a/services/website/website-redirect.tester.js +++ b/services/website/website-redirect.tester.js @@ -10,24 +10,24 @@ t.create('Website with custom messages') .get('/website-up-down/https/www.google.com.svg') .expectRedirect( `/website.svg?down_message=down&up_message=up&url=${encodeURIComponent( - 'https://www.google.com' - )}` + 'https://www.google.com', + )}`, ) t.create('Website with custom messages and colors') .get('/website-up-down-yellow-gray/https/www.google.com.svg') .expectRedirect( `/website.svg?down_color=gray&down_message=down&up_color=yellow&up_message=up&url=${encodeURIComponent( - 'https://www.google.com' - )}` + 'https://www.google.com', + )}`, ) t.create('Website to queryParam with custom messages and colors') .get( - '/website/https/www.google.com.svg?down_color=gray&down_message=down&up_color=yellow&up_message=up' + '/website/https/www.google.com.svg?down_color=gray&down_message=down&up_color=yellow&up_message=up', ) .expectRedirect( `/website.svg?down_color=gray&down_message=down&up_color=yellow&up_message=up&url=${encodeURIComponent( - 'https://www.google.com' - )}` + 'https://www.google.com', + )}`, ) diff --git a/services/website/website.service.js b/services/website/website.service.js index cbce86afb0cd985f547f03bbb9937eb46316b4f0..ef867bb740c2994925676b98363d3df5a47cdfbc 100644 --- a/services/website/website.service.js +++ b/services/website/website.service.js @@ -71,7 +71,7 @@ export default class Website extends BaseService { up_color: upColor, down_color: downColor, url, - } + }, ) { let isUp try { diff --git a/services/website/website.tester.js b/services/website/website.tester.js index c70a206e684415616e6f1b0d9908958722e202c0..a7e592bbec7c6afd5a2c01c5b2854ca367caf432 100644 --- a/services/website/website.tester.js +++ b/services/website/website.tester.js @@ -48,14 +48,14 @@ t.create('status is down if response code is 401') t.create('custom online label, online message and online color') .get( - '/website.json?url=http://online.com&up_message=up&down_message=down&up_color=green&down_color=grey' + '/website.json?url=http://online.com&up_message=up&down_message=down&up_color=green&down_color=grey', ) .intercept(nock => nock('http://online.com').head('/').reply(200)) .expectBadge({ label: 'website', message: 'up', color: 'green' }) t.create('custom offline message and offline color') .get( - '/website.json?url=http://offline.com&up_message=up&down_message=down&up_color=green&down_color=grey' + '/website.json?url=http://offline.com&up_message=up&down_message=down&up_color=green&down_color=grey', ) .intercept(nock => nock('http://offline.com').head('/').reply(500)) .expectBadge({ label: 'website', message: 'down', color: 'grey' }) diff --git a/services/whatpulse/whatpulse.tester.js b/services/whatpulse/whatpulse.tester.js index 4dcbd311045b91c2c115d424dfe752c8f8ab8d16..c8850805d45497fd771300f91d4a5250b296a7ba 100644 --- a/services/whatpulse/whatpulse.tester.js +++ b/services/whatpulse/whatpulse.tester.js @@ -32,7 +32,7 @@ t.create('WhatPulse team as team name, keys - from Ranks') .expectBadge({ label: 'keys', message: isOrdinalNumber }) t.create( - 'WhatPulse invalid metric name (not one of the options from the modal`s dropdown)' + 'WhatPulse invalid metric name (not one of the options from the modal`s dropdown)', ) .get('/UpTIMe/user/jerone.json') .expectBadge({ label: '404', message: 'badge not found' }) diff --git a/services/wheelmap/wheelmap.service.js b/services/wheelmap/wheelmap.service.js index 98a43ef1d4eef773878ecddd065dbfdb997e6784..0729d9c416d8824cb7a0668e95132ed8beae227c 100644 --- a/services/wheelmap/wheelmap.service.js +++ b/services/wheelmap/wheelmap.service.js @@ -54,8 +54,8 @@ export default class Wheelmap extends BaseJsonService { 401: 'invalid token', 404: 'node not found', }, - } - ) + }, + ), ) } diff --git a/services/wheelmap/wheelmap.spec.js b/services/wheelmap/wheelmap.spec.js index 80287395c033ddf37563fc4c76f8119c3c6fd131..b6d9f22a5e62cc940063a70950b2eed604d49609 100644 --- a/services/wheelmap/wheelmap.spec.js +++ b/services/wheelmap/wheelmap.spec.js @@ -25,7 +25,7 @@ describe('Wheelmap', function () { const nodeId = '26699541' const scope = createMock({ nodeId, wheelchair: 'yes' }) expect( - await Wheelmap.invoke(defaultContext, config, { nodeId }) + await Wheelmap.invoke(defaultContext, config, { nodeId }), ).to.deep.equal({ message: 'yes', color: 'brightgreen' }) scope.done() }) @@ -34,7 +34,7 @@ describe('Wheelmap', function () { const nodeId = '2034868974' const scope = createMock({ nodeId, wheelchair: 'limited' }) expect( - await Wheelmap.invoke(defaultContext, config, { nodeId }) + await Wheelmap.invoke(defaultContext, config, { nodeId }), ).to.deep.equal({ message: 'limited', color: 'yellow' }) scope.done() }) @@ -43,7 +43,7 @@ describe('Wheelmap', function () { const nodeId = '-147495158' const scope = createMock({ nodeId, wheelchair: 'no' }) expect( - await Wheelmap.invoke(defaultContext, config, { nodeId }) + await Wheelmap.invoke(defaultContext, config, { nodeId }), ).to.deep.equal({ message: 'no', color: 'red' }) scope.done() }) @@ -52,7 +52,7 @@ describe('Wheelmap', function () { const nodeId = '0' const scope = createMock({ nodeId }) expect( - await Wheelmap.invoke(defaultContext, config, { nodeId }) + await Wheelmap.invoke(defaultContext, config, { nodeId }), ).to.deep.equal({ message: 'node not found', color: 'red', isError: true }) scope.done() }) diff --git a/services/wikiapiary/wikiapiary-installs.service.js b/services/wikiapiary/wikiapiary-installs.service.js index a8a772bca13f3528ebc21ea53237c31ec86436db..2adddec05baccd9b884f14662e0fd36a8a8f4d21 100644 --- a/services/wikiapiary/wikiapiary-installs.service.js +++ b/services/wikiapiary/wikiapiary-installs.service.js @@ -91,7 +91,7 @@ export default class WikiapiaryInstalls extends BaseJsonService { } const keyLowerCase = `${variant}:${name.toLowerCase()}` const resultKey = Object.keys(results).find( - key => keyLowerCase === key.toLowerCase() + key => keyLowerCase === key.toLowerCase(), ) if (resultKey === undefined) diff --git a/services/wikiapiary/wikiapiary-installs.tester.js b/services/wikiapiary/wikiapiary-installs.tester.js index 878ec756dd1632256acaa68ee3659de0e047a8a3..4637c604da1e4107dc64504f10a2b379fc37b099 100644 --- a/services/wikiapiary/wikiapiary-installs.tester.js +++ b/services/wikiapiary/wikiapiary-installs.tester.js @@ -38,6 +38,6 @@ t.create('Malformed API Response') 'Extension:Malformed': { printouts: { 'Has website count': [0] } }, }, }, - }) + }), ) .expectBadge({ label: 'installs', message: 'not found' }) diff --git a/services/wordpress/wordpress-base.js b/services/wordpress/wordpress-base.js index 04046aa0c4687c8c64d65c793dec6cf97c9cc18a..24ecd4ca20ed6e5cde96b122b6c6bc3d2792d283 100644 --- a/services/wordpress/wordpress-base.js +++ b/services/wordpress/wordpress-base.js @@ -68,7 +68,7 @@ export class BaseWordpress extends BaseJsonService { }, }, }, - { encode: false } + { encode: false }, ) const json = await this._requestJson({ diff --git a/services/wordpress/wordpress-downloads.service.js b/services/wordpress/wordpress-downloads.service.js index ec5b020857b9357d91bd1c783ee262a1d95fea49..aeb2aeac89da17a7b1f1bf9f0dbe7fe41df55a2d 100644 --- a/services/wordpress/wordpress-downloads.service.js +++ b/services/wordpress/wordpress-downloads.service.js @@ -92,7 +92,7 @@ function DownloadsForExtensionType(extensionType) { }, }) downloads = Object.values(json).reduce( - (a, b) => parseInt(a) + parseInt(b) + (a, b) => parseInt(a) + parseInt(b), ) } diff --git a/services/wordpress/wordpress-platform.tester.js b/services/wordpress/wordpress-platform.tester.js index c5987cdd1a18d5c6728943e93cc06d03f3f7ffc9..118f72e736dbd25274cf87942815c99f3be3bec5 100644 --- a/services/wordpress/wordpress-platform.tester.js +++ b/services/wordpress/wordpress-platform.tester.js @@ -73,7 +73,7 @@ t.create('Plugin Tested WP Version - current') requires_php: '5.5', }) .get('/core/version-check/1.7/') - .reply(200, mockedCoreResponseData) + .reply(200, mockedCoreResponseData), ) .expectBadge({ label: 'wordpress', @@ -99,7 +99,7 @@ t.create('Plugin Tested WP Version - old') requires_php: '5.5', }) .get('/core/version-check/1.7/') - .reply(200, mockedCoreResponseData) + .reply(200, mockedCoreResponseData), ) .expectBadge({ label: 'wordpress', @@ -125,7 +125,7 @@ t.create('Plugin Tested WP Version - non-exsistant or unsupported') requires_php: '5.5', }) .get('/core/version-check/1.7/') - .reply(200, mockedCoreResponseData) + .reply(200, mockedCoreResponseData), ) .expectBadge({ label: 'wordpress', @@ -149,7 +149,7 @@ t.create('Plugin Required WP Version | Missing') tested: '4.0.0', last_updated: '2020-01-01 7:21am GMT', requires_php: '5.5', - }) + }), ) .expectBadge({ label: 'wordpress', @@ -204,7 +204,7 @@ t.create('Plugin Required PHP Version (Not Set)') tested: '4.0.0', last_updated: '2020-01-01 7:21am GMT', requires_php: false, - }) + }), ) .expectBadge({ label: 'php', @@ -240,7 +240,7 @@ t.create('Theme Required PHP Version (Not Set)') tested: '4.0.0', requires_php: false, last_updated: '2020-01-01', - }) + }), ) .expectBadge({ label: 'php', diff --git a/services/wordpress/wordpress-version-color.integration.js b/services/wordpress/wordpress-version-color.integration.js index 5f4b6ce832a4c2bab99804c7bbf10e89b61223c8..2bbeef5a349bc868f9722ce796b567f52857c014 100644 --- a/services/wordpress/wordpress-version-color.integration.js +++ b/services/wordpress/wordpress-version-color.integration.js @@ -6,18 +6,18 @@ describe('versionColorForWordpressVersion()', function () { this.timeout(5e3) expect(await versionColorForWordpressVersion('11.2.0')).to.equal( - 'brightgreen' + 'brightgreen', ) expect(await versionColorForWordpressVersion('11.2')).to.equal( - 'brightgreen' + 'brightgreen', ) expect(await versionColorForWordpressVersion('3.2.0')).to.equal('yellow') expect(await versionColorForWordpressVersion('3.2')).to.equal('yellow') expect(await versionColorForWordpressVersion('4.7-beta.3')).to.equal( - 'yellow' + 'yellow', ) expect(await versionColorForWordpressVersion('cheese')).to.equal( - 'lightgrey' + 'lightgrey', ) }) }) diff --git a/services/youtube/youtube-base.js b/services/youtube/youtube-base.js index b66de4b4ef659ea644d67ebb1c17ba04d31678ce..7dec0ee51627312272b29e4348f78c50499a4f30 100644 --- a/services/youtube/youtube-base.js +++ b/services/youtube/youtube-base.js @@ -25,9 +25,9 @@ const schema = Joi.object({ Joi.object({ viewCount: nonNegativeInteger, subscriberCount: nonNegativeInteger, - }) + }), ), - }) + }), ), }).required() @@ -67,8 +67,8 @@ class YouTubeBase extends BaseJsonService { options: { searchParams: { id, part: 'statistics' }, }, - } - ) + }, + ), ) }