mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-29 17:50:22 +00:00
Add test to guard against unused colours
This commit is contained in:
@@ -494,4 +494,11 @@ class TestLanguage < Minitest::Test
|
||||
message << missing.sort.join("\n")
|
||||
assert missing.empty?, message
|
||||
end
|
||||
|
||||
def test_no_unused_colours
|
||||
Language.all.each do |language|
|
||||
next unless language.type == :data || language.type == :prose
|
||||
assert !language.color, "Unused colour assigned to #{language.name}"
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user