Skip to content

Commit

Permalink
standardize the tslint:disable comments
Browse files Browse the repository at this point in the history
  • Loading branch information
jennifer-shehane committed Dec 18, 2024
1 parent 9db9e96 commit dd574ba
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion packages/app/src/composables/useSpecFilter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export function useSpecFilter (savedFilter?: string) {
})

// initialize spec filter in store
// tslint:disable:no-floating-promises TODO: look at this
// tslint:disable:no-floating-promises
setSpecFilter(specFilterModel.value)

return {
Expand Down
2 changes: 1 addition & 1 deletion packages/app/src/runs/useProjectRuns.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ export const useProjectRuns = (online: Ref<boolean>): RunsComposable => {
function startPolling () {
timeout = window.setTimeout(function fetchNewerRuns () {
if (variables.value && online.value) {
/* tslint:disable:no-floating-promises TODO: promise should be handled */
// tslint:disable:no-floating-promises
refetcher.executeMutation(variables.value)
.then(() => {
startPolling()
Expand Down
8 changes: 4 additions & 4 deletions packages/driver/src/cy/net-stubbing/events/before-request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export const onBeforeRequest: HandlerFn<CyHttpMessages.IncomingRequest> = (Cypre

debug('created request subscription %o', { eventName, request, subscription, handler })

// tslint:disable-next-line:no-floating-promises
// tslint:disable:no-floating-promises
emitNetEvent('subscribe', { requestId, subscription } as NetEvent.ToServer.Subscribe)
}

Expand Down Expand Up @@ -166,7 +166,7 @@ export const onBeforeRequest: HandlerFn<CyHttpMessages.IncomingRequest> = (Cypre
queryObj = createQueryObject()
queryProxy = createQueryProxy(queryObj)
},
// tslint:disable-next-line:no-floating-promises
// tslint:disable:no-floating-promises
on (eventName, handler) {
if (!validEvents.includes(eventName)) {
$errUtils.throwErrByPath('net_stubbing.request_handling.unknown_event', {
Expand All @@ -181,7 +181,7 @@ export const onBeforeRequest: HandlerFn<CyHttpMessages.IncomingRequest> = (Cypre
$errUtils.throwErrByPath('net_stubbing.request_handling.event_needs_handler')
}

// tslint:disable-next-line:no-floating-promises
// tslint:disable:no-floating-promises
subscribe(eventName, handler)

return userReq
Expand All @@ -206,7 +206,7 @@ export const onBeforeRequest: HandlerFn<CyHttpMessages.IncomingRequest> = (Cypre
}

// allow `req` to be sent outgoing, then pass the response body to `responseHandler`
// tslint:disable-next-line:no-floating-promises
// tslint:disable:no-floating-promises
subscribe('response:callback', responseHandler)

return finish(true)
Expand Down
4 changes: 2 additions & 2 deletions packages/driver/src/cy/net-stubbing/events/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export function registerEvents (Cypress: Cypress.Cypress, cy: Cypress.cy) {
}

function sendStaticResponse (requestId: string, staticResponse: StaticResponse) {
// tslint:disable-next-line:no-floating-promises
// tslint:disable:no-floating-promises
emitNetEvent('send:static:response', {
requestId,
staticResponse: getBackendStaticResponse(staticResponse),
Expand Down Expand Up @@ -94,7 +94,7 @@ export function registerEvents (Cypress: Cypress.Cypress, cy: Cypress.cy) {
if (!route) {
if (frame.subscription.await) {
// route not found, just resolve so the request can continue
// tslint:disable-next-line:no-floating-promises
// tslint:disable:no-floating-promises
emitResolved(frame.data)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ export const useCohorts = () => {
cohortOptionSelected.value = options.find((option) => option.cohort === cohortSelected.data?.determineCohort?.cohort)
}

// tslint:disable-next-line:no-floating-promises TODO: This should be awaiting the fetchCohort call
// // tslint:disable:no-floating-promises
fetchCohort()
}

Expand Down
2 changes: 1 addition & 1 deletion packages/icons/scripts/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,5 @@ async function build () {
await fs.remove(iconsetPath)
}

/* tslint:disable:no-floating-promises TODO: look at this */
// tslint:disable:no-floating-promises
build()
2 changes: 1 addition & 1 deletion packages/icons/scripts/ico.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const files = [
fs.readFileSync('./assets/icons/icon_256x256.png'),
]

/* tslint:disable:no-floating-promises TODO: look at this */
// tslint:disable:no-floating-promises
toIco(files).then((buf) => {
fs.writeFileSync('./dist/icons/cypress.ico', buf)
})

0 comments on commit dd574ba

Please sign in to comment.