input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
testMetaDirect ( ) { loghub . Event ev = RunEtl ( "[#a]<sp>=<sp>1" , ( i ) -> { } ) ; "<AssertPlaceHolder>" ; } getMeta ( java . lang . String ) { return metas . get ( key ) ; } | org . junit . Assert . assertEquals ( 1 , ev . getMeta ( "a" ) ) |
can_set_variable_with_default_in_array ( ) { environmentProvider . put ( "ARRAY_2" , "5" ) ; de . thomaskrille . dropwizard . environment_configuration . TestConfiguration testConfiguration = environmentConfigurationFactory . build ( new java . io . File ( "src/test/resources/config.yaml" ) ) ; "<AssertPlaceHolder>" ; ... | org . junit . Assert . assertThat ( testConfiguration . array . get ( 2 ) , org . hamcrest . CoreMatchers . is ( org . hamcrest . CoreMatchers . equalTo ( "5" ) ) ) |
testGetBuilderIdempotent ( ) { org . apache . olingo . odata2 . jpa . processor . api . access . JPAEdmBuilder builder1 = org . apache . olingo . odata2 . jpa . processor . core . model . JPAEdmReferentialConstraintTest . objJPAEdmReferentialConstraint . getBuilder ( ) ; org . apache . olingo . odata2 . jpa . processor... | org . junit . Assert . assertEquals ( builder1 . hashCode ( ) , builder2 . hashCode ( ) ) |
testBareJID ( ) { final org . xmpp . packet . JID fullJID = new org . xmpp . packet . JID ( org . xmpp . packet . JIDCreationNodeTest . NODE , org . xmpp . packet . JIDCreationNodeTest . DOMAIN , null ) ; final java . lang . String bareJID = fullJID . toBareJID ( ) ; "<AssertPlaceHolder>" ; } toBareJID ( ) { final java... | org . junit . Assert . assertEquals ( ( ( ( org . xmpp . packet . JIDCreationNodeTest . NODE ) + '@' ) + ( org . xmpp . packet . JIDCreationNodeTest . DOMAIN ) ) , bareJID ) |
testInTopK ( ) { for ( int k = 4 ; k >= 1 ; k -- ) { log . info ( ( "Testing:<sp>k=" + k ) ) ; org . nd4j . linalg . api . ndarray . INDArray in = org . nd4j . linalg . factory . Nd4j . linspace ( 1 , 20 , 20 , DataType . DOUBLE ) . reshape ( 4 , 5 ) ; org . nd4j . linalg . api . ndarray . INDArray idxs = org . nd4j . ... | org . junit . Assert . assertNull ( err ) |
testConvertPassToHashTest_unknownAlg_assertException ( ) { final java . lang . String password = "password" ; org . nhindirect . common . rest . auth . impl . HashableBasicAuthValidator validator = new org . nhindirect . common . rest . auth . impl . HashableBasicAuthValidator ( ) ; HashableBasicAuthValidator . DIGEST_... | org . junit . Assert . assertTrue ( exceptionOccured ) |
shouldPassOnNbLinesHeaderParameter_TDP_5925 ( ) { java . lang . String str = "1;2;3;4;5;6\n" + ( "1;John;Lennon;40;10/09/1940;false\n" + "2;David;Bowie;67;01/08/1947;true\n" ) ; try ( java . io . InputStream inputStream = new java . io . ByteArrayInputStream ( str . getBytes ( ) ) ) { org . talend . dataprep . schema .... | org . junit . Assert . assertEquals ( 0 , actual ) |
ensureFontIsMaintainedAfterBackgroundPainterSet ( ) { java . awt . Font font = java . awt . Font . decode ( "Arial-BOLDITALIC-14" ) ; org . junit . Assume . assumeThat ( button . getFont ( ) , org . hamcrest . CoreMatchers . is ( org . hamcrest . CoreMatchers . not ( font ) ) ) ; button . setFont ( font ) ; button . se... | org . junit . Assert . assertThat ( button . getFont ( ) , org . hamcrest . CoreMatchers . is ( font ) ) |
testGetDocumentFile ( ) { when ( reader . getDocumentFile ( doc1 , "file" ) ) . thenReturn ( mock ( com . findwise . hydra . DocumentFile . class ) ) ; "<AssertPlaceHolder>" ; verify ( reader ) . getDocumentFile ( doc1 , "file" ) ; verifyNoMoreInteractions ( cache ) ; } getDocumentFile ( com . findwise . hydra . Databa... | org . junit . Assert . assertNotNull ( io . getDocumentFile ( doc1 , "file" ) ) |
test006 ( ) { java . lang . String umlaute = "100.00" 5 ; java . util . Properties props = new java . util . Properties ( ) ; props . setProperty ( "src.bic" , "ABCDEFAA123" ) ; props . setProperty ( "100.00" 9 , "100.00" 6 ) ; props . setProperty ( "100.00" 4 , umlaute ) ; props . setProperty ( "100.00" 0 , "ABCDEFAA1... | org . junit . Assert . assertTrue ( xml . contains ( umlaute ) ) |
testRoundTrip ( ) { com . amazonaws . mobileconnectors . dynamodbv2 . dynamodbmapper . AttributeTransformer transformer1 = new com . amazonaws . mobileconnectors . dynamodbv2 . dynamodbmapper . AttributeTransformerChainTest . TestTransformer ( ".one" ) ; com . amazonaws . mobileconnectors . dynamodbv2 . dynamodbmapper ... | org . junit . Assert . assertEquals ( values , result ) |
testRenameLocalVariableToSameName ( ) { spoon . reflect . declaration . CtType varRenameClass = spoon . testing . utils . ModelUtils . buildClass ( spoon . test . refactoring . testclasses . CtRenameLocalVariableRefactoringTestSubject . class ) ; spoon . reflect . code . CtLocalVariable < ? > local1Var = varRenameClass... | org . junit . Assert . assertEquals ( "local1" , local1Var . getSimpleName ( ) ) |
testMultipleTransaction_SAMPLED_NEW ( ) { final long expectedTransactionCount = 99L ; for ( int i = 0 ; i < expectedTransactionCount ; i ++ ) { this . idGenerator . nextTransactionId ( ) ; } final long actualCount = this . transactionCounter . getSampledNewCount ( ) ; "<AssertPlaceHolder>" ; } getSampledNewCount ( ) { ... | org . junit . Assert . assertEquals ( expectedTransactionCount , actualCount ) |
treeTest ( ) { org . spout . api . inventory . recipe . RecipeBuilder builder = new org . spout . api . inventory . recipe . RecipeBuilder ( ) ; builder . setIngredient ( 'A' , BlockMaterial . SOLID_BLUE ) . setIngredient ( 'B' , BlockMaterial . UNBREAKABLE ) ; builder . addRow ( "AAA" ) . addRow ( "BBB" ) . addRow ( "... | org . junit . Assert . assertSame ( recipe , tree . matchShapedRecipe ( testIngredients , true ) ) |
testToString ( ) { "<AssertPlaceHolder>" ; } toString ( ) { return "MongoEntity<sp>" + ( entityId ) ; } | org . junit . Assert . assertTrue ( ( ! ( "" . equals ( method . toString ( ) ) ) ) ) |
testEncryptedChannelWithoutEncryptionConfigFails ( ) { java . util . Map < java . lang . String , java . lang . String > overrides = getOverridesForEncryption ( ) ; channel = createFileChannel ( overrides ) ; channel . start ( ) ; "<AssertPlaceHolder>" ; fillChannel ( channel , "will-not-restart" ) ; channel . stop ( )... | org . junit . Assert . assertTrue ( channel . isOpen ( ) ) |
test_isQualifierEqual_AnnotationLiteralMutliple_MultipleNonbinding_Equals ( ) { org . apache . webbeans . test . util . TestQualifierMultipleNonbindingAnnotationLiteral q1 = new org . apache . webbeans . test . util . TestQualifierMultipleNonbindingAnnotationLiteral ( ) ; q1 . setValue ( "hello" ) ; org . apache . webb... | org . junit . Assert . assertTrue ( org . apache . webbeans . util . AnnotationUtil . isCdiAnnotationEqual ( q1 , q2 ) ) |
testFetchByPrimaryKeysWithNoPrimaryKeys ( ) { java . util . Set < java . io . Serializable > primaryKeys = new java . util . HashSet < java . io . Serializable > ( ) ; java . util . Map < java . io . Serializable , com . liferay . asset . auto . tagger . model . AssetAutoTaggerEntry > assetAutoTaggerEntries = _persiste... | org . junit . Assert . assertTrue ( assetAutoTaggerEntries . isEmpty ( ) ) |
noNewExceptions_returnsNull ( ) { org . everit . json . schema . ValidationException actual = createSubject ( ) . inContextOfSchema ( NullSchema . INSTANCE , org . everit . json . schema . CollectingFailureReporterTest . NOOP ) ; "<AssertPlaceHolder>" ; } inContextOfSchema ( org . everit . json . schema . Schema , java... | org . junit . Assert . assertNull ( actual ) |
testSetTabIndex_onSashForm ( ) { org . eclipse . swt . widgets . Control control = new org . eclipse . swt . custom . SashForm ( shell , org . eclipse . swt . SWT . NONE ) ; org . eclipse . swt . internal . widgets . IControlAdapter adapter = org . eclipse . swt . internal . widgets . ControlUtil . getControlAdapter ( ... | org . junit . Assert . assertEquals ( ( - 1 ) , adapter . getTabIndex ( ) ) |
testIsSet ( ) { storage . setSyncState ( "user" , "folder" , "state" ) ; "<AssertPlaceHolder>" ; } getLastSyncState ( java . lang . String , java . lang . String ) { java . util . Map < java . lang . String , java . lang . String > folders = syncStates . get ( user ) ; if ( folders == null ) { return null ; } return fo... | org . junit . Assert . assertEquals ( "state" , storage . getLastSyncState ( "user" , "folder" ) ) |
testGetMaskFacet ( ) { org . sagebionetworks . repo . model . table . QueryOptions options = new org . sagebionetworks . repo . model . table . QueryOptions ( ) . withReturnFacets ( true ) ; long mask = options . getPartMask ( ) ; "<AssertPlaceHolder>" ; } getPartMask ( ) { long partMask = 0 ; if ( this . runQuery ) { ... | org . junit . Assert . assertEquals ( QueryOptions . BUNDLE_MASK_QUERY_FACETS , mask ) |
testBatchWithFailedMonitorJobDeletionWithCascade ( ) { org . camunda . bpm . engine . repository . ProcessDefinition processDefinition = testRule . deployAndGetDefinition ( instance ) ; org . camunda . bpm . engine . batch . Batch batch = helper . startBeforeAsync ( "process1" , 2 , "user2" , processDefinition . getId ... | org . junit . Assert . assertEquals ( 0 , historicIncidents ) |
testOptionNoConflict ( ) { boolean error = false ; channel . setOptionCheck ( true ) ; org . apache . catalina . tribes . ChannelInterceptor i = new org . apache . catalina . tribes . group . TestGroupChannelOptionFlag . TestInterceptor ( ) ; i . setOptionFlag ( 128 ) ; channel . addInterceptor ( i ) ; i = new org . ap... | org . junit . Assert . assertFalse ( error ) |
fetchFirstItemsWithoutTopItemToRecover ( ) { itemProvider . addItems ( book . twju . chapter_4 . TimelineTest . FIRST_ITEM , book . twju . chapter_4 . TimelineTest . SECOND_ITEM , book . twju . chapter_4 . TimelineTest . THIRD_ITEM , book . twju . chapter_4 . TimelineTest . FOURTH_ITEM ) ; timeline . setFetchCount ( 2 ... | org . junit . Assert . assertArrayEquals ( new book . twju . chapter_4 . Item [ ] { book . twju . chapter_4 . TimelineTest . FOURTH_ITEM , book . twju . chapter_4 . TimelineTest . THIRD_ITEM } , actual . toArray ( new book . twju . chapter_4 . Item [ 2 ] ) ) |
shouldPassValidation ( ) { final com . github . bmsantos . core . cola . formatter . FeatureDetails result = com . github . bmsantos . core . cola . formatter . FeatureValidator . validate ( featureDetails , com . github . bmsantos . core . cola . formatter . FeatureValidatorTest . URI ) ; "<AssertPlaceHolder>" ; } val... | org . junit . Assert . assertThat ( result , org . hamcrest . Matchers . is ( featureDetails ) ) |
testCreateMockIMocksControl ( ) { org . easymock . IMocksControl ctrl = createControl ( ) ; mock = builder . createMock ( ctrl ) ; "<AssertPlaceHolder>" ; } getControl ( java . lang . Object ) { try { org . easymock . internal . IProxyFactory factory = org . easymock . internal . MocksControl . getProxyFactory ( mock )... | org . junit . Assert . assertSame ( org . easymock . internal . MocksControl . getControl ( mock ) , ctrl ) |
entity_should_not_be_managed_by_transaction_scoped_pc_outside_active_ejb ( ) { com . acme . jpa . model . Record record = helper . retrieveById ( com . acme . jpa . model . Record . class , com . acme . jpa . business . RepositoryTestCase . idOfFirstRecord ) ; "<AssertPlaceHolder>" ; } isManaging ( java . io . Serializ... | org . junit . Assert . assertFalse ( helper . isManaging ( record ) ) |
testHappyFlowOntbinding ( ) { final java . lang . String bericht = org . apache . commons . io . IOUtils . toString ( nl . bzk . migratiebrp . synchronisatie . runtime . service . VerwerkToevalligeGebeurtenisService . class . getResourceAsStream ( "VerwerkToevalligeGebeurtenisVerzoekBericht.xml" ) ) ; final nl . bzk . ... | org . junit . Assert . assertNull ( antwoord ) |
testGroupItemChangesBaseItemAndFunction ( ) { org . eclipse . smarthome . model . item . internal . GenericItemProvider gip = new org . eclipse . smarthome . model . item . internal . GenericItemProvider ( ) ; org . eclipse . smarthome . core . items . GroupItem g1 = new org . eclipse . smarthome . core . items . Group... | org . junit . Assert . assertTrue ( gip . hasItemChanged ( g1 , g2 ) ) |
instantiation ( ) { org . junithelper . core . filter . impl . TrimCommentFilter target = new org . junithelper . core . filter . impl . TrimCommentFilter ( ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertNotNull ( target ) |
testGetActiveBillingItemByCh1Id ( ) { int ch1Id1 = 101 ; int ch1Id2 = 202 ; java . lang . String status1 = "D" ; java . lang . String status2 = "Active" ; org . oscarehr . common . model . BillingONItem bONI1 = new org . oscarehr . common . model . BillingONItem ( ) ; org . oscarehr . common . dao . utils . EntityDataG... | org . junit . Assert . assertTrue ( true ) |
testNormalDelete ( ) { org . apache . directory . ldap . client . api . LdapConnection conn = getAdminConnection ( getLdapServer ( ) ) ; conn . delete ( "ou=computers,uid=akarasulu,ou=users,ou=system" ) ; try { conn . delete ( "uid=elecharny,ou=users,ou=system" ) ; org . junit . Assert . fail ( ) ; } catch ( org . apac... | org . junit . Assert . assertTrue ( true ) |
testSaveState2 ( ) { javax . faces . context . FacesContext context = org . easymock . EasyMock . createMock ( javax . faces . context . FacesContext . class ) ; javax . faces . component . UIData data = new javax . faces . component . UIData ( ) ; replay ( context ) ; "<AssertPlaceHolder>" ; verify ( context ) ; } sav... | org . junit . Assert . assertNotNull ( data . saveState ( context ) ) |
get5 ( ) { com . google . inject . TypeLiteral < ? > a = com . kaching . platform . guice . TypeLiterals . get ( java . util . List . class , new com . google . inject . TypeLiteral < java . lang . Double > ( ) { } ) ; com . google . inject . TypeLiteral < ? > b = com . kaching . platform . guice . TypeLiterals . get (... | org . junit . Assert . assertEquals ( a , b ) |
shouldMarkTransitionFromNonSuperadminToSuperadminAsValidWhenPerformedBySuperAdmin ( ) { stubCurrentUserRole ( com . qcadoo . security . internal . validators . ROLE_SUPERADMIN ) ; stubRoleTransition ( "99anyOtherRole" , com . qcadoo . security . internal . validators . ROLE_SUPERADMIN ) ; final boolean isValid = userRo... | org . junit . Assert . assertTrue ( isValid ) |
shouldReturnNullIfIndexRuleForLabelAndPropertyDoesNotExist ( ) { org . neo4j . kernel . impl . store . SchemaStorageTest . createSchema ( org . neo4j . kernel . impl . store . SchemaStorageTest . index ( org . neo4j . kernel . impl . store . SchemaStorageTest . LABEL1 , org . neo4j . kernel . impl . store . SchemaStora... | org . junit . Assert . assertNull ( rule ) |
testAnyMatchWithTrueResult ( ) { boolean match = com . annimon . stream . Stream . range ( 0 , 10 ) . anyMatch ( com . annimon . stream . Functions . remainder ( 2 ) ) ; "<AssertPlaceHolder>" ; } remainder ( int ) { return new com . annimon . stream . Predicate < java . lang . Integer > ( ) { @ com . annimon . stream .... | org . junit . Assert . assertTrue ( match ) |
testCheckEndsWithIndefiniteArticle3 ( ) { java . lang . String cannedText = "I<sp>see<sp>an" ; java . lang . String np = "cow" ; java . lang . String expected = "I<sp>see<sp>an" ; java . lang . String actual = simplenlg . morphology . english . DeterminerAgrHelper . checkEndsWithIndefiniteArticle ( cannedText , np ) ; ... | org . junit . Assert . assertEquals ( expected , actual ) |
basicVariableTest ( ) { java . lang . String transformationCode = "something<sp>=<sp>\"garbage\"\nreturn<sp>something<sp>+<sp>getValue(\"value\")" ; edu . isi . karma . transformation . tokenizer . PythonTransformationAsURIValidator validator = new edu . isi . karma . transformation . tokenizer . PythonTransformationAs... | org . junit . Assert . assertFalse ( validator . validate ( transformationCode ) ) |
testIgnoredWhenWrongType ( ) { org . axonframework . messaging . annotation . ParameterResolver resolver = testSubject . createInstance ( stringMethod , stringMethod . getParameters ( ) , 0 ) ; "<AssertPlaceHolder>" ; } createInstance ( java . lang . reflect . Executable , java . lang . reflect . Parameter [ ] , int ) ... | org . junit . Assert . assertNull ( resolver ) |
readAndParseYangFileTest ( ) { org . opendaylight . yangtools . yang . model . api . SchemaContext result = org . opendaylight . yangtools . yang . parser . rfc7950 . reactor . RFC7950Reactors . defaultReactor ( ) . newBuild ( ) . addSources ( org . opendaylight . yangtools . yang . stmt . YangTypesStmtTest . TYPEFILE1... | org . junit . Assert . assertNotNull ( result ) |
greek_UTF8 ( ) { java . io . FileInputStream fis = new java . io . FileInputStream ( ( ( ch . qos . cal10n . CAL10NTestConstants . TEST_CLASSES ) + "/encodingsUTF8/a_el_GR.properties" ) ) ; java . io . Reader reader = new java . io . InputStreamReader ( fis , "UTF8" ) ; ch . qos . cal10n . util . Parser parser = new ch... | org . junit . Assert . assertEquals ( witness , map ) |
testPostfixFunction8 ( ) { java . lang . String expr ; double expected ; double varE = java . lang . Math . Math . E ; expr = "2^3.4223232<sp>+<sp>tan(e)" ; expected = ( java . lang . Math . Math . pow ( 2 , 3.4223232 ) ) + ( java . lang . Math . Math . tan ( Math . E ) ) ; net . objecthunter . exp4j . Expression e = n... | org . junit . Assert . assertTrue ( ( expected == ( e . setVariable ( "e" , varE ) . evaluate ( ) ) ) ) |
testDestroy ( ) { org . apache . tuscany . sca . implementation . java . introspect . impl . DestroyProcessor processor = new org . apache . tuscany . sca . implementation . java . introspect . impl . DestroyProcessor ( assemblyFactory ) ; org . apache . tuscany . sca . implementation . java . JavaImplementation type =... | org . junit . Assert . assertNotNull ( type . getDestroyMethod ( ) ) |
testRepeatKey ( ) { try { resolver . resolve ( 1 , "a=b\nb=c\nA=d\nB=e" , java . util . Collections . emptyList ( ) ) ; } catch ( java . lang . Exception e ) { "<AssertPlaceHolder>" ; } } resolve ( long , java . lang . String , java . util . List ) { java . util . Map < java . lang . Integer , com . ctrip . framework .... | org . junit . Assert . assertTrue ( ( e instanceof com . ctrip . framework . apollo . common . exception . BadRequestException ) ) |
testSerialization ( ) { org . jfree . chart . block . BorderArrangement b1 = new org . jfree . chart . block . BorderArrangement ( ) ; java . io . ByteArrayOutputStream buffer = new java . io . ByteArrayOutputStream ( ) ; java . io . ObjectOutput out = new java . io . ObjectOutputStream ( buffer ) ; out . writeObject (... | org . junit . Assert . assertEquals ( b1 , b2 ) |
testDefaultConnectionFactory ( ) { javax . jms . ConnectionFactory factory = ( ( javax . jms . ConnectionFactory ) ( context . lookup ( "java:jboss/DefaultJMSConnectionFactory" ) ) ) ; "<AssertPlaceHolder>" ; } lookup ( java . lang . String ) { return new org . wildfly . swarm . microprofile . faulttolerance . deployme... | org . junit . Assert . assertNotNull ( factory ) |
testCreateDataOutputCompressor ( ) { java . io . DataOutput dataOutputStream = new java . io . DataOutputStream ( new java . io . ByteArrayOutputStream ( ) ) ; try ( org . apache . commons . compress . archivers . zip . StreamCompressor streamCompressor = org . apache . commons . compress . archivers . zip . StreamComp... | org . junit . Assert . assertNotNull ( streamCompressor ) |
testSuccessfulCallShouldReturnValue ( ) { com . ticketmaster . exp . util . Try < java . lang . String > t = com . ticketmaster . exp . util . Try . of ( "s" , null ) ; java . lang . String s = t . call ( ) ; "<AssertPlaceHolder>" ; } call ( ) { if ( value . isPresent ( ) ) { return value . get ( ) ; } else { throw exc... | org . junit . Assert . assertEquals ( "s" , s ) |
testCacheParameters ( ) { java . lang . String ejbql1 = "select<sp>a<sp>FROM<sp>Artist<sp>a<sp>WHERE<sp>a.artistName<sp>=<sp>?1<sp>OR<sp>a.artistName<sp>=<sp>:name" ; org . apache . cayenne . query . EJBQLQuery q1 = new org . apache . cayenne . query . EJBQLQuery ( ejbql1 ) ; q1 . setParameter ( 1 , "X" ) ; q1 . setPar... | org . junit . Assert . assertEquals ( q1 . getMetaData ( resolver ) . getCacheKey ( ) , q2 . getMetaData ( resolver ) . getCacheKey ( ) ) |
testkapuaTad ( ) { org . eclipse . kapua . commons . configuration . metatype . KapuaMetatypeFactoryImpl factory = new org . eclipse . kapua . commons . configuration . metatype . KapuaMetatypeFactoryImpl ( ) ; "<AssertPlaceHolder>" ; } newKapuaTad ( ) { return factory . newKapuaTad ( ) ; } | org . junit . Assert . assertNotNull ( factory . newKapuaTad ( ) ) |
streamToModel ( ) { final org . apache . jena . graph . Node subject = createURI ( "subject" ) ; final org . apache . jena . graph . Node prop1 = createURI ( "prop1" ) ; final org . apache . jena . graph . Node prop2 = createURI ( "prop2" ) ; final java . util . List < org . apache . jena . graph . Triple > triples = a... | org . junit . Assert . assertEquals ( 3 , filtered . size ( ) ) |
testEquals ( ) { org . jfree . chart . plot . ColorPalette p1 = new org . jfree . chart . plot . GreyPalette ( ) ; org . jfree . chart . plot . ColorPalette p2 = new org . jfree . chart . plot . GreyPalette ( ) ; "<AssertPlaceHolder>" ; } equals ( java . lang . Object ) { if ( obj == ( this ) ) { return true ; } if ( !... | org . junit . Assert . assertTrue ( p1 . equals ( p2 ) ) |
testGetAllEmpty ( ) { de . metanome . backend . results_db . HibernateUtil . clear ( ) ; java . util . Collection < de . metanome . backend . results_db . Algorithm > actualAlgorithms = resource . getAll ( ) ; "<AssertPlaceHolder>" ; de . metanome . backend . results_db . HibernateUtil . clear ( ) ; } isEmpty ( ) { ret... | org . junit . Assert . assertTrue ( actualAlgorithms . isEmpty ( ) ) |
test_setReplicationCtx_overwrite_fails ( ) { final java . util . Properties initialCtx = new java . util . Properties ( ) ; org . compiere . util . Env . setContext ( initialCtx , Env . CTXNAME_AD_Client_ID , 12345 ) ; final java . util . Properties ctx = new java . util . Properties ( initialCtx ) ; org . adempiere . ... | org . junit . Assert . assertEquals ( org . compiere . util . Env . getContextAsInt ( ctx , Env . CTXNAME_AD_Client_ID ) , 1 ) |
testDebugAtom_IElement ( ) { org . openscience . cdk . interfaces . IChemObject object = newChemObject ( ) ; org . openscience . cdk . interfaces . IElement element = object . getBuilder ( ) . newInstance ( org . openscience . cdk . interfaces . IElement . class ) ; org . openscience . cdk . interfaces . IAtom a = new ... | org . junit . Assert . assertNotNull ( a ) |
creditDenied ( ) { org . switchyard . quickstarts . remoteinvoker . Application app = new org . switchyard . quickstarts . remoteinvoker . Application ( ) ; app . setName ( "bill<sp>whatwhatwhat" ) ; app . setCreditScore ( 400 ) ; org . switchyard . quickstarts . remoteinvoker . Offer offer = new org . switchyard . qui... | org . junit . Assert . assertFalse ( result . isApproved ( ) ) |
illegalModuleDescriptor ( ) { final org . nohope . spring . app . AppWithContainer app = org . nohope . spring . app . SpringAsyncModularAppTest . probe ( "app" , "" , "illegalDescriptor" ) ; "<AssertPlaceHolder>" ; } getModules ( ) { return modules ; } | org . junit . Assert . assertEquals ( 0 , app . getModules ( ) . size ( ) ) |
testBuild ( ) { org . lnu . is . domain . person . name . PersonName context = new org . lnu . is . domain . person . name . PersonName ( ) ; java . lang . String expected = "SELECT<sp>e<sp>FROM<sp>PersonName<sp>e<sp>WHERE<sp>e.status=:status<sp>AND<sp>e.crtUserGroup<sp>IN<sp>(:userGroups)<sp>" ; org . lnu . is . pagin... | org . junit . Assert . assertEquals ( expected , actualQuery ) |
shouldBuildAnInterfaceConfigByDelegatingToAnnotationHandlersForEachAnnotationsDetected ( ) { org . codegist . crest . config . InterfaceConfig expected = mock ( org . codegist . crest . config . InterfaceConfig . class ) ; when ( mockInterfaceConfigBuilder . build ( ) ) . thenReturn ( expected ) ; org . codegist . cres... | org . junit . Assert . assertSame ( expected , actual ) |
testFromEbXMLEmpty ( ) { org . openehealth . ipf . commons . ihe . xds . core . ebxml . EbXMLRetrieveImagingDocumentSetRequest ebXML = transformer . toEbXML ( new org . openehealth . ipf . commons . ihe . xds . core . requests . RetrieveImagingDocumentSet ( ) ) ; org . openehealth . ipf . commons . ihe . xds . core . r... | org . junit . Assert . assertEquals ( new org . openehealth . ipf . commons . ihe . xds . core . requests . RetrieveImagingDocumentSet ( ) , result ) |
mainPath ( ) { org . apache . jackrabbit . oak . plugins . document . Revision r = org . apache . jackrabbit . oak . plugins . document . Revision . fromString ( "r1-0-1" ) ; for ( java . lang . String p : new java . lang . String [ ] { "/" , "/test" , "/test/path" } ) { org . apache . jackrabbit . oak . plugins . docu... | org . junit . Assert . assertEquals ( path , doc . getMainPath ( ) ) |
testGetNadereAanduidingVerval ( ) { final nl . bzk . brp . bijhouding . bericht . model . CharacterElement nadereAanduidingVerval = new nl . bzk . brp . bijhouding . bericht . model . CharacterElement ( 'O' ) ; final nl . bzk . brp . bijhouding . bericht . model . RelatieElement relatieElement = builder . maakHuwelijkE... | org . junit . Assert . assertEquals ( nadereAanduidingVerval , actieElement . getNadereAanduidingVerval ( ) ) |
testHotSwappingNaturaelyCaches ( ) { com . picocontainer . DefaultPicoContainer pico = new com . picocontainer . DefaultPicoContainer ( new com . picocontainer . gems . behaviors . HotSwapping ( ) . wrap ( new com . picocontainer . injectors . ConstructorInjection ( ) ) ) ; pico . addComponent ( java . util . Map . cla... | org . junit . Assert . assertSame ( firstMap , secondMap ) |
parse_withFilterNumbersOnly_shouldReturnOnlyNumbers ( ) { System . out . println ( "parse" ) ; java . lang . String text = "Test1235<sp>ok" ; coffeepot . bean . wr . mapper . Metadata metadata = null ; coffeepot . bean . wr . typeHandler . DefaultStringHandler instance = new coffeepot . bean . wr . typeHandler . Defaul... | org . junit . Assert . assertEquals ( expResult , result ) |
delete ( ) { org . apache . usergrid . chop . webapp . dao . RunnerDaoTest . LOG . info ( "\n===RunnerDaoTest.delete===\n" ) ; org . apache . usergrid . chop . webapp . dao . RunnerDaoTest . LOG . info ( "Runners<sp>before<sp>delete:<sp>" ) ; java . util . List < org . apache . usergrid . chop . api . Runner > runners ... | org . junit . Assert . assertEquals ( 0 , runnersAfter . size ( ) ) |
testRevokeDefinePermissions ( ) { com . liferay . data . engine . model . DEDataRecordCollection deDataRecordCollection = com . liferay . data . engine . service . test . DEDataEngineTestUtil . insertDEDataRecordCollection ( _adminUser , _group , _deDataDefinitionService , _deDataRecordCollectionService ) ; com . lifer... | org . junit . Assert . assertEquals ( deDataRecordCollection . getDEDataRecordCollectionId ( ) , deDataRecordCollectionAfterUpdate . getDEDataRecordCollectionId ( ) ) |
test2 ( ) { org . eclipse . angularjs . core . utils . AngularELRegion region = org . eclipse . angularjs . core . utils . AngularRegionUtils . getAngularELRegion ( DOMRegionContext . XML_CONTENT , "{{" , 588 , 604 , "{{" , "}}" ) ; "<AssertPlaceHolder>" ; } getAngularELRegion ( java . lang . String , java . lang . Str... | org . junit . Assert . assertNull ( region ) |
testGetClusterNodeLabels ( ) { org . apache . hadoop . yarn . client . api . YarnClient client = mock ( org . apache . hadoop . yarn . client . api . YarnClient . class ) ; when ( client . getClusterNodeLabels ( ) ) . thenReturn ( java . util . Arrays . asList ( org . apache . hadoop . yarn . api . records . NodeLabel ... | org . junit . Assert . assertEquals ( 0 , rc ) |
testAttributes ( ) { final java . util . Collection < org . uberfire . ext . security . management . api . UserManager . UserAttribute > USER_ATTRIBUTES = java . util . Arrays . asList ( BaseTomcatManager . USER_FULLNAME ) ; java . util . Collection < org . uberfire . ext . security . management . api . UserManager . U... | org . junit . Assert . assertEquals ( attributes , USER_ATTRIBUTES ) |
testProcessSong ( ) { java . lang . String testGenre = "testGenre" ; org . bff . javampd . processor . GenreTagProcessor genreTagProcessor = new org . bff . javampd . processor . GenreTagProcessor ( ) ; org . bff . javampd . song . MPDSong song = new org . bff . javampd . song . MPDSong ( "testFile" , "testName" ) ; ja... | org . junit . Assert . assertEquals ( testGenre , song . getGenre ( ) ) |
testIncrementVariableAssignment ( ) { executeWithDefaultScope ( "intVar<sp>=<sp>intVar++" ) ; "<AssertPlaceHolder>" ; } getIntValue ( ) { return context . getVariable ( "intVar" ) . getValue ( ) ; } | org . junit . Assert . assertEquals ( 0 , getIntValue ( ) ) |
getDelayValue_A$Calendar$TimeUnit_day ( ) { com . github . seratch . taskun . scheduler . impl . TaskunImpl target = new com . github . seratch . taskun . scheduler . impl . TaskunImpl ( ) ; java . util . Calendar arg0 = com . github . seratch . taskun . util . CalendarUtil . getCurrentTime ( ) ; arg0 = com . github . ... | org . junit . Assert . assertEquals ( expected , actual ) |
testDeblokkeer ( ) { final nl . bzk . brp . bijhouding . business . stappen . resultaat . ResultaatMelding melding = nl . bzk . brp . bijhouding . business . stappen . resultaat . ResultaatMelding . builder ( nl . bzk . brp . bijhouding . business . stappen . resultaat . ResultaatMeldingTest . MELDING ) . withSoort ( S... | org . junit . Assert . assertEquals ( gedeblokkeerd , melding . deblokkeer ( ) ) |
getBigDecimal ( ) { final java . lang . Double value = 1.2 ; final io . trane . ndbc . value . DoubleValue wrapper = new io . trane . ndbc . value . DoubleValue ( value ) ; "<AssertPlaceHolder>" ; } getBigDecimal ( ) { return new java . math . BigDecimal ( get ( ) ) ; } | org . junit . Assert . assertEquals ( new java . math . BigDecimal ( value ) , wrapper . getBigDecimal ( ) ) |
shouldGetIntValue ( ) { int intValue = de . slackspace . openkeepass . domain . CompressionAlgorithm . getIntValue ( CompressionAlgorithm . Gzip ) ; "<AssertPlaceHolder>" ; } getIntValue ( de . slackspace . openkeepass . domain . CompressionAlgorithm ) { switch ( algorithm ) { case None : return 0 ; case Gzip : return ... | org . junit . Assert . assertEquals ( 1 , intValue ) |
testSetTimeintTime ( ) { stmt . prepare ( ( ( org . eclipse . birt . report . data . oda . jdbc . StatementTest . SELECT_SQL ) + "<sp>where<sp>col5<sp>=<sp>?" ) ) ; stmt . setTime ( 1 , java . sql . Time . valueOf ( "12:00:01" ) ) ; org . eclipse . birt . report . data . oda . jdbc . ResultSet rs = ( ( org . eclipse . ... | org . junit . Assert . assertTrue ( rs . next ( ) ) |
testCreateMessages ( ) { edu . jhu . pacaya . util . semiring . Algebra s = edu . jhu . pacaya . util . semiring . LogSemiring . getInstance ( ) ; int n = 4 ; edu . jhu . pacaya . gm . model . globalfac . ConsecutiveSiblingsFactor f = edu . jhu . pacaya . gm . model . globalfac . ConsecutiveSiblingsFactorTest . getDefa... | org . junit . Assert . assertEquals ( outMsgs1 [ i ] , outMsgs2 [ i ] ) |
testGetNetConfigIp4 ( ) { org . eclipse . kura . net . admin . monitor . ModemMonitorServiceImpl svc = new org . eclipse . kura . net . admin . monitor . ModemMonitorServiceImpl ( ) ; java . util . List < org . eclipse . kura . net . NetConfig > netConfigs = new java . util . ArrayList ( ) ; org . eclipse . kura . net ... | org . junit . Assert . assertEquals ( config , result ) |
testToStringEmptyValueNullCustomFacts ( ) { org . gedcom4j . model . StringWithCustomFacts swct = new org . gedcom4j . model . StringWithCustomFacts ( ) ; swct . value = "" ; swct . customFacts = null ; "<AssertPlaceHolder>" ; swct . getCustomFacts ( true ) ; } | org . junit . Assert . assertEquals ( "" , ( "" + swct ) ) |
descendantOrSelfOf ( ) { final com . b2international . index . query . Expression actual = eval ( ( "<<" + ( com . b2international . snowowl . snomed . core . ecl . SnomedEclEvaluationRequestTest . ROOT_ID ) ) ) ; com . b2international . index . query . Expression expected ; if ( isInferred ( ) ) { expected = com . b2i... | org . junit . Assert . assertEquals ( expected , actual ) |
getListOfTrafficscripts ( ) { java . util . List < org . rackspace . stingray . client . list . Child > children = client . getTrafficscripts ( ) ; "<AssertPlaceHolder>" ; } size ( ) { return size ; } | org . junit . Assert . assertTrue ( ( ( children . size ( ) ) > 0 ) ) |
testElectronImpactPDBReaction ( ) { org . openscience . cdk . reaction . IReactionProcess type = new org . openscience . cdk . reaction . type . ElectronImpactPDBReaction ( ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertNotNull ( type ) |
validatePackagingOfDisallowedCall ( ) { com . github . hakko . musiccabinet . ws . lastfm . TestWSGetClient testWSClient = getTestWSClient ( false , com . github . hakko . musiccabinet . ws . lastfm . AbstractWSGetClientTest . SIMILAR_TRACKS_RESOURCE ) ; com . github . hakko . musiccabinet . ws . lastfm . WSResponse ws... | org . junit . Assert . assertFalse ( wsResponse . wasCallAllowed ( ) ) |
testSerialization ( ) { org . jfree . chart . labels . StandardXYItemLabelGenerator g1 = new org . jfree . chart . labels . StandardXYItemLabelGenerator ( ) ; org . jfree . chart . labels . StandardXYItemLabelGenerator g2 = ( ( org . jfree . chart . labels . StandardXYItemLabelGenerator ) ( org . jfree . chart . TestUt... | org . junit . Assert . assertEquals ( g1 , g2 ) |
shouldRejectNullLbLimitName ( ) { lbLimitGroup . setName ( null ) ; org . openstack . atlas . api . validation . results . ValidatorResult result = lbLimitGroupValidator . validate ( lbLimitGroup , HttpRequestType . POST ) ; "<AssertPlaceHolder>" ; } resultMessage ( org . openstack . atlas . api . validation . results ... | org . junit . Assert . assertFalse ( resultMessage ( result , HttpRequestType . POST ) , result . passedValidation ( ) ) |
testRefToRuleDoesNotSetTokenNorEmitAnother ( ) { java . lang . String grammar = "lexer<sp>grammar<sp>L;\n" + ( ( "A<sp>:<sp>\'-\'<sp>I<sp>;\n" + "I<sp>:<sp>\'0\'..\'9\'+<sp>;\n" ) + "I<sp>:<sp>\'0\'..\'9\'+<sp>;\n" 0 ) ; java . lang . String found = execLexer ( "L.g4" , grammar , "L" , "34<sp>-21<sp>3" ) ; java . lang ... | org . junit . Assert . assertEquals ( expecting , found ) |
testMultipleVaryMessageBytes ( ) { com . cloudera . flume . core . Event e1 ; com . cloudera . flume . core . Event e2 ; for ( com . cloudera . flume . core . EventSource src : com . cloudera . flume . FlumeBenchmarkHarness . createVariedMsgBytesCases ( ) . values ( ) ) { src . open ( ) ; e1 = src . next ( ) ; src . op... | org . junit . Assert . assertTrue ( java . util . Arrays . equals ( e1 . getBody ( ) , e2 . getBody ( ) ) ) |
testZSS660InvalidNamedRange ( ) { org . zkoss . zss . issue . Book book = org . zkoss . zss . issue . Util . loadBook ( this , "book/blank.xlsx" ) ; org . zkoss . zss . issue . Sheet sheet = book . getSheetAt ( 0 ) ; java . lang . String [ ] invalidNameList = new java . lang . String [ ] { "1A" , "123" , "A1" , "c" , "... | org . junit . Assert . assertEquals ( invalidCount , invalidNameList . length ) |
buildQueryConditionsWithParameters_should_work_with_primitive_type_parameter_values ( ) { final int age = 5 ; final java . lang . String convertedAge = org . springframework . data . simpledb . attributeutil . SimpleDBAttributeConverter . encode ( age ) ; final java . lang . String expectedQuery = ( "select<sp>item_id,... | org . junit . Assert . assertThat ( resultedQuery , org . hamcrest . CoreMatchers . is ( expectedQuery ) ) |
testWinProcessingCappture ( ) { com . xrtb . common . HttpPostGet http = new com . xrtb . common . HttpPostGet ( ) ; test . java . TestWinProcessing . redisson . del ( "%7Bbid_id" 2 ) ; java . lang . String s = java . nio . charset . Charset . defaultCharset ( ) . decode ( java . nio . ByteBuffer . wrap ( java . nio . ... | org . junit . Assert . assertNull ( m ) |
shouldSendNotificationSearchAction ( ) { com . devicehive . NotificationSearchRequest searchRequest = new com . devicehive . NotificationSearchRequest ( ) ; searchRequest . setId ( Long . MAX_VALUE ) ; searchRequest . setDeviceIds ( com . devicehive . Collections . singleton ( com . devicehive . UUID . randomUUID ( ) .... | org . junit . Assert . assertTrue ( responseBody . getNotifications ( ) . isEmpty ( ) ) |
getArchivedActivityDataInstance ( ) { final java . lang . String dataName = "title" ; final org . bonitasoft . engine . bpm . process . impl . ProcessDefinitionBuilder builder = new org . bonitasoft . engine . bpm . process . impl . ProcessDefinitionBuilder ( ) . createNewInstance ( "ProcessToArchive" , "1.0" ) ; build... | org . junit . Assert . assertEquals ( "2" , archivedData . getValue ( ) ) |
testDontUseBoundCodeForExampleBinding ( ) { org . hl7 . fhir . dstu3 . model . Practitioner p = new org . hl7 . fhir . dstu3 . model . Practitioner ( ) ; org . hl7 . fhir . dstu3 . model . Practitioner . PractitionerQualificationComponent qualification = p . addQualification ( ) ; org . hl7 . fhir . dstu3 . model . Cod... | org . junit . Assert . assertEquals ( org . hl7 . fhir . dstu3 . model . CodeableConcept . class , roleField . getClass ( ) ) |
testConversion ( ) { cern . c2mon . server . common . datatag . DataTagCacheObject tag = new cern . c2mon . server . common . datatag . DataTagCacheObject ( 10L ) ; tag . setValueDescription ( "value<sp>desc" ) ; cern . c2mon . server . history . structure . TagRecord tagRecord = ( ( cern . c2mon . server . history . s... | org . junit . Assert . assertEquals ( "value<sp>desc" , tagRecord . getTagValueDesc ( ) ) |
hasAssociatedControls ( ) { java . lang . String html = "<form<sp>id=1><button<sp>id=1><fieldset<sp>id=2<sp>/><input<sp>id=3><keygen<sp>id=4><object<sp>id=5><output<sp>id=6>" + "<select<sp>id=7><option></select><textarea<sp>id=8><p<sp>id=9>" ; org . jsoup . nodes . Document doc = org . jsoup . Jsoup . parse ( html ) ; ... | org . junit . Assert . assertEquals ( 8 , form . elements ( ) . size ( ) ) |
getPositionsFor ( ) { java . util . List < slash . navigation . common . SimpleNavigationPosition > expected = asList ( new slash . navigation . common . SimpleNavigationPosition ( 10.2014032 , 50.0002123 , null , "Bühlstraße,<sp>Grafenrheinfeld,<sp>Landkreis<sp>Schweinfurt,<sp>Unterfranken,<sp>Bayern,<sp>97506,<sp>Deu... | org . junit . Assert . assertEquals ( expected , actual ) |
testSetTotalUnits ( ) { empty . setTotalUnits ( VLWSentence . KM ) ; "<AssertPlaceHolder>" ; } getTotalUnits ( ) { return getCharValue ( net . sf . marineapi . nmea . parser . VLWParser . TOTAL_UNITS ) ; } | org . junit . Assert . assertEquals ( VLWSentence . KM , empty . getTotalUnits ( ) ) |
determineSegmentCount_override32 ( ) { int _segs = org . cache2k . core . InternalCache2kBuilder . determineSegmentCount ( false , 12 , true , 1000000 , 32 ) ; "<AssertPlaceHolder>" ; } determineSegmentCount ( boolean , int , boolean , long , int ) { int _segmentCount = 1 ; if ( _availableProcessors > 1 ) { _segmentCou... | org . junit . Assert . assertEquals ( 32 , _segs ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.