Package com.google.code.timetrail.backend

Examples of com.google.code.timetrail.backend.River


  @Test
  public void testTakeFerryNutritionist() {
    control.setPlayer(nutritionist);

    River river;
    for (Place p : places) {
      river = new River(control, p);
      String ferry = river.takeFerry();
      assertFalse(
          "Not able to take Ferry",
          ferry.equals("You don't have enough money to make it across!"));
    }

    river = new River(control, control.getCurrentPlace());
    assertEquals(40, river.getFerryPrice());

    control.getPlayer().intializeSkills();

    assertEquals(40, river.getFerryPrice());
  }
View Full Code Here


  @Test
  public void testFordNutritionist() {
    control.setPlayer(nutritionist);

    River river;
    for (Place p : places) {
      river = new River(control, p);
      int passed = 0;
      for (int i = 0; i < 10000; i++) {
        String ford = river.ford();
        if (ford.equals("You sucessfully made it across the time stream"))
          passed++;
      }

      if (p.getName().equals("Kansas River")
View Full Code Here

 
  @Test
  public void testCaulkNutritionist() {
    control.setPlayer(nutritionist);

    River river;
    for (Place p : places) {
      river = new River(control, p);
      int passed = 0;
      for (int i = 0; i < 10000; i++) {
        String ford = river.ford();
        if (ford.equals("You sucessfully made it across the time stream"))
          passed++;
      }

      assertEquals(.35, (double) passed / 10000.0, 0.55);
View Full Code Here

TOP

Related Classes of com.google.code.timetrail.backend.River

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.