示例#1
0
            public static TestConfig ForFirebaseAuth()
            {
                var authBuilder = new AuthBuilder
                {
                    Signer = JwtTestUtils.DefaultSigner,
                };
                var tokenVerifier = CustomTokenVerifier.ForServiceAccount(
                    JwtTestUtils.DefaultClientEmail, JwtTestUtils.DefaultPublicKey);

                return(new TestConfig(authBuilder, tokenVerifier));
            }
示例#2
0
            internal TestConfig WithEmulator()
            {
                var authBuilder = new AuthBuilder
                {
                    TenantId     = this.TenantId,
                    EmulatorHost = "localhost:9090",
                };
                var tokenVerifier = CustomTokenVerifier.ForEmulator(this.TenantId);

                return(new TestConfig(authBuilder, tokenVerifier));
            }
示例#3
0
            public static TestConfig ForTenantAwareFirebaseAuth(string tenantId)
            {
                var authBuilder = new AuthBuilder
                {
                    TenantId = tenantId,
                    Signer   = JwtTestUtils.DefaultSigner,
                };
                var tokenVerifier = CustomTokenVerifier.ForServiceAccount(
                    JwtTestUtils.DefaultClientEmail, JwtTestUtils.DefaultPublicKey, tenantId);

                return(new TestConfig(authBuilder, tokenVerifier));
            }
示例#4
0
 private TestConfig(AuthBuilder authBuilder, CustomTokenVerifier tokenVerifier)
 {
     this.authBuilder   = authBuilder;
     this.tokenVerifier = tokenVerifier;
 }