METHOD_0 ( ) { java . util . Set < Map . Entry < com . spotify . metrics . core . IDENT_0 , com . IDENT_1 . metrics . IDENT_2 > > IDENT_3 = com . google . common . collect . ImmutableMap . of ( id , IDENT_4 , IDENT_5 , IDENT_6 ) . entrySet ( ) ; final com . spotify . metrics . core . IDENT_7 filter = mock ( com . spotify . metrics . core . IDENT_7 . class ) ; doReturn ( IDENT_3 ) . when ( metrics ) . entrySet ( ) ; doReturn ( true ) . when ( filter ) . matches ( IDENT_5 , IDENT_6 ) ; final java . util . Map < com . spotify . metrics . core . IDENT_0 , com . IDENT_1 . metrics . IDENT_2 > expected = com . google . common . collect . ImmutableMap . of ( IDENT_5 , IDENT_6 ) ; "<AssertPlaceHolder>" ; verify ( metrics ) . entrySet ( ) ; verify ( filter ) . matches ( IDENT_5 , IDENT_6 ) ; } METHOD_1 ( java . lang . Class , com . spotify . metrics . core . IDENT_7 ) { final java . util . IDENT_8 < com . spotify . metrics . core . IDENT_0 , T > metrics = new java . util . IDENT_8 < com . spotify . metrics . core . IDENT_0 , T > ( ) ; for ( final Map . Entry < com . spotify . metrics . core . IDENT_0 , com . IDENT_1 . metrics . IDENT_2 > entry : this . metrics . entrySet ( ) ) { if ( ( IDENT_9 . METHOD_2 ( entry . getValue ( ) ) ) && ( filter . matches ( entry . getKey ( ) , entry . getValue ( ) ) ) ) { metrics . put ( entry . getKey ( ) , ( ( T ) ( entry . getValue ( ) ) ) ) ; } } return java . util . Collections . METHOD_3 ( metrics ) ; }
org . junit . Assert . assertEquals ( expected , registry . METHOD_1 ( com . IDENT_1 . metrics . IDENT_2 . class , filter ) )