METHOD_0 ( ) { org . apache . ambari . server . configuration . Configuration configuration = mock ( org . apache . ambari . server . configuration . Configuration . class ) ; when ( configuration . METHOD_1 ( ) ) . thenReturn ( 100 ) ; org . apache . ambari . server . api . services . IDENT_0 . IDENT_1 IDENT_2 = mock ( org . apache . ambari . server . api . services . IDENT_0 . IDENT_1 . class ) ; org . apache . ambari . server . api . services . IDENT_3 IDENT_4 = mock ( org . apache . ambari . server . api . services . IDENT_3 . class ) ; org . apache . ambari . server . state . IDENT_5 service = mock ( org . apache . ambari . server . state . IDENT_5 . class ) ; when ( IDENT_4 . METHOD_2 ( org . mockito . Mockito . anyString ( ) , org . mockito . Mockito . anyString ( ) , org . mockito . Mockito . anyString ( ) ) ) . thenReturn ( service ) ; when ( service . METHOD_3 ( ) ) . thenReturn ( IDENT_5 . IDENT_6 . IDENT_7 ) ; org . apache . ambari . server . api . services . IDENT_0 . IDENT_8 helper = org . apache . ambari . server . api . services . IDENT_0 . IDENT_9 . METHOD_4 ( configuration , IDENT_2 , IDENT_4 ) ; org . apache . ambari . server . api . services . IDENT_0 . commands . IDENT_10 < org . apache . ambari . server . api . services . IDENT_0 . IDENT_11 . IDENT_12 > command = mock ( org . apache . ambari . server . api . services . IDENT_0 . commands . IDENT_10 . class ) ; org . apache . ambari . server . api . services . IDENT_0 . IDENT_11 . IDENT_12 expected = mock ( org . apache . ambari . server . api . services . IDENT_0 . IDENT_11 . IDENT_12 . class ) ; org . apache . ambari . server . api . services . IDENT_0 . IDENT_13 . IDENT_14 IDENT_15 = org . apache . ambari . server . api . services . IDENT_0 . IDENT_13 . IDENT_14 . IDENT_16 ; org . apache . ambari . server . api . services . IDENT_0 . IDENT_13 request = org . apache . ambari . server . api . services . IDENT_0 . IDENT_13 . IDENT_17 . METHOD_5 ( STRING_0 , STRING_1 ) . METHOD_6 ( IDENT_15 ) . build ( ) ; when ( command . invoke ( request , IDENT_5 . IDENT_6 . IDENT_7 ) ) . thenReturn ( expected ) ; doReturn ( command ) . when ( helper ) . METHOD_7 ( STRING_2 , request ) ; org . apache . ambari . server . api . services . IDENT_0 . IDENT_11 . IDENT_12 response = helper . validate ( request ) ; "<AssertPlaceHolder>" ; } validate ( org . apache . ambari . server . api . services . IDENT_0 . IDENT_13 ) { if ( ( ( ( ( ( ( request . METHOD_8 ( ) ) == null ) || ( request . METHOD_8 ( ) . isEmpty ( ) ) ) || ( ( request . METHOD_9 ( ) ) == null ) ) || ( request . METHOD_9 ( ) . isEmpty ( ) ) ) || ( ( request . METHOD_10 ( ) ) == null ) ) || ( request . METHOD_10 ( ) . isEmpty ( ) ) ) { throw new org . apache . ambari . server . api . services . IDENT_0 . METHOD_11 ( STRING_3 ) ; } }
org . junit . Assert . assertEquals ( expected , response )