input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
testPredictMissingFixturesTwice ( ) { com . sap . pto . paul . AveragePaul . predictMissingFixtures ( new com . sap . pto . dao . FixtureDAO ( ) . getAll ( ) , new com . sap . pto . dao . PredictionDAO ( ) . getAll ( ) ) ; com . sap . pto . paul . AveragePaul . predictMissingFixtures ( new com . sap . pto . dao . Fixtu... | org . junit . Assert . assertEquals ( 2 , new com . sap . pto . dao . PredictionDAO ( ) . getAll ( ) . size ( ) ) |
testJoinAllNullElements ( ) { java . util . Set < java . lang . String > elements = new java . util . LinkedHashSet ( ) ; java . lang . String separator = "," ; elements . add ( null ) ; elements . add ( null ) ; java . lang . String join = org . apache . catalina . filters . CorsFilter . join ( elements , separator ) ... | org . junit . Assert . assertTrue ( "" . equals ( join ) ) |
testBackendDefault ( ) { final com . typesafe . config . Config config = com . typesafe . config . ConfigFactory . parseMap ( com . google . common . collect . ImmutableMap . of ( ) ) ; final com . spotify . apollo . environment . ApolloConfig sut = new com . spotify . apollo . environment . ApolloConfig ( config ) ; "... | org . junit . Assert . assertThat ( sut . backend ( ) , org . hamcrest . Matchers . is ( "" ) ) |
testGetInstance ( ) { System . out . println ( "getInstance" ) ; com . bixly . pastevid . download . DownloadManager result = com . bixly . pastevid . download . DownloadManager . getInstance ( ) ; "<AssertPlaceHolder>" ; } getInstance ( ) { if ( ( com . bixly . pastevid . download . DownloadManager . instance ) == nul... | org . junit . Assert . assertNotNull ( result ) |
testDifferentCaseLookup ( ) { java . lang . String entry1 = "1a" ; java . lang . String entry2 = "1A" ; opennlp . tools . dictionary . Dictionary dict = getDict ( ) ; dict . put ( asSL ( entry1 ) ) ; java . util . Set < java . lang . String > set = dict . asStringSet ( ) ; "<AssertPlaceHolder>" ; } contains ( java . la... | org . junit . Assert . assertTrue ( set . contains ( entry2 ) ) |
testIsWarnEnabled ( ) { org . apache . commons . logging . Log mock = createStrictMock ( org . apache . commons . logging . Log . class ) ; expect ( mock . isWarnEnabled ( ) ) . andReturn ( true ) ; replay ( mock ) ; org . jboss . netty . logging . InternalLogger logger = new org . jboss . netty . logging . CommonsLogg... | org . junit . Assert . assertTrue ( logger . isWarnEnabled ( ) ) |
checkSuperAdminAccessToComponentType ( ) { final org . sentilo . web . catalog . domain . ComponentType resource = new org . sentilo . web . catalog . domain . ComponentType ( "1" ) ; when ( userDetails . isSuperAdminUser ( ) ) . thenReturn ( true ) ; when ( service . findAndThrowErrorIfNotExist ( any ( org . sentilo .... | org . junit . Assert . assertTrue ( allowedCRUL ) |
testTest ( ) { logger . info ( "test" ) ; com . datumbox . framework . common . dataobjects . TransposeDataCollection transposeDataCollection = new com . datumbox . framework . common . dataobjects . TransposeDataCollection ( ) ; transposeDataCollection . put ( 0 , new com . datumbox . framework . common . dataobjects ... | org . junit . Assert . assertEquals ( expResult , result ) |
getSecurityDescriptor ( ) { final com . rapid7 . client . dcerpc . msrrp . dto . RegistryKeyInfo keyInfo = new com . rapid7 . client . dcerpc . msrrp . dto . RegistryKeyInfo ( 0 , 0 , 0 , 0 , 0 , 0 , 255 , 0L ) ; "<AssertPlaceHolder>" ; } getSecurityDescriptor ( ) { return securityDescriptor ; } | org . junit . Assert . assertEquals ( 255 , keyInfo . getSecurityDescriptor ( ) ) |
testExtendedDataDelete ( ) { graph . prepareVertex ( "v1" , org . vertexium . test . GraphTestBase . VISIBILITY_A ) . addExtendedData ( "table1" , "row1" , "name" , "value" , org . vertexium . test . GraphTestBase . VISIBILITY_A ) . save ( AUTHORIZATIONS_A ) ; graph . flush ( ) ; graph . deleteVertex ( "v1" , AUTHORIZA... | org . junit . Assert . assertEquals ( 0 , searchResults . getTotalHits ( ) ) |
testFindAllActive ( ) { boolean isActive = true ; org . oscarehr . common . model . CtlRelationships ctlRelation1 = new org . oscarehr . common . model . CtlRelationships ( ) ; org . oscarehr . common . dao . utils . EntityDataGenerator . generateTestDataForModelClass ( ctlRelation1 ) ; ctlRelation1 . setActive ( isAct... | org . junit . Assert . assertTrue ( true ) |
testEvaluateTwoIndexTwoVarOrder6 ( ) { final java . lang . String indexSparqlString = "" + ( ( ( ( "SELECT<sp>?e<sp>?l<sp>?c<sp>" + "{" ) + "<sp>?e<sp>a<sp>?c<sp>.<sp>" ) + "<sp>?e<sp><http://www.w3.org/2000/01/rdf-schema#label><sp>?l<sp>" ) + "}" ) ; final java . lang . String indexSparqlString2 = "" + ( ( ( ( "SELECT... | org . junit . Assert . assertEquals ( true , ipv . isValid ( tup ) ) |
shouldRunTaskLater ( ) { java . lang . Runnable task = ( ) -> { } ; org . bukkit . scheduler . BukkitTask bukkitTask = mock ( org . bukkit . scheduler . BukkitTask . class ) ; long delay = 400 ; given ( scheduler . runTaskLater ( authMe , task , delay ) ) . willReturn ( bukkitTask ) ; org . bukkit . scheduler . BukkitT... | org . junit . Assert . assertThat ( resultingTask , org . hamcrest . Matchers . equalTo ( bukkitTask ) ) |
testProfType ( ) { org . apache . uima . resource . metadata . TypeSystemDescription tsd = org . apache . uima . fit . factory . TypeSystemDescriptionFactory . createTypeSystemDescription ( "desc.types.TestTypeSystemDescriptor" ) ; org . apache . uima . cas . CAS cas = org . apache . uima . util . CasCreationUtils . cr... | org . junit . Assert . assertEquals ( possibleValues , exValues ) |
zouMeldingMoetenGevenOmdatVaderNaKindIsGeboren ( ) { final nl . bzk . brp . model . operationeel . kern . FamilierechtelijkeBetrekkingModel relatieModel = mock ( nl . bzk . brp . model . operationeel . kern . FamilierechtelijkeBetrekkingModel . class ) ; final nl . bzk . brp . model . bericht . kern . BetrokkenheidBeri... | org . junit . Assert . assertThat ( meldingen . size ( ) , org . hamcrest . core . Is . is ( 1 ) ) |
testGenerateHMAC_SHA256 ( ) { de . rub . nds . tlsattacker . core . util . StaticTicketCryptoTest . LOGGER . info ( "Generate<sp>HMAC<sp>SHA256" ) ; byte [ ] plaintext = de . rub . nds . modifiablevariable . util . ArrayConverter . hexStringToByteArray ( "4869205468657265" ) ; byte [ ] key = de . rub . nds . modifiable... | org . junit . Assert . assertArrayEquals ( expResult , result ) |
testComment ( ) { java . io . StringWriter stringWriter = new java . io . StringWriter ( ) ; createXmlEventWriter ( stringWriter ) . add ( createXmlEventReader ( "<!--james-->" ) ) ; "<AssertPlaceHolder>" ; } toString ( ) { return ( ( ( ( ( ( ( ( ( "[pri=" + ( facility ) ) + "." ) + ( severity ) ) + "<sp>tag=" ) + ( ta... | org . junit . Assert . assertEquals ( "<!--james-->" , stringWriter . toString ( ) ) |
testCoerceIntegerToNumber ( ) { java . lang . Integer input = java . lang . Integer . valueOf ( 4390241 ) ; java . lang . Object output = org . apache . el . lang . ELSupport . coerceToType ( input , org . apache . el . lang . Number . class ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertEquals ( input , output ) |
testGetHeight_ensureValueIsAsExpected ( ) { final int length = StaticGrid . TILE_GRID . getColumn ( 0 ) . length ; "<AssertPlaceHolder>" ; } getColumn ( int ) { if ( ( columnIndex >= ( tiles [ 0 ] . length ) ) || ( columnIndex < 0 ) ) { return com . valkryst . VTerminal . TileGrid . EMPTY_ARRAY ; } final com . valkryst... | org . junit . Assert . assertEquals ( 6 , length ) |
testHasNext_EmptyData ( ) { this . it = new com . taobao . metamorphosis . consumer . MessageIterator ( "test" , new byte [ 0 ] ) ; "<AssertPlaceHolder>" ; } hasNext ( ) { return it . hasNext ( ) ; } | org . junit . Assert . assertFalse ( this . it . hasNext ( ) ) |
testZeroBaselineRateShouldBeDefined ( ) { org . drugis . addis . entities . RateMeasurement base = new org . drugis . addis . entities . BasicRateMeasurement ( 0 , 100 ) ; org . drugis . addis . entities . RateMeasurement subj = new org . drugis . addis . entities . BasicRateMeasurement ( 50 , 100 ) ; org . drugis . ad... | org . junit . Assert . assertTrue ( or . isDefined ( ) ) |
testProcessing ( ) { this . processor . start ( ) ; this . processor . storeMessage ( new net . roboconf . messaging . api . messages . from_dm_to_agent . MsgCmdResynchronize ( ) ) ; java . lang . Thread . sleep ( 1000 ) ; this . processor . stopProcessor ( ) ; "<AssertPlaceHolder>" ; } getMessageQueue ( ) { return thi... | org . junit . Assert . assertEquals ( 0 , this . processor . getMessageQueue ( ) . size ( ) ) |
testBasicScenario_NoElements ( ) { org . mockito . Mockito . when ( daoMock . getData ( ) ) . thenReturn ( new int [ ] { } ) ; "<AssertPlaceHolder>" ; } findGreatest ( ) { int greatest = Integer . MIN_VALUE ; int [ ] data = someCdiDao . getData ( ) ; for ( int value : data ) { if ( value > greatest ) { greatest = value... | org . junit . Assert . assertEquals ( Integer . MIN_VALUE , business . findGreatest ( ) ) |
testGetBytes ( ) { java . sql . PreparedStatement preparedStatement = createMock ( java . sql . PreparedStatement . class ) ; java . sql . ResultSet resultSet = createMock ( java . sql . ResultSet . class ) ; int colN = 120 ; byte [ ] val = new byte [ ] { 23 , 1 , 17 } ; expect ( resultSet . getMetaData ( ) ) . andRetu... | org . junit . Assert . assertTrue ( results . getBytes ( colN ) . equals ( val ) ) |
saveTopic ( ) { org . swarmcom . jsynapse . domain . Room room = roomService . saveTopic ( "abcdef0123456789:swarmcom.org" , "Room<sp>Topic" ) ; "<AssertPlaceHolder>" ; } getTopic ( ) { return topic ; } | org . junit . Assert . assertEquals ( "Room<sp>Topic" , room . getTopic ( ) ) |
should_create_query_with_order_by_only ( ) { final java . lang . String name = "findByOrderByIdAsc" ; final java . lang . String expected = "select<sp>e<sp>from<sp>Simple<sp>e<sp>" + "order<sp>by<sp>e.id<sp>asc" ; java . lang . String result = com . ctp . cdi . query . builder . part . QueryRoot . create ( name , dao )... | org . junit . Assert . assertEquals ( expected , result ) |
shouldProduceSchemaValidatedXml ( ) { java . lang . String actualXml = net . ripe . rpki . commons . provisioning . payload . list . request . ResourceClassListQueryPayloadBuilderTest . SERIALIZER . serialize ( net . ripe . rpki . commons . provisioning . payload . list . request . ResourceClassListQueryPayloadBuilderT... | org . junit . Assert . assertTrue ( net . ripe . rpki . commons . provisioning . payload . RelaxNgSchemaValidator . validateAgainstRelaxNg ( actualXml ) ) |
testCanvasCommandAllow ( ) { makeCommand ( 0 ) ; final org . kie . workbench . common . stunner . core . command . Command < org . kie . workbench . common . stunner . core . client . canvas . AbstractCanvasHandler , org . kie . workbench . common . stunner . core . client . command . CanvasViolation > canvasCommand = ... | org . junit . Assert . assertEquals ( CanvasCommandResultBuilder . SUCCESS , canvasCommand . allow ( canvasHandler ) ) |
ancestor ( ) { com . google . appengine . api . datastore . Key key = org . slim3 . datastore . DatastoreUtil . put ( ds , null , new com . google . appengine . api . datastore . Entity ( "Parent" ) ) ; org . slim3 . datastore . DatastoreUtil . put ( ds , null , new com . google . appengine . api . datastore . Entity (... | org . junit . Assert . assertThat ( list . size ( ) , org . hamcrest . CoreMatchers . is ( 1 ) ) |
testFindJobProperties_inexitingJob ( ) { net . roboconf . core . model . runtime . ScheduledJob job = this . scheduler . findJobProperties ( "inexisting" ) ; "<AssertPlaceHolder>" ; } findJobProperties ( java . lang . String ) { this . logger . fine ( ( "Roboconf's<sp>scheduler<sp>is<sp>about<sp>to<sp>find<sp>the<sp>pr... | org . junit . Assert . assertNull ( job ) |
testDestinationNodeDestinationName ( ) { org . springframework . cloud . dataflow . core . dsl . DestinationNode node = new org . springframework . cloud . dataflow . core . dsl . DestinationNode ( 0 , 0 , "foo.bar.bazz" , null ) ; "<AssertPlaceHolder>" ; } getDestinationName ( ) { return destinationNode . getDestinati... | org . junit . Assert . assertEquals ( "foo.bar.bazz" , node . getDestinationName ( ) ) |
itShouldReturnNullIfPathIsAbsoluteAndNonExisting ( ) { fileSupport = new jdk . tools . jaotc . test . collect . FakeFileSupport ( jdk . tools . jaotc . test . collect . Utils . set ( ) , jdk . tools . jaotc . test . collect . Utils . set ( ) ) ; jdk . tools . jaotc . test . collect . SearchPath target = new jdk . tools... | org . junit . Assert . assertNull ( result ) |
roundtrip ( ) { final java . lang . String value = "hello<sp>world" ; final java . lang . String encoding = "UTF-8" ; org . exist . xquery . functions . util . BinaryToStringTest . TestableBinaryToString testable = new org . exist . xquery . functions . util . BinaryToStringTest . TestableBinaryToString ( new org . exi... | org . junit . Assert . assertEquals ( value , result . getStringValue ( ) ) |
testArrayLeftDivideEquals ( ) { jama . Matrix COMPARE = new jama . Matrix ( A . getRowDimension ( ) , A . getColumnDimension ( ) , 1.0 ) ; jama . Matrix TMP = R . copy ( ) ; TMP . arrayLeftDivideEquals ( R ) ; "<AssertPlaceHolder>" ; } arrayLeftDivideEquals ( jama . FloatMatrix ) { checkFloatMatrixDimensions ( B ) ; fo... | org . junit . Assert . assertEquals ( TMP , COMPARE ) |
testRemoveFromSet3 ( ) { final java . util . Set < nl . bzk . migratiebrp . conversie . model . validatie . Periode > testSet = new java . util . HashSet ( ) ; testSet . add ( new nl . bzk . migratiebrp . conversie . model . validatie . Periode ( 8L , 14L ) ) ; testSet . add ( new nl . bzk . migratiebrp . conversie . m... | org . junit . Assert . assertTrue ( testResult . isEmpty ( ) ) |
testCollectTails_cyclic ( ) { com . asakusafw . utils . graph . Graph < java . lang . Integer > graph = com . asakusafw . utils . graph . Graphs . newInstance ( ) ; com . asakusafw . utils . graph . GraphsTest . addPath ( graph , 1 , 2 , 3 , 4 , 1 ) ; "<AssertPlaceHolder>" ; } collectTails ( com . asakusafw . utils . g... | org . junit . Assert . assertThat ( com . asakusafw . utils . graph . Graphs . collectTails ( graph ) , is ( set ( ) ) ) |
testParseSuperErr ( ) { actions = new java . util . HashMap < java . lang . String , java . lang . String > ( ) { { put ( "aaa" , "bbb" ) ; } } ; target = new org . o3project . odenos . core . component . network . flow . query . OFPFlowActionCopyTtlInQuery ( actions ) ; "<AssertPlaceHolder>" ; } parse ( ) { if ( ! ( s... | org . junit . Assert . assertThat ( target . parse ( ) , org . hamcrest . CoreMatchers . is ( false ) ) |
testThatWhenNoDelegateIsSuppliedTheDelegateIsAssumedToBeTheListenerAdapterItself ( ) { "<AssertPlaceHolder>" ; } getDelegate ( ) { return this . delegate ; } | org . junit . Assert . assertSame ( adapter , adapter . getDelegate ( ) ) |
syncPropertyDefinitions ( ) { org . apache . jackrabbit . oak . plugins . index . lucene . util . IndexDefinitionBuilder defnb = new org . apache . jackrabbit . oak . plugins . index . lucene . util . IndexDefinitionBuilder ( ) ; defnb . indexRule ( "nt:base" ) . property ( "foo" ) . sync ( ) ; org . apache . jackrabbi... | org . junit . Assert . assertTrue ( defn . hasSyncPropertyDefinitions ( ) ) |
serialize ( ) { com . google . gson . Gson gson = com . github . seratch . jslack . common . json . GsonFactory . createSnakeCase ( ) ; com . github . seratch . jslack . api . model . event . SubteamCreatedEvent event = new com . github . seratch . jslack . api . model . event . SubteamCreatedEvent ( ) ; java . lang . ... | org . junit . Assert . assertThat ( generatedJson , org . hamcrest . CoreMatchers . is ( expectedJson ) ) |
testSystemicSamplingProbs ( ) { org . apache . commons . math3 . stat . inference . BinomialTest bt = new org . apache . commons . math3 . stat . inference . BinomialTest ( ) ; double alpha = 1.0E-4 ; int [ ] counts = new int [ ] { 1 , 140 , 14 , 20 , 13 , 110 , 4 , 29 , 90 , 34 , 1 , 29 , 230 , 1 } ; int sum = cc . ma... | org . junit . Assert . assertTrue ( ( p_value > alpha ) ) |
test_3 ( ) { final org . erlide . core . builder . CompilerOptions prefs = new org . erlide . core . builder . CompilerOptions ( ) ; prefs . setListOption ( CompilerOptions . DEFINE , new org . eclipse . xtext . xbase . lib . Pair < java . lang . String , java . lang . String > ( "Macro" , null ) ) ; final java . lang ... | org . junit . Assert . assertEquals ( expect , actual ) |
testGetCurrentNoMoreRecords ( ) { org . talend . components . jira . runtime . reader . JiraProjectsReader jiraReader = new org . talend . components . jira . runtime . reader . JiraProjectsReader ( source ) ; boolean hasNext = jiraReader . start ( ) ; while ( hasNext ) { hasNext = jiraReader . advance ( ) ; } "<Assert... | org . junit . Assert . assertFalse ( jiraReader . advance ( ) ) |
testBondPermutation ( ) { org . openscience . cdk . interfaces . IAtomContainer pamine = org . openscience . cdk . fingerprint . FingerprinterTest . makePropylAmine ( ) ; org . openscience . cdk . fingerprint . Fingerprinter fp = new org . openscience . cdk . fingerprint . Fingerprinter ( ) ; org . openscience . cdk . ... | org . junit . Assert . assertTrue ( bs1 . equals ( bs2 ) ) |
isDeleted_negative ( ) { org . oscm . app . domain . ServiceInstance si = new org . oscm . app . domain . ServiceInstance ( ) ; si . setSubscriptionId ( "subscriptionId" ) ; "<AssertPlaceHolder>" ; } isDeleted ( ) { return false ; } | org . junit . Assert . assertFalse ( si . isDeleted ( ) ) |
testHttpURLSetValue ( ) { final java . lang . String urlValue = "http://www.geoserver.org/" ; java . util . Map < java . lang . String , java . lang . Object > params = new java . util . HashMap < java . lang . String , java . lang . Object > ( ) ; org . apache . wicket . model . IModel model = org . apache . wicket . ... | org . junit . Assert . assertEquals ( urlValue , urlModel . getObject ( ) ) |
testIsBuildingProjectTriggeredTrue ( ) { com . sonymobile . tools . gerrit . gerritevents . dto . events . PatchsetCreated event = com . sonyericsson . hudson . plugins . gerrit . trigger . mock . Setup . createPatchsetCreated ( ) ; com . sonyericsson . hudson . plugins . gerrit . trigger . gerritnotifier . model . Bui... | org . junit . Assert . assertTrue ( instance . isBuilding ( event , project ) ) |
testReadValue_FewParameter ( ) { "<AssertPlaceHolder>" ; } | org . junit . Assert . assertThat ( result , org . hamcrest . CoreMatchers . is ( true ) ) |
testSameCacheManager ( ) { javax . cache . spi . CachingProvider p = javax . cache . Caching . getCachingProvider ( ) ; javax . cache . CacheManager cm1 = p . getCacheManager ( ) ; javax . cache . CacheManager cm2 = p . getCacheManager ( ) ; "<AssertPlaceHolder>" ; } getCacheManager ( ) { return getCacheManager ( getDe... | org . junit . Assert . assertTrue ( ( cm1 == cm2 ) ) |
testHasProductAttributeWithPresentProductAttribute ( ) { org . candlepin . dto . manifest . v1 . PoolDTO dto = new org . candlepin . dto . manifest . v1 . PoolDTO ( ) ; java . util . Map < java . lang . String , java . lang . String > productAttributes = new java . util . HashMap ( ) ; productAttributes . put ( "prod-a... | org . junit . Assert . assertTrue ( dto . hasProductAttribute ( "prod-attribute-key-2" ) ) |
testToString ( ) { byte [ ] array1 = new byte [ ] { 0 , 8 , 0 , 2 , 1 , 9 } ; dk . alexandra . fresco . framework . util . BinaryMatrix binaryMatrix1 = new dk . alexandra . fresco . framework . util . BinaryMatrix ( array1 ) ; java . lang . String s = "1<sp>1<sp>\n0<sp>0<sp>\n0<sp>0<sp>\n0<sp>1<sp>\n0<sp>0<sp>\n0<sp>0<... | org . junit . Assert . assertEquals ( s , binaryMatrix1 . toString ( ) ) |
testGetPolicyChecker ( ) { gov . hhs . fha . nhinc . docquery . DocQueryPolicyChecker testSubject = new gov . hhs . fha . nhinc . docquery . DocQueryPolicyChecker ( ) ; gov . hhs . fha . nhinc . policyengine . DocumentRetrievePolicyEngineChecker result = testSubject . getPolicyChecker ( ) ; "<AssertPlaceHolder>" ; } ge... | org . junit . Assert . assertNotNull ( result ) |
testAttrMapping ( ) { eu . trentorise . opendata . semantics . services . AttrMapping x1 = eu . trentorise . opendata . semantics . services . AttrMapping . builder ( ) . addSourcePath ( "schema" , "s" ) . addTargetPath ( "b" ) . setScore ( 1.0 ) . build ( ) ; eu . trentorise . opendata . semantics . services . AttrMap... | org . junit . Assert . assertTrue ( ( ( x1 . compareTo ( x2 ) ) > 0 ) ) |
testListPageSize ( ) { java . util . Map < java . lang . String , java . lang . Object > objectMap = new java . util . HashMap < java . lang . String , java . lang . Object > ( ) ; objectMap . put ( "results" , "2" ) ; objectMap . put ( "page" , "1" ) ; com . shippo . model . ParcelCollection ParcelCollection = com . s... | org . junit . Assert . assertEquals ( ParcelCollection . getData ( ) . size ( ) , 2 ) |
writeStringWithFlush ( ) { final byte [ ] data = new byte [ ] { 0 , 49 , 50 , 51 , 0 } ; final java . io . ByteArrayOutputStream stream = new java . io . ByteArrayOutputStream ( ) ; final com . flagstone . transform . coder . SWFEncoder encoder = new com . flagstone . transform . coder . SWFEncoder ( stream , 2 ) ; enc... | org . junit . Assert . assertArrayEquals ( data , stream . toByteArray ( ) ) |
testSetDurableWrites ( ) { mockOptions . setDurableWrites ( durableSize ) ; boolean isDurable = mockOptions . isDurableWrites ( ) ; "<AssertPlaceHolder>" ; } isDurableWrites ( ) { return durableWrites ; } | org . junit . Assert . assertTrue ( isDurable ) |
testClean ( ) { java . lang . String cl = "systemml<sp>-clean" ; java . lang . String [ ] args = cl . split ( "<sp>" ) ; org . apache . sysml . conf . DMLOptions o = org . apache . sysml . conf . DMLOptions . parseCLArguments ( args ) ; "<AssertPlaceHolder>" ; } parseCLArguments ( java . lang . String [ ] ) { org . apa... | org . junit . Assert . assertEquals ( true , o . clean ) |
testWriteToDeletedFile ( ) { org . apache . hadoop . conf . Configuration conf = new org . apache . hadoop . conf . Configuration ( ) ; org . apache . hadoop . hdfs . MiniDFSCluster cluster = new org . apache . hadoop . hdfs . MiniDFSCluster . Builder ( conf ) . numDataNodes ( 1 ) . build ( ) ; cluster . waitActive ( )... | org . junit . Assert . assertTrue ( fs . mkdirs ( path ) ) |
writeTaskLog ( ) { org . searchisko . api . tasker . TaskPersisterJpa tested = new org . searchisko . api . tasker . TaskPersisterJpa ( ) ; tested . em = em ; try { em . getTransaction ( ) . begin ( ) ; java . lang . String id1 = tested . createTask ( "type1" , null ) ; em . getTransaction ( ) . commit ( ) ; em . getTr... | org . junit . Assert . assertEquals ( "starting" , ts . getProcessingLog ( ) ) |
testPropertiesShouldBeClone ( ) { System . out . println ( "testPropertiesShouldBeClone" ) ; java . util . Map < java . lang . String , java . lang . String > map = new java . util . HashMap ( ) ; storage . indexPicture ( retrieval . utils . FileUtils . readPicture ( retrieval . storage . PICTURETOOHOMOGENOUS ) , 5L , ... | org . junit . Assert . assertNull ( imageMap . get ( "hello" ) ) |
connection_should_be_registered_at_start ( ) { com . lordofthejars . nosqlunit . core . ConnectionManagement connectionManagement = com . lordofthejars . nosqlunit . core . ConnectionManagement . getInstance ( ) ; connectionManagement . addConnection ( "localhost" , 111 ) ; "<AssertPlaceHolder>" ; connectionManagement ... | org . junit . Assert . assertThat ( connectionManagement . isConnectionRegistered ( "localhost" , 111 ) , org . hamcrest . CoreMatchers . is ( true ) ) |
testOOM ( ) { org . apache . servicecomb . core . Invocation invocation1 = org . mockito . Mockito . mock ( org . apache . servicecomb . core . Invocation . class ) ; org . apache . servicecomb . core . Invocation invocation2 = org . mockito . Mockito . mock ( org . apache . servicecomb . core . Invocation . class ) ; ... | org . junit . Assert . assertEquals ( customizeCommandGroupKey1 , customizeCommandGroupKey2 ) |
dummy ( ) { final org . nohope . concurrent . Timeout t = new org . nohope . concurrent . Timeout ( 1 ) ; "<AssertPlaceHolder>" ; } milliseconds ( ) { return TimeUnit . MILLISECONDS . convert ( time ( ) , timeUnit ( ) ) ; } | org . junit . Assert . assertEquals ( 1000 , t . milliseconds ( ) ) |
testSetRange ( ) { indexer . setRange ( 23 ) ; "<AssertPlaceHolder>" ; } getRange ( ) { return range ; } | org . junit . Assert . assertEquals ( 23 , indexer . getRange ( ) ) |
setAllServicesSelected ( ) { model . setAvailableOperations ( generateAvailableOperations ( ) ) ; ctrl . setAllServicesSelected ( true ) ; for ( org . oscm . ui . model . AuditLogOperation o : model . getAvailableOperations ( ) ) { "<AssertPlaceHolder>" ; } } isSelected ( ) { return selected ; } | org . junit . Assert . assertTrue ( o . isSelected ( ) ) |
testReadShort ( ) { "<AssertPlaceHolder>" ; } readShort ( ) { return byteBuf . readShort ( ) ; } | org . junit . Assert . assertEquals ( 0 , instance . readShort ( ) ) |
cleanUpResourcesBundleFromDisposedClassLoader ( ) { org . mule . runtime . module . artifact . classloader . ResourceReleaserTestCase . TestArtifactClassLoader classLoader = new org . mule . runtime . module . artifact . classloader . ResourceReleaserTestCase . TestArtifactClassLoader ( new org . mule . runtime . modul... | org . junit . Assert . assertThat ( actualCacheList . size ( ) , org . hamcrest . Matchers . equalTo ( 0 ) ) |
hasWhileMatchFilter_noInNested ( ) { org . apache . hadoop . hbase . filter . QualifierFilter filter = new org . apache . hadoop . hbase . filter . QualifierFilter ( org . apache . hadoop . hbase . filter . CompareFilter . CompareOp . EQUAL , new org . apache . hadoop . hbase . filter . BinaryComparator ( org . apache ... | org . junit . Assert . assertFalse ( com . google . cloud . bigtable . hbase . AbstractBigtableTable . hasWhileMatchFilter ( filterList ) ) |
testWrapAndUnwrapThrowable ( ) { try { org . apache . commons . lang3 . exception . ExceptionUtils . wrapAndThrow ( new org . apache . commons . lang3 . exception . ExceptionUtilsTest . TestThrowable ( ) ) ; org . junit . Assert . fail ( "Checked<sp>Exception<sp>not<sp>thrown" ) ; } catch ( final java . lang . Throwabl... | org . junit . Assert . assertTrue ( org . apache . commons . lang3 . exception . ExceptionUtils . hasCause ( t , org . apache . commons . lang3 . exception . ExceptionUtilsTest . TestThrowable . class ) ) |
encodeDecodeMapIp ( ) { java . util . Map < java . lang . String , java . lang . Object > m = new java . util . HashMap < java . lang . String , java . lang . Object > ( ) ; java . net . InetAddress local = java . net . Inet4Address . getByAddress ( new byte [ ] { 127 , 0 , 0 , 1 } ) ; m . put ( "ip" , local ) ; int le... | org . junit . Assert . assertEquals ( local , dm . get ( "ip" ) ) |
testGenerateIbatis2 ( ) { java . util . List < java . lang . String > warnings = new java . util . ArrayList < java . lang . String > ( ) ; org . mybatis . generator . config . xml . ConfigurationParser cp = new org . mybatis . generator . config . xml . ConfigurationParser ( warnings ) ; org . mybatis . generator . co... | org . junit . Assert . assertEquals ( 1 , e . getErrors ( ) . size ( ) ) |
sync2 ( ) { java . io . File source = com . google . common . io . Files . createTempDir ( ) ; java . io . File sourceFile = new java . io . File ( source , "file" ) ; com . google . common . io . Files . write ( "abc" , sourceFile , Charsets . UTF_8 ) ; java . io . File target = com . google . common . io . Files . cr... | org . junit . Assert . assertEquals ( modified , targetFile . lastModified ( ) ) |
writeBeanInvalidValue_hasBindings_singleEvent ( ) { binder . forField ( nameField ) . withValidator ( ( name ) -> false , "" ) . bind ( Person :: getFirstName , Person :: setFirstName ) ; binder . readBean ( item ) ; binder . addStatusChangeListener ( this :: statusChanged ) ; "<AssertPlaceHolder>" ; try { binder . wri... | org . junit . Assert . assertNull ( event . get ( ) ) |
with0Box ( ) { "<AssertPlaceHolder>" ; } createStack ( java . util . List ) { boxes . sort ( java . util . Comparator . comparing ( ( b ) -> - b . h ) ) ; int [ ] cache = new int [ boxes . size ( ) ] ; int max = 0 ; for ( int i = 0 ; i < ( boxes . size ( ) ) ; i ++ ) { int h = doCreateStack ( boxes , i , cache ) ; max ... | org . junit . Assert . assertEquals ( 0 , s . createStack ( java . util . Collections . emptyList ( ) ) ) |
test_success_no_results ( ) { java . util . List < java . lang . String > sourceSystemValues = new java . util . ArrayList < java . lang . String > ( ) ; sourceSystemValues . add ( "no_results" ) ; java . lang . String result = this . xaMappingConfigurationDao . getTargetConfigurationValue ( "CMI2" , "Salesperson<sp>to... | org . junit . Assert . assertEquals ( null , result ) |
testStripSecretsFromUrl_twoSecretsFirstHitsAfterQuery ( ) { java . lang . String input = "http://localhost:8010/path?client_secret=password" ; java . lang . String expected = "http://localhost:8010/path?client_secret=*****" ; java . lang . String [ ] secrets = new java . lang . String [ ] { "client_secret" , "secret1" ... | org . junit . Assert . assertEquals ( expected , value ) |
testReturnFalseWhenDoesNotMatches ( ) { addMessageToContextWithPayload ( "TEST" ) ; boolean result = ( ( java . lang . Boolean ) ( wildcardFunction . call ( new java . lang . Object [ ] { "'*ASDF*QWER*'" } , context ) ) ) ; "<AssertPlaceHolder>" ; } call ( java . lang . Object [ ] , org . mule . runtime . api . el . Bi... | org . junit . Assert . assertFalse ( result ) |
compareToNotEqualsTest ( ) { java . lang . StackTraceElement [ ] stack1 = java . lang . Thread . currentThread ( ) . getStackTrace ( ) ; org . threadly . util . debug . Profiler . Trace t1 = new org . threadly . util . debug . Profiler . Trace ( stack1 ) ; java . lang . StackTraceElement [ ] stack2 = new java . lang . ... | org . junit . Assert . assertFalse ( ( ( t1 . compareTo ( t2 ) ) == 0 ) ) |
testGetEndpointPolicyServerSide ( ) { java . lang . reflect . Method m = org . apache . cxf . ws . policy . PolicyEngineImpl . class . getDeclaredMethod ( "createEndpointPolicyInfo" , new java . lang . Class [ ] { org . apache . cxf . service . model . EndpointInfo . class , boolean . class , org . apache . cxf . ws . ... | org . junit . Assert . assertSame ( epi , engine . getServerEndpointPolicy ( ei , destination , msg ) ) |
testLiteralWithMultipleEntries ( ) { org . apache . commons . jexl3 . JexlExpression e = org . apache . commons . jexl3 . JEXL . createExpression ( "{<sp>'foo'<sp>:<sp>'bar',<sp>'eat'<sp>:<sp>'food'<sp>}" ) ; org . apache . commons . jexl3 . JexlContext jc = new org . apache . commons . jexl3 . MapContext ( ) ; java . ... | org . junit . Assert . assertEquals ( expected , o ) |
testGetSelectionCount ( ) { org . eclipse . nebula . widgets . grid . GridTestUtil . createGridItems ( grid , 3 , 0 ) ; grid . select ( 0 ) ; "<AssertPlaceHolder>" ; } getSelectionCount ( ) { checkWidget ( ) ; int result = 0 ; if ( cellSelectionEnabled ) { } else { result = selectedItems . size ( ) ; } return result ; ... | org . junit . Assert . assertEquals ( 1 , grid . getSelectionCount ( ) ) |
testReleaseEntityComparatorEqual ( ) { ch . puzzle . itc . mobiliar . business . generator . control . extracted . ResourceDependencyResolverService . ReleaseComparator comparator = new ch . puzzle . itc . mobiliar . business . generator . control . extracted . ResourceDependencyResolverService . ReleaseComparator ( ) ... | org . junit . Assert . assertEquals ( 0 , comparator . compare ( currentRelease , currentRelease ) ) |
getChargePointInfoNoSubscriptionValidateEmptyResponse ( ) { io . motown . vas . v10 . soap . publisher . GetChargePointInfoRequest request = new io . motown . vas . v10 . soap . publisher . GetChargePointInfoRequest ( ) ; io . motown . vas . v10 . soap . publisher . GetChargePointInfoResponse response = service . getCh... | org . junit . Assert . assertEquals ( 0 , response . getChargePoints ( ) . size ( ) ) |
shouldReturnAllProductApplicableFees ( ) { java . util . List < org . mifos . dto . domain . FeeDto > feeDtos = this . feeDao . retrieveAllProductFees ( ) ; "<AssertPlaceHolder>" ; } size ( ) { return fieldErrors . size ( ) ; } | org . junit . Assert . assertThat ( feeDtos . size ( ) , org . hamcrest . CoreMatchers . is ( 1 ) ) |
itReturnsTxactionsWithFilteredNamesContainingTheQuery ( ) { inject ( com . wesabe . api . accounts . entities . Txaction . class , starbucks , "filteredName" , "Starbucks<sp>San<sp>Francis" ) ; final com . wesabe . api . accounts . entities . TxactionList list = buildTxactionList ( "Starbucks" ) ; "<AssertPlaceHolder>"... | org . junit . Assert . assertEquals ( com . google . common . collect . ImmutableList . of ( starbucks ) , list . getTxactions ( ) ) |
deveObterCodigoStatusComoFoiSetado ( ) { final com . fincatto . documentofiscal . nfe310 . classes . evento . cancelamento . NFRetornoInfoCancelamento retornoInfoCancelamento = new com . fincatto . documentofiscal . nfe310 . classes . evento . cancelamento . NFRetornoInfoCancelamento ( ) ; final java . lang . String co... | org . junit . Assert . assertEquals ( codigoStatus , retornoInfoCancelamento . getCodigoStatus ( ) ) |
testTWQnENoQNoEWithDEFWindows ( ) { if ( ( java . io . File . separatorChar ) != '\\' ) { org . opennms . test . mock . MockUtil . println ( "--------<sp>Skipping<sp>testTWQnENoQNoEWithDEFWindows<sp>since<sp>File.separator<sp>is<sp>not<sp>\\<sp>------------" ) ; org . opennms . test . mock . MockUtil . println ( "No<sp... | org . junit . Assert . assertEquals ( java . util . Arrays . asList ( expected ) , java . util . Arrays . asList ( actual ) ) |
testSFBug1708336 ( ) { org . openscience . cdk . interfaces . IChemObjectBuilder builder = org . openscience . cdk . DefaultChemObjectBuilder . getInstance ( ) ; org . openscience . cdk . interfaces . IAtomContainer atomContainer = builder . newInstance ( org . openscience . cdk . interfaces . IAtomContainer . class ) ... | org . junit . Assert . assertTrue ( list . isEmpty ( ) ) |
testIsExistsTrue ( ) { com . sap . core . odata . processor . core . jpa . model . JPAEdmReferentialConstraintTest . objJPAEdmReferentialConstraintTest = new com . sap . core . odata . processor . core . jpa . model . JPAEdmReferentialConstraintTest ( ) ; com . sap . core . odata . processor . core . jpa . model . JPAE... | org . junit . Assert . assertTrue ( com . sap . core . odata . processor . core . jpa . model . JPAEdmReferentialConstraintTest . objJPAEdmReferentialConstraint . isExists ( ) ) |
testDeleteStorage ( ) { org . finra . herd . model . api . xml . StorageKey storageKey = new org . finra . herd . model . api . xml . StorageKey ( STORAGE_NAME ) ; org . finra . herd . model . api . xml . Storage storage = new org . finra . herd . model . api . xml . Storage ( STORAGE_NAME , STORAGE_PLATFORM_CODE , NO_... | org . junit . Assert . assertEquals ( storage , result ) |
testSetNonFormattedDateStr ( ) { hudson . plugins . clearcase . ClearCaseChangeLogEntry entry = new hudson . plugins . clearcase . ClearCaseChangeLogEntry ( ) ; entry . setDateStr ( "Tue<sp>Aug<sp>28<sp>15:27:00<sp>CEST<sp>2007" ) ; "<AssertPlaceHolder>" ; } getDateStr ( ) { if ( ( date ) == null ) { return dateStr ; }... | org . junit . Assert . assertEquals ( "Tue<sp>Aug<sp>28<sp>15:27:00<sp>CEST<sp>2007" , entry . getDateStr ( ) ) |
testSourceCounterEventFail ( ) { init ( "true" ) ; errorCounterCommon ( new java . lang . RuntimeException ( "dummy" ) ) ; for ( int i = 0 ; ( i < 10 ) && ( ( source . getSourceCounter ( ) . getEventReadFail ( ) ) == 0 ) ; i ++ ) { java . lang . Thread . sleep ( 100 ) ; } "<AssertPlaceHolder>" ; } getSourceCounter ( ) ... | org . junit . Assert . assertEquals ( 1 , source . getSourceCounter ( ) . getEventReadFail ( ) ) |
testCreateStreamable ( ) { javax . xml . namespace . QName objName = new javax . xml . namespace . QName ( "object" ) ; javax . xml . namespace . QName objIdlType = new javax . xml . namespace . QName ( org . apache . cxf . binding . corba . wsdl . CorbaConstants . NU_WSDL_CORBA , "short" , org . apache . cxf . binding... | org . junit . Assert . assertNotNull ( streamable ) |
whenCallExtractSimpleQueryParamWithNotValidString ( ) { java . util . Map < java . lang . String , com . stratio . explorer . notebook . form . Input > params = com . stratio . explorer . notebook . form . Input . extractSimpleQueryParam ( ScriptTypes . NOT_VALID ) ; "<AssertPlaceHolder>" ; } extractSimpleQueryParam ( ... | org . junit . Assert . assertTrue ( params . isEmpty ( ) ) |
testValidateQuestionnaire ( ) { java . lang . String input = org . apache . commons . io . IOUtils . toString ( getClass ( ) . getResourceAsStream ( "/questionnaire_jon_z_20160506.xml" ) , StandardCharsets . UTF_8 ) ; org . hl7 . fhir . dstu3 . hapi . validation . FhirValidator val = org . hl7 . fhir . dstu3 . hapi . v... | org . junit . Assert . assertTrue ( result . isSuccessful ( ) ) |
testBusIsWrappedOnlyOnce ( ) { java . util . HashMap < java . lang . String , java . lang . Object > smResponse = getSmResponse ( "MTA" , "903037" ) ; java . util . HashMap < java . lang . String , java . lang . Object > siri = ( ( java . util . HashMap < java . lang . String , java . lang . Object > ) ( smResponse . g... | org . junit . Assert . assertEquals ( mvjs . size ( ) , 0 ) |
shouldFindRouteDelegatingToRouter ( ) { com . threewks . thundr . route . Route route = mock ( com . threewks . thundr . route . Route . class ) ; when ( router . findMatchingRoute ( HttpMethod . PATCH , "/a/b/c" ) ) . thenReturn ( route ) ; "<AssertPlaceHolder>" ; } findRoute ( com . threewks . thundr . route . HttpMe... | org . junit . Assert . assertThat ( thundr . findRoute ( HttpMethod . PATCH , "/a/b/c" ) , is ( route ) ) |
supports_update_with_new_org_references ( ) { when ( update . getNewValues ( AttributeType . ORG ) ) . thenReturn ( ciSet ( "ORG2" ) ) ; when ( update . getUpdatedObject ( ) ) . thenReturn ( net . ripe . db . whois . common . rpsl . RpslObject . parse ( "organisation:<sp>ORG1\norg:<sp>ORG1" ) ) ; "<AssertPlaceHolder>" ... | org . junit . Assert . assertThat ( subject . supports ( update ) , org . hamcrest . core . Is . is ( true ) ) |
testAllGenericProps ( ) { org . json . JSONObject actual = json ( "my<sp>title" , "my<sp>description" , "my/id" ) ; "<AssertPlaceHolder>" ; } getNames ( org . json . JSONObject ) { if ( ( obj == null ) || ( ( obj . length ( ) ) == 0 ) ) { return null ; } java . lang . String [ ] rval = new java . lang . String [ obj . ... | org . junit . Assert . assertEquals ( 3 , org . json . JSONObject . getNames ( actual ) . length ) |
canSkipOverImmutable2 ( ) { byte [ ] input = "{\"a\":1,\"x\":2}" . getBytes ( "UTF-8" ) ; com . dslplatform . json . SkippingTest . SingleImmutable s = dslJson . deserialize ( com . dslplatform . json . SkippingTest . SingleImmutable . class , input , input . length ) ; "<AssertPlaceHolder>" ; } deserialize ( java . la... | org . junit . Assert . assertEquals ( 2 , s . y ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.