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

FI-3285: Add fields to backend services access mode #544

Merged
merged 7 commits into from
Oct 23, 2024

Conversation

AlyssaWang
Copy link
Collaborator

Summary

Updates fields for backend services access mode to display client_id, token_url, and encryption_algorithm.

Testing Guidance

Check that the above fields appear if access token is populated.

Copy link

codecov bot commented Oct 16, 2024

Codecov Report

Attention: Patch coverage is 90.90909% with 1 line in your changes missing coverage. Please review.

Project coverage is 84.07%. Comparing base (b1af368) to head (af1bde5).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
client/src/components/InputsModal/AuthSettings.ts 90.90% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #544      +/-   ##
==========================================
+ Coverage   84.05%   84.07%   +0.02%     
==========================================
  Files         261      261              
  Lines       11396    11386      -10     
  Branches     1255     1251       -4     
==========================================
- Hits         9579     9573       -6     
+ Misses       1807     1803       -4     
  Partials       10       10              
Flag Coverage Δ
backend 92.17% <ø> (ø)
frontend 79.35% <90.90%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@@ -249,7 +249,10 @@ export const getAccessFields = (
title: 'Client ID',
description: 'Client ID provided during registration of Inferno',
optional: true,
hide: !accessValues.get('refresh_token'),
hide:
authType === 'backend_services'
Copy link
Collaborator

Choose a reason for hiding this comment

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

Could you use this logic to just assign 'access_token' or 'refresh_token' to a variable that gets used here rather than repeating the logic for each field?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yep totally works -- updated.

@@ -234,6 +234,11 @@ export const getAccessFields = (
accessValues: Map<string, unknown>,
components: TestInput[],
): TestInput[] => {
const backendServicesHideCondition =
Copy link
Collaborator

Choose a reason for hiding this comment

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

This isn't just for backend services, though, it's for everything, right?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Sort of? I named it that since it stipulates backend_services in the check itself but I think this could be better named regardless -- updated.

@AlyssaWang AlyssaWang merged commit a3c913e into main Oct 23, 2024
10 checks passed
@AlyssaWang AlyssaWang deleted the FI-3285-backend-services-access branch October 23, 2024 14:44
@Shaumik-Ashraf Shaumik-Ashraf mentioned this pull request Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants