forked from exercism/scala
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update isogram to latest canoncial json. Refs exercism#488
- Loading branch information
Showing
1 changed file
with
17 additions
and
12 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,49 +1,54 @@ | ||
import org.scalatest.{Matchers, FunSuite} | ||
|
||
/** @version 1.3.0 */ | ||
/** @version 1.4.0 */ | ||
class IsogramTest extends FunSuite with Matchers { | ||
|
||
test("empty string") { | ||
Isogram.isIsogram("") should be (true) | ||
Isogram.isIsogram("") should be(true) | ||
} | ||
|
||
test("isogram with only lower case characters") { | ||
pending | ||
Isogram.isIsogram("isogram") should be (true) | ||
Isogram.isIsogram("isogram") should be(true) | ||
} | ||
|
||
test("word with one duplicated character") { | ||
pending | ||
Isogram.isIsogram("eleven") should be (false) | ||
Isogram.isIsogram("eleven") should be(false) | ||
} | ||
|
||
test("word with one duplicated character from the end of the alphabet") { | ||
pending | ||
Isogram.isIsogram("zzyzx") should be(false) | ||
} | ||
|
||
test("longest reported english isogram") { | ||
pending | ||
Isogram.isIsogram("subdermatoglyphic") should be (true) | ||
Isogram.isIsogram("subdermatoglyphic") should be(true) | ||
} | ||
|
||
test("word with duplicated character in mixed case") { | ||
pending | ||
Isogram.isIsogram("Alphabet") should be (false) | ||
Isogram.isIsogram("Alphabet") should be(false) | ||
} | ||
|
||
test("hypothetical isogrammic word with hyphen") { | ||
pending | ||
Isogram.isIsogram("thumbscrew-japingly") should be (true) | ||
Isogram.isIsogram("thumbscrew-japingly") should be(true) | ||
} | ||
|
||
test("isogram with duplicated hyphen") { | ||
pending | ||
Isogram.isIsogram("six-year-old") should be (true) | ||
Isogram.isIsogram("six-year-old") should be(true) | ||
} | ||
|
||
test("made-up name that is an isogram") { | ||
pending | ||
Isogram.isIsogram("Emily Jung Schwartzkopf") should be (true) | ||
Isogram.isIsogram("Emily Jung Schwartzkopf") should be(true) | ||
} | ||
|
||
test("duplicated character in the middle") { | ||
pending | ||
Isogram.isIsogram("accentor") should be (false) | ||
Isogram.isIsogram("accentor") should be(false) | ||
} | ||
} | ||
} |