-
Notifications
You must be signed in to change notification settings - Fork 54
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes #40 when email in is nil, output nil as well
- Loading branch information
Showing
2 changed files
with
5 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -116,4 +116,8 @@ def test_relaxed_normal | |
assert ! EmailAddress.new('[email protected]').valid? | ||
assert true, EmailAddress.new('[email protected]', local_format: :relaxed).valid? | ||
end | ||
|
||
def test_nil_address | ||
assert_nil EmailAddress.new(nil).normal, "Expected a nil input to make nil output" | ||
end | ||
end |