import {
  TrainExchange,
  TrainTripType,
  TrainSearchModalUtil,
  SncfBookingParams,
  TrainBookingManager,
  AgencyCurrency
} from '@train-lib/index';

describe('Train: SNCF oneway exchange workflow ', () => {
  it(
    'C2317454: Should be able to book and exchange one way train ticket',
    { tags: ['@sncf', '@all_train_test', '@france'] },
    () => {
      TrainSearchModalUtil.createCompanyWithProviderName({
        feeModelInfo: AgencyCurrency.Euro
      });
      TrainBookingManager.createFirstClassBooking({
        origin: SncfBookingParams.Location.Paris,
        destination: SncfBookingParams.Location.Lyon,
        trainClass: true,
        tripType: TrainTripType.ONEWAY,
        fareType: SncfBookingParams.FareType.FIRST_CLASS
      });

      TrainExchange.processExchangeWorkflow('We will send your e-ticket(s) to your email and Navan mobile app');
    }
  );
});
