Skip to content

Commit

Permalink
CCM-6833: Add place holder stage to auth
Browse files Browse the repository at this point in the history
  • Loading branch information
m-salaudeen committed Oct 15, 2024
1 parent bf5d925 commit 0a9bd0c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/__tests__/components/Header.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ describe('Header component', () => {
});

it('should not render login link', () => {
process.env.FEATURE_VISIBILITY_TESTING = 'on';
process.env.NEXT_PUBLIC_FEATURE_VISIBILITY_TESTING = 'on';
render(<NHSNotifyHeader />);

expect(screen.queryByTestId('login-link')).not.toBeInTheDocument();
Expand Down
2 changes: 1 addition & 1 deletion src/components/layouts/container/container.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export async function NHSNotifyContainer({
return (
<div className='nhsuk-width-container'>
<main className='nhsuk-main-wrapper nhsuk-u-padding-top-4' role='main'>
{process.env.FEATURE_VISIBILITY_TESTING === 'on' ? (
{process.env.NEXT_PUBLIC_FEATURE_VISIBILITY_TESTING === 'on' ? (
<h1>Coming soon</h1>
) : (
children
Expand Down
5 changes: 3 additions & 2 deletions src/components/molecules/Header/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export function NHSNotifyHeader({ className, dataTestId }: HeaderType) {
<Link
className='nhsuk-header__link nhsuk-header__link--service'
href={
process.env.FEATURE_VISIBILITY_TESTING === 'on'
process.env.NEXT_PUBLIC_FEATURE_VISIBILITY_TESTING === 'on'
? '/'
: '/create-and-submit-templates'
}
Expand Down Expand Up @@ -55,7 +55,8 @@ export function NHSNotifyHeader({ className, dataTestId }: HeaderType) {
id='content-header'
>
{/* I am currently testing the link wrapper, this will change later when we implement auth as the link will change based on auth state */}
{process.env.FEATURE_VISIBILITY_TESTING === 'on' ? undefined : (
{process.env.NEXT_PUBLIC_FEATURE_VISIBILITY_TESTING ===
'on' ? undefined : (
<div className='nhsuk-account__login' data-testid='login-link'>
<Link className='nhsuk-account__login--link' href='/'>
{content.components.headerComponent.links.logIn}
Expand Down

0 comments on commit 0a9bd0c

Please sign in to comment.