mirror of
https://github.com/projekteuler/projekteuler.git
synced 2026-11-23 19:33:46 +01:00
Add check whether problem has a translation
This commit is contained in:
1 parent
cbf17cfce0
commit
4c16813c92
8 files changed
+41
-5
No files matched your search
@@ -1,7 +1,16 @@
|
||||
require 'test_helper'
|
||||
|
||||
class ProblemTest < ActiveSupport::TestCase
|
||||
# test "the truth" do
|
||||
# assert true
|
||||
# end
|
||||
test "should save correct problem" do
|
||||
problem = Problem.new
|
||||
assert problem.save
|
||||
end
|
||||
|
||||
test "is_translated? should return false for missing translation" do
|
||||
assert_not problems(:three).is_translated?
|
||||
end
|
||||
|
||||
test "is_translated? should return true for existing translation" do
|
||||
assert problems(:one).is_translated?
|
||||
end
|
||||
end
|
||||
Reference in new issue
Block a user