Skip to content
Snippets Groups Projects
Select Git revision
  • 5ff138c7d32417ec407e4c0aaa7d09032d5adb86
  • main default protected
  • correction_video
  • going_further
  • ImprovedMouseInteraction
  • final2023
  • template
  • ModifGUI
8 results

GameOfLifeState.java

Blame
  • Forked from YAGOUBI Rim / Game of life Template
    Source project has a limited visibility.
    Code owners
    Assign users and groups as approvers for specific file changes. Learn more.
    PalindromeTest.java 541 B
    package palindrome;
    
    import org.junit.jupiter.api.*;
    
    import static org.assertj.core.api.Assertions.assertThat;
    
    public class PalindromeTest {
    
      @Test
      void testEmptyString() {
        assertThat(Palindrome.isPalindrome("")).isTrue();
      }
    
      @Test
      void testEvenLengthFalse() {
        assertThat(Palindrome.isPalindrome("abcd")).isFalse();
      }
    
      @Test
      void testEvenLengthTrue() {
        assertThat(Palindrome.isPalindrome("abba")).isTrue();
      }
      @Test
      void testOddLengthTrue() {
        assertThat(Palindrome.isPalindrome("aba")).isTrue();
      }
    }