Update .gitlab-ci.yml file

This commit is contained in:
AmirHossein Mahmoodi
2023-10-15 07:57:37 +00:00
parent df947537e4
commit 9c10d5b249

View File

@@ -1,26 +1,47 @@
image: node:latest image: node:latest
stages: stages:
- build - build
- test - test
merge:build:
stage: build
script:
- echo "Run build project"
- npm install
- npm run build
only:
- merge_requests
artifacts:
paths:
- node_modules
merge:test:
stage: test
script:
- echo "Run test project"
- npm run test
only:
- merge_requests
artifacts:
paths:
- node_modules
build: build:
stage: build stage: build
script: script:
- npm install - echo "Run build project"
- npm run build - npm install
only: - npm run build
- merge_requests artifacts:
artifacts: paths:
paths: - node_modules
- node_modules
test: test:
stage: test stage: test
script: script:
- npm run test - echo "Run test project"
only: - npm run test
- merge_requests artifacts:
artifacts: paths:
paths: - node_modules
- node_modules