package cz.moneta.test.regression.channels.branch.archive;

import cz.moneta.dataprepare.CustomerDataPrepare;
import cz.moneta.test.dsl.Harness;
import cz.moneta.test.dsl.ufo.banka.tasks.BankaTasks;
import cz.moneta.test.harness.annotations.JiraTestCase;
import cz.moneta.test.harness.annotations.TestCase;
import cz.moneta.test.harness.annotations.TestScenario;
import org.junit.jupiter.api.Disabled;

import static cz.moneta.test.harness.annotations.Environment.EDU;
import static cz.moneta.test.harness.annotations.Environment.PPE;
import static cz.moneta.test.harness.annotations.Environment.TST1;

@Disabled
@TestScenario(name = "Teller must be able to create new insurance")
public class CreateNewCustomerWithInsurance extends CustomerDataPrepare {

    @TestCase(name = "Teller must be able to create new group insurance", environments = {TST1, PPE, EDU})
    @JiraTestCase(id = "POB-T19522")
    public void create_new_group_insurance(Harness harness) {
        String feePlan = "Tom Plus";
        BankaTasks bankaTasks = harness.tasks().ufo().banka();

        harness.withUfo()
                .openLoginPage()
                .then(bankaTasks.login().withCredentialsAndTurnOffSignpad(credentials))
                .then(bankaTasks.search().findByCif(newCustomerCif))
                .then(bankaTasks.newProduct().createNewCurrentAccount(feePlan))
                .then(bankaTasks.newProduct().createNewGroupInsurance("Pojištění cenností, karet, elektroniky a telefonu"));
    }
}
