Skip to content

Commit 6ab15da

Browse files
committed
Responding to review feedback
1 parent 3a831aa commit 6ab15da

File tree

3 files changed

+9
-6
lines changed

3 files changed

+9
-6
lines changed

src/Common/Commands.Common.Authentication.Test/AzureRMProfileTests.cs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ public void ProfileSerializeDeserializeWorks()
3131
{
3232
var dataStore = new MockDataStore();
3333
AzureSession.DataStore = dataStore;
34-
var currentProfile = new AzureRMProfile(Path.Combine(AzureSession.ProfileDirectory, AzureSession.ProfileFile));
34+
var profilePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, AzureSession.ProfileFile);
35+
var currentProfile = new AzureRMProfile(profilePath);
3536
var tenantId = Guid.NewGuid().ToString();
3637
var environment = new AzureEnvironment
3738
{
@@ -128,7 +129,7 @@ public void SavingProfileWorks()
128129
""TokenCache"": ""AQIDBAUGCAkA""
129130
}
130131
}";
131-
string path = Path.Combine(AzureSession.ProfileDirectory, AzureSession.ProfileFile);
132+
var path = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, AzureSession.ProfileFile);
132133
var dataStore = new MockDataStore();
133134
AzureSession.DataStore = dataStore;
134135
AzureRMProfile profile = new AzureRMProfile(path);
@@ -211,7 +212,7 @@ public void LoadingProfileWorks()
211212
}
212213
}
213214
}";
214-
string path = Path.Combine(AzureSession.ProfileDirectory, AzureSession.ProfileFile);
215+
var path = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, AzureSession.ProfileFile);
215216
var dataStore = new MockDataStore();
216217
AzureSession.DataStore = dataStore;
217218
dataStore.WriteFile(path, contents);

src/Common/Commands.Common.Authentication.Test/AzureSMProfileTests.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ public class AzureSMProfileTests
3232
public void ProfileSaveDoesNotSerializeContext()
3333
{
3434
var dataStore = new MockDataStore();
35-
var profile = new AzureSMProfile(Path.Combine(AzureSession.ProfileDirectory, AzureSession.ProfileFile));
35+
var profilePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, AzureSession.ProfileFile);
36+
var profile = new AzureSMProfile(profilePath);
3637
AzureSession.DataStore = dataStore;
3738
var tenant = Guid.NewGuid().ToString();
3839
var environment = new AzureEnvironment
@@ -82,7 +83,8 @@ public void ProfileSaveDoesNotSerializeContext()
8283
public void ProfileSerializeDeserializeWorks()
8384
{
8485
var dataStore = new MockDataStore();
85-
var profile = new AzureSMProfile(Path.Combine(AzureSession.ProfileDirectory, AzureSession.ProfileFile));
86+
var profilePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, AzureSession.ProfileFile);
87+
var profile = new AzureSMProfile(profilePath);
8688
AzureSession.DataStore = dataStore;
8789
var tenant = Guid.NewGuid().ToString();
8890
var environment = new AzureEnvironment

src/Common/Commands.Common.Authentication.Test/ConversionUtilitiesTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ public class ConversionUtilitiesTests
2323
{
2424
[Fact]
2525
[Trait(Category.AcceptanceType, Category.CheckIn)]
26-
public void DeserializeJsonWorksForSimpleCases()
26+
public void DeserializeJsonWorksForSimpleCases()
2727
{
2828
const string json1 =
2929
@"{

0 commit comments

Comments
 (0)