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

Add GitHub Enterprise Server support #286

Merged
merged 29 commits into from
Jan 11, 2024

Conversation

vineeththomasalex
Copy link
Contributor

@vineeththomasalex vineeththomasalex commented Nov 27, 2023

Summary of the pull request

This PR contains the following changes:

  • Adds GitHub Enterprise Server (GHES) v3 Support (supported version determined by Octokit)

  • Adds LoginUI page for GHES flow to enter PAT

  • Refactors LoginUIController flow to be more encapsulated into Pages

  • Refactors CredentialVault to allow test configuration

  • Adds Unit Tests for DeveloperID components

  • Adds Functional tests for restoring and using saved credentials for repository query

  • Catches (and logs) a crash during Startup due to bad saved credentials

  • Also, enables multi-user support for widgets (requires Widget UI update in a follow-up PR)

References and relevant issues

microsoft/devhome#825
#235

LoginUI flow for GHES

Untitled video - Made with Clipchamp
Not uploading gif of 2nd page since it has personal info. Please try it out yourself.

Validation steps performed

Ran old and new tests, and manually ran through login flow, widget and setup flow.

PR checklist

  • Closes #xxx
  • [X ] Tests added - Currently fails due to lack of Env variables. Looking into this.
  • Documentation updated

@vineeththomasalex vineeththomasalex self-assigned this Nov 27, 2023
@vineeththomasalex vineeththomasalex added this to the DHGE v0.7 milestone Nov 27, 2023
@vineeththomasalex vineeththomasalex added the Area-Account-Sign-In Related to authenticating your GitHub account or anything related to sign-in label Nov 27, 2023
@krschau krschau removed this from the DHGE v0.7 milestone Nov 27, 2023
@krschau krschau modified the milestones: DHGE v0.9, DHGE v0.10 Jan 8, 2024
src/GitHubExtension/Client/Validation.cs Outdated Show resolved Hide resolved
src/GitHubExtension/DeveloperId/CredentialVault.cs Outdated Show resolved Hide resolved
@vineeththomasalex vineeththomasalex linked an issue Jan 11, 2024 that may be closed by this pull request
@vineeththomasalex vineeththomasalex dismissed jamespik’s stale review January 11, 2024 21:51

Received permission to dismiss review from Jamespik

@vineeththomasalex vineeththomasalex merged commit 82ae898 into main Jan 11, 2024
4 checks passed
EricJohnson327 pushed a commit that referenced this pull request Jan 18, 2024
* Explicitly disallow multiple accounts on GitHub extension

* Fix constructor bug

* Tested GHES

* Stashing

* Basic flow works

* Validation added

* Minor updates

* Minor Widget update

* SearchManager minor update

* Fixed LoginUI

* Created separate states for pages

* Added CredentialVault Tests

* Added LoginUI tests

* Added some tests

* Reverted Widget updates

* Fixed tests

* Revert changes to allow multi-user for tests

* PR Comments 1

* PR comments 2

* Ignore some tests in pipeline

* PR Comments 3

* PR Comments 4

* Minor update

* PR comments 6

* PR Comments 7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Account-Sign-In Related to authenticating your GitHub account or anything related to sign-in
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Extension requires too much OAuth permissions Dev Home GitHub extension should support Enterprise accounts
8 participants