Just the blockers now!!

This commit is contained in:
2024-05-10 07:27:32 +01:00
parent abff880184
commit e3901d26c6
6 changed files with 81 additions and 73 deletions

View File

@@ -3,18 +3,23 @@ require "test_helper"
class CredentialTest < ActiveSupport::TestCase
test "email must be present" do
@c = Credential.new
assert !@c.save
assert_not @c.save
end
test "email must be valid" do
@c = Credential.new
@c.email = "not on your nelly"
assert !@c.save
assert_not @c.save
end
test "email must be unique" do
@c = Credential.new
@c.email = "bob@example.net"
assert !@c.save
assert_not @c.save
end
test "domain added to name" do
@c = Credential.new(email: "jez", password: "1234567&ab", domain_id: domains(:one).id)
assert @c.save
end
end