METHOD_0 ( ) { org . apache . ambari . server . controller . IDENT_0 IDENT_1 = METHOD_1 ( org . apache . ambari . server . controller . IDENT_0 . class ) ; org . apache . ambari . server . controller . spi . IDENT_2 . Type type = IDENT_2 . Type . IDENT_3 ; org . apache . ambari . server . state . IDENT_4 IDENT_5 = new org . apache . ambari . server . state . METHOD_2 ( ) ; IDENT_5 . METHOD_3 ( IDENT_6 ) ; org . apache . ambari . server . controller . IDENT_7 IDENT_8 = new org . apache . ambari . server . controller . METHOD_4 ( IDENT_5 ) ; expect ( IDENT_1 . METHOD_5 ( org . easymock . EasyMock . METHOD_6 ( ) ) ) . andReturn ( com . google . common . collect . IDENT_9 . of ( IDENT_8 ) ) ; replay ( IDENT_1 ) ; org . apache . ambari . server . controller . spi . IDENT_10 request = org . apache . ambari . server . controller . IDENT_11 . IDENT_12 . METHOD_7 ( IDENT_13 ) ; org . apache . ambari . server . controller . spi . IDENT_14 IDENT_15 = org . apache . ambari . server . controller . internal . IDENT_16 . METHOD_8 ( type , IDENT_1 ) ; java . util . Set < org . apache . ambari . server . controller . spi . IDENT_2 > resources = IDENT_15 . METHOD_9 ( request , null ) ; java . util . Map < java . lang . String , java . lang . String > IDENT_17 = com . google . common . collect . ImmutableMap . < java . lang . String , java . lang . String > builder ( ) . METHOD_10 ( IDENT_18 ) . put ( METHOD_2 . IDENT_19 ) . put ( METHOD_2 . IDENT_20 ) . put ( METHOD_2 . IDENT_21 ) . build ( ) ; org . apache . ambari . server . controller . spi . IDENT_2 expected = new org . apache . ambari . server . controller . internal . METHOD_11 ( type ) ; org . apache . ambari . server . controller . internal . IDENT_22 . METHOD_12 ( expected , IDENT_13 , IDENT_17 , com . google . common . collect . IDENT_9 . of ( IDENT_13 ) ) ; "<AssertPlaceHolder>" ; verify ( IDENT_1 ) ; } of ( java . lang . IDENT_23 ) { java . util . List < org . apache . ambari . server . controller . spi . IDENT_24 > IDENT_25 = new java . util . METHOD_13 ( ) ; for ( org . apache . ambari . server . controller . spi . IDENT_24 IDENT_26 : IDENT_27 ) { if ( IDENT_26 instanceof org . apache . ambari . server . controller . IDENT_26 . IDENT_28 ) { return IDENT_26 ; } else if ( IDENT_26 instanceof org . apache . ambari . server . controller . IDENT_26 . IDENT_29 ) { IDENT_25 . addAll ( java . util . Arrays . asList ( ( ( org . apache . ambari . server . controller . IDENT_26 . IDENT_29 ) ( IDENT_26 ) ) . METHOD_14 ( ) ) ) ; } else { IDENT_25 . add ( IDENT_26 ) ; } } return ( IDENT_25 . size ( ) ) == 1 ? IDENT_25 . get ( 0 ) : new org . apache . ambari . server . controller . IDENT_26 . METHOD_15 ( IDENT_25 . toArray ( new org . apache . ambari . server . controller . spi . IDENT_24 [ IDENT_25 . size ( ) ] ) ) ; }
org . junit . Assert . assertEquals ( com . google . common . collect . IDENT_9 . of ( expected ) , resources )