@@ -9,55 +9,63 @@ public class AcronymTest {
99 public void basic () {
1010 String phrase = "Portable Network Graphics" ;
1111 String expected = "PNG" ;
12- assertEquals (expected , new Acronym (phrase ).get ());
12+ assertEquals (expected , new Acronym (phrase ).getAcronym ());
1313 }
1414
1515 @ Ignore ("Remove to run test" )
1616 @ Test
1717 public void lowercaseWords () {
1818 String phrase = "Ruby on Rails" ;
1919 String expected = "ROR" ;
20- assertEquals (expected , new Acronym (phrase ).get ());
20+ assertEquals (expected , new Acronym (phrase ).getAcronym ());
2121 }
2222
2323 @ Ignore ("Remove to run test" )
2424 @ Test
2525 public void punctuation () {
2626 String phrase = "First In, First Out" ;
2727 String expected = "FIFO" ;
28- assertEquals (expected , new Acronym (phrase ).get ());
28+ assertEquals (expected , new Acronym (phrase ).getAcronym ());
2929 }
3030
3131 @ Ignore ("Remove to run test" )
3232 @ Test
3333 public void nonAcronymAllCapsWord () {
3434 String phrase = "GNU Image Manipulation Program" ;
3535 String expected = "GIMP" ;
36- assertEquals (expected , new Acronym (phrase ).get ());
36+ assertEquals (expected , new Acronym (phrase ).getAcronym ());
3737 }
3838
3939 @ Ignore ("Remove to run test" )
4040 @ Test
4141 public void punctuationWithoutWhitespace () {
4242 String phrase = "Complementary metal-oxide semiconductor" ;
4343 String expected = "CMOS" ;
44- assertEquals (expected , new Acronym (phrase ).get ());
44+ assertEquals (expected , new Acronym (phrase ).getAcronym ());
4545 }
4646
4747 @ Ignore ("Remove to run test" )
4848 @ Test
4949 public void veryLongAbbreviation () {
5050 String phrase = "Rolling On The Floor Laughing So Hard That My Dogs Came Over And Licked Me" ;
5151 String expected = "ROTFLSHTMDCOALM" ;
52- assertEquals (expected , new Acronym (phrase ).get ());
52+ assertEquals (expected , new Acronym (phrase ).getAcronym ());
5353 }
5454
5555 @ Ignore ("Remove to run test" )
5656 @ Test
5757 public void consecutiveDelimiters () {
5858 String phrase = "Something - I made up from thin air" ;
5959 String expected = "SIMUFTA" ;
60- assertEquals (expected , new Acronym (phrase ).get ());
60+ assertEquals (expected , new Acronym (phrase ).getAcronym ());
61+ }
62+
63+ @ Ignore ("Remove to run test" )
64+ @ Test
65+ public void apostrophes () {
66+ String phrase = "Halley's Comet" ;
67+ String expected = "HC" ;
68+ assertEquals (expected , new Acronym (phrase ).getAcronym ());
6169 }
6270
6371}
0 commit comments