Skip to content

Commit 4e5b70d

Browse files
Copilotgavinbarron
andcommitted
Add GovSGCloud sovereign cloud environment
Co-authored-by: gavinbarron <7122716+gavinbarron@users.noreply.github.com>
1 parent ee1df43 commit 4e5b70d

File tree

2 files changed

+19
-4
lines changed

2 files changed

+19
-4
lines changed

src/Authentication/Authentication.Test/Common/GraphSettingsTests.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,8 @@ public void ShouldLoadSettingsFromConfiguredDataStore()
115115

116116
// Assert
117117
Assert.NotNull(loadedEnvironment);
118-
// 6 built-in + 2 user-defined
119-
Assert.Equal(8, settings.Environments.Count());
118+
// 7 built-in + 2 user-defined
119+
Assert.Equal(9, settings.Environments.Count());
120120
Assert.Equal("https://login.MyNewCloud.com", loadedEnvironment.AzureADEndpoint);
121121
Assert.Equal("https://graph.MyNewCloud.com", loadedEnvironment.GraphEndpoint);
122122
Assert.Equal(GraphEnvironmentConstants.EnvironmentType.UserDefined, loadedEnvironment.Type);
@@ -155,8 +155,8 @@ public void ShouldRemoveSettingsFromConfiguredDataStore()
155155

156156
// Assert
157157
Assert.NotEmpty(settingsContent);
158-
// 6 built-in + 1 user-defined
159-
Assert.Equal(7, settings.Environments.Count());
158+
// 7 built-in + 1 user-defined
159+
Assert.Equal(8, settings.Environments.Count());
160160

161161
GraphSession.Reset();
162162
}

src/Authentication/Authentication/GraphEnvironmentConstants.cs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,11 @@ public static class EnvironmentName
4343
/// The German sovereign cloud operated by Delos.
4444
/// </summary>
4545
public const string DelosCloud = "DelosCloud";
46+
47+
/// <summary>
48+
/// The Singapore government sovereign cloud.
49+
/// </summary>
50+
public const string GovSGCloud = "GovSGCloud";
4651
}
4752

4853
/// <summary>
@@ -118,6 +123,16 @@ public static class EnvironmentType
118123
AzureADEndpoint = "https://login.sovcloud-identity.de",
119124
GraphEndpoint = "https://graph.svc.sovcloud.de"
120125
}
126+
},
127+
// Singapore government sovereign cloud endpoints.
128+
{
129+
EnvironmentName.GovSGCloud, new GraphEnvironment
130+
{
131+
Name = EnvironmentName.GovSGCloud,
132+
Type = EnvironmentType.BuiltIn,
133+
AzureADEndpoint = "https://login.sovcloud-identity.sg",
134+
GraphEndpoint = "https://graph.svc.sovcloud.sg"
135+
}
121136
}
122137
};
123138
}

0 commit comments

Comments
 (0)