diff --git a/Makefile b/Makefile index 376a7f65e9..998ed44ed3 100644 --- a/Makefile +++ b/Makefile @@ -233,13 +233,17 @@ run-e2e: .PHONY: run-e2e status: ## an alias for "docker compose ps" - @$(COMPOSE_E2E) ps + @$(COMPOSE) ps .PHONY: status stop: ## stop the development server using Docker - @$(COMPOSE_E2E) stop + @$(COMPOSE) stop .PHONY: stop +stop-e2e: ## stop the e2e server using Docker + @$(COMPOSE_E2E) stop +.PHONY: stop-e2e + # -- Backend demo: ## flush db then create a demo for load testing purpose @@ -406,6 +410,14 @@ run-frontend-development: ## Run the frontend in development mode cd $(PATH_FRONT_IMPRESS) && yarn dev .PHONY: run-frontend-development +frontend-test: ## Run the frontend tests + cd $(PATH_FRONT) && yarn test +.PHONY: frontend-test + +frontend-test-e2e: ## Run the e2e tests + cd $(PATH_FRONT) && yarn playwright install && yarn e2e:test --project='chromium' +.PHONY: frontend-test-e2e + frontend-i18n-extract: ## Extract the frontend translation inside a json to be used for crowdin cd $(PATH_FRONT) && yarn i18n:extract .PHONY: frontend-i18n-extract diff --git a/README.md b/README.md index c772d37442..44d6c09879 100644 --- a/README.md +++ b/README.md @@ -122,22 +122,16 @@ $ make run ⚠️ For the frontend developer, it is often better to run the frontend in development mode locally. -To do so, install the frontend dependencies with the following command: +This is the commands you will need in that order to develop and make your code ready for PR submission : ```shellscript -$ make frontend-development-install -``` - -And run the frontend locally in development mode with the following command: - -```shellscript -$ make run-frontend-development -``` - -To start all the services, except the frontend container, you can use the following command: - -```shellscript -$ make run-backend +make frontend-development-install # install the frontend dependencies +make run-backend # start all the services, except the frontend container +make run-frontend-development # run the frontend locally on your host in development mode +make frontend-test # execute frontend unit tests +make frontend-lint # execute frontend linting +make run-e2e # start another docker stack for e2e tests +make frontend-e2e # execute frontend e2e tests ``` **Adding content**