Skip to content

Commit

Permalink
Merge branch 'develop' into doc-site---home-template-update
Browse files Browse the repository at this point in the history
  • Loading branch information
htcollier authored Aug 28, 2024
2 parents 1d7954e + 5ed8a68 commit f70e47c
Show file tree
Hide file tree
Showing 54 changed files with 499 additions and 316 deletions.
12 changes: 6 additions & 6 deletions VAMobile/android/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ GEM
artifactory (3.0.17)
atomos (0.1.3)
aws-eventstream (1.3.0)
aws-partitions (1.966.0)
aws-sdk-core (3.201.5)
aws-partitions (1.968.0)
aws-sdk-core (3.202.0)
aws-eventstream (~> 1, >= 1.3.0)
aws-partitions (~> 1, >= 1.651.0)
aws-sigv4 (~> 1.9)
Expand Down Expand Up @@ -113,7 +113,7 @@ GEM
google-apis-firebaseappdistribution_v1alpha (~> 0.2.0)
fastlane-plugin-slack_bot (1.4.0)
gh_inspector (1.1.3)
google-apis-androidpublisher_v3 (0.69.0)
google-apis-androidpublisher_v3 (0.70.0)
google-apis-core (>= 0.15.0, < 2.a)
google-apis-core (0.15.1)
addressable (~> 2.5, >= 2.5.1)
Expand All @@ -131,12 +131,12 @@ GEM
google-apis-core (>= 0.15.0, < 2.a)
google-apis-playcustomapp_v1 (0.16.0)
google-apis-core (>= 0.15.0, < 2.a)
google-apis-storage_v1 (0.43.0)
google-apis-storage_v1 (0.44.0)
google-apis-core (>= 0.15.0, < 2.a)
google-cloud-core (1.7.1)
google-cloud-env (>= 1.0, < 3.a)
google-cloud-errors (~> 1.0)
google-cloud-env (2.1.1)
google-cloud-env (2.2.0)
faraday (>= 1.0, < 3.a)
google-cloud-errors (1.4.0)
google-cloud-storage (1.52.0)
Expand Down Expand Up @@ -181,7 +181,7 @@ GEM
trailblazer-option (>= 0.1.1, < 0.2.0)
uber (< 0.2.0)
retriable (3.1.2)
rexml (3.3.5)
rexml (3.3.6)
strscan
rouge (2.0.7)
ruby2_keywords (0.0.5)
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
We created a new personalized Home screen. It shows important activity happening with your VA health and benefits. We also made other improvements and fixed a few bugs.
We updated disability compensation claims. We explain the 8-step process for these claims and show what step your claim is on. Additionally, you can now manage your direct deposit information for Post-9/11 GI Bill benefits.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion VAMobile/documentation/docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,14 +56,14 @@ const config = {
plugins: [
'./docusaurus-plugin-react-native-web',
engineeringDocForm('documentation', 'documentation', [
'CHANGELOG.md',
'contributing.md',
'namingConventions.md',
'overview.md',
'releaseProcess.md',
'testing.md',
'versioning.md',
]),
engineeringDocForm('changelog', '', ['CHANGELOG.md']),
engineeringDocForm('assets', 'packages/assets', ['README.md']),
engineeringDocForm('components', 'packages/components', ['README.md']),
engineeringDocForm('linting', 'packages/linting', ['README.md']),
Expand Down
269 changes: 162 additions & 107 deletions VAMobile/documentation/yarn.lock

Large diffs are not rendered by default.

14 changes: 9 additions & 5 deletions VAMobile/e2e/tests/VeteranStatusCard.e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ export async function validateVeteranStatusDesign() {
await expect(element(by.id('veteranStatusDOBTestID'))).toExist()
await expect(element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_DISCLAIMER_TEXT))).toExist()
await expect(element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_DOB_DISABILITY_ERROR_PHONE_TEXT))).toExist()
await expect(element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_DOB_DISABILITY_ERROR_TTY_TEXT))).toExist()
await expect(
element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_DOB_DISABILITY_ERROR_TTY_TEXT)).atIndex(0),
).toExist()
await expect(element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_PERIOD_OF_SERVICE_ERROR_PHONE_TEXT))).toExist()
const veteranStatusCardBranchIcon = await element(by.id('VeteranStatusUSCoastGuardTestID')).takeScreenshot(
'veteranStatusCardBranchIcon',
Expand All @@ -55,6 +57,7 @@ export async function validateVeteranStatusDesign() {

export async function tapPhoneAndTTYLinks() {
it(':android: should tap phone and TTY links', async () => {
await device.disableSynchronization()
await waitFor(element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_DOB_DISABILITY_ERROR_PHONE_TEXT)))
.toBeVisible()
.whileElement(by.id('veteranStatusTestID'))
Expand All @@ -64,16 +67,16 @@ export async function tapPhoneAndTTYLinks() {
await device.takeScreenshot('VeteranStatusDOBorDisabilityErrorPhoneNumber')
await device.launchApp({ newInstance: false })

await waitFor(element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_DOB_DISABILITY_ERROR_TTY_TEXT)))
await waitFor(element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_DOB_DISABILITY_ERROR_TTY_TEXT)).atIndex(0))
.toBeVisible()
.whileElement(by.id('veteranStatusTestID'))
.scroll(200, 'down')
await element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_DOB_DISABILITY_ERROR_TTY_TEXT)).tap()
await element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_DOB_DISABILITY_ERROR_TTY_TEXT)).atIndex(0).tap()
try {
await element(by.text('Dismiss')).tap()
await element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_PERIOD_OF_SERVICE_ERROR_PHONE_TEXT)).tap()
} catch (e) {}
await setTimeout(7000)
await setTimeout(2000)
await device.takeScreenshot('VeteranStatusDOBorDisabilityErrorTTY')
await device.launchApp({ newInstance: false })

Expand All @@ -82,9 +85,10 @@ export async function tapPhoneAndTTYLinks() {
.whileElement(by.id('veteranStatusTestID'))
.scroll(200, 'down')
await element(by.text(VeteranStatusCardConstants.VETERAN_STATUS_PERIOD_OF_SERVICE_ERROR_PHONE_TEXT)).tap()
await setTimeout(7000)
await setTimeout(2000)
await device.takeScreenshot('VeteranStatusPeriodOfServiceErrorPhoneNumber')
await device.launchApp({ newInstance: false })
await device.enableSynchronization()
})
}

Expand Down
6 changes: 3 additions & 3 deletions VAMobile/ios/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ GEM
artifactory (3.0.17)
atomos (0.1.3)
aws-eventstream (1.3.0)
aws-partitions (1.966.0)
aws-sdk-core (3.201.5)
aws-partitions (1.968.0)
aws-sdk-core (3.202.0)
aws-eventstream (~> 1, >= 1.3.0)
aws-partitions (~> 1, >= 1.651.0)
aws-sigv4 (~> 1.9)
Expand Down Expand Up @@ -231,7 +231,7 @@ GEM
trailblazer-option (>= 0.1.1, < 0.2.0)
uber (< 0.2.0)
retriable (3.1.2)
rexml (3.3.5)
rexml (3.3.6)
strscan
rouge (2.0.7)
ruby-macho (2.5.1)
Expand Down
2 changes: 1 addition & 1 deletion VAMobile/ios/fastlane/metadata/en-US/release_notes.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
We created a new personalized Home screen. It shows important activity happening with your VA health and benefits. We also made other improvements and fixed a few bugs.
We updated disability compensation claims. We explain the 8-step process for these claims and show what step your claim is on. Additionally, you can now manage your direct deposit information for Post-9/11 GI Bill benefits.
Binary file modified VAMobile/ios/fastlane/screenshots/en-US/ipadPro129-screen-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified VAMobile/ios/fastlane/screenshots/en-US/ipadPro129-screen-6.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified VAMobile/ios/fastlane/screenshots/en-US/iphone55-screen-6.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified VAMobile/ios/fastlane/screenshots/en-US/iphone67-screen-6.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 6 additions & 5 deletions VAMobile/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"env:test": "./env/env.sh -e staging -d true -t true",
"env:uat": "./env/env.sh -d true -t false",
"env:production": "./env/env.sh -e production -d false -t false",
"postinstall": "yarn prepare",
"postinstall": "yarn prepare && yarn patch-package",
"prepare": "cd .. && husky VAMobile/.husky",
"e2e:ios-build": "yarn run bundle:ios && detox build -c ios",
"e2e:ios-test": "yarn jest:clear && detox test -c ios --cleanup --record-logs all",
Expand Down Expand Up @@ -58,6 +58,7 @@
"jsc-android": "^250231.0.0",
"lottie-react-native": "^5.1.6",
"luxon": "^3.4.4",
"patch-package": "^8.0.0",
"postinstall-postinstall": "^2.1.0",
"react": "18.2.0",
"react-content-loader": "^7.0.0",
Expand All @@ -84,7 +85,7 @@
"react-native-webview": "^13.10.4",
"react-redux": "^9.1.2",
"styled-components": "^5.3.10",
"underscore": "^1.13.6"
"underscore": "^1.13.7"
},
"devDependencies": {
"@babel/core": "^7.24.9",
Expand All @@ -98,7 +99,7 @@
"@react-native/eslint-config": "^0.73.2",
"@react-native/metro-config": "^0.75.1",
"@react-native/typescript-config": "0.74.84",
"@testing-library/jest-dom": "^6.4.8",
"@testing-library/jest-dom": "^6.5.0",
"@testing-library/react-native": "^12.6.0",
"@trivago/prettier-plugin-sort-imports": "^4.3.0",
"@tsconfig/react-native": "^3.0.5",
Expand Down Expand Up @@ -131,13 +132,13 @@
"jest-image-snapshot": "^6.4.0",
"jest-junit": "^16.0.0",
"jest-when": "^3.6.0",
"lint-staged": "^15.2.7",
"lint-staged": "^15.2.9",
"metro-react-native-babel-preset": "^0.77.0",
"prettier": "^3.3.2",
"react-devtools": "^5.2.0",
"react-test-renderer": "^18.2.0",
"redux-mock-store": "^1.5.4",
"ts-jest": "^29.2.4",
"ts-jest": "^29.2.5",
"ts-node": "^10.9.2",
"typescript": "^5.5.4",
"watch": "^1.0.2"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/node_modules/@department-of-veterans-affairs/mobile-component-library/src/components/SegmentedControl/SegmentedControl.tsx b/node_modules/@department-of-veterans-affairs/mobile-component-library/src/components/SegmentedControl/SegmentedControl.tsx
index 4fbcda1..7df6342 100644
--- a/node_modules/@department-of-veterans-affairs/mobile-component-library/src/components/SegmentedControl/SegmentedControl.tsx
+++ b/node_modules/@department-of-veterans-affairs/mobile-component-library/src/components/SegmentedControl/SegmentedControl.tsx
@@ -110,7 +110,7 @@ export const SegmentedControl: FC<SegmentedControlProps> = ({
aria-label={accessibilityLabel}
accessibilityHint={a11yHints ? a11yHints[index] : ''}
accessibilityValue={accessibilityValue}
- role={'tab'}
+ role={'link'}
accessibilityState={{ selected: isSelected }}
style={PressableOpacityStyle()}
testID={testIDs?.[index]}>
2 changes: 1 addition & 1 deletion VAMobile/src/components/BaseListItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ const BaseListItem: FC<BaseListItemProps> = (props) => {
}

// Default role for list item is menuitem
const accessibilityRole = a11yRole || (isSwitchRow ? 'switch' : 'menuitem')
const accessibilityRole = a11yRole || (isSwitchRow ? 'switch' : 'link')

const pressableProps: PressableProps = {
onPress: onOuterPress,
Expand Down
2 changes: 1 addition & 1 deletion VAMobile/src/components/DefaultList.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,6 @@ context('DefaultList', () => {
})

it('calls onPress when item is clicked', () => {
fireEvent.press(screen.getByRole('menuitem', { name: 'another line' }))
fireEvent.press(screen.getByRole('link', { name: 'another line' }))
})
})
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ const PickerList: FC<PickerListProps> = ({ items, title, titleA11yLabel }) => {
decorator,
testId: testIdToUse,
a11yValue,
a11yRole: 'menuitem',
a11yRole: 'link',
a11yState,
}
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ context('VAModalPicker', () => {

render(<VAModalPicker {...props} />)

fireEvent.press(screen.getByRole('spinbutton'))
fireEvent.press(screen.getByRole('button'))
}

describe('when an option is selected', () => {
Expand All @@ -37,15 +37,15 @@ context('VAModalPicker', () => {
})

it('should update selected to the value of that option and select done', () => {
fireEvent.press(screen.getByRole('menuitem', { name: 'Java' }))
fireEvent.press(screen.getByRole('link', { name: 'Java' }))

fireEvent.press(screen.getByRole('button', { name: 'Done' }))

expect(selected).toEqual('java')
})

it('should not update selected to the value of that option and select cancel', async () => {
fireEvent.press(screen.getByRole('menuitem', { name: 'JavaScript2' }))
fireEvent.press(screen.getByRole('link', { name: 'JavaScript2' }))

fireEvent.press(screen.getByRole('button', { name: 'Cancel' }))

Expand All @@ -59,7 +59,7 @@ context('VAModalPicker', () => {
})

it('should render a textview for the label if present', () => {
expect(screen.getByRole('spinbutton', { name: 'Back picker Navigates to the previous page' })).toBeTruthy()
expect(screen.getByRole('button', { name: 'Back picker Navigates to the previous page' })).toBeTruthy()
expect(screen.getAllByText(/Back/).length).toBeGreaterThan(0)
})

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ const VAModalPicker: FC<VAModalPickerProps> = ({

const parentProps: AccessibilityProps = {
...a11yValueProp({ text: generateA11yValue(currentlySelectedOption?.label, isFocused, t) }),
accessibilityRole: 'spinbutton',
accessibilityRole: 'button',
}

const renderSelectionBox = (): ReactElement => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,13 @@ context('RadioGroup', () => {
})

it('initializes correctly', () => {
expect(screen.getAllByRole('radio').length).toEqual(mockOptions.length)
expect(screen.getAllByRole('link').length).toEqual(mockOptions.length)
expect(screen.getAllByLabelText('RadioEmpty').length).toEqual(mockOptions.length - 1)
expect(screen.getAllByLabelText('RadioFilled').length).toEqual(1)
})

it('calls setSelected on press', () => {
fireEvent.press(screen.getByRole('radio', { name: '2 ' }))
fireEvent.press(screen.getByRole('link', { name: '2 ' }))
expect(setSelected).toHaveBeenCalled()
})
})
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ const RadioGroup = <T,>({
: ButtonDecoratorType.RadioEmpty,
onPress: onSelectorChange,
minHeight: 64,
a11yRole: 'radio',
a11yRole: 'link',
a11yState: { selected: selected },
backgroundColor: selected ? 'listActive' : undefined,
testId: `${option.a11yLabel || option.labelKey} ${t('optionOutOfTotal', { count: index + 1, totalOptions: options.length })}`,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ const VASelector: FC<VASelectorProps> = ({
}

const hintProp = a11yHint ? a11yHintProp(a11yHint) : {}
const a11yRole = selectorType === SelectorType.Checkbox ? 'checkbox' : 'radio'
const a11yRole = selectorType === SelectorType.Checkbox ? 'checkbox' : 'link'
const a11yState = selectorType === SelectorType.Checkbox ? { checked: selected } : { selected }
const labelToUse = `${a11yLabel || getTranslation(labelKey, t, labelArgs)} ${error ? t('error', { error }) : ''}`

Expand Down
2 changes: 1 addition & 1 deletion VAMobile/src/components/List.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ context('List', () => {
})

it('should call onPress when one of the buttons has been clicked', () => {
fireEvent.press(screen.getByRole('menuitem', { name: 'Hello' }))
fireEvent.press(screen.getByRole('link', { name: 'Hello' }))
expect(onPressSpy).toBeCalled()
})
})
2 changes: 1 addition & 1 deletion VAMobile/src/components/MessageList.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ context('MessageList', () => {
})

it('should call onPress when one of the buttons has been clicked', () => {
fireEvent.press(screen.getByRole('menuitem', { name: 'another line' }))
fireEvent.press(screen.getByRole('link', { name: 'another line' }))
expect(onPressSpy).toBeCalled()
})

Expand Down
14 changes: 7 additions & 7 deletions VAMobile/src/components/NavigationTabBar.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,38 +50,38 @@ context('NavigationTabBar', () => {
})

it('navigates when tab is pressed', () => {
fireEvent.press(screen.getByRole('tab', { name: 'Home' }))
fireEvent.press(screen.getByRole('link', { name: 'Home' }))
expect(emitSpy).toBeCalled()
})

it('navigates when tab is long pressed', async () => {
await userEvent.longPress(screen.getByRole('tab', { name: 'Benefits' }))
await userEvent.longPress(screen.getByRole('link', { name: 'Benefits' }))
expect(emitSpy).toBeCalled()
})

it('calls nav and emit spies when tab is not focused and defaultPrevented is false', () => {
emitSpy.mockReturnValue({ defaultPrevented: false })
fireEvent.press(screen.getByRole('tab', { name: 'Benefits' }))
fireEvent.press(screen.getByRole('link', { name: 'Benefits' }))
expect(emitSpy).toBeCalled()
expect(mockNavigationSpy).toBeCalled()
})

it('selects correct tab for Home route', () => {
expect(screen.getByRole('tab', { name: 'Home', selected: true })).toBeTruthy()
expect(screen.getByRole('link', { name: 'Home', selected: true })).toBeTruthy()
})

it('selects correct tab for Benefits route', () => {
renderWithRoute(1)
expect(screen.getByRole('tab', { name: 'Benefits', selected: true })).toBeTruthy()
expect(screen.getByRole('link', { name: 'Benefits', selected: true })).toBeTruthy()
})

it('selects correct tab for Health route', () => {
renderWithRoute(2)
expect(screen.getByRole('tab', { name: 'Health', selected: true })).toBeTruthy()
expect(screen.getByRole('link', { name: 'Health', selected: true })).toBeTruthy()
})

it('selects correct tab for Payments route', () => {
renderWithRoute(3)
expect(screen.getByRole('tab', { name: 'Payments', selected: true })).toBeTruthy()
expect(screen.getByRole('link', { name: 'Payments', selected: true })).toBeTruthy()
})
})
2 changes: 1 addition & 1 deletion VAMobile/src/components/NavigationTabBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ const NavigationTabBar: FC<NavigationTabBarProps> = ({ state, navigation, transl
key: route.name,
onPress: (): void => onPress(route as TabBarRoute, isFocused),
onLongPress: (): void => onLongPress(route as TabBarRoute),
accessibilityRole: 'tab',
accessibilityRole: 'link',
accessibilityState: isFocused ? { selected: true } : { selected: false },
accessible: true,
}
Expand Down
Loading

0 comments on commit f70e47c

Please sign in to comment.