Package org.assertj.core.internal

Examples of org.assertj.core.internal.TestDescription


  @Before public void setup() {
    factory = shouldBeReadable(new FakeFile("pathname"));
  }

  @Test public void createExpectedMessage() {
    String actualMessage = factory.create(new TestDescription("Test"), new StandardRepresentation());
    assertEquals("[Test] \nExpecting file:\n <pathname>\nto be readable", actualMessage);
  }
View Full Code Here


    factory = shouldNotBeOfClassIn("Yoda", newArrayList(Long.class, String.class));
  }

  @Test
  public void should_create_error_message() {
    String message = factory.create(new TestDescription("Test"), new StandardRepresentation());
    assertEquals(
        "[Test] \nExpecting:\n <\"Yoda\">\nnot to be of any type in:\n <[java.lang.Long, java.lang.String]>\nbut was of type:<java.lang.String>",
        message);
  }
View Full Code Here

    factory = shouldBeEqual("Yoda", "Luke");
  }

  @Test
  public void should_create_error_message() {
    String message = factory.create(new TestDescription("Test"), new StandardRepresentation());
    assertEquals("[Test] \nExpecting:\n <\"Yoda\">\nto be equal to:\n <\"Luke\">\nignoring case considerations", message);
  }
View Full Code Here

    factory = shouldBeFile(new FakeFile("xyz"));
  }

  @Test
  public void should_create_error_message() {
    String message = factory.create(new TestDescription("Test"), new StandardRepresentation());
    assertEquals("[Test] \nExpecting:\n <xyz>\nto be a file", message);
  }
View Full Code Here

    factory = shouldBeAbsolutePath(new FakeFile("xyz"));
  }

  @Test
  public void should_create_error_message() {
    String message = factory.create(new TestDescription("Test"), new StandardRepresentation());
    assertEquals("[Test] \nExpecting:\n <xyz>\nto be an absolute path", message);
  }
View Full Code Here

      "Expecting file (or directory) without parent, but parent was:%n" +
      "  <" + actual.getParentFile() + ">"));
  }

  private String createMessage() {
    return shouldHaveNoParent(actual).create(new TestDescription("TEST"), new StandardRepresentation());
  }
View Full Code Here

  }

  @Test
  public void should_create_error_message() {
    assertEquals("[Test] \nsome elements are not mutually comparable in group:\n<[\"b\", 5, \"a\"]>",
        factory.create(new TestDescription("Test"), new StandardRepresentation()));
  }
View Full Code Here

    factory = shouldBeDirectory(new FakeFile("xyz"));
  }

  @Test
  public void should_create_error_message() {
    String message = factory.create(new TestDescription("Test"), new StandardRepresentation());
    assertEquals("[Test] \nExpecting:\n <xyz>\nto be an existing directory", message);
  }
View Full Code Here

    factory = shouldBeRelativePath(new FakeFile("xyz"));
  }

  @Test
  public void should_create_error_message() {
    String message = factory.create(new TestDescription("Test"), new StandardRepresentation());
    assertEquals("[Test] \nExpecting file:\n <xyz>\nto be a relative path", message);
  }
View Full Code Here

    factory = shouldNotExist(new FakeFile("xyz"));
  }

  @Test
  public void should_create_error_message() {
    String message = factory.create(new TestDescription("Test"), new StandardRepresentation());
    assertEquals("[Test] \nExpecting file:<xyz> not to exist", message);
  }
View Full Code Here

TOP

Related Classes of org.assertj.core.internal.TestDescription

Copyright © 2018 www.massapicom. 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.