Skip to content

Commit

Permalink
more logs and test fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
AndyOHart committed Oct 18, 2024
1 parent 5878d1c commit 5cf3fa7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
7 changes: 0 additions & 7 deletions apps/managedidentity/managedidentity.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,6 @@ func WithHTTPClient(httpClient ops.HTTPClient) ClientOption {
// Options: [WithHTTPClient]
func New(id ID, options ...ClientOption) (Client, error) {
source, err := GetSource(id)
println("source: " + source)
if err != nil {
return Client{}, err
}
Expand Down Expand Up @@ -205,12 +204,6 @@ func GetSource(id ID) (Source, error) {
msiEndpoint := os.Getenv(msiEndpointEnvVar)
imdsEndpoint := os.Getenv(imdsEndVar)

println("identityEndpoint: " + identityEndpoint)
println("identityHeader: " + identityHeader)
println("identityServerThumbprint: " + identityServerThumbprint)
println("msiEndpoint: " + msiEndpoint)
println("imdsEndpoint: " + imdsEndpoint)

if identityEndpoint != "" && identityHeader != "" {
if identityServerThumbprint != "" {
return ServiceFabric, nil
Expand Down
4 changes: 4 additions & 0 deletions apps/managedidentity/managedidentity_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,10 @@ func Test_SystemAssigned_Returns_AcquireToken_Failure(t *testing.T) {

for _, testCase := range testCases {
t.Run(http.StatusText(testCase.code), func(t *testing.T) {
unsetEnvVars(t)
restoreFunc := setCustomAzureArcFilePath("fake/fake")
defer restoreFunc()

fakeErrorClient := mock.Client{}
responseBody, err := makeResponseWithErrorData(testCase.err, testCase.desc)
if err != nil {
Expand Down

0 comments on commit 5cf3fa7

Please sign in to comment.