Skip to content

PO-2391 - #2890

Open
louisbriggs wants to merge 7 commits into
PO-2389from
PO-2391
Open

PO-2391#2890
louisbriggs wants to merge 7 commits into
PO-2389from
PO-2391

Conversation

@louisbriggs

Copy link
Copy Markdown
Contributor

Jira link

See PO-2391

Change description

Added consolidated accounts tab contents to defendant accounts.
Added table to tab to display all consolidated accounts.

Testing done

Verified that the endpoint returns the correct data for the consolidated accounts.
Verified that the table contents are rendered correctly based on mock data.

Security Vulnerability Assessment

CVE Suppression: Are there any CVEs present in the codebase (either newly introduced or pre-existing) that are being intentionally suppressed or ignored by this commit?

  • Yes
  • No

Checklist

  • commit messages are meaningful and follow good commit message guidelines
  • README and other documentation has been updated / added (if needed)
  • tests have been updated / new tests has been added (if needed)
  • Does this PR introduce a breaking change

@louisbriggs louisbriggs self-assigned this Jul 22, 2026
@louisbriggs
louisbriggs marked this pull request as ready for review July 22, 2026 09:24
@louisbriggs
louisbriggs requested a review from a team July 22, 2026 09:24

@Arnabsubedi233 Arnabsubedi233 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@iamfrankiemoran iamfrankiemoran left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor changes

@iamfrankiemoran iamfrankiemoran left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM ✅

*/
export class AccountDetailsConsolidatedAccountsActions {
private static readonly WAIT_MS = 15_000;
private static readonly tab = 'app-fines-acc-defendant-details-consolidated-accounts-tab';

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pop this in a shared locators file in cypress/shared/selectors makes it more maintainable and a single source for the locators!


const log = createScopedLogger('AccountDetailsConsolidatedAccountsActions');

const accountCaptionSelector = 'opal-lib-govuk-heading-with-caption .govuk-caption-l';

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pop this in a shared locators file in cypress/shared/selectors makes it more maintainable and a single source for the locators!

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Selectors in this file ideally need to go in a shared locators file in cypress/shared/selectors makes it more maintainable and a single source for the locators!

Comment on lines +72 to +76
cy.intercept('GET', `/opal-fines-service/defendant-accounts/${accountId}/consolidated-accounts`, {
statusCode: 200,
headers: { ETag: '123' },
body: mockData.consolidated_accounts,
}).as('getConsolidatedAccounts');

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This intercept would be good to have in the defendant account intercepts file, makes it more reusable and maintainable.

Comment on lines +216 to +221
@R1B @JIRA-STORY:PO-2391 @JIRA-EPIC:PO-2332
Scenario: Consolidated account links open the child account At a glance view
Given I am viewing a master account with a consolidated child account
When I go to the Consolidated accounts tab
And I open the first Consolidated accounts link at the At a glance view

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There isn't a clear Then, as in its not clear what is being expected in this test. Something like this may be better:

Given I am viewing a master account with a consolidated child account
When I view the Consolidated accounts tab
Then I can see a table containing the child accounts
When I view the first child account record
Then I am presented with the details of the selected child account

There are also quite a few things being mocked behind the scenes in this test which is fine as we can't actually consolidate accounts yet, may be good just to add some comments that explain that at a high level to anyone reading the test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants