Ejemplo n.º 1
0
 function test_UpdateNeighborhood()
 {
     //arrange
     $type = "Tacos";
     $id = null;
     $test_cuisine = new Cuisine($type, $id);
     $test_cuisine->save();
     $name = "Nathans";
     $cuisine_id = $test_cuisine->getId();
     $price_range = 1;
     $neighborhood = "Felony Flats";
     $test_restaurant = new Restaurant($name, $id, $cuisine_id, $price_range, $neighborhood);
     $test_restaurant->save();
     $new_neighborhood = "Foster";
     //act
     $test_restaurant->updateNeighborhood($new_neighborhood);
     //assert
     $this->assertEquals("Foster", $test_restaurant->getNeighborhood());
 }