Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

data-testid added for submission-details #1820

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ const ApplicationFilter = ({
<button
className="btn btn-link text-danger"
onClick={clearAllFilters}
data-testid="submission-filter-clear-input-button"
data-testid="submission-filter-clear-button"
>
{t("Clear All Filters")}
</button>
Expand All @@ -202,13 +202,15 @@ const ApplicationFilter = ({
<button
className="btn btn-link text-dark me-1 "
onClick={closeFilterModal}
data-testid="submission-filter-close-button"
>
{t("Cancel")}
</button>
<button
className="btn btn-dark"
onClick={applyFilters}
disabled={!isSearchParamEntered}
data-testid="submission-filter-apply-button"
>
{t("Show results")}
</button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ const ViewApplication = React.memo(() => {
return (
<div className="">
<div className="d-flex align-items-center">
<Link title={t("Back to Submissions")} to={`${redirectUrl}application`} className="">
<Link data-testid="back-to-submissions-link" title={t("Back to Submissions")} to={`${redirectUrl}application`} className="">
<i className="fa fa-chevron-left fa-lg me-2" />
</Link>
<h3 className=" text-truncate">
Expand All @@ -101,24 +101,28 @@ const ViewApplication = React.memo(() => {
<br />
<Tabs id="application-details" defaultActiveKey="details" mountOnEnter>
<Tab
data-testid="submissions-details-tab"
eventKey="details"
title={<Translation>{(t) => t("Details")}</Translation>}
>
<Details application={applicationDetail} />
</Tab>
<Tab
data-testid="submissions-form-tab"
eventKey="form"
title={<Translation>{(t) => t("Form")}</Translation>}
>
<View page="application-detail" />
</Tab>
<Tab
data-testid="submissions-history-tab"
eventKey="history"
title={<Translation>{(t) => t("History")}</Translation>}
>
<History page="application-detail" applicationId={applicationId} />
</Tab>
<Tab
data-testid="submissions-process-diagram-tab"
eventKey="process-diagram"
title={<Translation>{(t) => t("Process Diagram")}</Translation>}
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const linkSubmision = (row, redirectUrl) => {
const url = getFormUrl(formId, submissionId, redirectUrl);
return (
<div onClick={() => window.open(url, "_blank")}>
<span className="btn btn-primary btn-sm form-btn">
<span className="btn btn-primary btn-sm form-btn" data-testid="submission-viewsubmission-button" >
<span>
<i className="fa fa-eye" aria-hidden="true"></i>&nbsp;
</span>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export const ExportButton = React.memo(({ buttonState,
const isLoading = buttonState === ButtonState.Loading;
return (
<div className="d-flex justify-content-center">
<InternalButton onClick={onClick} variant="primary" size="sm">
<InternalButton onClick={onClick} variant="primary" size="sm" data-testid="export-pdf-button">
{!isLoading && (
<i className="fa fa-print me-2" aria-hidden="true" />
)}
Expand Down
Loading