2121import static com .jupiter .service .hotel .enums .Locations .LOCATION_VALENCIA ;
2222import static com .jupiter .service .hotel .enums .RequestStatus .ERROR ;
2323import static com .jupiter .utils .DateTimeUtils .*;
24+ import static java .lang .String .format ;
2425import static org .junit .jupiter .api .Assertions .*;
2526
2627public class HotelLivingCostTest extends BaseTest {
2728
2829 private static Stream <Arguments > hotelDataSet () {
2930 return Stream .of (
3031 Arguments .of (LOCATION_VALENCIA .getName (), List .of (HOTEL_LAS_ARENAS , HOTEL_EUROSTARS , HOTEL_MALCOM , HOTEL_VENECIA ), 1 ),
31- Arguments .of (LOCATION_ALANYA .getName (), List .of (HOTEL_GREEN_GARDEN , HOTEL_HARMONY , HOTEL_SUNWAY , HOTEL_MUSTI ), 14 )
32+ Arguments .of (LOCATION_ALANYA .getName (), List .of (HOTEL_GREEN_GARDEN , HOTEL_HARMONY , HOTEL_SUNWAY , HOTEL_BLUE_HEAVEN ), 14 )
3233 );
3334 }
3435
@@ -45,7 +46,7 @@ public void displayHotelPriceWhenLocationNameProvided(String locationName, List<
4546 private static Stream <Arguments > hotelLocationIdDataSet () {
4647 return Stream .of (
4748 Arguments .of (LOCATION_VALENCIA .getLocationId (), List .of (HOTEL_LAS_ARENAS , HOTEL_EUROSTARS , HOTEL_MALCOM , HOTEL_VENECIA ), 1 ),
48- Arguments .of (LOCATION_ALANYA .getLocationId (), List .of (HOTEL_GREEN_GARDEN , HOTEL_HARMONY , HOTEL_SUNWAY , HOTEL_MUSTI ), 7 )
49+ Arguments .of (LOCATION_ALANYA .getLocationId (), List .of (HOTEL_GREEN_GARDEN , HOTEL_HARMONY , HOTEL_SUNWAY , HOTEL_OZGUR ), 7 )
4950 );
5051 }
5152
@@ -86,7 +87,7 @@ private void checkHotelDataAndPrice(List<Hotels> hotelListExpected, List<HotelPr
8687 .filter (hotel -> hotel .getHotelName ().equals (hotelExpected .getHotelName ()))
8788 .findFirst ();
8889
89- assertNotNull (hotelOpt .get ( ));
90+ assertTrue (hotelOpt .isPresent (), format ( "Hotel name = '%s' is not found" , hotelExpected . getHotelName () ));
9091
9192 HotelPriceResponseDTO hotelActual = hotelOpt .get ();
9293
0 commit comments