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

Release v0.5.0.beta.1 (sprint 35) #1546

Merged
merged 64 commits into from
Jul 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
64 commits
Select commit Hold shift + click to select a range
1250207
PXBF-1453-content-translations-zero-ben: updated english content valu…
scottqueen-bixal Jun 27, 2024
cdb9137
PXBF-1453-content-translations-zero-ben: include translation values f…
scottqueen-bixal Jun 27, 2024
b079fc6
PXBF-1514-update-result-view-value: new appended value for bf-resultview
scottqueen-bixal Jul 1, 2024
9086834
PXBF-1514-update-result-view-value: toggle page view value based on n…
scottqueen-bixal Jul 1, 2024
56327ea
PXBF-1514-update-result-view-value: update cypress test to accept ind…
scottqueen-bixal Jul 1, 2024
76a7b71
PXBF-1514-update-result-view-value: update dataLayer index
scottqueen-bixal Jul 1, 2024
45cf204
PXBF-1516-update-benefit-event-values: update benefitClick to benefit…
scottqueen-bixal Jul 1, 2024
accf048
PXBF-1516-update-benefit-event-values: update event values to undersc…
scottqueen-bixal Jul 1, 2024
1f537da
PXBF-1516-update-benefit-event-values: allow overide of dedup
scottqueen-bixal Jul 1, 2024
3de1b50
PXBF-1516-new-event-open-all-accordions: new gtm event to track open …
scottqueen-bixal Jul 1, 2024
9707039
PXBF-1516-new-event-open-all-accordions: default datalayer accodionsO…
scottqueen-bixal Jul 1, 2024
8511b89
PXBF-1516-new-event-open-all-accordions: new open all benefits struct…
scottqueen-bixal Jul 1, 2024
d5338b6
PXBF-1516-new-event-open-all-accordions: include dedup logic
scottqueen-bixal Jul 1, 2024
867b245
PXBF-1516-new-event-open-all-accordions: new push event handler on ex…
scottqueen-bixal Jul 1, 2024
373166a
PXBF-1392-handle-codes-prod-link-test: remove old prod config
scottqueen-bixal Jul 1, 2024
f2829eb
PXBF-1392-handle-codes-prod-link-test: update prod links test to use …
scottqueen-bixal Jul 1, 2024
64b155e
PXBF-1392-handle-codes-prod-link-test: update node scrit to use prod …
scottqueen-bixal Jul 1, 2024
f6deaea
PXBF-1392-handle-codes-prod-link-test: refactor code to structure loc…
scottqueen-bixal Jul 1, 2024
61d7e08
PXBF-1392-handle-codes-prod-link-test: set up negative validations be…
scottqueen-bixal Jul 1, 2024
dcaf388
PXBF-1392-handle-codes-prod-link-test: only ignore errors when meanin…
scottqueen-bixal Jul 1, 2024
e7061a4
PXBF-1392-handle-codes-prod-link-test: remove log
scottqueen-bixal Jul 2, 2024
5d092dd
Merge pull request #1508 from GSA/1453-content-translations-zero-ben
scottqueen-bixal Jul 2, 2024
533fa92
Merge pull request #1518 from GSA/1514-update-result-view-value
scottqueen-bixal Jul 2, 2024
5c17cfd
Merge pull request #1519 from GSA/1516-update-benefit-event-values
scottqueen-bixal Jul 2, 2024
450e172
PXBF-1516-new-event-open-all-accordions: Merge branch 'dev' of github…
scottqueen-bixal Jul 2, 2024
1364b69
PXBF-1516-new-event-open-all-accordions: remove wait values in open a…
scottqueen-bixal Jul 2, 2024
b5da2d1
Merge pull request #1526 from GSA/1392-handle-codes-prod-link-test
scottqueen-bixal Jul 2, 2024
0b8cfb8
Update thog, add some features
Jul 2, 2024
d983cf5
Update thog, add some features 2
Jul 2, 2024
c969cd3
Update thog, add some features 3
Jul 2, 2024
cae5b17
Update thog, add some features 4
Jul 2, 2024
f22347f
Update thog, add some features 5
Jul 2, 2024
6ea652d
Update thog, add some features 6
Jul 2, 2024
21a8802
Merge pull request #1520 from GSA/1516-new-event-open-all-accordions
scottqueen-bixal Jul 2, 2024
f8f91ef
Update thog, add some features 7
Jul 2, 2024
e5ae1b4
PXBF-1525-clean-benefit-finder-configuration: remove benefit finder c…
gchi25 Jul 2, 2024
de601a5
Update thog, add some features 8
Jul 2, 2024
a742e66
Update thog, add some features 9
Jul 2, 2024
68c12ab
PXBF-1521-disable-life-event-form-delete-if-used: disable life event …
gchi25 Jul 3, 2024
587b0ea
Split commands
Jul 3, 2024
7b3fc0b
Cleanup
Jul 3, 2024
f5ce70f
Add workflow permissions
Jul 8, 2024
fcc402c
PXBF-1541-remove-deprecated-function: remove deprecated function
gchi25 Jul 9, 2024
c11c513
PXBF-1525-clean-benefit-finder-configuration: Merge branch 'dev' of g…
scottqueen-bixal Jul 9, 2024
acea152
PXBF-1541-remove-deprecated-function: remove checking archived
gchi25 Jul 9, 2024
01d0e82
PXBF-1525-clean-benefit-finder-configuration: recursively remove all …
scottqueen-bixal Jul 9, 2024
0839d51
Merge pull request #1529 from GSA/1525-clean-benefit-finder-configura…
scottqueen-bixal Jul 9, 2024
e62596b
Merge pull request #1531 from GSA/1521-disable-life-event-form-delete…
scottqueen-bixal Jul 9, 2024
5b2dfe3
Merge pull request #1543 from GSA/1541-remove-deprecated-function
scottqueen-bixal Jul 9, 2024
f4c107a
PXBF-1536-1537-1538-datalayer-updates: log error
scottqueen-bixal Jul 10, 2024
c60cb36
PXBF-1536-1537-1538-datalayer-updates: revert back to unhandled
scottqueen-bixal Jul 10, 2024
bd7b31f
PXBF-1536-1537-1538-datalayer-updates: update modal to page change ev…
scottqueen-bixal Jul 10, 2024
b772165
PXBF-1536-1537-1538-datalayer-updates: ignore linting in thest
scottqueen-bixal Jul 10, 2024
4fddaf9
PXBF-1536-1537-1538-datalayer-updates: pass title as prop to dataLaye…
scottqueen-bixal Jul 10, 2024
18717b7
PXBF-1536-1537-1538-datalayer-updates: remove view state from structu…
scottqueen-bixal Jul 10, 2024
bc8e8c6
PXBF-1536-1537-1538-datalayer-updates: move bf_count to page change e…
scottqueen-bixal Jul 10, 2024
4abc3cb
PXBF-1536-1537-1538-datalayer-updates: update benefit count assertion
scottqueen-bixal Jul 10, 2024
6e30457
PXBF-dev: git keep configuration file
scottqueen-bixal Jul 10, 2024
6543cd6
PXBF-1536-1537-1538-datalayer-updates: Merge branch 'dev' of github.c…
scottqueen-bixal Jul 10, 2024
bed36e7
PXBF-1536-1537-1538-datalayer-updates: establish null state, then bui…
scottqueen-bixal Jul 10, 2024
0e0a5aa
PXBF-1536-1537-1538-datalayer-updates: benefit count is now part of p…
scottqueen-bixal Jul 10, 2024
7f3ca7d
PXBF-1536-1537-1538-datalayer-updates: updated snaps
scottqueen-bixal Jul 10, 2024
82c5bc7
PXBF-1536-1537-1538-datalayer-updates: append modal string to viewTitle
scottqueen-bixal Jul 10, 2024
4025201
Merge pull request #1551 from GSA/1536-1537-1538-datalayer-updates
scottqueen-bixal Jul 10, 2024
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
4 changes: 4 additions & 0 deletions .github/workflows/build-and-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ on:
- dev
- main

permissions:
contents: read
packages: write

jobs:
php-lint:
name: PHP Lint
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/database-restore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
PROJECT: "${{ secrets.PROJECT }}"
run: |
echo "BRANCH=$(echo $GITHUB_REF | cut -d'/' -f 3)" >> $GITHUB_ENV
cf start "${PROJECT}-${DATABASE_BACKUP_BASTION_NAME}-${BRANCH}" >/dev/null 2>&1
cf start "${PROJECT}-${DATABASE_BACKUP_BASTION_NAME}-${BRANCH}" #>/dev/null 2>&1
./scripts/pipeline/cloud-gov-wait-for-app-start.sh "${PROJECT}-${DATABASE_BACKUP_BASTION_NAME}-${BRANCH}"
- name: Restore database
shell: bash
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-cypress-prod-links.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
with:
browser: chrome
env: NODE_ENV=test
config-file: cypress.prod.config.js
config-file: cypress.prod.links.config.js
working-directory: benefit-finder

- name: create github issue
Expand Down
29 changes: 0 additions & 29 deletions .github/workflows/thog_scan.yml

This file was deleted.

83 changes: 83 additions & 0 deletions .github/workflows/thog_scan_commit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
name: TruffleHog Scan

on:
push:
branches:
- main
- develop
pull_request:

jobs:
scan:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Install GitHub CLI
run: |
sudo apt-get update
sudo apt-get install -y gh
- name: Authenticate GitHub CLI
env:
GITHUB_TOKEN: ${{ secrets.ADD_TO_PROJECT_PAT }}
run: |
gh auth setup-git
- name: Run TruffleHog scan
id: trufflehog_scan
uses: trufflesecurity/[email protected]
with:
base: ""
head: ${{ github.ref_name }}
extra_args: --only-verified --json --entropy --max-depth=50
continue-on-error: true

- name: Check TruffleHog Results
id: check_results
run: |
if [ -f truffleHogResults.json ]; then
echo "file_exists=true" >> $GITHUB_ENV
else
echo "file_exists=false" >> $GITHUB_ENV
fi
- name: Upload TruffleHog scan results
if: always() && env.file_exists == 'true'
uses: actions/upload-artifact@v3
with:
name: trufflehog-results
path: truffleHogResults.json

- name: Convert JSON to Readable Report
if: always() && env.file_exists == 'true'
run: |
jq -r '.results[] | "File: \(.path)\nCommit: \(.commit)\nDate: \(.date)\nReason: \(.reason)\n---------------------------"' truffleHogResults.json > truffleHogReport.txt
- name: Upload Readable Report
if: always() && env.file_exists == 'true'
uses: actions/upload-artifact@v3
with:
name: trufflehog-readable-report
path: truffleHogReport.txt

- name: Check for findings and create issue
if: failure() && env.file_exists == 'true'
env:
GITHUB_TOKEN: ${{ secrets.ADD_TO_PROJECT_PAT }}
run: |
if jq -e '.results | length > 0' truffleHogResults.json > /dev/null; then
echo "Secrets found. Creating GitHub issue."
gh issue create --title "TruffleHog Scan Results" --body "$(cat truffleHogReport.txt)" --label "bug,security" --assignee "@me"
exit 1
else
echo "No secrets found or no results file."
fi
- name: Fail the job if any secrets are found
if: steps.trufflehog_scan.outcome == 'failure'
run: exit 1
Empty file.
12 changes: 0 additions & 12 deletions benefit-finder/cypress.prod.config.js

This file was deleted.

64 changes: 47 additions & 17 deletions benefit-finder/cypress/e2e/storybook/dataLayer.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { pageObjects } from '../../support/pageObjects'
import * as EN_LOCALE_DATA from '../../../../benefit-finder/src/shared/locales/en/en.json'
import * as BENEFITS_ELIBILITY_DATA from '../../fixtures/benefits-eligibility.json'

const { intro, lifeEventSection, resultsView, benefitCount } =
const { intro, lifeEventSection, resultsView, openAllBenefitAccordions } =
dataLayerUtils.dataLayerStructure

const dataLayerValues = [
Expand All @@ -26,17 +26,17 @@ const dataLayerValues = [
{
event: resultsView.event,
bfData: {
pageView: resultsView.bfData.pageView,
pageView: resultsView.bfData.pageView[0],
viewTitle: 'Your potential benefits',
viewState: resultsView.bfData.viewState[1],
eligibleBenefitCount: { number: 4, string: '4' },
moreInfoBenefitCount: { number: 1, string: '1' },
notEligibleBenefitCount: { number: 25, string: '25' },
},
},
{
event: benefitCount.event,
event: openAllBenefitAccordions.event,
bfData: {
eligible: 4,
moreInfo: 1,
notEligible: 25,
accordionsOpen: openAllBenefitAccordions.bfData.accordionsOpen,
},
},
]
Expand Down Expand Up @@ -120,19 +120,49 @@ describe('Calls to Google Analytics Object', function () {
}
delete ev[0]['gtm.uniqueEventId']

expect(dataLayerValues[2]).to.deep.equal(ev[0])
expect(ev[0]).to.deep.equal(dataLayerValues[2])
})
})
})
})

// // check count event
const evCount = {
...window.dataLayer.filter(
x => x.event === dataLayerValues[3].event
),
}
it('clicking open all on results page has a bf_open_all_accordions event', function () {
const selectedData = BENEFITS_ELIBILITY_DATA.scenario_1_covid.en.param
const scenario = utils.encodeURIFromObject(selectedData)
cy.visit(`${utils.storybookUri}${scenario}`)

delete evCount[0]['gtm.uniqueEventId']
cy.window().then(window => {
assert.isDefined(window.dataLayer, 'window.dataLayer is defined')

expect(dataLayerValues[3]).to.deep.equal(evCount[0])
})
pageObjects
.expandAll()
.click()
.then(() => {
// check last page change event
const ev = {
...window.dataLayer.filter(
x => x?.event === dataLayerValues[3].event
),
}
delete ev[0]['gtm.uniqueEventId']

expect(dataLayerValues[3]).to.deep.equal(ev[0])
})

pageObjects
.expandAll()
.click()
.then(() => {
// check last page change event
const ev = {
...window.dataLayer.filter(
x => x?.event === dataLayerValues[3].event
),
}
// we ignore dedup here so there can be multiple fires
delete ev[1]['gtm.uniqueEventId']

expect(dataLayerValues[4]).to.not.deep.equal(ev[1])
})
})
})
Expand Down
Loading
Loading