diff --git a/apps/testing-todos-list/.eslintrc.json b/apps/test/todos-list/.eslintrc.json
similarity index 94%
rename from apps/testing-todos-list/.eslintrc.json
rename to apps/test/todos-list/.eslintrc.json
index b428c22..bf8df14 100644
--- a/apps/testing-todos-list/.eslintrc.json
+++ b/apps/test/todos-list/.eslintrc.json
@@ -1,5 +1,5 @@
{
- "extends": ["../../.eslintrc.json"],
+ "extends": ["../../../.eslintrc.json"],
"ignorePatterns": ["!**/*"],
"overrides": [
{
diff --git a/apps/testing-todos-list/README.md b/apps/test/todos-list/README.md
similarity index 87%
rename from apps/testing-todos-list/README.md
rename to apps/test/todos-list/README.md
index 2adce88..0495bd8 100644
--- a/apps/testing-todos-list/README.md
+++ b/apps/test/todos-list/README.md
@@ -5,7 +5,7 @@
### Run Application
```bash
-npx nx serve testing-todos-list
+npx nx serve test-todos-list
```
### Documentation and Instruction
diff --git a/apps/testing-todos-list/cypress.config.ts b/apps/test/todos-list/cypress.config.ts
similarity index 100%
rename from apps/testing-todos-list/cypress.config.ts
rename to apps/test/todos-list/cypress.config.ts
diff --git a/apps/testing-todos-list/cypress/fixtures/example.json b/apps/test/todos-list/cypress/fixtures/example.json
similarity index 100%
rename from apps/testing-todos-list/cypress/fixtures/example.json
rename to apps/test/todos-list/cypress/fixtures/example.json
diff --git a/apps/testing-todos-list/cypress/support/commands.ts b/apps/test/todos-list/cypress/support/commands.ts
similarity index 100%
rename from apps/testing-todos-list/cypress/support/commands.ts
rename to apps/test/todos-list/cypress/support/commands.ts
diff --git a/apps/test/todos-list/cypress/support/component-index.html b/apps/test/todos-list/cypress/support/component-index.html
new file mode 100644
index 0000000..8b1d587
--- /dev/null
+++ b/apps/test/todos-list/cypress/support/component-index.html
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+ testing-todos-list Components App
+
+
+
+
+
diff --git a/apps/testing-todos-list/cypress/support/component.ts b/apps/test/todos-list/cypress/support/component.ts
similarity index 100%
rename from apps/testing-todos-list/cypress/support/component.ts
rename to apps/test/todos-list/cypress/support/component.ts
diff --git a/apps/testing-todos-list/cypress/tsconfig.json b/apps/test/todos-list/cypress/tsconfig.json
similarity index 100%
rename from apps/testing-todos-list/cypress/tsconfig.json
rename to apps/test/todos-list/cypress/tsconfig.json
diff --git a/apps/testing-todos-list/jest.config.ts b/apps/test/todos-list/jest.config.ts
similarity index 88%
rename from apps/testing-todos-list/jest.config.ts
rename to apps/test/todos-list/jest.config.ts
index d110948..0abb644 100644
--- a/apps/testing-todos-list/jest.config.ts
+++ b/apps/test/todos-list/jest.config.ts
@@ -1,7 +1,7 @@
/* eslint-disable */
export default {
- displayName: 'testing-todos-list',
- preset: '../../jest.preset.js',
+ displayName: 'test-todos-list',
+ preset: '../../../jest.preset.js',
setupFilesAfterEnv: ['/src/test-setup.ts'],
transform: {
'^.+\\.(ts|mjs|js|html)$': [
diff --git a/apps/testing-todos-list/project.json b/apps/test/todos-list/project.json
similarity index 68%
rename from apps/testing-todos-list/project.json
rename to apps/test/todos-list/project.json
index fcb66f2..f9e9944 100644
--- a/apps/testing-todos-list/project.json
+++ b/apps/test/todos-list/project.json
@@ -1,26 +1,26 @@
{
- "name": "testing-todos-list",
- "$schema": "../node_modules/nx/schemas/project-schema.json",
+ "name": "test-todos-list",
+ "$schema": "../../../node_modules/nx/schemas/project-schema.json",
"projectType": "application",
- "sourceRoot": "apps/testing-todos-list/src",
+ "sourceRoot": "apps/test/todos-list/src",
"prefix": "app",
"targets": {
"build": {
"executor": "@angular-devkit/build-angular:browser",
"outputs": ["{options.outputPath}"],
"options": {
- "outputPath": "dist/apps/testing-todos-list",
- "index": "apps/testing-todos-list/src/index.html",
- "main": "apps/testing-todos-list/src/main.ts",
+ "outputPath": "dist/apps/test/todos-list",
+ "index": "apps/test/todos-list/src/index.html",
+ "main": "apps/test/todos-list/src/main.ts",
"polyfills": ["zone.js"],
- "tsConfig": "apps/testing-todos-list/tsconfig.app.json",
+ "tsConfig": "apps/test/todos-list/tsconfig.app.json",
"inlineStyleLanguage": "scss",
"assets": [
- "apps/testing-todos-list/src/favicon.ico",
- "apps/testing-todos-list/src/assets"
+ "apps/test/todos-list/src/favicon.ico",
+ "apps/test/todos-list/src/assets"
],
"styles": [
- "apps/testing-todos-list/src/styles.scss",
+ "apps/test/todos-list/src/styles.scss",
"./node_modules/@angular/material/prebuilt-themes/indigo-pink.css"
],
"scripts": []
@@ -56,10 +56,10 @@
"executor": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
- "browserTarget": "testing-todos-list:build:production"
+ "browserTarget": "test-todos-list:build:production"
},
"development": {
- "browserTarget": "testing-todos-list:build:development"
+ "browserTarget": "test-todos-list:build:development"
}
},
"defaultConfiguration": "development"
@@ -67,7 +67,7 @@
"extract-i18n": {
"executor": "@angular-devkit/build-angular:extract-i18n",
"options": {
- "browserTarget": "testing-todos-list:build"
+ "browserTarget": "test-todos-list:build"
}
},
"lint": {
@@ -75,8 +75,8 @@
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": [
- "apps/testing-todos-list/**/*.ts",
- "apps/testing-todos-list/**/*.html"
+ "apps/test/todos-list/**/*.ts",
+ "apps/test/todos-list/**/*.html"
]
}
},
@@ -84,7 +84,7 @@
"executor": "@nx/jest:jest",
"outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
"options": {
- "jestConfig": "apps/testing-todos-list/jest.config.ts",
+ "jestConfig": "apps/test/todos-list/jest.config.ts",
"passWithNoTests": true
},
"configurations": {
@@ -97,10 +97,10 @@
"component-test": {
"executor": "@nx/cypress:cypress",
"options": {
- "cypressConfig": "apps/testing-todos-list/cypress.config.ts",
+ "cypressConfig": "apps/test/todos-list/cypress.config.ts",
"testingType": "component",
"skipServe": true,
- "devServerTarget": "testing-todos-list:build"
+ "devServerTarget": "test-todos-list:build"
}
}
},
diff --git a/apps/testing-todos-list/src/app/app.component.ts b/apps/test/todos-list/src/app/app.component.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/app.component.ts
rename to apps/test/todos-list/src/app/app.component.ts
diff --git a/apps/testing-todos-list/src/app/app.config.ts b/apps/test/todos-list/src/app/app.config.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/app.config.ts
rename to apps/test/todos-list/src/app/app.config.ts
diff --git a/apps/testing-todos-list/src/app/app.route.ts b/apps/test/todos-list/src/app/app.route.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/app.route.ts
rename to apps/test/todos-list/src/app/app.route.ts
diff --git a/apps/testing-todos-list/src/app/backend.service.ts b/apps/test/todos-list/src/app/backend.service.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/backend.service.ts
rename to apps/test/todos-list/src/app/backend.service.ts
diff --git a/apps/testing-todos-list/src/app/detail/detail.component.ts b/apps/test/todos-list/src/app/detail/detail.component.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/detail/detail.component.ts
rename to apps/test/todos-list/src/app/detail/detail.component.ts
diff --git a/apps/testing-todos-list/src/app/detail/detail.store.ts b/apps/test/todos-list/src/app/detail/detail.store.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/detail/detail.store.ts
rename to apps/test/todos-list/src/app/detail/detail.store.ts
diff --git a/apps/testing-todos-list/src/app/list/list.component.spec.ts b/apps/test/todos-list/src/app/list/list.component.spec.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/list/list.component.spec.ts
rename to apps/test/todos-list/src/app/list/list.component.spec.ts
diff --git a/apps/testing-todos-list/src/app/list/list.component.ts b/apps/test/todos-list/src/app/list/list.component.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/list/list.component.ts
rename to apps/test/todos-list/src/app/list/list.component.ts
diff --git a/apps/testing-todos-list/src/app/list/ticket.store.spec.ts b/apps/test/todos-list/src/app/list/ticket.store.spec.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/list/ticket.store.spec.ts
rename to apps/test/todos-list/src/app/list/ticket.store.spec.ts
diff --git a/apps/testing-todos-list/src/app/list/ticket.store.ts b/apps/test/todos-list/src/app/list/ticket.store.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/list/ticket.store.ts
rename to apps/test/todos-list/src/app/list/ticket.store.ts
diff --git a/apps/testing-todos-list/src/app/list/ui/add.component.ts b/apps/test/todos-list/src/app/list/ui/add.component.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/list/ui/add.component.ts
rename to apps/test/todos-list/src/app/list/ui/add.component.ts
diff --git a/apps/testing-todos-list/src/app/list/ui/row.component.spec.ts b/apps/test/todos-list/src/app/list/ui/row.component.spec.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/list/ui/row.component.spec.ts
rename to apps/test/todos-list/src/app/list/ui/row.component.spec.ts
diff --git a/apps/testing-todos-list/src/app/list/ui/row.component.ts b/apps/test/todos-list/src/app/list/ui/row.component.ts
similarity index 100%
rename from apps/testing-todos-list/src/app/list/ui/row.component.ts
rename to apps/test/todos-list/src/app/list/ui/row.component.ts
diff --git a/apps/testing-todos-list/src/assets/.gitkeep b/apps/test/todos-list/src/assets/.gitkeep
similarity index 100%
rename from apps/testing-todos-list/src/assets/.gitkeep
rename to apps/test/todos-list/src/assets/.gitkeep
diff --git a/apps/testing-todos-list/src/favicon.ico b/apps/test/todos-list/src/favicon.ico
similarity index 100%
rename from apps/testing-todos-list/src/favicon.ico
rename to apps/test/todos-list/src/favicon.ico
diff --git a/apps/testing-todos-list/src/index.html b/apps/test/todos-list/src/index.html
similarity index 100%
rename from apps/testing-todos-list/src/index.html
rename to apps/test/todos-list/src/index.html
diff --git a/apps/testing-todos-list/src/main.ts b/apps/test/todos-list/src/main.ts
similarity index 100%
rename from apps/testing-todos-list/src/main.ts
rename to apps/test/todos-list/src/main.ts
diff --git a/apps/testing-todos-list/src/styles.scss b/apps/test/todos-list/src/styles.scss
similarity index 100%
rename from apps/testing-todos-list/src/styles.scss
rename to apps/test/todos-list/src/styles.scss
diff --git a/apps/testing-todos-list/src/test-setup.ts b/apps/test/todos-list/src/test-setup.ts
similarity index 100%
rename from apps/testing-todos-list/src/test-setup.ts
rename to apps/test/todos-list/src/test-setup.ts
diff --git a/apps/testing-todos-list/tailwind.config.js b/apps/test/todos-list/tailwind.config.js
similarity index 100%
rename from apps/testing-todos-list/tailwind.config.js
rename to apps/test/todos-list/tailwind.config.js
diff --git a/apps/testing-todos-list/tsconfig.app.json b/apps/test/todos-list/tsconfig.app.json
similarity index 89%
rename from apps/testing-todos-list/tsconfig.app.json
rename to apps/test/todos-list/tsconfig.app.json
index e46d4fc..01a02ed 100644
--- a/apps/testing-todos-list/tsconfig.app.json
+++ b/apps/test/todos-list/tsconfig.app.json
@@ -1,7 +1,7 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
- "outDir": "../../dist/out-tsc",
+ "outDir": "../../../dist/out-tsc",
"types": []
},
"files": ["src/main.ts"],
diff --git a/apps/testing-todos-list/tsconfig.editor.json b/apps/test/todos-list/tsconfig.editor.json
similarity index 100%
rename from apps/testing-todos-list/tsconfig.editor.json
rename to apps/test/todos-list/tsconfig.editor.json
diff --git a/apps/testing-todos-list/tsconfig.json b/apps/test/todos-list/tsconfig.json
similarity index 94%
rename from apps/testing-todos-list/tsconfig.json
rename to apps/test/todos-list/tsconfig.json
index 28546c4..3879b94 100644
--- a/apps/testing-todos-list/tsconfig.json
+++ b/apps/test/todos-list/tsconfig.json
@@ -25,7 +25,7 @@
"path": "./cypress/tsconfig.json"
}
],
- "extends": "../../tsconfig.base.json",
+ "extends": "../../../tsconfig.base.json",
"angularCompilerOptions": {
"enableI18nLegacyMessageIdFormat": false,
"strictInjectionParameters": true,
diff --git a/apps/testing-todos-list/tsconfig.spec.json b/apps/test/todos-list/tsconfig.spec.json
similarity index 88%
rename from apps/testing-todos-list/tsconfig.spec.json
rename to apps/test/todos-list/tsconfig.spec.json
index 1a4817a..c0c092e 100644
--- a/apps/testing-todos-list/tsconfig.spec.json
+++ b/apps/test/todos-list/tsconfig.spec.json
@@ -1,7 +1,7 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
- "outDir": "../../dist/out-tsc",
+ "outDir": "../../../dist/out-tsc",
"module": "commonjs",
"types": ["jest", "node", "@testing-library/jest-dom"]
},
diff --git a/apps/testing-todos-list/cypress/support/component-index.html b/apps/testing-todos-list/cypress/support/component-index.html
deleted file mode 100644
index 4bcc08e..0000000
--- a/apps/testing-todos-list/cypress/support/component-index.html
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-
-
-
-
- testing-todos-list Components App
-
-
-
-
-
-
diff --git a/docs/src/content/docs/challenges/testing/29-real-application.md b/docs/src/content/docs/challenges/testing/29-real-application.md
index f65ed65..f4d21d4 100644
--- a/docs/src/content/docs/challenges/testing/29-real-application.md
+++ b/docs/src/content/docs/challenges/testing/29-real-application.md
@@ -3,7 +3,7 @@ title: 🔴 Real-life Application
description: Challenge 29 is about testing a real-life application
author: Thomas Laforge
challengeNumber: 29
-command: testing-todos-list
+command: test-todos-list
sidebar:
order: 205
---
@@ -18,11 +18,11 @@ In this challenge, you will write tests for the `ListComponent`, which represent
Handling asynchronous tasks will be particularly challenging. It's important not to introduce any explicit waits in your tests, as this would introduce unnecessary delays. Instead, it's better to look for an element that needs to appear or disappear from the DOM. In this case, the test will naturally wait for the correct period of time, as the waits are already implemented within both libraries. Take advantage of these built-in functionalities to create efficient and reliable tests.
-You can play with it by running : `npx nx serve testing-todos-list`.
+You can play with it by running : `npx nx serve test-todos-list`.
-To run Testing Library test suits, you need to run `npx nx test testing-input-output`. You can also install [Jest Runner](https://marketplace.visualstudio.com/items?itemName=firsttris.vscode-jest-runner) to execute your test by clicking on the `Run` button above each `describe` or `it` blocks.
+To run Testing Library test suits, you need to run `npx nx test test-input-output`. You can also install [Jest Runner](https://marketplace.visualstudio.com/items?itemName=firsttris.vscode-jest-runner) to execute your test by clicking on the `Run` button above each `describe` or `it` blocks.
-For testing cypress, you will execute your test inside the `child.component.cy.ts` and run `npx nx component-test testing-input-output` to execute your test suits. You can add the `--watch` flag to execute your test in watch mode.
+For testing cypress, you will execute your test inside the `child.component.cy.ts` and run `npx nx component-test test-input-output` to execute your test suits. You can add the `--watch` flag to execute your test in watch mode.
# Statement