@@ -53,13 +53,13 @@ public void RendersNothingIfNotAuthorized()
5353 }
5454
5555 [ Fact ]
56- public void RendersNotAuthorizedContentIfNotAuthorized ( )
56+ public void RendersNotAuthorizedIfNotAuthorized ( )
5757 {
5858 // Arrange
5959 var authorizationService = new TestAuthorizationService ( ) ;
6060 var renderer = CreateTestRenderer ( authorizationService ) ;
6161 var rootComponent = WrapInAuthorizeView (
62- notAuthorizedContent :
62+ notAuthorized :
6363 context => builder => builder . AddContent ( 0 , $ "You are not authorized, even though we know you are { context . User . Identity . Name } ") ) ;
6464 rootComponent . AuthenticationState = CreateAuthenticationState ( "Nellie" ) ;
6565
@@ -88,7 +88,7 @@ public void RendersNotAuthorizedContentIfNotAuthorized()
8888 }
8989
9090 [ Fact ]
91- public void RendersNothingIfAuthorizedButNoChildContentOrAuthorizedContentProvided ( )
91+ public void RendersNothingIfAuthorizedButNoChildContentOrAuthorizedProvided ( )
9292 {
9393 // Arrange
9494 var authorizationService = new TestAuthorizationService ( ) ;
@@ -152,14 +152,14 @@ public void RendersChildContentIfAuthorized()
152152 }
153153
154154 [ Fact ]
155- public void RendersAuthorizedContentIfAuthorized ( )
155+ public void RendersAuthorizedIfAuthorized ( )
156156 {
157157 // Arrange
158158 var authorizationService = new TestAuthorizationService ( ) ;
159159 authorizationService . NextResult = AuthorizationResult . Success ( ) ;
160160 var renderer = CreateTestRenderer ( authorizationService ) ;
161161 var rootComponent = WrapInAuthorizeView (
162- authorizedContent : context => builder =>
162+ authorized : context => builder =>
163163 builder . AddContent ( 0 , $ "You are authenticated as { context . User . Identity . Name } ") ) ;
164164 rootComponent . AuthenticationState = CreateAuthenticationState ( "Nellie" ) ;
165165
@@ -235,13 +235,13 @@ public void RespondsToChangeInAuthorizationState()
235235 }
236236
237237 [ Fact ]
238- public void ThrowsIfBothChildContentAndAuthorizedContentProvided ( )
238+ public void ThrowsIfBothChildContentAndAuthorizedProvided ( )
239239 {
240240 // Arrange
241241 var authorizationService = new TestAuthorizationService ( ) ;
242242 var renderer = CreateTestRenderer ( authorizationService ) ;
243243 var rootComponent = WrapInAuthorizeView (
244- authorizedContent : context => builder => { } ,
244+ authorized : context => builder => { } ,
245245 childContent : context => builder => { } ) ;
246246
247247 // Act/Assert
@@ -260,7 +260,7 @@ public void RendersNothingUntilAuthorizationCompleted()
260260 var renderer = CreateTestRenderer ( authorizationService ) ;
261261 renderer . OnUpdateDisplayComplete = ( ) => { @event . Set ( ) ; } ;
262262 var rootComponent = WrapInAuthorizeView (
263- notAuthorizedContent :
263+ notAuthorized :
264264 context => builder => builder . AddContent ( 0 , "You are not authorized" ) ) ;
265265 var authTcs = new TaskCompletionSource < AuthenticationState > ( ) ;
266266 rootComponent . AuthenticationState = authTcs . Task ;
@@ -293,7 +293,7 @@ public void RendersNothingUntilAuthorizationCompleted()
293293 }
294294
295295 [ Fact ]
296- public void RendersAuthorizingContentUntilAuthorizationCompleted ( )
296+ public void RendersAuthorizingUntilAuthorizationCompleted ( )
297297 {
298298 // Arrange
299299 var @event = new ManualResetEventSlim ( ) ;
@@ -302,8 +302,8 @@ public void RendersAuthorizingContentUntilAuthorizationCompleted()
302302 var renderer = CreateTestRenderer ( authorizationService ) ;
303303 renderer . OnUpdateDisplayComplete = ( ) => { @event . Set ( ) ; } ;
304304 var rootComponent = WrapInAuthorizeView (
305- authorizingContent : builder => builder . AddContent ( 0 , "Auth pending..." ) ,
306- authorizedContent : context => builder => builder . AddContent ( 0 , $ "Hello, { context . User . Identity . Name } !") ) ;
305+ authorizing : builder => builder . AddContent ( 0 , "Auth pending..." ) ,
306+ authorized : context => builder => builder . AddContent ( 0 , $ "Hello, { context . User . Identity . Name } !") ) ;
307307 var authTcs = new TaskCompletionSource < AuthenticationState > ( ) ;
308308 rootComponent . AuthenticationState = authTcs . Task ;
309309
@@ -447,9 +447,9 @@ public void RejectsNonemptyScheme()
447447
448448 private static TestAuthStateProviderComponent WrapInAuthorizeView (
449449 RenderFragment < AuthenticationState > childContent = null ,
450- RenderFragment < AuthenticationState > authorizedContent = null ,
451- RenderFragment < AuthenticationState > notAuthorizedContent = null ,
452- RenderFragment authorizingContent = null ,
450+ RenderFragment < AuthenticationState > authorized = null ,
451+ RenderFragment < AuthenticationState > notAuthorized = null ,
452+ RenderFragment authorizing = null ,
453453 string policy = null ,
454454 string roles = null ,
455455 object resource = null )
@@ -458,9 +458,9 @@ private static TestAuthStateProviderComponent WrapInAuthorizeView(
458458 {
459459 builder . OpenComponent < AuthorizeView > ( 0 ) ;
460460 builder . AddAttribute ( 1 , nameof ( AuthorizeView . ChildContent ) , childContent ) ;
461- builder . AddAttribute ( 2 , nameof ( AuthorizeView . Authorized ) , authorizedContent ) ;
462- builder . AddAttribute ( 3 , nameof ( AuthorizeView . NotAuthorized ) , notAuthorizedContent ) ;
463- builder . AddAttribute ( 4 , nameof ( AuthorizeView . Authorizing ) , authorizingContent ) ;
461+ builder . AddAttribute ( 2 , nameof ( AuthorizeView . Authorized ) , authorized ) ;
462+ builder . AddAttribute ( 3 , nameof ( AuthorizeView . NotAuthorized ) , notAuthorized ) ;
463+ builder . AddAttribute ( 4 , nameof ( AuthorizeView . Authorizing ) , authorizing ) ;
464464 builder . AddAttribute ( 5 , nameof ( AuthorizeView . Policy ) , policy ) ;
465465 builder . AddAttribute ( 6 , nameof ( AuthorizeView . Roles ) , roles ) ;
466466 builder . AddAttribute ( 7 , nameof ( AuthorizeView . Resource ) , resource ) ;
0 commit comments