Examples of HexadecimalRepresentation


Examples of org.assertj.core.presentation.HexadecimalRepresentation

    assertEquals("[6, 8]", formatter.format(new StandardRepresentation(), new byte[] { 6, 8 }));
  }

  @Test
  public void should_format_byte_array_in_hex_representation() {
    assertEquals("[0x06, 0x08]", formatter.format(new HexadecimalRepresentation(), new byte[] { 6, 8 }));
  }
View Full Code Here

Examples of org.assertj.core.presentation.HexadecimalRepresentation

  }

  @Test
  public void should_format_byte_array_in_hex_representation() {
    Object array = new byte[] { (byte) 3, (byte) 8 };
    assertEquals("[0x03, 0x08]", Arrays.format(new HexadecimalRepresentation(), array));
  }
View Full Code Here

Examples of org.assertj.core.presentation.HexadecimalRepresentation

    assertThat(message).isEqualTo("[Test] \nExpected size:<2> but was:<4> in:\n<['a', 'b']>");
  }

  @Test
  public void should_create_error_message_with_hexadecimal_representation() {
    String message = factory.create(new TextDescription("Test"), new HexadecimalRepresentation());
    assertThat(message).isEqualTo("[Test] \nExpected size:<2> but was:<4> in:\n<['0x0061', '0x0062']>");
  }
View Full Code Here

Examples of org.assertj.core.presentation.HexadecimalRepresentation

                                   "<['a', 'b']>");
  }

  @Test
  public void should_create_error_message_with_hexadecimal_representation() {
    String message = factory.create(new TextDescription("Test"), new HexadecimalRepresentation());
    assertThat(message).isEqualTo("[Test] \n" +
                                  "Actual and expected should have same size but actual size is:\n" +
                                  " <2>\n" +
                                  "while expected is:\n" +
                                  " <4>\n" +
View Full Code Here

Examples of org.assertj.core.presentation.HexadecimalRepresentation

    }
    return representation;
  }

  public void useHexadecimalRepresentation() {
    representation = new HexadecimalRepresentation();
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.