Skip to content

Commit

Permalink
fixed linting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
almorbah committed Aug 14, 2024
1 parent fdaa5cf commit 0b80f4a
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 37 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,12 @@ const IndividualClaimHistoryTable = (props) => {
};

const ClaimClosedFragment = (details) => {

let component = null;

switch (details.eventType) {
case 'cancelled':
component = <React.Fragment>
<b>Claim cancelled.</b>
Claim cancelled.
</React.Fragment>;
break;
default:
Expand Down
6 changes: 3 additions & 3 deletions spec/feature/non_comp/individual_claim_history_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -667,7 +667,7 @@
end
end

context "should do expected details to show claim closed" do
context "should do expected details to show claim closed when cancelled" do
before { visit "/decision_reviews/vha/tasks/#{cancelled_claim.tasks[0].id}/history" }

it "Claim Cancelled" do
Expand All @@ -676,12 +676,12 @@
dropdown_filter = page.find(class: "cf-dropdown-filter")

dropdown_filter.find("label", text: "Claim closed (1)", match: :prefer_exact).click

table = page.find("tbody")
expect(table).to have_selector("tr", count: 1)

table_row = table.first("tr")
expect(table_row).to have_content("Claim closed.")
expect(table_row).to have_content("Claim closed")
expect(table_row).to have_content("Claim cancelled.")
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,24 @@
ClaimHistoryService.new(vha_org, task_id: vha_task.id).build_events
end

let(:modificationRequestDetailsObject) do
{
benefitType: "vha",
requestType: nil,
issueModificationRequestWithdrawalDate: nil,
modificationRequestReason: nil,
newDecisionDate: nil,
newIssueDescription: nil,
newIssueType: nil,
removeOriginalIssue: nil,
issueModificationRequestStatus: nil,
requestor: nil,
decider: nil,
decidedAtDate: nil,
decisionReason: nil
}
end

let(:serialized_hash_array) do
[
{
Expand All @@ -60,22 +78,7 @@
issueType: nil,
withdrawalRequestDate: nil
},
modificationRequestDetails:
{
benefitType: "vha",
requestType: nil,
issueModificationRequestWithdrawalDate: nil,
modificationRequestReason: nil,
newDecisionDate: nil,
newIssueDescription: nil,
newIssueType: nil,
removeOriginalIssue: nil,
issueModificationRequestStatus: nil,
requestor: nil,
decider: nil,
decidedAtDate: nil,
decisionReason: nil
}
modificationRequestDetails: modificationRequestDetailsObject
}
},
{
Expand All @@ -96,22 +99,7 @@
issueType: "Other",
withdrawalRequestDate: nil
},
modificationRequestDetails:
{
benefitType: "vha",
requestType: nil,
issueModificationRequestWithdrawalDate: nil,
modificationRequestReason: nil,
newDecisionDate: nil,
newIssueDescription: nil,
newIssueType: nil,
removeOriginalIssue: nil,
issueModificationRequestStatus: nil,
requestor: nil,
decider: nil,
decidedAtDate: nil,
decisionReason: nil
},
modificationRequestDetails: modificationRequestDetailsObject,
eventDate: events[1].event_date,
eventType: :added_issue,
eventUser: "L. Roth",
Expand Down

0 comments on commit 0b80f4a

Please sign in to comment.