Skip to content

Commit 067d3ce

Browse files
authored
acronym display-tags (#2986)
1 parent 301df04 commit 067d3ce

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

exercises/practice/acronym/src/test/java/AcronymTest.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,65 +1,76 @@
11
import org.junit.jupiter.api.Disabled;
22
import org.junit.jupiter.api.Test;
3+
import org.junit.jupiter.api.DisplayName;
34

45
import static org.assertj.core.api.Assertions.assertThat;
56

67
public class AcronymTest {
78

9+
10+
@DisplayName("basic")
811
@Test
912
public void basic() {
1013
assertThat(new Acronym("Portable Network Graphics").get())
1114
.isEqualTo("PNG");
1215
}
1316

17+
@DisplayName("lowercase words")
1418
@Disabled("Remove to run test")
1519
@Test
1620
public void lowercaseWords() {
1721
assertThat(new Acronym("Ruby on Rails").get())
1822
.isEqualTo("ROR");
1923
}
2024

25+
@DisplayName("punctuation")
2126
@Disabled("Remove to run test")
2227
@Test
2328
public void punctuation() {
2429
assertThat(new Acronym("First In, First Out").get())
2530
.isEqualTo("FIFO");
2631
}
2732

33+
@DisplayName("all caps word")
2834
@Disabled("Remove to run test")
2935
@Test
3036
public void nonAcronymAllCapsWord() {
3137
assertThat(new Acronym("GNU Image Manipulation Program").get())
3238
.isEqualTo("GIMP");
3339
}
3440

41+
@DisplayName("punctuation without whitespace")
3542
@Disabled("Remove to run test")
3643
@Test
3744
public void punctuationWithoutWhitespace() {
3845
assertThat(new Acronym("Complementary metal-oxide semiconductor").get())
3946
.isEqualTo("CMOS");
4047
}
4148

49+
@DisplayName("very long abbreviation")
4250
@Disabled("Remove to run test")
4351
@Test
4452
public void veryLongAbbreviation() {
4553
assertThat(new Acronym("Rolling On The Floor Laughing So Hard That My Dogs Came Over And Licked Me").get())
4654
.isEqualTo("ROTFLSHTMDCOALM");
4755
}
4856

57+
@DisplayName("consecutive delimiters")
4958
@Disabled("Remove to run test")
5059
@Test
5160
public void consecutiveDelimiters() {
5261
assertThat(new Acronym("Something - I made up from thin air").get())
5362
.isEqualTo("SIMUFTA");
5463
}
5564

65+
@DisplayName("apostrophes")
5666
@Disabled("Remove to run test")
5767
@Test
5868
public void apostrophes() {
5969
assertThat(new Acronym("Halley's Comet").get())
6070
.isEqualTo("HC");
6171
}
6272

73+
@DisplayName("underscore emphasis")
6374
@Disabled("Remove to run test")
6475
@Test
6576
public void underscoreEmphasis() {

0 commit comments

Comments
 (0)