Fixed a few lints; changed rake task name to test:lint
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
@@ -26,7 +26,7 @@ steps:
|
||||
commands:
|
||||
- gem install rake
|
||||
- bundle config set --local path "vendor/bundle"
|
||||
- rake test:rubocop
|
||||
- rake test:lint
|
||||
|
||||
gitea_release:
|
||||
image: plugins/gitea-release
|
||||
|
2
Rakefile
2
Rakefile
@@ -32,7 +32,7 @@ namespace :test do
|
||||
system("rspec")
|
||||
end
|
||||
|
||||
task :rubocop do
|
||||
task :lint do
|
||||
system("rubocop src/ spec/")
|
||||
end
|
||||
end
|
||||
|
@@ -7,8 +7,11 @@ RSpec.describe(BenchmarkController) do
|
||||
describe 'GET /benchmark' do
|
||||
before { get '/benchmark' }
|
||||
|
||||
it 'Benchmark base route redirects to /benchmark/list' do
|
||||
it 'Benchmark base route is a redirect' do
|
||||
expect(last_response).to(be_redirect)
|
||||
end
|
||||
|
||||
it 'Benchmark base route Location header points to /benchmark/list' do
|
||||
expect(last_response['Location']).to(eq("#{BASE_URL}/benchmark/list"))
|
||||
end
|
||||
end
|
||||
|
@@ -7,8 +7,11 @@ RSpec.describe(HardwareController) do
|
||||
describe 'GET /hardware' do
|
||||
before { get '/hardware' }
|
||||
|
||||
it 'Hardware base route redirects to /hardware/list' do
|
||||
it 'Hardware base route is a redirect' do
|
||||
expect(last_response).to(be_redirect)
|
||||
end
|
||||
|
||||
it 'Hardware base route Location header points to /hardware/list' do
|
||||
expect(last_response['Location']).to(eq("#{BASE_URL}/hardware/list"))
|
||||
end
|
||||
end
|
||||
|
@@ -7,8 +7,11 @@ RSpec.describe(TestController) do
|
||||
describe 'GET /test' do
|
||||
before { get '/test' }
|
||||
|
||||
it 'Test base route redirects to /test/list' do
|
||||
it 'Test base route is a redirect' do
|
||||
expect(last_response).to(be_redirect)
|
||||
end
|
||||
|
||||
it 'Test base route Location header points to /test/list' do
|
||||
expect(last_response['Location']).to(eq("#{BASE_URL}/test/list"))
|
||||
end
|
||||
end
|
||||
|
@@ -12,7 +12,6 @@ class Config
|
||||
@data = YAML.load_file(DEFAULT_CONFIG)
|
||||
|
||||
# merge in user-defined configuration if it exists
|
||||
puts "Merging #{config_path} with #{DEFAULT_CONFIG}."
|
||||
@data.merge!(YAML.load_file(config_path)) if File.exist?(config_path)
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user