METHOD_0 ( ) { com . cloud . IDENT_0 . api . IDENT_1 . IDENT_2 IDENT_3 = mock ( com . cloud . IDENT_0 . api . IDENT_1 . IDENT_2 . class ) ; when ( IDENT_3 . METHOD_1 ( ) ) . thenReturn ( true ) ; com . cloud . IDENT_4 . IDENT_5 IDENT_6 = mock ( com . cloud . IDENT_4 . IDENT_5 . class ) ; long IDENT_7 = 1L ; com . cloud . IDENT_0 . manager . IDENT_8 IDENT_9 = mock ( com . cloud . IDENT_0 . manager . IDENT_8 . class ) ; when ( IDENT_9 . METHOD_2 ( STRING_0 ) ) . thenReturn ( IDENT_3 ) ; com . cloud . IDENT_4 . IDENT_10 context = mock ( com . cloud . IDENT_4 . IDENT_10 . class ) ; boolean expected = true ; boolean actual = IDENT_11 . METHOD_3 ( IDENT_6 , IDENT_7 , IDENT_9 , context ) ; "<AssertPlaceHolder>" ; } METHOD_3 ( com . cloud . IDENT_4 . IDENT_5 , long , com . cloud . IDENT_0 . manager . IDENT_8 , com . cloud . IDENT_4 . IDENT_10 ) { com . cloud . IDENT_0 . api . IDENT_1 . IDENT_2 IDENT_12 = ( ( com . cloud . IDENT_0 . api . IDENT_1 . IDENT_2 ) ( IDENT_9 . METHOD_2 ( STRING_0 ) ) ) ; if ( ! ( IDENT_12 . METHOD_1 ( ) ) ) { org . apache . IDENT_13 . IDENT_14 . IDENT_15 . IDENT_16 . warn ( ( STRING_1 + ( IDENT_12 . METHOD_4 ( ) ) ) ) ; return false ; } try { IDENT_17 . METHOD_5 ( IDENT_18 . METHOD_6 ( ) , false ) ; com . cloud . network . dao . IDENT_19 IDENT_20 = IDENT_21 . METHOD_7 ( IDENT_18 . METHOD_6 ( ) . getId ( ) ) ; if ( ( IDENT_20 != null ) && ( IDENT_20 . METHOD_8 ( ) ) ) { com . cloud . IDENT_4 . IDENT_22 IDENT_23 = IDENT_24 . METHOD_9 ( IDENT_18 . getId ( ) ) ; IDENT_23 . METHOD_10 ( IDENT_20 . METHOD_11 ( ) . METHOD_12 ( ) ) ; IDENT_24 . update ( IDENT_23 . getId ( ) , IDENT_23 ) ; } } catch ( java . lang . Exception ex ) { org . apache . IDENT_13 . IDENT_14 . IDENT_15 . IDENT_16 . warn ( ( ( STRING_2 + ( IDENT_18 . METHOD_6 ( ) ) ) + STRING_3 ) , ex ) ; return false ; } return true ; }
org . junit . Assert . assertEquals ( expected , actual )