Skip to content
Snippets Groups Projects
Commit b98b488d authored by Darius Schneider's avatar Darius Schneider
Browse files

stages maybe

parent 94c11b36
No related branches found
No related tags found
No related merge requests found
stages:
- detect_ruby
- test
default: default:
tags: tags:
- rails - rails
...@@ -7,44 +11,42 @@ default: ...@@ -7,44 +11,42 @@ default:
- wget --quiet "https://git-ce.rwth-aachen.de/noc-public/noc-netze-gitlab-cicd/-/raw/main/rails/haml-lint.yml" -O ".haml-lint.yml" - wget --quiet "https://git-ce.rwth-aachen.de/noc-public/noc-netze-gitlab-cicd/-/raw/main/rails/haml-lint.yml" -O ".haml-lint.yml"
- rm -f ./config/brakeman.yml ./config/brakeman.ignore - rm -f ./config/brakeman.yml ./config/brakeman.ignore
- gem install bundler --silent && bundle install --quiet - gem install bundler --silent && bundle install --quiet
- export RUBY_VERSION=$(cat .ruby-version | sed 's/ruby-//g')
variables: variables:
RAILS_ENV: test RAILS_ENV: test
detect_ruby:
detect:
script: echo "RUBY_VERSION=$(cat .ruby-version | sed 's/ruby-//g')" >> ruby.env
artifacts:
reports:
dotenv: ruby.env
test:
default:
image: ruby:$RUBY_VERSION
rubocop: rubocop:
stage: test
image: ruby:$(cat .ruby-version | sed 's/ruby-//g')
script: script:
- rubocop - rubocop
erb_lint: erb_lint:
stage: test
image: ruby:$(cat .ruby-version | sed 's/ruby-//g')
script: script:
- erblint --lint-all --allow-no-files true - erblint --lint-all --allow-no-files true
haml_lint: haml_lint:
stage: test
image: ruby:$(cat .ruby-version | sed 's/ruby-//g')
script: script:
- haml-lint - haml-lint
brakeman: brakeman:
stage: test
image: ruby:$(cat .ruby-version | sed 's/ruby-//g')
script: script:
- brakeman -A --except UnscopedFind - brakeman -A --except UnscopedFind
rails_test: rails_test:
stage: test
image: ruby:$(cat .ruby-version | sed 's/ruby-//g')
script: script:
- bin/rails db:prepare test - bin/rails db:prepare test
rails_system_test: rails_system_test:
stage: test
image: ruby:$(cat .ruby-version | sed 's/ruby-//g')
services: services:
- selenium/standalone-chrome:latest - selenium/standalone-chrome:latest
variables: variables:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment