declare namespace Cypress {
  interface Chainable {
    login(username?: string, password?: string): Chainable<void>;
    logout(): Chainable<void>;
    getByTestId(testId: string): Chainable<JQuery<HTMLElement>>;
    waitForLoading(): Chainable<void>;

    // Discount codes helper methods
    navigateToCreateDiscount(): Chainable<void>;
    fillBasicDiscountInfo(data: any): Chainable<void>;
    fillDiscountSettings(data: any): Chainable<void>;
    fillUserRestrictions(data: any): Chainable<void>;
    submitDiscountForm(): Chainable<void>;
    verifyDiscountCreation(): Chainable<void>;
    createDiscountCode(data: any): Chainable<void>;
    searchDiscountCode(code: string): Chainable<void>;
    clearDiscountFilters(): Chainable<void>;
  }
}
