package cz.moneta.test.dsl.ufo.banka.pages.products.current.account;

import cz.moneta.test.harness.context.StoreAccessor;
import cz.moneta.test.harness.support.web.*;

import static cz.moneta.test.dsl.ufo.banka.pages.products.current.account.ZPL_OBR001_SmoothPaymentInfo.*;

@Wait(value = {OBR001_S001_PAGE_LABEL_XPATH, ZPL_PAGE_LABEL_XPATH}, by = Lookup.XPATH, waitSecondsForElement = 90)
@Wait(value = OK_BUTTON, waitSecondsForElement = 90)
public interface ZPL_OBR001_SmoothPaymentInfo extends WebFlow<ZPL_OBR001_SmoothPaymentInfo>, StoreAccessor {

    String SMOOTH_PAYMENT_ID_KEY = "SMOOTH_PAYMENT_ID";
    String OBR001_S001_PAGE_LABEL_XPATH = "//div[text()='OBR001_S001']";
    String ZPL_PAGE_LABEL_XPATH = "//div[contains(text(), 'ZPL00')]";
    String PAGE_LABEL_DIV = "OBR001_S001_L002";
    String NAME_PAGE = "//div[text()='Instrukce k tisku']";
    String OK_BUTTON = "OBR001_S001_B002";
    String INFO_LABEL = "OBR001_S001_L004";

    @StoreElementContent(storeKey = SMOOTH_PAYMENT_ID_KEY, value = INFO_LABEL)
    ZPL_OBR001_SmoothPaymentInfo storeSmoothPaymentId();

    @Click(OK_BUTTON)
    ZPL006_S002_ListOfForeignPaymentsPage clickOkButton();

    @CheckElementContent(PAGE_LABEL_DIV)
    ZPL_OBR001_SmoothPaymentInfo checkPageLabelContent(String expectedContent);

    @CheckElementContent(INFO_LABEL)
    ZPL_OBR001_SmoothPaymentInfo checkInfoLabelContent(String expectedContent);

}
