aurelia/aurelia

View on GitHub
packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts

Summary

Maintainability
F
3 wks
Test Coverage

File controller.deactivation.partially-activated.spec.ts has 2271 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import {
  DI,
  onResolve,
  resolve,
} from '@aurelia/kernel';

    Function getPendingActivationLog has 73 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

            function getPendingActivationLog(prefix: string, isDeactivated: boolean) {
              const logs = [];
              /* eslint-disable no-fallthrough */
              switch (hook) {
                case 'attached': logs.push(

      Function getPendingActivationLog has 71 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

              function getPendingActivationLog(prefix: string, isDeactivated: boolean) {
                const logs = [];
                /* eslint-disable no-fallthrough */
                switch (hook) {
                  case 'attached': logs.push(

        Function getPendingActivationLog has 57 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                function getPendingActivationLog(prefix: string, isDeactivated: boolean) {
                  const logs = [];
                  /* eslint-disable no-fallthrough */
                  switch (hook) {
                    case 'attached': logs.push(

          Function getErredActivationLog has 47 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                  function getErredActivationLog() {
                    const logs = [];
                    /* eslint-disable no-fallthrough */
                    switch (hook) {
                      case 'attached': logs.push(

            Function getErredDeactivationLog has 45 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                    function getErredDeactivationLog() {
                      return [
                        ...(
                          hook === 'attached' || hook === 'attaching'
                            ? [

              Function getPendingActivationLog has 41 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                      function getPendingActivationLog(isSettled: boolean) {
                        const logs = [];
                        /* eslint-disable no-fallthrough */
                        switch (hook) {
                          case 'attached': logs.push('phase#1.c2-c.attached.enter', 'phase#1.c2-c.attaching.leave');

                Function getPendingActivationLog has 40 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                        function getPendingActivationLog(prefix: string, isDeactivated: boolean) {
                          const logs = [];
                          /* eslint-disable no-fallthrough */
                          switch (hook) {
                            case 'attached': logs.push(

                  Function getErredDeactivationLog has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                          function getErredDeactivationLog() {
                            return [
                              ...(
                                hook === 'attached' || hook === 'attaching'
                                  ? [

                    Function getPendingActivationLog has 31 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                            function getPendingActivationLog(isSettled: boolean) {
                              const logs = [];
                              /* eslint-disable no-fallthrough */
                              switch (hook) {
                                case 'attached': logs.push('phase#1.c-2.attached.enter', 'phase#1.c-2.attaching.leave');

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

                                switch (hook) {
                                  case 'attached': logs.push(
                                    // because the hooks are invoked in parallel
                                    `${prefix}.c-2.attached.leave`,
                                    `${prefix}.c-2.attached.enter`,
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1556..1595

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 345.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                switch (hook) {
                                  case 'attached': logs.push(
                                    // because the hooks are invoked in parallel
                                    `${prefix}.c-2.attached.leave`,
                                    `${prefix}.c-2.attached.enter`,
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 906..945

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 345.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              mgr.assertLog([
                                'phase#5.Global.c-1.detaching.enter',
                                'phase#5.Global.c-1.detaching.leave',
                                'phase#5.c-1.detaching.enter',
                                'phase#5.c-1.detaching.leave',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1141..1178

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 171.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              mgr.assertLog([
                                'phase#3.Global.c-1.detaching.enter',
                                'phase#3.Global.c-1.detaching.leave',
                                'phase#3.c-1.detaching.enter',
                                'phase#3.c-1.detaching.leave',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1225..1262

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 171.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                switch (hook) {
                                  case 'attached': logs.push(
                                    `${prefix}.c2-c.attached.enter`,
                                    `${prefix}.c2-c.attaching.leave`,
                                  );
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1324..1340

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 127.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                switch (hook) {
                                  case 'attached': logs.push(
                                    `${prefix}.c-2.attached.enter`,
                                    `${prefix}.c-2.attaching.leave`,
                                  );
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2406..2422

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 127.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              @lifecycleHooks()
                              class Local extends TestHook {
                                public get hookName(): string {
                                  return 'Local';
                                }
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 993..1003

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 110.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              @lifecycleHooks()
                              class Local extends TestHook {
                                public get hookName(): string {
                                  return 'Local';
                                }
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1641..1651

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 110.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              @customElement({ name: 'c-2', template: 'c2' })
                              class C2 extends TestVM {
                                private readonly promiseManager: IPromiseManager = resolve(IPromiseManager);
                      
                                public [`$${hook}`](_initiator: IHydratedController, _parent: IHydratedController): void | Promise<void> {
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 725..731
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2159..2166
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2469..2476

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 100.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              @customElement({ name: 'c-2', template: 'c2' })
                              class C2 extends TestVM {
                                private readonly promiseManager: IPromiseManager = resolve(IPromiseManager);
                                public [`$${hook}`](_initiator: IHydratedController, _parent: IHydratedController): void | Promise<void> {
                                  return this.promiseManager.createPromise();
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1373..1380
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2159..2166
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2469..2476

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 100.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              @customElement({ name: 'c2-c', template: 'c2c' })
                              class C2Child extends TestVM {
                                private readonly promiseManager: IPromiseManager = resolve(IPromiseManager);
                      
                                public [`$${hook}`](_initiator: IHydratedController, _parent: IHydratedController): void | Promise<void> {
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 725..731
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1373..1380
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2469..2476

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 100.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              @customElement({ name: 'c2-c', template: 'c2c' })
                              class C2Child extends TestVM {
                                private readonly promiseManager: IPromiseManager = resolve(IPromiseManager);
                      
                                public [`$${hook}`](_initiator: IHydratedController, _parent: IHydratedController): void | Promise<void> {
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 725..731
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1373..1380
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2159..2166

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 100.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                logs.unshift(
                                  `${prefix}.Global.c-1.detaching.enter`,
                                  `${prefix}.Global.c-1.detaching.leave`,
                                  `${prefix}.c-1.detaching.enter`,
                                  `${prefix}.c-1.detaching.leave`,
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 947..956

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 90.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                logs.unshift(
                                  `${prefix}.Global.c-1.detaching.enter`,
                                  `${prefix}.Global.c-1.detaching.leave`,
                                  `${prefix}.c-1.detaching.enter`,
                                  `${prefix}.c-1.detaching.leave`,
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1597..1606

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 90.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                return [
                                  ...(
                                    hook === 'attached' || hook === 'attaching'
                                      ? [
                                        'phase#2.c2-c.detaching.enter',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2594..2631

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 80.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              mgr.assertLog([
                                ...(
                                  hook === 'attaching' || hook === 'attached'
                                    ? [
                                      'phase#4.c2-c.detaching.enter',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1961..1998

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 80.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                            for (let i = 0; i < len; i++) {
                              assert.strictEqual(log[i], expected[i], `${message} - unexpected log at index${i}: ${log[i]}; actual log: ${JSON.stringify(log, undefined, 2)}`);
                            }
                      packages/__tests__/src/router-lite/lifecycle-hooks.spec.ts on lines 47..49

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 79.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              @customElement({ name: 'c2-c', template: 'c2c' })
                              class C2Child extends TestVM {
                                public [`$${hook}`](_initiator: IHydratedController, _parent: IHydratedController): void | Promise<void> {
                                  throw new Error('Synthetic test error');
                                }
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 230..235
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 336..341

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 78.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              @customElement({ name: 'c-1', template: '' })
                              class C1 extends TestVM {
                                public [`$${hook}`](_initiator: IHydratedController, _parent: IHydratedController): void | Promise<void> {
                                  throw new Error('Synthetic test error');
                                }
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 336..341
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2004..2009

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 78.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              @customElement({ name: 'c-2', template: 'c2' })
                              class C2 extends TestVM {
                                public [`$${hook}`](_initiator: IHydratedController, _parent: IHydratedController): void | Promise<void> {
                                  throw new Error('Synthetic test error');
                                }
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 230..235
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2004..2009

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 78.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                  case 'bound':
                                    logs.push(
                                      `${prefix}.Global.c-2.unbinding.enter`,
                                      `${prefix}.Global.c-2.unbinding.leave`,
                                      `${prefix}.Local.c-2.unbinding.enter`,
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 963..971
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 972..980
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1611..1619

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 74.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                  case 'binding':
                                    logs.push(
                                      `${prefix}.Global.c-2.unbinding.enter`,
                                      `${prefix}.Global.c-2.unbinding.leave`,
                                      `${prefix}.Local.c-2.unbinding.enter`,
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 963..971
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1611..1619
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1620..1628

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 74.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                  case 'attached':
                                    logs.push(
                                      `${prefix}.Global.c-2.detaching.enter`,
                                      `${prefix}.Global.c-2.detaching.leave`,
                                      `${prefix}.Local.c-2.detaching.enter`,
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 963..971
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 972..980
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1620..1628

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 74.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                  case 'attached':
                                    logs.push(
                                      `${prefix}.Global.c-2.detaching.enter`,
                                      `${prefix}.Global.c-2.detaching.leave`,
                                      `${prefix}.Local.c-2.detaching.enter`,
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 972..980
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1611..1619
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1620..1628

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 74.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                switch (hook) {
                                  case 'attached': logs.push('phase#1.c2-c.attached.enter', 'phase#1.c2-c.attaching.leave');
                                  case 'attaching': logs.push('phase#1.c2-c.attaching.enter', 'phase#1.c2-c.bound.leave');
                                  case 'bound': logs.push('phase#1.c2-c.bound.enter', 'phase#1.c2-c.binding.leave');
                                  case 'binding': logs.push('phase#1.c2-c.binding.enter');
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 205..210
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 251..256
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 288..293
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2112..2117

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 71.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              switch (hook) {
                                case 'attached': logs.push('start.c-1.attached.enter', 'start.c-1.attaching.leave');
                                case 'attaching': logs.push('start.c-1.attaching.enter', 'start.c-1.bound.leave');
                                case 'bound': logs.push('start.c-1.bound.enter', 'start.c-1.binding.leave');
                                case 'binding': logs.push('start.c-1.binding.enter');
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 205..210
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 288..293
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1933..1938
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2112..2117

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 71.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              switch (hook) {
                                case 'attached': logs.push('start.app.attached.enter', 'start.app.attaching.leave');
                                case 'attaching': logs.push('start.app.attaching.enter', 'start.app.bound.leave');
                                case 'bound': logs.push('start.app.bound.enter', 'start.app.binding.leave');
                                case 'binding': logs.push('start.app.binding.enter');
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 251..256
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 288..293
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1933..1938
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2112..2117

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 71.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                switch (hook) {
                                  case 'attached': logs.push('phase#1.c2-c.attached.enter', 'phase#1.c2-c.attaching.leave');
                                  case 'attaching': logs.push('phase#1.c2-c.attaching.enter', 'phase#1.c2-c.bound.leave');
                                  case 'bound': logs.push('phase#1.c2-c.bound.enter', 'phase#1.c2-c.binding.leave');
                                  case 'binding': logs.push('phase#1.c2-c.binding.enter');
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 205..210
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 251..256
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 288..293
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1933..1938

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 71.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                switch (hook) {
                                  case 'attached': logs.push('phase#1.c-2.attached.enter', 'phase#1.c-2.attaching.leave');
                                  case 'attaching': logs.push('phase#1.c-2.attaching.enter', 'phase#1.c-2.bound.leave');
                                  case 'bound': logs.push('phase#1.c-2.bound.enter', 'phase#1.c-2.binding.leave');
                                  case 'binding': logs.push('phase#1.c-2.binding.enter');
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 205..210
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 251..256
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1933..1938
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2112..2117

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 71.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                return [
                                  ...(
                                    hook === 'attached' || hook === 'attaching'
                                      ? [
                                        'phase#2.Global.c-2.detaching.enter',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1802..1846

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 70.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              mgr.assertLog([
                                ...(
                                  hook === 'attaching' || hook === 'attached'
                                    ? [
                                      'phase#4.Global.c-2.detaching.enter',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 472..516

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 70.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              mgr.assertLog([
                                'start.Global.app.binding.enter',
                                'start.Global.app.binding.leave',
                                'start.app.binding.enter',
                                'start.app.binding.leave',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 551..610
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1023..1082

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 61.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              mgr.assertLog([
                                'start.Global.app.binding.enter',
                                'start.Global.app.binding.leave',
                                'start.app.binding.enter',
                                'start.app.binding.leave',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1023..1082
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1671..1730

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 61.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              mgr.assertLog([
                                'start.Global.app.binding.enter',
                                'start.Global.app.binding.leave',
                                'start.app.binding.enter',
                                'start.app.binding.leave',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 551..610
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1671..1730

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 61.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              mgr.assertLog([
                                ...(hook === 'attaching' || hook === 'attached'
                                  ? [
                                    'phase#4.c-2.detaching.enter',
                                    'phase#4.c-2.detaching.leave',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 306..330

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 50.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                                return [
                                  ...(
                                    hook === 'attached' || hook === 'attaching'
                                      ? [
                                        'phase#2.c-2.detaching.enter',
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 1477..1500

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 50.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              try {
                                rootVm.showC1 = false;
                                assert.fail('expected error');
                              } catch (e) {
                                assert.instanceOf(e, Error, 'swap');
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 2054..2059

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 48.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

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

                              try {
                                rootVm.showC1 = false;
                                assert.fail('expected error');
                              } catch (e) {
                                assert.instanceOf(e, Error, 'swap');
                      packages/__tests__/src/3-runtime-html/controller.deactivation.partially-activated.spec.ts on lines 373..378

                      Duplicated Code

                      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                      Tuning

                      This issue has a mass of 48.

                      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                      Refactorings

                      Further Reading

                      There are no issues that match your filters.

                      Category
                      Status