Skip to content

Commit

Permalink
scalafmt
Browse files Browse the repository at this point in the history
  • Loading branch information
bennettn4 committed Dec 10, 2024
1 parent a4bca69 commit f9e8de5
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -199,12 +199,12 @@ object AppConfig {
}

implicit val azureEnvironmentConfigReader: ValueReader[Option[AzureEnvironment]] = new ValueReader[Option[AzureEnvironment]] {
def read(config: Config, path: String): Option[AzureEnvironment] = {
def read(config: Config, path: String): Option[AzureEnvironment] =
if (config.hasPath(path)) {
val azureEnvironment: String = config.getString(path)
val Azure: String = "AZURE"
val AzureGov: String = "AZURE_GOV"

azureEnvironment match {
case AzureGov => Some(AzureEnvironment.AZURE_US_GOVERNMENT)
case Azure => Some(AzureEnvironment.AZURE)
Expand All @@ -213,7 +213,6 @@ object AppConfig {
} else {
None
}
}

}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ case class AzureServicePrincipalConfig(
tenantId: String
)


case class AzureServicesConfig(
managedAppWorkloadClientId: Option[String],
managedAppServicePrincipal: Option[AzureServicePrincipalConfig],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,15 @@ import org.broadinstitute.dsde.workbench.oauth2.mock.FakeOpenIDConnectConfigurat
import org.broadinstitute.dsde.workbench.sam.TestSupport.samRequestContext
import org.broadinstitute.dsde.workbench.sam.azure.{AzureService, CrlService, MockCrlService}
import org.broadinstitute.dsde.workbench.sam.config.AppConfig.AdminConfig
import org.broadinstitute.dsde.workbench.sam.config.{AppConfig, AzureMarketPlace, AzureServiceCatalog, AzureServicePrincipalConfig, AzureServicesConfig, LiquibaseConfig, TermsOfServiceConfig}
import org.broadinstitute.dsde.workbench.sam.config.{
AppConfig,
AzureMarketPlace,
AzureServiceCatalog,
AzureServicePrincipalConfig,
AzureServicesConfig,
LiquibaseConfig,
TermsOfServiceConfig
}
import org.broadinstitute.dsde.workbench.sam.dataAccess._
import org.broadinstitute.dsde.workbench.sam.model.SamResourceActions.{adminAddMember, adminReadPolicies, adminRemoveMember}
import org.broadinstitute.dsde.workbench.sam.model._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class CreateUserSpec extends UserServiceTestTraits {
cloudExtensions,
Seq.empty,
defaultTosService,
Some(AzureServicesConfig(None, None, None, None, allowManagedIdentityUserCreation = true,azureEnvironment = AzureEnvironment.AZURE))
Some(AzureServicesConfig(None, None, None, None, allowManagedIdentityUserCreation = true, azureEnvironment = AzureEnvironment.AZURE))
)

// Act
Expand Down Expand Up @@ -296,7 +296,7 @@ class CreateUserSpec extends UserServiceTestTraits {
cloudExtensions,
Seq.empty,
defaultTosService,
Some(AzureServicesConfig(None, None, None, None, allowManagedIdentityUserCreation = false,azureEnvironment = AzureEnvironment.AZURE))
Some(AzureServicesConfig(None, None, None, None, allowManagedIdentityUserCreation = false, azureEnvironment = AzureEnvironment.AZURE))
)

// Act and Assert
Expand Down

0 comments on commit f9e8de5

Please sign in to comment.