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

FCRM-5547 Change the AWS repo that fmp-app deploys to #459

Merged
merged 3 commits into from
Jan 27, 2025
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
2 changes: 1 addition & 1 deletion .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
workflow_dispatch:

env:
REPOSITORY: flood_map_planning/app-internal
REPOSITORY: flood_map_planning/app

jobs:
build:
Expand Down
15 changes: 15 additions & 0 deletions server/routes/__tests__/about.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
jest.mock('../../services/external-health-check')
const { submitGetRequest } = require('../../__test-helpers__/server')
const { assertCopy } = require('../../__test-helpers__/copy')
const url = '/about'

describe('About Page', () => {
it('/about page should contain version numbers as expected', async () => {
await submitGetRequest({ url }, 'Flood map for planning')
assertCopy('#fmp-app-version', 'Version: v3.0.0-1')
assertCopy('#fmp-app-revision', 'Revision: 9256171')
assertCopy('#fmp-app-type', 'internal')
assertCopy('#fmp-api-version', 'Version: v8.8.8')
assertCopy('#fmp-api-revision', 'Revision: 9988776')
})
})
4 changes: 3 additions & 1 deletion server/routes/about.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
const { config } = require('../../config')
const { version, revision } = require('../../version')
const externalHealthCheck = require('../services/external-health-check')

Expand All @@ -14,7 +15,8 @@ module.exports = {
const data = {
fmpApp: {
version: version.substring(0, version.lastIndexOf('-')),
revision: revision.substring(0, GIT_REVISION_LENGTH)
revision: revision.substring(0, GIT_REVISION_LENGTH),
appType: config.appType
},
fmpApi
}
Expand Down
3 changes: 3 additions & 0 deletions server/services/__mocks__/external-health-check.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
const getFmpApiVersion = async () => ({ version: 'v8.8.8', revision: '998877665544332211' })

module.exports = { getFmpApiVersion }
1 change: 1 addition & 0 deletions server/views/about.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ <h1 class="govuk-heading-l" tabindex="0">Flood map for planning</h1>
<li class="govuk-heading-m">Application</li>
<li id='fmp-app-version' class="govuk-body govuk-!-padding-left-5">Version: {{fmpApp.version}}</li>
<li id='fmp-app-revision' class="govuk-body govuk-!-padding-left-5">Revision: {{fmpApp.revision}}</li>
<li id='fmp-app-type' class="govuk-body govuk-!-padding-left-5">Type: {{fmpApp.appType}}</li>
<li class="govuk-heading-m">API</li>
<li id='fmp-api-version' class="govuk-body govuk-!-padding-left-5">Version: {{fmpApi.version}}</li>
<li id='fmp-api-revision' class="govuk-body govuk-!-padding-left-5">Revision: {{fmpApi.revision}}</li>
Expand Down
45 changes: 0 additions & 45 deletions test/routes/about.js

This file was deleted.

Loading