input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
getAppStreamV2 ( ) { java . util . List < com . podio . stream . StreamObjectV2 > objects = getAPI ( ) . getAppStream ( 1 , 3 , 2 ) ; "<AssertPlaceHolder>" ; } getAppStream ( int , java . lang . Integer , java . lang . Integer ) { return getStreamV2 ( ( ( "/stream/app/" + appId ) + "/" ) , limit , offset , null , null ... | org . junit . Assert . assertEquals ( objects . size ( ) , 3 ) |
testError ( ) { boolean wasFound = false ; for ( org . openl . message . OpenLMessage message : getCompiledOpenClass ( ) . getMessages ( ) ) { if ( ( message . getSeverity ( ) ) == ( org . openl . message . Severity . ERROR ) ) { if ( message . getSummary ( ) . equals ( "Field<sp>[field1]<sp>has<sp>been<sp>already<sp>d... | org . junit . Assert . assertTrue ( wasFound ) |
lotsOfInsertsWithTxsThatStayOpen ( ) { createPageFileAndIndex ( ( ( short ) ( 200 ) ) ) ; org . fusesource . hawtdb . internal . index . BTreeIndex < java . lang . String , java . lang . Long > index = ( ( org . fusesource . hawtdb . internal . index . BTreeIndex < java . lang . String , java . lang . Long > ) ( this .... | org . junit . Assert . assertEquals ( new java . lang . Long ( i ) , index . get ( key ( i ) ) ) |
testInsertBefore ( ) { java . lang . String expectedJavascript = "$('div').insertBefore('<div>a<div>');" ; java . lang . String generatedJavascript = new org . odlabs . wiquery . core . javascript . JsStatement ( ) . $ ( null , "div" ) . chain ( org . odlabs . wiquery . core . javascript . helper . ManipulatingHelper .... | org . junit . Assert . assertEquals ( generatedJavascript , expectedJavascript ) |
testConvertAll ( ) { java . lang . Long id = 1L ; java . lang . String abbrName = "abbr<sp>Name" ; java . lang . String name = "n<sp>a<sp>m<sp>e" ; org . lnu . is . domain . admin . unit . type . AdminUnitType source = new org . lnu . is . domain . admin . unit . type . AdminUnitType ( ) ; source . setId ( id ) ; sourc... | org . junit . Assert . assertEquals ( expecteds , actuals ) |
findAllTenantsTest ( ) { org . kaaproject . kaa . common . dto . TenantDto tenantDto = generateTenantDto ( ) ; java . util . List < org . kaaproject . kaa . common . dto . TenantDto > saved = new java . util . ArrayList ( 1 ) ; saved . add ( tenantDto ) ; java . util . List < org . kaaproject . kaa . common . dto . Ten... | org . junit . Assert . assertEquals ( saved , tenants ) |
test_getPathInWorkspace_macosx_edge_case ( ) { java . lang . String workspace = "/var/folders/lq/50t8n2nx7l316pwm8gc_2rt40000gn/T/jenkinsTests.tmp/jenkins3845105900446934883test/workspace/build-on-master-with-tool-provided-maven" ; java . lang . String absolutePath = "/private/var/folders/lq/50t8n2nx7l316pwm8gc_2rt4000... | org . junit . Assert . assertThat ( actual , org . hamcrest . CoreMatchers . is ( expected ) ) |
testEmptyGeometryRendering ( ) { org . geotools . map . MapContent mc = new org . geotools . map . MapContent ( ) ; org . geotools . styling . StyleBuilder sb = new org . geotools . styling . StyleBuilder ( ) ; org . geotools . styling . Style style = sb . createStyle ( sb . createPolygonSymbolizer ( ) ) ; org . geotoo... | org . junit . Assert . assertTrue ( ( ( errors ) == 0 ) ) |
findUserByName ( ) { com . apress . demo . User user = userRepository . findByUserName ( "Robert" ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertNotNull ( user ) |
testEqualsWithEqualInstances ( ) { edu . illinois . library . cantaloupe . image . Info info2 = edu . illinois . library . cantaloupe . image . Info . builder ( ) . withIdentifier ( new edu . illinois . library . cantaloupe . image . Identifier ( "cats" ) ) . withSize ( 100 , 80 ) . withTileSize ( 50 , 40 ) . withOrien... | org . junit . Assert . assertTrue ( instance . equals ( info2 ) ) |
getHtml ( ) { when ( markdownProcessor . markdownToHtml ( de . blizzy . documentr . markdown . PageRendererTest . MARKDOWN , de . blizzy . documentr . markdown . PageRendererTest . PROJECT , de . blizzy . documentr . markdown . PageRendererTest . BRANCH , de . blizzy . documentr . markdown . PageRendererTest . PAGE_PAT... | org . junit . Assert . assertEquals ( de . blizzy . documentr . markdown . PageRendererTest . HTML , result ) |
testTimeZoneMatches ( ) { org . apache . commons . lang3 . time . DateParser parser = getInstance ( org . apache . commons . lang3 . time . FastDateParserTest . yMdHmsSZ , org . apache . commons . lang3 . time . FastDateParserTest . REYKJAVIK ) ; "<AssertPlaceHolder>" ; } getTimeZone ( ) { return this . timeZone ; } | org . junit . Assert . assertEquals ( org . apache . commons . lang3 . time . FastDateParserTest . REYKJAVIK , parser . getTimeZone ( ) ) |
canBeSatisfiedFalse ( ) { eu . abc4trust . services . user . UserServiceFactory userServiceFactory = new eu . abc4trust . services . user . UserServiceFactory ( ) ; java . lang . String engineSuffix = "idemix" ; eu . abc4trust . xml . IssuancePolicyAndAttributes issuancePolicyAndAttributes = userServiceFactory . loadIs... | org . junit . Assert . assertFalse ( b ) |
whenStream_thenOk ( ) { java . util . List < com . stackify . optional . User > users = new java . util . ArrayList ( ) ; com . stackify . optional . User user = users . stream ( ) . findFirst ( ) . orElse ( new com . stackify . optional . User ( "default" , "1234" ) ) ; "<AssertPlaceHolder>" ; } getEmail ( ) { return ... | org . junit . Assert . assertEquals ( user . getEmail ( ) , "default" ) |
testFromJsonObjectNoData ( ) { javax . json . JsonObject jsonObject = javax . json . Json . createObjectBuilder ( ) . build ( ) ; edu . wpi . rail . jrosbridge . messages . std . Int32 data = edu . wpi . rail . jrosbridge . messages . std . Int32 . fromJsonObject ( jsonObject ) ; "<AssertPlaceHolder>" ; } getData ( ) {... | org . junit . Assert . assertEquals ( 0 , data . getData ( ) ) |
testGetFile ( ) { upDownloader . upload ( testFile , bin ) ; byte [ ] b = upDownloader . getFile ( testFile ) ; "<AssertPlaceHolder>" ; } getFile ( java . lang . String ) { java . io . File f = new java . io . File ( basePath , com . github . emailtohl . building . common . utils . UpDownloader . getSystemPath ( relati... | org . junit . Assert . assertTrue ( java . util . Arrays . equals ( bin , b ) ) |
testUAndQuery_EncodingDelimiter ( ) { java . lang . String [ ] inputStr = new java . lang . String [ ] { "+" , "&" , "=" } ; for ( java . lang . String str : inputStr ) { java . lang . String matcher = "name=" + ( org . terasoluna . gfw . web . el . Functions . u ( str ) ) ; java . util . Map < java . lang . String , j... | org . junit . Assert . assertThat ( actual , org . hamcrest . CoreMatchers . is ( matcher ) ) |
testRDFSSubPropertyOf ( ) { org . apache . stanbol . reasoners . jena . JenaRDFSReasoningServiceTest . log . info ( "Testing<sp>rdfs:subPropertyOf<sp>inference<sp>with<sp>RDFS<sp>reasoner" ) ; com . hp . hpl . jena . rdf . model . Property collegueOf = TestData . model . createProperty ( ( ( TestData . TEST_NS ) + "col... | org . junit . Assert . assertTrue ( inferred . contains ( knowsHim ) ) |
testGetDisabledReason ( ) { "<AssertPlaceHolder>" ; verify ( dlg , times ( 2 ) ) . getDisabledReason ( ) ; verify ( autosaveMgr , never ( ) ) . autosave ( ) ; } getDisabledReason ( ) { return getDelegate ( ) . getDisabledReason ( ) ; } | org . junit . Assert . assertEquals ( dlg . getDisabledReason ( ) , user . getDisabledReason ( ) ) |
getBigDecimal ( ) { final java . lang . Float value = 1.2F ; final io . trane . ndbc . value . FloatValue wrapper = new io . trane . ndbc . value . FloatValue ( value ) ; "<AssertPlaceHolder>" ; } getBigDecimal ( ) { return new java . math . BigDecimal ( get ( ) ) ; } | org . junit . Assert . assertEquals ( new java . math . BigDecimal ( value ) , wrapper . getBigDecimal ( ) ) |
emptyLogger ( ) { org . jenkinsci . test . acceptance . po . JenkinsLogger logger = jenkins . createLogger ( "test" , java . util . Collections . singletonMap ( "" , Level . ALL ) ) ; "<AssertPlaceHolder>" ; } isEmpty ( ) { open ( ) ; return ( getElement ( by . css ( "#main-panel<sp>pre" ) ) ) == null ; } | org . junit . Assert . assertFalse ( logger . isEmpty ( ) ) |
restoreWithFilterSuccessfullyWithoutChecksumAndMatching ( ) { entry = new org . codice . ddf . configuration . migration . ImportMigrationExternalEntryImpl ( mockContext , com . google . common . collect . ImmutableMap . of ( MigrationEntryImpl . METADATA_NAME , org . codice . ddf . configuration . migration . ImportMi... | org . junit . Assert . assertThat ( entry . restore ( true , ( p ) -> true ) , org . hamcrest . CoreMatchers . equalTo ( true ) ) |
testWithNameWhenSameName ( ) { final com . allanbank . mongodb . bson . element . NullElement element = new com . allanbank . mongodb . bson . element . NullElement ( "foo" ) ; "<AssertPlaceHolder>" ; } withName ( java . lang . String ) { if ( getName ( ) . equals ( name ) ) { return this ; } return new com . allanbank... | org . junit . Assert . assertSame ( element , element . withName ( "foo" ) ) |
testText ( ) { label . setText ( "abc" ) ; "<AssertPlaceHolder>" ; } getText ( ) { checkWidget ( ) ; return getText ( 0 ) ; } | org . junit . Assert . assertEquals ( "abc" , label . getText ( ) ) |
createService ( ) { wizardAction . openNewLiferayModuleWizard ( ) ; wizardAction . newModule . prepareMaven ( project . getName ( ) , com . liferay . ide . ui . module . tests . SERVICE ) ; wizardAction . next ( ) ; wizardAction . newModuleInfo . openSelectServiceDialog ( ) ; dialogAction . prepareText ( "*lifecycleAct... | org . junit . Assert . assertTrue ( viewAction . project . visibleFileTry ( project . getName ( ) ) ) |
testReturnTypesCompileString ( ) { java . util . List < java . lang . String > ls = new java . util . ArrayList < java . lang . String > ( ) ; ls . add ( "homer" ) ; ls . add ( "marge" ) ; table . createListColumn ( "simpson" , java . lang . String . class , false ) ; attrs . set ( "simpson" , ls ) ; java . util . List... | org . junit . Assert . assertEquals ( ls , res ) |
testSelect ( ) { createArtistsDataSet ( ) ; org . apache . cayenne . query . SelectQuery < org . apache . cayenne . testdo . testmap . Artist > query = new org . apache . cayenne . query . SelectQuery ( org . apache . cayenne . testdo . testmap . Artist . class ) ; java . util . List < ? > objects = query . select ( co... | org . junit . Assert . assertEquals ( 20 , objects . size ( ) ) |
testCreate ( ) { "<AssertPlaceHolder>" ; } create ( ) { if ( null == ( ch . cyberduck . core . sparkle . Updater . CLASS ) ) { return null ; } final ch . cyberduck . core . sparkle . Updater updater = ch . cyberduck . core . sparkle . Updater . CLASS . sharedUpdater ( ) ; updater . setUserAgentString ( new ch . cyberdu... | org . junit . Assert . assertNotNull ( ch . cyberduck . core . sparkle . Updater . create ( ) ) |
test_writeInt ( int , java . lang . String ) { outputCompact . writeInt ( input ) ; "<AssertPlaceHolder>" ; } toString ( ) { return getClass ( ) . getSimpleName ( ) ; } | org . junit . Assert . assertEquals ( buf . toString ( ) , expected ) |
shouldNotEqualsWhenObjectHasTypeNotTab ( ) { "<AssertPlaceHolder>" ; } equals ( java . lang . Object ) { if ( ( this ) == other ) { return true ; } if ( ! ( other instanceof org . eclipse . che . ide . ext . runner . client . tabs . common . Tab ) ) { return false ; } org . eclipse . che . ide . ext . runner . client .... | org . junit . Assert . assertThat ( tab . equals ( new java . lang . Object ( ) ) , org . hamcrest . core . Is . is ( false ) ) |
customerListAfterGrouping ( ) { java . io . InputStream inputStream = null ; parameters . put ( "customer" , 103 ) ; parameters . put ( "order" , 10123 ) ; if ( ( inputStream = runAndRenderSampleReport ( "samplereports/Reporting<sp>Feature<sp>Examples/Grouping/CustomerListAfter_Grouping.rptdesign" , "xlsx" ) ) != null ... | org . junit . Assert . assertNotNull ( inputStream ) |
should_return_empty_List_if_given_Iterable_is_null ( ) { java . util . Collection < ? > c = null ; "<AssertPlaceHolder>" ; } nonNullElementsIn ( java . lang . Iterable ) { if ( org . fest . util . Iterables . isNullOrEmpty ( i ) ) { return emptyList ( ) ; } java . util . List < T > nonNull = new java . util . ArrayList... | org . junit . Assert . assertTrue ( org . fest . util . Iterables . nonNullElementsIn ( c ) . isEmpty ( ) ) |
testDeadMinionsCheckWithNoDeadMinions ( ) { tracker . reportMinionAlive ( com . facebook . buck . distributed . build_slave . MinionHealthTrackerTest . MINION_ONE , com . facebook . buck . distributed . build_slave . MinionHealthTrackerTest . MINION_ONE ) ; tracker . reportMinionAlive ( com . facebook . buck . distribu... | org . junit . Assert . assertTrue ( deadMinions . isEmpty ( ) ) |
testCompareSorteerVolgorde ( ) { final nl . bzk . brp . domain . berichtmodel . BijgehoudenPersoon bijgehoudenPersoon1 = bouwPersoon ( 1 , 2 ) ; final nl . bzk . brp . domain . berichtmodel . BijgehoudenPersoon bijgehoudenPersoon2 = bouwPersoon ( 2 , 1 ) ; final int compare = DefaultPersoonComparator . INSTANCE . compa... | org . junit . Assert . assertEquals ( ( - 1 ) , compare ) |
testDefault ( ) { org . apache . accumulo . core . data . Value v = new org . apache . accumulo . core . data . Value ( ) ; "<AssertPlaceHolder>" ; } get ( ) { return sb . toString ( ) ; } | org . junit . Assert . assertEquals ( 0 , v . get ( ) . length ) |
testConnectFutureBeforeChannelActive ( ) { io . netty . bootstrap . Bootstrap cb = new io . netty . bootstrap . Bootstrap ( ) ; io . netty . bootstrap . ServerBootstrap sb = new io . netty . bootstrap . ServerBootstrap ( ) ; cb . group ( io . netty . channel . local . LocalChannelTest . group1 ) . channel ( io . netty ... | org . junit . Assert . assertTrue ( promise . isSuccess ( ) ) |
testGetLineup ( ) { com . sonatype . s2 . p2lineup . model . P2Lineup lineup = new com . sonatype . s2 . p2lineup . model . P2Lineup ( ) ; lineup . setDescription ( "description" ) ; lineup . setGroupId ( "groupId-testGetLineup" ) ; lineup . setId ( "id-testGetLineup" ) ; lineup . setVersion ( "version-testGetLineup" )... | org . junit . Assert . assertEquals ( lineup , result ) |
ttlDirectoryDeleteReplay ( ) { alluxio . master . file . contexts . CreateDirectoryContext context = alluxio . master . file . contexts . CreateDirectoryContext . mergeFrom ( alluxio . grpc . CreateDirectoryPOptions . newBuilder ( ) . setRecursive ( true ) . setCommonOptions ( alluxio . grpc . FileSystemMasterCommonPOp... | org . junit . Assert . assertEquals ( fileInfo . getFileId ( ) , dirId ) |
testSetSelfIsNoOp ( ) { io . netty . handler . codec . http . HttpHeaders headers = new io . netty . handler . codec . http . DefaultHttpHeaders ( false ) ; headers . add ( "name" , "value" ) ; headers . set ( headers ) ; "<AssertPlaceHolder>" ; } size ( ) { return delegate . size ( ) ; } | org . junit . Assert . assertEquals ( 1 , headers . size ( ) ) |
testGetName ( ) { int result = fixture . getName ( ) ; "<AssertPlaceHolder>" ; } getName ( ) { return fName ; } | org . junit . Assert . assertEquals ( 1 , result ) |
testDeepCopyReflect_privateCtor ( ) { org . apache . avro . Schema schema = org . apache . crunch . types . avro . Avros . reflects ( org . apache . crunch . types . avro . PojoWithPrivateCtor . class ) . getSchema ( ) ; org . apache . crunch . types . avro . AvroDeepCopier < org . apache . crunch . types . avro . Pojo... | org . junit . Assert . assertEquals ( orig . getField ( ) , deepCopy . getField ( ) ) |
testGetTest2 ( ) { io . vertx . core . MultiMap mmap = newMultiMap ( ) ; java . lang . String name = "1" ; "<AssertPlaceHolder>" ; } get ( int ) { switch ( id ) { case 1 : return headerTableSize ; case 2 : return pushEnabled ? 1L : 0L ; case 3 : return maxConcurrentStreams ; case 4 : return ( ( long ) ( initialWindowSi... | org . junit . Assert . assertNull ( mmap . get ( name ) ) |
testURLWithAccents ( ) { java . lang . String urlWithAccents = "https://hu.wikipedia.org/wiki/rvztr_tkrfrgp" ; java . lang . String expected = ( "<a<sp>href=\"" + ( com . liferay . portal . kernel . util . HtmlUtil . escapeHREF ( urlWithAccents ) ) ) + "\">link</a>" ; java . lang . String actual = _htmlBBCodeTranslator... | org . junit . Assert . assertEquals ( expected , actual ) |
testCrash_119_ae_00 ( ) { org . nd4j . linalg . factory . Nd4j . create ( 1 ) ; lombok . val tg = org . nd4j . imports . graphmapper . tf . TFGraphMapper . getInstance ( ) . importGraph ( new org . nd4j . linalg . io . ClassPathResource ( "tf_graphs/examples/ae_00/frozen_model.pb" ) . getInputStream ( ) ) ; "<AssertPla... | org . junit . Assert . assertNotNull ( tg ) |
testResolve ( ) { org . unidal . dal . jdbc . query . QueryResolver resolver = lookup ( org . unidal . dal . jdbc . query . QueryResolver . class ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertNotNull ( resolver ) |
testCallVoidMethodOnInterfaceBlueprinRandomt ( ) { final net . sf . qualitytest . blueprint . BlueprintTest_interfaceMethod . SomeEntityBean bean = net . sf . qualitytest . blueprint . Blueprint . random ( ) . with ( "getId" , 42L ) . with ( "getName" , "Hello<sp>World!" ) . construct ( net . sf . qualitytest . bluepri... | org . junit . Assert . assertEquals ( "Hello<sp>World!" , bean . getName ( ) ) |
testLogoutNull ( ) { when ( repo . findByUserid ( ServiceTestConfiguration . USER_ID ) ) . thenReturn ( null ) ; io . pivotal . springtrader . accounts . domain . Account result = service . logout ( ServiceTestConfiguration . USER_ID ) ; "<AssertPlaceHolder>" ; } logout ( java . lang . String ) { io . pivotal . springt... | org . junit . Assert . assertNull ( result ) |
testGetMissingPathsRecursive2 ( ) { java . lang . String path = ( uri . getPath ( ) ) + "/path/to/log" ; org . apache . bookkeeper . util . ZkUtils . createFullPathOptimistic ( zkc . get ( ) , path , org . apache . distributedlog . DistributedLogConstants . EMPTY_BYTES , zkc . getDefaultACL ( ) , CreateMode . PERSISTEN... | org . junit . Assert . assertEquals ( java . util . Collections . emptyList ( ) , missingPaths ) |
createPolicyWithConfigurationAndConfigurationData02 ( ) { try ( java . io . InputStream is = io . gravitee . gateway . policy . PolicyConfigurationFactoryTest . class . getResourceAsStream ( "policy-configuration-02.json" ) ) { java . lang . String configuration = org . apache . commons . io . IOUtils . toString ( is ,... | org . junit . Assert . assertNotNull ( policyConfiguration ) |
testShowExecutionPlanWithParallelism ( ) { try { java . lang . String [ ] parameters = new java . lang . String [ ] { "-e" , "-p" , "17" , eu . stratosphere . client . CliFrontendTestUtils . getTestJarPath ( ) } ; eu . stratosphere . client . CliFrontendInfoTest . InfoTestCliFrontend testFrontend = new eu . stratospher... | org . junit . Assert . assertTrue ( ( retCode == 0 ) ) |
testGetNotNullHasTypeRefs ( ) { final org . kie . workbench . common . dmn . api . definition . HasTypeRef hasTypeRef = mock ( org . kie . workbench . common . dmn . api . definition . HasTypeRef . class ) ; final java . util . List < org . kie . workbench . common . dmn . api . definition . HasTypeRef > expectedHasTyp... | org . junit . Assert . assertEquals ( expectedHasTypeRefs , actualHasTypeRefs ) |
testGetInternalObject ( ) { com . amazonaws . services . kinesis . model . StreamDescription kinesisStreamDescription = new com . amazonaws . services . dynamodbv2 . streamsadapter . model . StreamDescriptionAdapter ( mockDescription ) ; com . amazonaws . services . dynamodbv2 . model . StreamDescription internalObject... | org . junit . Assert . assertSame ( mockDescription , internalObject ) |
exchangeWithDelayShouldRestart ( ) { network . thunder . core . communication . layer . high . payments . LNPaymentProcessor . TIMEOUT_NEGOTIATION = 500 ; processor12 . makePayment ( getMockPaymentData ( ) ) ; java . lang . Thread . sleep ( 100 ) ; network . thunder . core . communication . layers . high . TestTools . ... | org . junit . Assert . assertNull ( channel21 . readOutbound ( ) ) |
test4 ( ) { java . io . ByteArrayOutputStream baos = new java . io . ByteArrayOutputStream ( ) ; org . terrier . compression . integer . ByteOutputStream out = new org . terrier . compression . integer . ByteOutputStream ( baos ) ; byte [ ] arr = new byte [ ] { 1 , 2 , 3 , 4 , 5 } ; out . write ( arr , 0 , arr . length... | org . junit . Assert . assertEquals ( 314 , in . readVInt ( ) ) |
detect_A$String_CRLF ( ) { java . lang . String sourceCodeString = "foo\r\nbar\r\n" ; org . junithelper . core . meta . CurrentLineBreak actual = org . junithelper . core . extractor . CurrentLineBreakDetector . detect ( sourceCodeString ) ; org . junithelper . core . meta . CurrentLineBreak expected = org . junithelpe... | org . junit . Assert . assertThat ( actual , org . hamcrest . CoreMatchers . is ( org . hamcrest . CoreMatchers . equalTo ( expected ) ) ) |
testInvalidParameter ( ) { final net . violet . platform . datamodel . Lang frLang = getSiteFrLang ( ) ; final net . violet . platform . datamodel . User theOwner = new net . violet . platform . datamodel . mock . UserMock ( 42 , net . violet . common . StringShop . EMPTY_STRING , net . violet . common . StringShop . E... | org . junit . Assert . assertNull ( theResult ) |
getNumberOfProcessDeploymentInfosWithParameters ( ) { final org . bonitasoft . engine . persistence . QueryOptions options = new org . bonitasoft . engine . persistence . QueryOptions ( 0 , 10 ) ; final long userId = 9 ; final java . lang . String querySuffix = "suffix" ; when ( persistenceService . getNumberOfEntities... | org . junit . Assert . assertEquals ( 1L , result ) |
testSetLiteralWithNulls ( ) { java . lang . String [ ] exprs = new java . lang . String [ ] { "{<sp>}" , "{<sp>10<sp>}" , "{<sp>10<sp>,<sp>null<sp>}" , "{<sp>10<sp>,<sp>null<sp>,<sp>20}" , "{<sp>'10'<sp>,<sp>null<sp>}" , "{<sp>null,<sp>'10'<sp>,<sp>20<sp>}" } ; java . util . Set < ? > [ ] checks = new java . util . Set... | org . junit . Assert . assertTrue ( exprs [ t ] , checks [ t ] . equals ( o ) ) |
testEqualsWithEqualPixelRegions ( ) { edu . illinois . library . cantaloupe . resource . iiif . v1 . Region region1 = new edu . illinois . library . cantaloupe . resource . iiif . v1 . Region ( ) ; region1 . setPercent ( false ) ; region1 . setX ( 20.0F ) ; region1 . setY ( 20.0F ) ; region1 . setWidth ( 20.0F ) ; regi... | org . junit . Assert . assertEquals ( region1 , region2 ) |
testLoadPassword ( ) { final javax . crypto . SecretKey storedSecretKey = storeKeyIntoKeyStoreFile ( org . drools . core . util . KeyStoreHelperTest . KEY_PHRASE ) ; final java . net . URL serverKeyStoreURL = getClass ( ) . getResource ( org . drools . core . util . KeyStoreHelperTest . KEYSTORE_JCEKS_RESOURCE_NAME ) ;... | org . junit . Assert . assertEquals ( new java . lang . String ( storedSecretKey . getEncoded ( ) ) , passwordKey ) |
testSetValidationMessage_illegalArtifactId ( ) { enableUi ( ) ; getGroupIdField ( ) . setText ( "com.example" ) ; getArtifactIdField ( ) . setText ( "<:#=<sp>Illegal<sp>ID<sp>=#:>" ) ; "<AssertPlaceHolder>" ; verify ( dialogPage ) . setErrorMessage ( "Illegal<sp>Maven<sp>Artifact<sp>ID:<sp><:#=<sp>Illegal<sp>ID<sp>=#:>... | org . junit . Assert . assertFalse ( ui . setValidationMessage ( dialogPage ) ) |
testAdoptLeft ( ) { org . gradoop . common . model . impl . id . GradoopId v0 = org . gradoop . common . model . impl . id . GradoopId . get ( ) ; org . gradoop . common . model . impl . id . GradoopId e0 = org . gradoop . common . model . impl . id . GradoopId . get ( ) ; org . gradoop . common . model . impl . id . G... | org . junit . Assert . assertEquals ( org . gradoop . common . model . impl . properties . PropertyValue . create ( "Alice" ) , result . get ( 0 ) . getProperty ( 0 ) ) |
testToStringWithNullDatabaseName ( ) { final com . allanbank . mongodb . bson . DocumentReference ref = new com . allanbank . mongodb . bson . DocumentReference ( "c" , new com . allanbank . mongodb . bson . element . LongElement ( "a" , 1 ) ) ; final java . lang . String expected = "{<sp>'$ref'<sp>:<sp>'c',<sp>'$id'<s... | org . junit . Assert . assertEquals ( expected , result ) |
testGroovyVersionSupportsActionTrue ( ) { testMojo = new org . codehaus . gmavenplus . mojo . AbstractCompileMojoTest . TestMojo ( "1.5.0" ) ; "<AssertPlaceHolder>" ; } groovyVersionSupportsAction ( ) { return ( ( classWrangler . getGroovyVersion ( ) ) != null ) && ( groovyAtLeast ( minGroovyVersion ) ) ; } | org . junit . Assert . assertTrue ( testMojo . groovyVersionSupportsAction ( ) ) |
testCodeGenInterfaces ( ) { java . lang . String [ ] args = new java . lang . String [ ] { "-d" , output . getCanonicalPath ( ) , "/wadl/bookstore.xml" 1 , "custom.service" , "-tMap" , "{http://www.w3.org/2001/XMLSchema}date=java.util.List..String" , "-async<sp>getName,delete" , "-inheritResourceParams<sp>first" , "/wa... | org . junit . Assert . assertNotNull ( output . list ( ) ) |
elem_match_returns_false_when_no_values_in_array_match ( ) { com . redhat . lightblue . query . QueryExpression expr = com . redhat . lightblue . eval . EvalTestContext . queryExpressionFromJson ( "{'array':'field7','elemMatch':{'field':'elemf3','op':'>','rvalue':10}}" ) ; com . redhat . lightblue . eval . QueryEvaluat... | org . junit . Assert . assertFalse ( context . getResult ( ) ) |
order_03_shouldGenerateDailyDigestNoMessage ( ) { log . debug ( "In<sp>shouldGenerateDailyDigestNoMessage" ) ; mockAuthenticationOnUserService ( fr . ippon . tatami . service . MailDigestServiceTest . DAILY_DIGEST_USER ) ; userService . updateDailyDigestRegistration ( true ) ; org . mockito . ArgumentCaptor < java . ut... | org . junit . Assert . assertThat ( ( ( statuses . getValue ( ) . size ( ) ) == 0 ) , org . hamcrest . CoreMatchers . is ( true ) ) |
testLocatedBlockConstructorWithNullCachedLocs ( ) { org . apache . hadoop . hdfs . protocol . DatanodeInfo d = org . apache . hadoop . hdfs . DFSTestUtil . getLocalDatanodeInfo ( ) ; org . apache . hadoop . hdfs . protocol . DatanodeInfo [ ] ds = new org . apache . hadoop . hdfs . protocol . DatanodeInfo [ 1 ] ; ds [ 0... | org . junit . Assert . assertTrue ( ( ( cachedLocs . length ) == 0 ) ) |
testContentTypes ( ) { char [ ] [ ] javaLikeExtensions = org . eclipse . jdt . internal . core . util . Util . getJavaLikeExtensions ( ) ; char [ ] [ ] groovyLikeExtensions = org . eclipse . jdt . groovy . core . util . ContentTypeUtils . getGroovyLikeExtensions ( ) ; char [ ] [ ] javaButNotGroovyExtensions = org . ecl... | org . junit . Assert . assertEquals ( message , javaLikeExtensions . length , ( ( groovyLikeExtensions . length ) + ( javaButNotGroovyExtensions . length ) ) ) |
testMatchConditionAllDimensions1 ( ) { org . nd4j . linalg . api . ndarray . INDArray array = org . nd4j . linalg . factory . Nd4j . create ( new double [ ] { 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 } ) ; int val = ( ( int ) ( org . nd4j . linalg . factory . Nd4j . getExecutioner ( ) . exec ( new org . nd4j . linalg . ap... | org . junit . Assert . assertEquals ( 5 , val ) |
testExtractQuarterTimestamp ( ) { java . lang . String sqlText = ( "select<sp>ts,<sp>EXTRACT(QUARTER<sp>FROM<sp>ts)<sp>as<sp>\"QUARTER\"<sp>from<sp>" + ( com . splicemachine . derby . utils . SpliceDateFunctionsIT . tableWatcherI ) ) + "<sp>order<sp>by<sp>ts" ; try ( com . splicemachine . derby . utils . ResultSet rs =... | org . junit . Assert . assertEquals ( ( ( "\n" + sqlText ) + "\n" ) , expected , TestUtils . FormattedResult . ResultFactory . toStringUnsorted ( rs ) ) |
testMultiThread ( ) { final java . util . concurrent . CountDownLatch startLatch = new java . util . concurrent . CountDownLatch ( 1 ) ; final java . util . concurrent . CountDownLatch finishedLatch = new java . util . concurrent . CountDownLatch ( 10 ) ; final java . util . concurrent . atomic . AtomicBoolean failed =... | org . junit . Assert . assertFalse ( failed . get ( ) ) |
testCompare ( ) { final uk . gov . gchq . gaffer . parquetstore . partitioner . PartitionKey [ ] partitionKeys = new uk . gov . gchq . gaffer . parquetstore . partitioner . PartitionKey [ 6 ] ; partitionKeys [ 0 ] = new uk . gov . gchq . gaffer . parquetstore . partitioner . PartitionKey ( new java . lang . Object [ ] ... | org . junit . Assert . assertTrue ( ( ( partitionKeys [ ( i - 1 ) ] . compareTo ( partitionKeys [ i ] ) ) < 0 ) ) |
encodeAndDecode ( ) { java . lang . String input = ( ( "The<sp>date<sp>is:<sp>" + ( new java . util . Date ( ) ) ) + ",<sp>a<sp>random<sp>number<sp>is:<sp>" ) + ( new java . util . Random ( ) . nextLong ( ) ) ; java . lang . String encoded = org . aeonbits . owner . util . Base64 . encode ( input . getBytes ( ) ) ; byt... | org . junit . Assert . assertEquals ( input , new java . lang . String ( result ) ) |
testGetProxiedConnection ( ) { final com . allanbank . mongodb . client . connection . Connection mockConnetion = createMock ( com . allanbank . mongodb . client . connection . Connection . class ) ; mockConnetion . close ( ) ; expectLastCall ( ) ; replay ( mockConnetion ) ; final com . allanbank . mongodb . client . c... | org . junit . Assert . assertSame ( mockConnetion , conn . getProxiedConnection ( ) ) |
findCandidatesWithOneResult ( ) { System . out . println ( ( ( cz . metacentrum . perun . core . entry . VosManagerEntryIntegrationTest . CLASS_NAME ) + "findCandidatesWithOneResult" ) ) ; final cz . metacentrum . perun . core . api . Vo createdVo = vosManagerEntry . createVo ( sess , myVo ) ; addExtSourceDelegate ( cr... | org . junit . Assert . assertEquals ( 1 , candidates . size ( ) ) |
testInterruptionAffects ( ) { connection = connectionFactory . createConnection ( ) ; connection . start ( ) ; session = connection . createSession ( false , ActiveMQSession . INDIVIDUAL_ACKNOWLEDGE ) ; javax . jms . Queue queue = session . createQueue ( "AMQ3732Test" ) ; final java . util . concurrent . LinkedBlocking... | org . junit . Assert . assertEquals ( NUM_MESSAGES , totalConsumed . get ( ) ) |
testCloneOfCloneable ( ) { final org . apache . commons . lang3 . ObjectUtilsTest . CloneableString string = new org . apache . commons . lang3 . ObjectUtilsTest . CloneableString ( "apache" ) ; final org . apache . commons . lang3 . ObjectUtilsTest . CloneableString stringClone = org . apache . commons . lang3 . Objec... | org . junit . Assert . assertEquals ( "apache" , stringClone . getValue ( ) ) |
testGenerateScoreForCheckmate_M8 ( ) { testPly = eubos . position . MateScoreGeneratorTest . LAST_PLY ; score = classUnderTest . generateScoreForCheckmate ( testPly ) ; "<AssertPlaceHolder>" ; } generateScoreForCheckmate ( int ) { int totalMovesSearched = ( searchDepth ) / ( eubos . position . MateScoreGenerator . PLIE... | org . junit . Assert . assertTrue ( ( ( score ) == ( eubos . board . pieces . King . MATERIAL_VALUE ) ) ) |
testBrokenExternalLinkButValueIsCached ( ) { org . kie . internal . utils . KieHelper kieHelper = new org . kie . internal . utils . KieHelper ( ) ; java . io . InputStream dtableIs = this . getClass ( ) . getResourceAsStream ( "BZ967609-brokenExtLinkButValueCached.xls" ) ; kieHelper . addResource ( org . kie . interna... | org . junit . Assert . assertNotNull ( kbase ) |
testConvertReply ( ) { final com . allanbank . mongodb . bson . builder . DocumentBuilder db = com . allanbank . mongodb . bson . builder . BuilderFactory . start ( ) . addInteger ( "ok" , 1 ) ; db . pushArray ( "results" ) . push ( ) ; final java . util . List < com . allanbank . mongodb . bson . Document > docs = jav... | org . junit . Assert . assertEquals ( java . util . Collections . singletonList ( com . allanbank . mongodb . bson . builder . BuilderFactory . start ( ) . build ( ) ) , callback . convert ( reply ) . toList ( ) ) |
testHuwelijkOfGpParserGeenWaarden ( ) { final nl . bzk . migratiebrp . bericht . model . lo3 . parser . Lo3HuwelijkOfGpParser parser = new nl . bzk . migratiebrp . bericht . model . lo3 . parser . Lo3HuwelijkOfGpParser ( ) ; final nl . bzk . migratiebrp . conversie . model . lo3 . Lo3Stapel < nl . bzk . migratiebrp . c... | org . junit . Assert . assertNull ( parsedInhoud ) |
testAddCrisisType ( ) { qa . qcri . aidr . dbmanager . dto . CrisisTypeDTO addCrisisType = new qa . qcri . aidr . dbmanager . dto . CrisisTypeDTO ( ) ; addCrisisType . setName ( qa . qcri . aidr . dbmanager . ejb . remote . facade . imp . TestCrisisTypeResourceFacadeImp . sampleCrisisTypeName ) ; qa . qcri . aidr . dbm... | org . junit . Assert . assertEquals ( qa . qcri . aidr . dbmanager . ejb . remote . facade . imp . TestCrisisTypeResourceFacadeImp . sampleCrisisTypeName , result . getName ( ) ) |
testPushWithBadScheme ( ) { expectedException . expect ( org . apache . druid . storage . hdfs . RuntimeException . class ) ; expectedException . expectMessage ( "No<sp>FileSystem<sp>for<sp>scheme" ) ; testUsingScheme ( "xyzzy" ) ; "<AssertPlaceHolder>" ; } testUsingScheme ( java . lang . String ) { org . apache . hado... | org . junit . Assert . assertTrue ( false ) |
shouldCompareEqualArrayWithString ( ) { final uk . gov . gchq . gaffer . data . element . comparison . ComparableOrToStringComparator comparator = new uk . gov . gchq . gaffer . data . element . comparison . ComparableOrToStringComparator ( ) ; final int result = comparator . compare ( new java . lang . Integer [ ] { 1... | org . junit . Assert . assertEquals ( 0 , result ) |
testGetNodeLabelForLocation ( ) { org . opennms . netmgt . model . OnmsNode node = new org . opennms . netmgt . model . OnmsNode ( m_locationDao . getDefaultLocation ( ) , "openNMS@Apex" ) ; m_nodeDao . saveOrUpdate ( node ) ; java . util . List < org . opennms . netmgt . model . OnmsNode > nodes = m_nodeDao . findByLa... | org . junit . Assert . assertEquals ( nodes . get ( 0 ) , node ) |
shouldEqualsEventsWhenSameCountLinesRemovedInLinesRemovedEventType ( ) { com . codenjoy . dojo . tetris . model . GlassEvent event = new com . codenjoy . dojo . tetris . model . GlassEvent ( LINES_REMOVED , 4 ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertTrue ( event . equals ( new com . codenjoy . dojo . tetris . model . GlassEvent ( LINES_REMOVED , 4 ) ) ) |
canConvertToProperties ( ) { com . treasuredata . client . ProxyConfig . ProxyConfigBuilder pb = new com . treasuredata . client . ProxyConfig . ProxyConfigBuilder ( ) ; pb . setHost ( "localhost" ) ; pb . setPort ( 8081 ) ; pb . setUser ( "dummy" ) ; pb . setPassword ( "hello" ) ; com . treasuredata . client . TDClien... | org . junit . Assert . assertEquals ( p1 , p2 ) |
existanceTest ( ) { org . apache . gossip . crdt . PNCounter counter = new org . apache . gossip . crdt . PNCounter ( mockManagers . get ( 0 ) ) ; "<AssertPlaceHolder>" ; } value ( ) { java . util . Map < java . lang . String , org . apache . gossip . lock . vote . VoteCandidate > copy = new java . util . concurrent . ... | org . junit . Assert . assertEquals ( 0 , ( ( long ) ( counter . value ( ) ) ) ) |
whenCollectionIsNotEmpty ( ) { try { colletion . add ( java . lang . Integer . valueOf ( 1 ) ) ; checkerCollection . checkIsCollectionISNotEmpty ( colletion ) ; "<AssertPlaceHolder>" ; } catch ( com . stratio . explorer . exceptions . NotPropertyFoundException e ) { org . junit . Assert . fail ( "mothod<sp>should<sp>no... | org . junit . Assert . assertTrue ( "mothod<sp>should<sp>not<sp>thorw<sp>exception<sp>" , true ) |
testClear ( ) { resourceRegistry . add ( "name" , mock ( org . eclipse . rap . rwt . service . ResourceLoader . class ) ) ; resourceRegistry . clear ( ) ; "<AssertPlaceHolder>" ; } getResourceRegistrations ( ) { return resources . toArray ( new org . eclipse . rap . rwt . internal . resources . ResourceRegistry . Resou... | org . junit . Assert . assertEquals ( 0 , resourceRegistry . getResourceRegistrations ( ) . length ) |
step_3 ( ) { org . sejda . model . parameter . AddBackPagesParameters parameters = defaultCommandLine ( ) . with ( "-n" , "3" ) . invokeSejdaConsole ( ) ; "<AssertPlaceHolder>" ; } getStep ( ) { return step ; } | org . junit . Assert . assertEquals ( 3 , parameters . getStep ( ) ) |
search ( ) { final org . apache . olingo . ext . proxy . api . Search < org . apache . olingo . fit . proxy . staticservice . odatawcfservice . types . Person , org . apache . olingo . fit . proxy . staticservice . odatawcfservice . types . PersonCollection > search = container . getPeople ( ) . createSearch ( ) . setS... | org . junit . Assert . assertFalse ( result . isEmpty ( ) ) |
testStartNoHttpWhenBkHttpEnabled ( ) { org . apache . commons . configuration . PropertiesConfiguration config = new org . apache . commons . configuration . PropertiesConfiguration ( ) ; config . setProperty ( PrometheusMetricsProvider . PROMETHEUS_STATS_HTTP_ENABLE , true ) ; config . setProperty ( "httpServerEnabled... | org . junit . Assert . assertNull ( provider . server ) |
noExceptionInContext_ReturnsFalse ( ) { "<AssertPlaceHolder>" ; } shouldRetry ( java . util . function . Consumer ) { return condition . shouldRetry ( software . amazon . awssdk . core . retry . RetryPolicyContext . builder ( ) . applyMutation ( builder ) . build ( ) ) ; } | org . junit . Assert . assertFalse ( shouldRetry ( ( builder ) -> builder . exception ( null ) ) ) |
testSerialization ( ) { org . jfree . chart . ChartRenderingInfo i1 = new org . jfree . chart . ChartRenderingInfo ( ) ; i1 . setChartArea ( new java . awt . geom . Rectangle2D . Double ( 1.0 , 2.0 , 3.0 , 4.0 ) ) ; org . jfree . chart . ChartRenderingInfo i2 = ( ( org . jfree . chart . ChartRenderingInfo ) ( org . jfr... | org . junit . Assert . assertEquals ( i1 , i2 ) |
listTilde ( ) { org . springframework . expression . Expression expr = org . springframework . sync . PathToSpEL . pathToExpression ( "/~/description" ) ; java . util . List < org . springframework . sync . Todo > todos = new java . util . ArrayList < org . springframework . sync . Todo > ( ) ; todos . add ( new org . ... | org . junit . Assert . assertEquals ( "C" , ( ( java . lang . String ) ( expr . getValue ( todos ) ) ) ) |
testReservedCharacterUnEscapingInUserId ( ) { org . lilyproject . repository . api . IdGenerator idGenerator = new org . lilyproject . repository . impl . id . IdGeneratorImpl ( ) ; java . lang . String idString = "USER.special\\.characters\\,are\\=fun\\\\.key=hoeba\\=hoep" ; org . lilyproject . repository . api . Reco... | org . junit . Assert . assertEquals ( idString , encodedString ) |
returning2 ( ) { new org . n3r . eql . Eqll ( ) . update ( "prepareTable4MyProcedure" ) . execute ( ) ; java . util . List < java . lang . String > ret = new org . n3r . eql . Eqll ( ) . params ( 10 ) . procedure ( "myprocedure2" ) . execute ( ) ; "<AssertPlaceHolder>" ; } size ( ) { return parts . size ( ) ; } | org . junit . Assert . assertThat ( ( ( ret . size ( ) ) > 0 ) , org . hamcrest . CoreMatchers . is ( true ) ) |
testBuildWithDisabledDefaultConstraintsWithOrderBy ( ) { unit . setActive ( false ) ; unit . setSecurity ( false ) ; org . lnu . is . pagination . OrderBy order1 = new org . lnu . is . pagination . OrderBy ( "name" , org . lnu . is . pagination . OrderByType . ASC ) ; java . util . List < org . lnu . is . pagination . ... | org . junit . Assert . assertEquals ( expectedSql , actualQuery ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.