Zizzamia/perfume.js

View on GitHub
__tests__/_mock.ts

Summary

Maintainability
B
5 hrs
Test Coverage

Function performance has 60 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  performance: () => {
    delete (window as any).performance;
    const performance = {
      clearMarks: jest.fn(),
      // https://developer.mozilla.org/en-US/docs/Web/API/Performance/getEntriesByName
Severity: Major
Found in __tests__/_mock.ts - About 2 hrs to fix

    Function getEntriesByType has 39 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

          getEntriesByType: (entryType: string) => {
            if (entryType === 'navigation') {
              return [
                {
                  connectEnd: 1.7850000876933336,
    Severity: Minor
    Found in __tests__/_mock.ts - About 1 hr to fix

      Function navigator has 30 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

        navigator: () => {
          delete (window as any).navigator;
          const navigator = {
            connection: {
              effectiveType: '4g',
      Severity: Minor
      Found in __tests__/_mock.ts - About 1 hr to fix

        There are no issues that match your filters.

        Category
        Status