mirror of
https://github.com/discourse/discourse.git
synced 2025-09-11 21:04:42 +08:00
Add rubocop to our build. (#5004)
This commit is contained in:
parent
ff4e295c4f
commit
5012d46cbd
871 changed files with 5480 additions and 6056 deletions
|
@ -83,7 +83,7 @@ JSON
|
|||
|
||||
expect(@theme.theme_fields.length).to eq(6)
|
||||
|
||||
mapped = Hash[*@theme.theme_fields.map{|f| ["#{f.target_id}-#{f.name}", f.value]}.flatten]
|
||||
mapped = Hash[*@theme.theme_fields.map { |f| ["#{f.target_id}-#{f.name}", f.value] }.flatten]
|
||||
|
||||
expect(mapped["0-header"]).to eq("I AM HEADER")
|
||||
expect(mapped["1-scss"]).to eq(scss_data)
|
||||
|
@ -106,7 +106,6 @@ JSON
|
|||
|
||||
`cd #{initial_repo} && git commit -am "update"`
|
||||
|
||||
|
||||
time = Time.new('2001')
|
||||
freeze_time time
|
||||
|
||||
|
@ -114,7 +113,6 @@ JSON
|
|||
expect(remote.commits_behind).to eq(1)
|
||||
expect(remote.remote_version).to eq(`cd #{initial_repo} && git rev-parse HEAD`.strip)
|
||||
|
||||
|
||||
remote.update_from_remote
|
||||
@theme.save
|
||||
@theme.reload
|
||||
|
@ -123,7 +121,7 @@ JSON
|
|||
expect(scheme.name).to eq("Amazing")
|
||||
expect(scheme.colors.find_by(name: 'love').hex).to eq('eaeaea')
|
||||
|
||||
mapped = Hash[*@theme.theme_fields.map{|f| ["#{f.target_id}-#{f.name}", f.value]}.flatten]
|
||||
mapped = Hash[*@theme.theme_fields.map { |f| ["#{f.target_id}-#{f.name}", f.value] }.flatten]
|
||||
|
||||
expect(mapped["0-header"]).to eq("I AM UPDATED")
|
||||
expect(mapped["1-scss"]).to eq(scss_data)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue