diff --git a/modules/10-basics/10-hello-world/test.js b/modules/10-basics/10-hello-world/test.js index 508ef4cf..41612173 100644 --- a/modules/10-basics/10-hello-world/test.js +++ b/modules/10-basics/10-hello-world/test.js @@ -3,7 +3,7 @@ import { expect, test, vi } from 'vitest'; test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/10-basics/40-instructions/test.js b/modules/10-basics/40-instructions/test.js index 5d4beef8..58c122cf 100644 --- a/modules/10-basics/40-instructions/test.js +++ b/modules/10-basics/40-instructions/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('instructions', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/10-basics/45-testing/test.js b/modules/10-basics/45-testing/test.js index 7fce79c4..643d5e0c 100644 --- a/modules/10-basics/45-testing/test.js +++ b/modules/10-basics/45-testing/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('testing', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/10-basics/50-syntax-errors/test.js b/modules/10-basics/50-syntax-errors/test.js index e2c9e32d..df57c200 100644 --- a/modules/10-basics/50-syntax-errors/test.js +++ b/modules/10-basics/50-syntax-errors/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('syntax errors', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/20-arithmetics/20-basic/test.js b/modules/20-arithmetics/20-basic/test.js index 61415271..b82ba185 100644 --- a/modules/20-arithmetics/20-basic/test.js +++ b/modules/20-arithmetics/20-basic/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('basic', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/20-arithmetics/25-operator/test.js b/modules/20-arithmetics/25-operator/test.js index 7062e1d8..5b95d30e 100644 --- a/modules/20-arithmetics/25-operator/test.js +++ b/modules/20-arithmetics/25-operator/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('operator', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/20-arithmetics/27-commutativity/test.js b/modules/20-arithmetics/27-commutativity/test.js index 87594ee2..9fadc132 100644 --- a/modules/20-arithmetics/27-commutativity/test.js +++ b/modules/20-arithmetics/27-commutativity/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('commutativity', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/20-arithmetics/30-composition/test.js b/modules/20-arithmetics/30-composition/test.js index 649e45e0..c483eb6a 100644 --- a/modules/20-arithmetics/30-composition/test.js +++ b/modules/20-arithmetics/30-composition/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('composition', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/20-arithmetics/40-priority/test.js b/modules/20-arithmetics/40-priority/test.js index 75928021..7605942c 100644 --- a/modules/20-arithmetics/40-priority/test.js +++ b/modules/20-arithmetics/40-priority/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('priority', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/20-arithmetics/50-float/test.js b/modules/20-arithmetics/50-float/test.js index faa2a296..b12bc4f6 100644 --- a/modules/20-arithmetics/50-float/test.js +++ b/modules/20-arithmetics/50-float/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('float', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/20-arithmetics/60-infinity/test.js b/modules/20-arithmetics/60-infinity/test.js index 37a00da7..f28f6266 100644 --- a/modules/20-arithmetics/60-infinity/test.js +++ b/modules/20-arithmetics/60-infinity/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('infinity', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/20-arithmetics/70-nan/test.js b/modules/20-arithmetics/70-nan/test.js index c5858540..b3d9ef22 100644 --- a/modules/20-arithmetics/70-nan/test.js +++ b/modules/20-arithmetics/70-nan/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('nan', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/20-arithmetics/80-linting/test.js b/modules/20-arithmetics/80-linting/test.js index 60e9ceba..f98a8d51 100644 --- a/modules/20-arithmetics/80-linting/test.js +++ b/modules/20-arithmetics/80-linting/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('linting', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/25-strings/10-quotes/test.js b/modules/25-strings/10-quotes/test.js index ac4a9568..b9d5bc11 100644 --- a/modules/25-strings/10-quotes/test.js +++ b/modules/25-strings/10-quotes/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('quotes', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/25-strings/15-escape-characters/test.js b/modules/25-strings/15-escape-characters/test.js index 8503b970..7956efbd 100644 --- a/modules/25-strings/15-escape-characters/test.js +++ b/modules/25-strings/15-escape-characters/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('escape characters', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/25-strings/20-string-concatenation/test.js b/modules/25-strings/20-string-concatenation/test.js index 2dcdd835..92233796 100644 --- a/modules/25-strings/20-string-concatenation/test.js +++ b/modules/25-strings/20-string-concatenation/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('string concatenation', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/25-strings/30-encoding/test.js b/modules/25-strings/30-encoding/test.js index 67454de5..90aaa457 100644 --- a/modules/25-strings/30-encoding/test.js +++ b/modules/25-strings/30-encoding/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('encoding', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/30-variables/10-definition/test.js b/modules/30-variables/10-definition/test.js index 3ebe0104..41837426 100644 --- a/modules/30-variables/10-definition/test.js +++ b/modules/30-variables/10-definition/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('definition', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/30-variables/11-change/test.js b/modules/30-variables/11-change/test.js index 7d69186d..5a1ee3e6 100644 --- a/modules/30-variables/11-change/test.js +++ b/modules/30-variables/11-change/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('change', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/30-variables/13-variables-naming/test.js b/modules/30-variables/13-variables-naming/test.js index d8ee3367..977ea482 100644 --- a/modules/30-variables/13-variables-naming/test.js +++ b/modules/30-variables/13-variables-naming/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('variables naming', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/30-variables/15-variables-expressions/test.js b/modules/30-variables/15-variables-expressions/test.js index 8b57a1f8..4007f3ce 100644 --- a/modules/30-variables/15-variables-expressions/test.js +++ b/modules/30-variables/15-variables-expressions/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('variables expressions', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/30-variables/18-variable-concatenation/test.js b/modules/30-variables/18-variable-concatenation/test.js index 60501131..4847336a 100644 --- a/modules/30-variables/18-variable-concatenation/test.js +++ b/modules/30-variables/18-variable-concatenation/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('variable concatenation', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/30-variables/19-naming-style/test.js b/modules/30-variables/19-naming-style/test.js index 531f816c..1c9c4602 100644 --- a/modules/30-variables/19-naming-style/test.js +++ b/modules/30-variables/19-naming-style/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('naming style', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/30-variables/20-magic-numbers/test.js b/modules/30-variables/20-magic-numbers/test.js index d6107692..cf2a19b3 100644 --- a/modules/30-variables/20-magic-numbers/test.js +++ b/modules/30-variables/20-magic-numbers/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('magic numbers', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/30-variables/23-constants/test.js b/modules/30-variables/23-constants/test.js index eed7e65b..7f223872 100644 --- a/modules/30-variables/23-constants/test.js +++ b/modules/30-variables/23-constants/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('constants', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/31-advanced-strings/25-interpolation/test.js b/modules/31-advanced-strings/25-interpolation/test.js index 15c7e9dc..edb3001d 100644 --- a/modules/31-advanced-strings/25-interpolation/test.js +++ b/modules/31-advanced-strings/25-interpolation/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('interpolation', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/31-advanced-strings/30-symbols/test.js b/modules/31-advanced-strings/30-symbols/test.js index 98ebac04..3db33fa0 100644 --- a/modules/31-advanced-strings/30-symbols/test.js +++ b/modules/31-advanced-strings/30-symbols/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('symbols', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/31-advanced-strings/70-slices/test.js b/modules/31-advanced-strings/70-slices/test.js index c4feaafa..0c3ee853 100644 --- a/modules/31-advanced-strings/70-slices/test.js +++ b/modules/31-advanced-strings/70-slices/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('slices', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/31-advanced-strings/90-multiline-strings/test.js b/modules/31-advanced-strings/90-multiline-strings/test.js index 629dab97..7d2e10da 100644 --- a/modules/31-advanced-strings/90-multiline-strings/test.js +++ b/modules/31-advanced-strings/90-multiline-strings/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('multiline strings', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/33-data-types/10-primitive-data-types/test.js b/modules/33-data-types/10-primitive-data-types/test.js index dd577ec9..32bf9d5d 100644 --- a/modules/33-data-types/10-primitive-data-types/test.js +++ b/modules/33-data-types/10-primitive-data-types/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('primitive data types', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/33-data-types/45-undefined/test.js b/modules/33-data-types/45-undefined/test.js index 3c0389a9..ce185511 100644 --- a/modules/33-data-types/45-undefined/test.js +++ b/modules/33-data-types/45-undefined/test.js @@ -3,7 +3,7 @@ import { expect, test, vi } from 'vitest'; test('undefined', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); // console.log must be called and must be passed an undefined argument diff --git a/modules/33-data-types/50-data-types-weak-typing/test.js b/modules/33-data-types/50-data-types-weak-typing/test.js index fabeee92..14521494 100644 --- a/modules/33-data-types/50-data-types-weak-typing/test.js +++ b/modules/33-data-types/50-data-types-weak-typing/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('data types weak typing', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/33-data-types/52-data-types-immutability/test.js b/modules/33-data-types/52-data-types-immutability/test.js index 059b7b92..cd6b0fee 100644 --- a/modules/33-data-types/52-data-types-immutability/test.js +++ b/modules/33-data-types/52-data-types-immutability/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('data types immutability', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/33-data-types/55-data-types-casting/test.js b/modules/33-data-types/55-data-types-casting/test.js index 3129b068..ffc49a99 100644 --- a/modules/33-data-types/55-data-types-casting/test.js +++ b/modules/33-data-types/55-data-types-casting/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('data types casting', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/35-calling-functions/100-call/test.js b/modules/35-calling-functions/100-call/test.js index 4d58fb6d..c4b81a34 100644 --- a/modules/35-calling-functions/100-call/test.js +++ b/modules/35-calling-functions/100-call/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('call', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/35-calling-functions/135-calling-functions-default-params/test.js b/modules/35-calling-functions/135-calling-functions-default-params/test.js index a0e60b1d..e54f6abd 100644 --- a/modules/35-calling-functions/135-calling-functions-default-params/test.js +++ b/modules/35-calling-functions/135-calling-functions-default-params/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('calling functions default params', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/35-calling-functions/150-calling-functions-expression/test.js b/modules/35-calling-functions/150-calling-functions-expression/test.js index ac06f6b5..573f1a69 100644 --- a/modules/35-calling-functions/150-calling-functions-expression/test.js +++ b/modules/35-calling-functions/150-calling-functions-expression/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('calling functions expression', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/35-calling-functions/180-variadic-parameters/test.js b/modules/35-calling-functions/180-variadic-parameters/test.js index 4d1b0622..02f5b00a 100644 --- a/modules/35-calling-functions/180-variadic-parameters/test.js +++ b/modules/35-calling-functions/180-variadic-parameters/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('variadic parameters', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/35-calling-functions/270-deterministic/test.js b/modules/35-calling-functions/270-deterministic/test.js index 97cd19dd..6e4d1e1c 100644 --- a/modules/35-calling-functions/270-deterministic/test.js +++ b/modules/35-calling-functions/270-deterministic/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('deterministic', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/38-objects/100-objects/test.js b/modules/38-objects/100-objects/test.js index 17d0dd7f..3ac7a130 100644 --- a/modules/38-objects/100-objects/test.js +++ b/modules/38-objects/100-objects/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('objects', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/38-objects/200-methods-immutability/test.js b/modules/38-objects/200-methods-immutability/test.js index 771266b8..f6681c12 100644 --- a/modules/38-objects/200-methods-immutability/test.js +++ b/modules/38-objects/200-methods-immutability/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('methods immutability', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/38-objects/500-method-chain/test.js b/modules/38-objects/500-method-chain/test.js index 8bbdd4d6..8e242a56 100644 --- a/modules/38-objects/500-method-chain/test.js +++ b/modules/38-objects/500-method-chain/test.js @@ -2,8 +2,8 @@ import { expect, test, vi } from 'vitest'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('method chain', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); await import('./index.js'); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/40-define-functions/100-define-function/test.js b/modules/40-define-functions/100-define-function/test.js index 6d7d81fe..658328b4 100644 --- a/modules/40-define-functions/100-define-function/test.js +++ b/modules/40-define-functions/100-define-function/test.js @@ -3,8 +3,8 @@ import { expect, test, vi } from 'vitest'; import f from './index.js'; -test('hello world', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('define function', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); f(); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/40-define-functions/150-return/test.js b/modules/40-define-functions/150-return/test.js index b0d1c54b..d218de22 100644 --- a/modules/40-define-functions/150-return/test.js +++ b/modules/40-define-functions/150-return/test.js @@ -3,7 +3,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('return', () => { expect(f('text', 3)).toBe('tex...'); expect(f('hexlet learning', 6)).toBe('hexlet...'); }); diff --git a/modules/40-define-functions/340-default-parameters/test.js b/modules/40-define-functions/340-default-parameters/test.js index 2bd1df4c..d8d193de 100644 --- a/modules/40-define-functions/340-default-parameters/test.js +++ b/modules/40-define-functions/340-default-parameters/test.js @@ -3,7 +3,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('default parameters', () => { expect(f('1234123412341234')).toEqual('****1234'); expect(f('1234123412344321')).toEqual('****4321'); expect(f('1234123412344321', 2)).toEqual('**4321'); diff --git a/modules/40-define-functions/350-type-annotations/test.js b/modules/40-define-functions/350-type-annotations/test.js index 40a2e69d..868f7682 100644 --- a/modules/40-define-functions/350-type-annotations/test.js +++ b/modules/40-define-functions/350-type-annotations/test.js @@ -4,7 +4,7 @@ import { readFileSync } from 'node:fs'; import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('type annotations', () => { const source = readFileSync(new URL('./index.js', import.meta.url), 'utf8'); const paramAnnotations = source.match(/@param\s*\{/g) ?? []; expect( diff --git a/modules/40-define-functions/450-define-functions-short-syntax/test.js b/modules/40-define-functions/450-define-functions-short-syntax/test.js index cd93f80e..83d73fe6 100644 --- a/modules/40-define-functions/450-define-functions-short-syntax/test.js +++ b/modules/40-define-functions/450-define-functions-short-syntax/test.js @@ -3,7 +3,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('define functions short syntax', () => { const expected1 = 'Daenerys'; const actual1 = f('daenerys'); expect(f(actual1)).toEqual(expected1); diff --git a/modules/40-define-functions/460-modules/test.js b/modules/40-define-functions/460-modules/test.js index 7d7b87dd..68726c60 100644 --- a/modules/40-define-functions/460-modules/test.js +++ b/modules/40-define-functions/460-modules/test.js @@ -3,7 +3,7 @@ import { expect, test } from 'vitest'; import mirror from './index.js'; -test('mirror', () => { +test('modules', () => { expect(mirror('hello')).toBe('OLLEH'); expect(mirror('Hexlet')).toBe('TELXEH'); }); diff --git a/modules/40-define-functions/470-packages/test.js b/modules/40-define-functions/470-packages/test.js index 417627c5..7c3c7201 100644 --- a/modules/40-define-functions/470-packages/test.js +++ b/modules/40-define-functions/470-packages/test.js @@ -3,7 +3,7 @@ import { expect, test } from 'vitest'; import formatPrice from './index.js'; -test('formatPrice', () => { +test('packages', () => { expect(formatPrice(12.3456)).toBe('12.35'); expect(formatPrice(2.5)).toBe('2.50'); expect(formatPrice(10)).toBe('10.00'); diff --git a/modules/45-logic/10-bool-type/test.js b/modules/45-logic/10-bool-type/test.js index 59b7f622..4a249517 100644 --- a/modules/45-logic/10-bool-type/test.js +++ b/modules/45-logic/10-bool-type/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('bool type', () => { expect(f(23)).toBe(false); expect(f(70)).toBe(true); expect(f(60)).toBe(true); diff --git a/modules/45-logic/17-bool-strings/test.js b/modules/45-logic/17-bool-strings/test.js index 648a30a0..4eed06ca 100644 --- a/modules/45-logic/17-bool-strings/test.js +++ b/modules/45-logic/17-bool-strings/test.js @@ -3,7 +3,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('bool strings', () => { expect(f('apple')).toBe(false); expect(f('banana')).toBe(true); expect(f('pineapple')).toBe(true); diff --git a/modules/45-logic/20-logic-combine-expressions/test.js b/modules/45-logic/20-logic-combine-expressions/test.js index 95c637e1..30f883ea 100644 --- a/modules/45-logic/20-logic-combine-expressions/test.js +++ b/modules/45-logic/20-logic-combine-expressions/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('logic combine expressions', () => { expect(f('89602223423')).toBe(false); expect(f('+79602223423')).toBe(true); }); diff --git a/modules/45-logic/25-logical-operators/test.js b/modules/45-logic/25-logical-operators/test.js index 28dfffba..86363d8b 100644 --- a/modules/45-logic/25-logical-operators/test.js +++ b/modules/45-logic/25-logical-operators/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('logical operators', () => { expect(f(2016)).toBe(true); expect(f(2000)).toBe(true); expect(f(2017)).toBe(false); diff --git a/modules/45-logic/28-logical-negation/test.js b/modules/45-logic/28-logical-negation/test.js index 1e8047ba..a4aadf03 100644 --- a/modules/45-logic/28-logical-negation/test.js +++ b/modules/45-logic/28-logical-negation/test.js @@ -3,7 +3,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('logical negation', () => { expect(f('wow')).toBe(false); expect(f('hexlet')).toBe(true); expect(f('asdffdsa')).toBe(false); diff --git a/modules/45-logic/70-logical-expressions/test.js b/modules/45-logic/70-logical-expressions/test.js index ee6e81e3..00be5ec0 100644 --- a/modules/45-logic/70-logical-expressions/test.js +++ b/modules/45-logic/70-logical-expressions/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('logical expressions', () => { const name = 'Hexlet'; expect(f(name, 0)).toBe(''); expect(f(name, 1)).toBe('H'); diff --git a/modules/48-conditionals/30-if/test.js b/modules/48-conditionals/30-if/test.js index 64971bef..59a3452b 100644 --- a/modules/48-conditionals/30-if/test.js +++ b/modules/48-conditionals/30-if/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('if', () => { expect(f(100500)).toBe('Try again!'); expect(f(42)).toBe('You win!'); }); diff --git a/modules/48-conditionals/40-if-else/test.js b/modules/48-conditionals/40-if-else/test.js index b201ac70..0b3b1c6a 100644 --- a/modules/48-conditionals/40-if-else/test.js +++ b/modules/48-conditionals/40-if-else/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('if else', () => { expect(f('yandex.ru')).toBe('https://yandex.ru'); expect(f('https://yandex.ru')).toBe('https://yandex.ru'); }); diff --git a/modules/48-conditionals/50-else-if/test.js b/modules/48-conditionals/50-else-if/test.js index 3f684be6..b02085d1 100644 --- a/modules/48-conditionals/50-else-if/test.js +++ b/modules/48-conditionals/50-else-if/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('else if', () => { expect(f('green')).toBe('go'); expect(f('yellow')).toBe('slow down'); expect(f('red')).toBe('stop'); diff --git a/modules/48-conditionals/60-ternary-operator/test.js b/modules/48-conditionals/60-ternary-operator/test.js index 49d83e71..9205e10c 100644 --- a/modules/48-conditionals/60-ternary-operator/test.js +++ b/modules/48-conditionals/60-ternary-operator/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('ternary operator', () => { expect(f('flip')).toBe('flop'); expect(f('flop')).toBe('flip'); expect(f('hello')).toBe('flip'); diff --git a/modules/48-conditionals/65-switch/test.js b/modules/48-conditionals/65-switch/test.js index e9f8b18c..fac8f431 100644 --- a/modules/48-conditionals/65-switch/test.js +++ b/modules/48-conditionals/65-switch/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('switch', () => { expect(f(0)).toBe('just a number'); expect(f(666)).toBe('devil number'); expect(f(42)).toBe('answer for everything'); diff --git a/modules/50-loops/10-while/test.js b/modules/50-loops/10-while/test.js index a03c64f3..dddd81fe 100644 --- a/modules/50-loops/10-while/test.js +++ b/modules/50-loops/10-while/test.js @@ -3,8 +3,8 @@ import { expect, test, vi } from 'vitest'; import f from './index.js'; -test('printNumbers', async () => { - const consoleLogSpy = vi.spyOn(console, 'log').mockImplementation(() => {}); +test('while', async () => { + const consoleLogSpy = vi.spyOn(console, 'log'); f(6); const firstArg = consoleLogSpy.mock.calls.join('\n'); diff --git a/modules/50-loops/15-conditions-inside-loops/test.js b/modules/50-loops/15-conditions-inside-loops/test.js index 2b45c92e..fbea5560 100644 --- a/modules/50-loops/15-conditions-inside-loops/test.js +++ b/modules/50-loops/15-conditions-inside-loops/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('conditions inside loops', () => { expect(f('axe', 'a')).toEqual(1); expect(f('', 'a')).toEqual(0); expect(f('OpPa', 'p')).toEqual(2); diff --git a/modules/50-loops/20-aggregation-numbers/test.js b/modules/50-loops/20-aggregation-numbers/test.js index e7034245..646780b1 100644 --- a/modules/50-loops/20-aggregation-numbers/test.js +++ b/modules/50-loops/20-aggregation-numbers/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('aggregation numbers', () => { expect(f(0)).toBe(0); expect(f(80)).toBe(400); expect(f(100)).toBe(500); diff --git a/modules/50-loops/23-aggregation-strings/test.js b/modules/50-loops/23-aggregation-strings/test.js index 31b58908..74105b2c 100644 --- a/modules/50-loops/23-aggregation-strings/test.js +++ b/modules/50-loops/23-aggregation-strings/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('aggregation strings', () => { expect(f('+7 (999) 123-45-67')).toBe('+79991234567'); expect(f('8 800 555 35 35')).toBe('88005553535'); expect(f('(123) 456-7890')).toBe('1234567890'); diff --git a/modules/50-loops/25-iteration-over-string/test.js b/modules/50-loops/25-iteration-over-string/test.js index c99d61a1..5bf7d74f 100644 --- a/modules/50-loops/25-iteration-over-string/test.js +++ b/modules/50-loops/25-iteration-over-string/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('iteration over string', () => { expect(f('1234567812345678')).toBe('************5678'); expect(f('12345678')).toBe('****5678'); }); diff --git a/modules/50-loops/30-syntactic-sugar/test.js b/modules/50-loops/30-syntactic-sugar/test.js index 34f3704e..a6b05b20 100644 --- a/modules/50-loops/30-syntactic-sugar/test.js +++ b/modules/50-loops/30-syntactic-sugar/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('syntactic sugar', () => { const text = 'If I look back I am lost'; expect(f(text, 'I')).toEqual('f look back am lost'); expect(f('zz Zorro', 'z')).toEqual(' Zorro'); diff --git a/modules/50-loops/50-mutators/test.js b/modules/50-loops/50-mutators/test.js index 7843897f..0569484b 100644 --- a/modules/50-loops/50-mutators/test.js +++ b/modules/50-loops/50-mutators/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('mutators', () => { const text = 'I never look back'; expect(f(text, 3)).toEqual('I NevEr LooK bAck'); expect(f('hello', 2)).toEqual('hElLo'); diff --git a/modules/50-loops/55-return-from-loops/test.js b/modules/50-loops/55-return-from-loops/test.js index 1fd544ba..f1176adf 100644 --- a/modules/50-loops/55-return-from-loops/test.js +++ b/modules/50-loops/55-return-from-loops/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('return from loops', () => { expect(f('support@example.com')).toBe(true); expect(f('wrong-email')).toBe(false); expect(f('@admin')).toBe(true); diff --git a/modules/50-loops/70-for/test.js b/modules/50-loops/70-for/test.js index 77a976c6..5087d211 100644 --- a/modules/50-loops/70-for/test.js +++ b/modules/50-loops/70-for/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('for', () => { expect(f(3)).toEqual('1 2 Fizz'); expect(f(5)).toEqual('1 2 Fizz 4 Buzz'); expect(f(15)).toEqual( diff --git a/modules/50-loops/90-debug/test.js b/modules/50-loops/90-debug/test.js index 7708354a..efc3237b 100644 --- a/modules/50-loops/90-debug/test.js +++ b/modules/50-loops/90-debug/test.js @@ -1,7 +1,7 @@ import { expect, test } from 'vitest'; import f from './index.js'; -test('test', () => { +test('debug', () => { expect(f('aaabcccc')).toBe('a3bc4'); expect(f('abcd')).toBe('abcd'); expect(f('aabbaa')).toBe('a2b2a2'); diff --git a/vitest.config.js b/vitest.config.js index f8553da6..65b75437 100644 --- a/vitest.config.js +++ b/vitest.config.js @@ -3,5 +3,6 @@ import { defineConfig } from 'vitest/config'; export default defineConfig({ test: { include: ['**/*.test.js', '**/*.spec.js', '**/test.js'], + disableConsoleIntercept: true, }, });