Showing 7 of 7 total issues

Function run has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
Open

async run() {
const {
flags: {
param: params,
config,
Severity: Minor
Found in bin/cli/commands/request.js - About 1 hr to fix

Identical blocks of code found in 2 locations. Consider refactoring.
Confirmed

jest.spyOn(process.stdout, 'write').mockImplementation((val) =>
result.push(require('strip-ansi')(val.toString('utf8')))
)
Severity: Minor
Found in bin/cli/__tests__/request.spec.js and 1 other location - About 50 mins to fix
bin/cli/__tests__/list.spec.js on lines 12..14

Identical blocks of code found in 2 locations. Consider refactoring.
Confirmed

jest.spyOn(process.stdout, 'write').mockImplementation((val) =>
result.push(require('strip-ansi')(val.toString('utf8')))
)
Severity: Minor
Found in bin/cli/__tests__/list.spec.js and 1 other location - About 50 mins to fix
bin/cli/__tests__/request.spec.js on lines 14..16

Similar blocks of code found in 2 locations. Consider refactoring.
Open

it(`should look for dynamic values executing and replacing them`, async () => {
let req = await request.exec(cache)
expect(req).toHaveProperty('request.body', 'counted 3 so far.')
})
Severity: Minor
Found in src/__tests__/plugins.spec.js and 1 other location - About 50 mins to fix
src/__tests__/plugins.spec.js on lines 87..90

Similar blocks of code found in 2 locations. Consider refactoring.
Open

it(`should return empty values as empty`, async () => {
let req = await request.exec(cache)
expect(req).toHaveProperty('request.headers.empty', '')
})
Severity: Minor
Found in src/__tests__/plugins.spec.js and 1 other location - About 50 mins to fix
src/__tests__/plugins.spec.js on lines 77..80

Similar blocks of code found in 2 locations. Consider refactoring.
Open

new Line()
.padding(2)
.column('HTTP Verb', 20, [clc.cyan])
.column('Alias', 30, [clc.cyan])
.column('Endpoint', 20, [clc.cyan])
Severity: Minor
Found in bin/cli/commands/list.js and 1 other location - About 40 mins to fix
bin/cli/commands/request.js on lines 19..23

Similar blocks of code found in 2 locations. Consider refactoring.
Open

new Line()
.padding(2)
.column('Status', 20, [clc.cyan])
.column('Endpoint', 20, [clc.cyan])
.output()
Severity: Minor
Found in bin/cli/commands/request.js and 1 other location - About 40 mins to fix
bin/cli/commands/list.js on lines 23..27
Severity
Category
Status
Source
Language