input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
shouldCallQueryAndReturnData ( ) { java . util . List < org . mifos . platform . accounting . AccountingDto > accountData = accountingDao . getAccountingDataByDate ( new org . joda . time . LocalDate ( 2010 , 8 , 10 ) , new org . joda . time . LocalDate ( 2010 , 8 , 10 ) ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertNull ( accountData ) |
metadata_xmltrue ( ) { final java . lang . String entryName = "bar/90_contents/odatacol1/00_$metadata.xml" ; final java . lang . String filename = "/00_$metadata_invalid_tag.xml" ; java . net . URL fileUrl = java . lang . ClassLoader . getSystemResource ( ( ( com . fujitsu . dc . test . unit . core . bar . BarFileValid... | org . junit . Assert . assertTrue ( res ) |
everyOddHourShouldBeParsedCorrectly ( ) { final com . cronutils . model . Cron cron = cronParser . parse ( "0<sp>1/2<sp>*<sp>*<sp>*" ) ; "<AssertPlaceHolder>" ; } asString ( ) { org . junit . Assert . assertEquals ( "0<sp>0<sp>0<sp>15|16<sp>8|9<sp>?<sp>2015/2" , cron1 . asString ( ) ) ; } | org . junit . Assert . assertThat ( cron . asString ( ) , org . hamcrest . core . Is . is ( "0<sp>1/2<sp>*<sp>*<sp>*" ) ) |
testRefreshDependentDataTypes ( ) { final org . kie . workbench . common . dmn . client . editors . types . common . DataType dataType = mock ( org . kie . workbench . common . dmn . client . editors . types . common . DataType . class ) ; final java . lang . String oldItemDefinitionName = "oldItemDefinitionName" ; fin... | org . junit . Assert . assertEquals ( expectedDataTypes , actualDataTypes ) |
testTokenCountFilter ( ) { org . apache . tika . eval . tokens . AnalyzerManager analyzerManager = org . apache . tika . eval . tokens . AnalyzerManager . newInstance ( 1000000 ) ; java . lang . StringBuilder sb = new java . lang . StringBuilder ( ) ; for ( int i = 0 ; i < 1001000 ; i ++ ) { sb . append ( "the<sp>" ) ;... | org . junit . Assert . assertEquals ( 1000000 , tokens ) |
get ( ) { org . eclipse . collections . api . list . primitive . ImmutableBooleanList list = this . classUnderTest ( ) ; for ( int i = 0 ; i < ( list . size ( ) ) ; i ++ ) { "<AssertPlaceHolder>" ; } } get ( int ) { return this . delegate . get ( index ) ; } | org . junit . Assert . assertEquals ( ( ( i & 1 ) == 0 ) , list . get ( i ) ) |
testResourceConverter ( ) { "<AssertPlaceHolder>" ; } getResourceConverter ( ) { return resourceConverter ; } | org . junit . Assert . assertNotNull ( unit . getResourceConverter ( ) ) |
mapAccessExpr ( ) { final org . drools . modelcompiler . builder . generator . TypedExpression expected3 = typedResult ( "_this.get(\"type\")" , java . lang . Object . class ) ; final org . drools . modelcompiler . builder . generator . TypedExpression actual3 = toTypedExpression ( "this[\"type\"]" , java . util . Map ... | org . junit . Assert . assertEquals ( expected3 , actual3 ) |
xmldbURIRelativizeContext1 ( ) { org . exist . xmldb . XmldbURI xmldbURI = org . exist . xmldb . XmldbURI . xmldbUriFor ( "xmldb:exist://localhost:8080/exist/exist/xmlrpc/db" ) ; java . net . URI uri = new java . net . URI ( "/exist/xmlrpc" ) ; "<AssertPlaceHolder>" ; } relativizeContext ( java . net . URI ) { return n... | org . junit . Assert . assertEquals ( "/exist/xmlrpc" , xmldbURI . relativizeContext ( uri ) . toString ( ) ) |
distinctOrderByTest ( ) { java . lang . String sql = ( "/*<sp>ANDOR<sp>ALLOW_TEMPORARY_TABLE=True<sp>*/select<sp>distinct<sp>name<sp>from<sp>" + ( normaltblTableName ) ) + "<sp>where<sp>name=?<sp>order<sp>by<sp>id" ; java . util . List < java . lang . Object > param = new java . util . ArrayList < java . lang . Object ... | org . junit . Assert . assertEquals ( 1 , resultsSize ( rc ) ) |
generateCodeShouldSucceed ( ) { configurationProvider . setupDatabase ( ) ; org . jooq . meta . jaxb . Configuration configuration = configurationProvider . createGeneratorConfig ( generator . getName ( ) , packageLocation , strategy ) ; try { org . jooq . codegen . GenerationTool . generate ( configuration ) ; "<Asser... | org . junit . Assert . assertTrue ( true ) |
canCountConfigs ( ) { int num = marytts . config . MaryConfig . countConfigs ( ) ; "<AssertPlaceHolder>" ; } countConfigs ( ) { int num = 0 ; for ( @ marytts . config . SuppressWarnings ( "unused" ) marytts . config . MaryConfig mc : marytts . config . MaryConfig . configLoader ) { num ++ ; } return num ; } | org . junit . Assert . assertTrue ( ( num >= 0 ) ) |
testCancelQuery_PositiveAck ( ) { final org . apache . drill . exec . proto . UserBitShared . QueryId mockQueryId = UserBitShared . QueryId . getDefaultInstance ( ) ; final org . apache . drill . exec . proto . GeneralRPCProtos . Ack mockResponse = org . apache . drill . exec . rpc . Acks . OK ; when ( org . apache . d... | org . junit . Assert . assertEquals ( response , mockResponse ) |
testGetBindVariableMap_noEntries ( ) { com . google . api . ads . admanager . axis . utils . v201811 . StatementBuilder statementBuilder = new com . google . api . ads . admanager . axis . utils . v201811 . StatementBuilder ( ) . where ( "id<sp>=<sp>1" ) ; "<AssertPlaceHolder>" ; } getBindVariableMap ( ) { return query... | org . junit . Assert . assertTrue ( statementBuilder . getBindVariableMap ( ) . isEmpty ( ) ) |
testDropScript ( ) { java . lang . String h = "<SCRIPT<sp>SRC=//ha.ckers.org/.j><SCRIPT>alert(/XSS/.source)</SCRIPT>" ; java . lang . String cleanHtml = org . jsoup . Jsoup . clean ( h , org . jsoup . safety . Whitelist . relaxed ( ) ) ; "<AssertPlaceHolder>" ; } relaxed ( ) { return new org . jsoup . safety . Whitelis... | org . junit . Assert . assertEquals ( "" , cleanHtml ) |
testCount ( ) { int count = getDao ( ) . count ( ) ; "<AssertPlaceHolder>" ; } count ( ) { return tiposAsuntos . size ( ) ; } | org . junit . Assert . assertTrue ( ( count > 0 ) ) |
testCreateCorbaObjectHandler ( ) { 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 , "long" , org . apache . cxf . ... | org . junit . Assert . assertNotNull ( obj ) |
rejectKeysValues ( ) { com . gs . collections . impl . multimap . bag . HashBagMultimap < java . lang . String , java . lang . Integer > mutableMultimap = com . gs . collections . impl . multimap . bag . HashBagMultimap . newMultimap ( ) ; mutableMultimap . putAll ( "One" , com . gs . collections . impl . list . mutabl... | org . junit . Assert . assertEquals ( expectedImmutableMultimap , rejectedMultimap ) |
testEncodeElementOne ( ) { byte [ ] actuals = org . ethereum . util . RLP . encodeElement ( new byte [ ] { 0 } ) ; "<AssertPlaceHolder>" ; } encodeElement ( byte [ ] ) { if ( srcData == null ) return new byte [ ] { ( ( byte ) ( org . ethereum . util . RLP . OFFSET_SHORT_ITEM ) ) } ; else if ( ( ( srcData . length ) == ... | org . junit . Assert . assertArrayEquals ( new byte [ ] { ( ( byte ) ( 0 ) ) } , actuals ) |
testStoreListDataConnectionFails ( ) { java . util . List < cern . c2mon . pmanager . IFallback > data = new java . util . ArrayList ( ) ; int lines = cern . c2mon . pmanager . persistence . impl . PersistenceManagerTest . persistenceManager . getFallbackManager ( ) . getFallbackFileController ( ) . getNumberOfLines ( ... | org . junit . Assert . assertEquals ( 5 , ( ( cern . c2mon . pmanager . persistence . impl . PersistenceManagerTest . persistenceManager . getFallbackManager ( ) . getFallbackFileController ( ) . getNumberOfLines ( ) ) - lines ) ) |
testUnknownTableException ( ) { when ( _server . get ( "table-name" , "row-key" , ReadConsistency . STRONG ) ) . thenThrow ( new com . bazaarvoice . emodb . sor . api . UnknownTableException ( "table-name" ) ) ; try { sorClient ( test . integration . sor . DataStoreJerseyTest . APIKEY_TABLE ) . get ( "table-name" , "ro... | org . junit . Assert . assertEquals ( e . getTable ( ) , "table-name" ) |
requisitionRemoveTest ( ) { org . opennms . xmlclient . ClientPropertiesLoader clientProps = new org . opennms . xmlclient . ClientPropertiesLoader ( ) ; clientProps . setPropertiesFilename ( "onmsxmlclient.properties" ) ; org . opennms . xmlclient . OpenNmsXmlClient onmsClient = new org . opennms . xmlclient . OpenNms... | org . junit . Assert . assertTrue ( onmsClient . requisitionRemove ( foreign_source , false ) ) |
testSendText ( ) { io . github . biezhi . ome . OhMyEmail . subject ( "TEXT" ) . from ( "" ) . to ( io . github . biezhi . ome . OhMyEmailTest . TO_EMAIL ) . text ( "" ) . send ( ) ; "<AssertPlaceHolder>" ; } send ( ) { if ( ( ( text ) == null ) && ( ( html ) == null ) ) { throw new java . lang . IllegalArgumentExcepti... | org . junit . Assert . assertTrue ( true ) |
onlyNonConflictFilesDeletedAfterRestoringInHomeDir_noOverwriteMode ( ) { org . pentaho . platform . web . http . api . resources . services . FileService fileService = mock ( org . pentaho . platform . web . http . api . resources . services . FileService . class ) ; mockSession ( fileService , org . pentaho . platform... | org . junit . Assert . assertEquals ( result , true ) |
equalsWithEqualOperationList ( ) { edu . illinois . library . cantaloupe . operation . OperationList ops1 = new edu . illinois . library . cantaloupe . operation . OperationList ( new edu . illinois . library . cantaloupe . operation . Rotate ( 1 ) ) ; edu . illinois . library . cantaloupe . operation . OperationList o... | org . junit . Assert . assertEquals ( ops1 , ops2 ) |
testSend ( ) { final net . violet . platform . api . actions . Action theAction = new net . violet . platform . api . actions . messages . SendMedia ( ) ; final net . violet . platform . datamodel . Files theFile = new net . violet . platform . datamodel . mock . FilesMock ( "message" , MimeType . MIME_TYPES . A_MPEG )... | org . junit . Assert . assertNull ( theResult ) |
shouldReturnNullDigestOnPartlyOverlappingWrites ( ) { chksumChannel . write ( buffers [ 1 ] , blocksize ) ; chksumChannel . write ( buffers [ 0 ] , ( ( blocksize ) - 1 ) ) ; if ( ( blocksize ) == 1 ) { org . junit . Assert . fail ( "Pick<sp>a<sp>blocksize<sp>><sp>1<sp>for<sp>testing<sp>correct<sp>handling<sp>of<sp>part... | org . junit . Assert . assertThat ( chksumChannel . getChecksums ( ) , is ( empty ( ) ) ) |
testLogDefault ( ) { org . jsoar . kernel . LogManager logManager = agent . getLogManager ( ) ; org . jsoar . kernel . commands . LogCommand logCommand = new org . jsoar . kernel . commands . LogCommand ( agent , new org . jsoar . util . commands . DefaultInterpreter ( agent ) ) ; logManager . setStrict ( false ) ; log... | org . junit . Assert . assertTrue ( success ) |
testQueryNonExistingProperty ( ) { com . oberasoftware . jasdb . test . DBSession pojoDb = sessionFactory . createSession ( ) ; com . oberasoftware . jasdb . test . EntityBag bag = pojoDb . createOrGetBag ( "thosha" ) ; bag . addEntity ( new com . oberasoftware . jasdb . core . SimpleEntity ( "00005442-4961-c49d-0000-0... | org . junit . Assert . assertThat ( result . size ( ) , org . hamcrest . CoreMatchers . is ( 0L ) ) |
testBuildWithDisabledStatusConstraint ( ) { unit . setActive ( false ) ; org . lnu . is . domain . department . address . DepartmentAddress context = new org . lnu . is . domain . department . address . DepartmentAddress ( ) ; java . lang . String expectedQuery = "SELECT<sp>e<sp>FROM<sp>DepartmentAddress<sp>e<sp>WHERE<... | org . junit . Assert . assertEquals ( expectedQuery , actualQuery ) |
testRemoveCycle ( ) { org . grain . thread . CycleTest cycleTest = new org . grain . thread . CycleTest ( ) ; cycleTest . name = "testRemoveCycle" ; boolean result = org . grain . thread . AsyncThreadManager . addCycle ( cycleTest , 1 , 1 ) ; result = org . grain . thread . AsyncThreadManager . removeCycle ( cycleTest ... | org . junit . Assert . assertEquals ( true , result ) |
testComplementMap6a ( ) { int [ ] expected = new int [ ] { 0 , 1 , 2 , 3 , 5 } ; int [ ] input = new int [ ] { 4 } ; int size = 6 ; int [ ] complement = com . splicemachine . utils . IntArrays . complementMap ( input , size ) ; "<AssertPlaceHolder>" ; } printArrays ( int [ ] , int , int [ ] , int [ ] ) { return ( ( ( (... | org . junit . Assert . assertArrayEquals ( printArrays ( input , size , expected , complement ) , expected , complement ) |
testCheckTopLevelConsistencyPathsAreInconsistent ( ) { java . util . List < org . pentaho . di . trans . steps . mongodboutput . MongoDbOutputMeta . MongoField > paths = asList ( org . pentaho . di . trans . steps . mongodboutput . MongoDbOutputTest . mf ( "field1" , true , "" ) , org . pentaho . di . trans . steps . m... | org . junit . Assert . assertTrue ( ( topLevel == ( org . pentaho . di . trans . steps . mongodboutput . MongoDbOutputData . MongoTopLevel . INCONSISTENT ) ) ) |
testGeneratePathIdRandomIncrements ( ) { for ( int i = 0 ; i < 20 ; i ++ ) { "<AssertPlaceHolder>" ; } pathIdSet . clear ( ) ; } generatePathIdRandomIncrements ( ) { int pathid ; int count = org . opendaylight . sfc . provider . api . SfcServicePathId . NUM_PATH_ID ; do { org . opendaylight . sfc . provider . api . Sfc... | org . junit . Assert . assertTrue ( pathIdSet . add ( org . opendaylight . sfc . provider . api . SfcServicePathId . generatePathIdRandomIncrements ( ) ) ) |
negative ( ) { org . smurn . jsift . Octave octave = new org . smurn . jsift . Octave ( java . util . Arrays . asList ( new org . smurn . jsift . Image ( 3 , 3 ) , new org . smurn . jsift . Image ( 3 , 3 ) , new org . smurn . jsift . Image ( 3 , 3 ) , new org . smurn . jsift . Image ( 3 , 3 ) ) , java . util . Arrays .... | org . junit . Assert . assertEquals ( expected , actual ) |
shiftByWordSizeBits ( ) { int [ ] positions = new int [ ] { 10 , 11 , 12 , 13 } ; com . googlecode . javaewah32 . EWAHCompressedBitmap32 bm1 = com . googlecode . javaewah32 . EWAHCompressedBitmap32 . bitmapOf ( positions ) ; com . googlecode . javaewah32 . EWAHCompressedBitmap32 bm2 = bm1 . shift ( com . googlecode . j... | org . junit . Assert . assertEquals ( bm3 , bm2 ) |
testGetOutputSchema ( ) { org . talend . components . jdbc . tjdbcinput . TJDBCInputProperties properties = new org . talend . components . jdbc . tjdbcinput . TJDBCInputProperties ( "input" ) ; properties . init ( ) ; org . apache . avro . Schema schema = org . talend . components . jdbc . CommonUtils . getOutputSchem... | org . junit . Assert . assertNotNull ( schema ) |
removeLimitedMapValueNotInMap ( ) { java . lang . Object object = new java . lang . Object ( ) ; java . lang . Object actualValue = limitedMap . remove ( object ) ; "<AssertPlaceHolder>" ; } remove ( java . lang . Object ) { if ( contains ( o ) ) { unlink ( ( ( E ) ( o ) ) ) ; return true ; } return false ; } | org . junit . Assert . assertEquals ( null , actualValue ) |
R1901_Nationaliteit_NL_beeindigd_voor_peildatum ( ) { final nl . bzk . brp . bijhouding . bericht . model . BijhoudingPersoon persoonEntiteit = actie . getPersoon ( ) . getPersoonEntiteit ( ) ; final nl . bzk . algemeenbrp . dal . domein . brp . entity . PersoonNationaliteit nationaliteit = new nl . bzk . algemeenbrp .... | org . junit . Assert . assertEquals ( 0 , meldingen . size ( ) ) |
testAccepts ( ) { final boolean result = servlet . accepts ( mockRequest ) ; "<AssertPlaceHolder>" ; } accepts ( org . apache . sling . api . SlingHttpServletRequest ) { final com . day . cq . wcm . api . PageManager pageManager = request . getResourceResolver ( ) . adaptTo ( com . day . cq . wcm . api . PageManager . ... | org . junit . Assert . assertTrue ( result ) |
testRetryAfterParsesMalformed ( ) { final ch . boye . httpclientandroidlib . HttpResponse response = new ch . boye . httpclientandroidlib . message . BasicHttpResponse ( new ch . boye . httpclientandroidlib . message . BasicStatusLine ( new ch . boye . httpclientandroidlib . ProtocolVersion ( "HTTP" , 1 , 1 ) , 503 , "... | org . junit . Assert . assertEquals ( ( - 1 ) , syncResponse . retryAfterInSeconds ( ) ) |
should_list_branches ( ) { java . util . List < java . lang . String > branches = client . branches ( ) ; "<AssertPlaceHolder>" ; } size ( ) { return info . size ( ) ; } | org . junit . Assert . assertTrue ( ( ( branches . size ( ) ) >= 1 ) ) |
testGetConnector ( ) { final org . easymock . Capture < org . apache . kafka . connect . util . Callback < org . apache . kafka . connect . runtime . rest . entities . ConnectorInfo > > cb = org . easymock . Capture . newInstance ( ) ; herder . connectorInfo ( org . easymock . EasyMock . eq ( org . apache . kafka . con... | org . junit . Assert . assertEquals ( new org . apache . kafka . connect . runtime . rest . entities . ConnectorInfo ( org . apache . kafka . connect . runtime . rest . resources . ConnectorsResourceTest . CONNECTOR_NAME , org . apache . kafka . connect . runtime . rest . resources . ConnectorsResourceTest . CONNECTOR_... |
ADSfalse ( ) { com . fujitsu . dc . core . model . impl . es . repair . RepairAds repair = com . fujitsu . dc . core . model . impl . es . repair . RepairAds . getInstance ( ) ; com . fujitsu . dc . common . ads . AdsWriteFailureLogWriter writer = com . fujitsu . dc . common . ads . AdsWriteFailureLogWriter . getInstan... | org . junit . Assert . assertFalse ( ( ( java . lang . Boolean ) ( method . invoke ( repair ) ) ) ) |
testNotSupportedHttpMethod ( ) { spark . route . HttpMethod method = spark . route . HttpMethod . get ( "lock" ) ; "<AssertPlaceHolder>" ; } get ( java . lang . String ) { spark . route . HttpMethod method = spark . route . HttpMethod . methods . get ( methodStr ) ; return method != null ? method : spark . route . Http... | org . junit . Assert . assertEquals ( HttpMethod . unsupported , method ) |
testStringBuilderAppend ( ) { final java . lang . StringBuilder theBuilder = new java . lang . StringBuilder ( ) ; theBuilder . append ( new java . lang . String ( "123" . getBytes ( ) ) ) ; final java . lang . String theResult = theBuilder . toString ( ) ; "<AssertPlaceHolder>" ; } length ( ) { float theSquareSum = 0.... | org . junit . Assert . assertEquals ( theResult . length ( ) , 3 , 0 ) |
testRemoveNoStroke ( ) { org . orbisgis . legend . thematic . categorize . CategorizedArea ca = getNoStroke ( ) ; org . orbisgis . legend . thematic . AreaParameters rm = ca . remove ( 100000.0 ) ; org . orbisgis . legend . thematic . AreaParameters tester = new org . orbisgis . legend . thematic . AreaParameters ( Col... | org . junit . Assert . assertTrue ( rm . equals ( tester ) ) |
shouldDecodeCommonBinary ( ) { com . couchbase . client . java . document . BinaryDocument document = converter . decode ( "id" , com . couchbase . client . deps . io . netty . buffer . Unpooled . copiedBuffer ( "value" , CharsetUtil . UTF_8 ) , 0 , 0 , TranscoderUtils . BINARY_COMMON_FLAGS , ResponseStatus . SUCCESS )... | org . junit . Assert . assertEquals ( "value" , document . content ( ) . toString ( CharsetUtil . UTF_8 ) ) |
constructor ( ) { final com . azure . common . implementation . http . UrlTokenizer tokenizer = new com . azure . common . implementation . http . UrlTokenizer ( "http://www.bing.com" ) ; "<AssertPlaceHolder>" ; } current ( ) { return currentToken ; } | org . junit . Assert . assertNull ( tokenizer . current ( ) ) |
testConfigurationPackage ( ) { org . cache2k . configuration . Cache2kConfiguration < java . lang . String , java . lang . String > c = org . cache2k . Cache2kBuilder . of ( java . lang . String . class , java . lang . String . class ) . eternal ( true ) . toConfiguration ( ) ; "<AssertPlaceHolder>" ; } isEternal ( ) {... | org . junit . Assert . assertTrue ( c . isEternal ( ) ) |
testContains_IAtom ( ) { org . openscience . cdk . interfaces . IChemObject object = newChemObject ( ) ; org . openscience . cdk . interfaces . IAtom atom = object . getBuilder ( ) . newInstance ( org . openscience . cdk . interfaces . IAtom . class , "N" ) ; org . openscience . cdk . interfaces . ISingleElectron radic... | org . junit . Assert . assertTrue ( radical . contains ( atom ) ) |
testGetIllegalArgument ( ) { final net . sf . qualitycheck . exception . IllegalArgumentHolder < java . lang . Object > iah = new net . sf . qualitycheck . exception . IllegalNotGreaterOrEqualThanException ( 2 ) ; "<AssertPlaceHolder>" ; } getIllegalArgument ( ) { return illegalArgumentValue ; } | org . junit . Assert . assertEquals ( java . lang . Integer . valueOf ( 2 ) , iah . getIllegalArgument ( ) ) |
testGetUserByIdNull ( ) { exception . expect ( uk . ac . bbsrc . tgac . miso . persistence . impl . Exception . class ) ; "<AssertPlaceHolder>" ; } getUserById ( java . lang . Long ) { return ( ( com . eaglegenomics . simlims . core . User ) ( currentSession ( ) . get ( uk . ac . bbsrc . tgac . miso . core . data . imp... | org . junit . Assert . assertNull ( dao . getUserById ( null ) ) |
initialStateIsValid ( ) { info . piwai . buildergen . validation . IsValid valid = new info . piwai . buildergen . validation . IsValid ( ) ; "<AssertPlaceHolder>" ; } isValid ( ) { return valid ; } | org . junit . Assert . assertTrue ( valid . isValid ( ) ) |
shouldReturnNullFailureOnNoFailure ( ) { "<AssertPlaceHolder>" ; } pageCacheAllocationOrNull ( ) { java . lang . String failure = failedFactoriesDescription . get ( ) ; if ( failure != null ) { failedFactoriesDescription . compareAndSet ( failure , null ) ; } return failure ; } | org . junit . Assert . assertNull ( monitor . pageCacheAllocationOrNull ( ) ) |
terminateExclusiveLockAcquisitionForSharedLockedResource ( ) { client . acquireShared ( LockTracer . NONE , ResourceTypes . NODE , 1 ) ; java . util . concurrent . Future < java . lang . Boolean > exclusiveLockAcquisition = threadB . execute ( ( state ) -> { client2 . acquireExclusive ( LockTracer . NONE , ResourceType... | org . junit . Assert . assertThat ( threadB , isWaiting ( ) ) |
testSetParallelFalse ( ) { System . out . println ( "testSetParallelFalse" ) ; boolean value = false ; edu . oswego . csc480_hci521_2013 . shared . h2o . urlbuilders . RFBuilder instance = new edu . oswego . csc480_hci521_2013 . shared . h2o . urlbuilders . RFBuilder ( "test.hex" ) ; java . lang . String expResult = "h... | org . junit . Assert . assertEquals ( expResult , result ) |
test_RcStopCoordinatorOperation ( ) { com . hazelcast . simulator . coordinator . operations . RcStopCoordinatorOperation op = new com . hazelcast . simulator . coordinator . operations . RcStopCoordinatorOperation ( ) ; java . lang . String result = remote . execute ( op ) ; "<AssertPlaceHolder>" ; verify ( coordinato... | org . junit . Assert . assertNull ( result ) |
readRSS ( ) { final org . eol . globi . data . ParserFactory parserFactory = null ; final org . eol . globi . data . NodeFactory nodeFactory = null ; final org . eol . globi . service . Dataset dataset = getDatasetGroup ( ) ; java . util . List < org . eol . globi . service . Dataset > datasets = org . eol . globi . da... | org . junit . Assert . assertThat ( datasets . size ( ) , org . hamcrest . core . Is . is ( 3 ) ) |
testEqualsByteArray ( ) { byte [ ] value = new byte [ 5 ] ; net . openhft . chronicle . map . Arrays . fill ( value , ( ( byte ) ( 'X' ) ) ) ; net . openhft . chronicle . map . ChronicleMapBuilder < java . lang . CharSequence , byte [ ] > builder = net . openhft . chronicle . map . ChronicleMapBuilder . of ( net . open... | org . junit . Assert . assertEquals ( map1 , map2 ) |
namespaceURI_contextItem_empty ( ) { final org . xmldb . api . base . ResourceSet result = org . exist . xquery . XQueryFunctionsTest . existEmbeddedServer . executeQuery ( ( "let<sp>$a<sp>:=<sp><a><b/></a>" + "return<sp>$a/exist:b/c/fn:namespace-uri()" ) ) ; final java . lang . String r = ( ( java . lang . String ) ( ... | org . junit . Assert . assertEquals ( "" , r ) |
testSimpleIndentOfAttributeList ( ) { java . lang . String templates = ( ( ( "<sp>Terence" 0 + "<sp><names;<sp>separator=\"\\n\"<sp>Terence" 2 ) + ( newline ) ) + "<sp>Terence" 3 ) + ( newline ) ; writeFile ( tmpdir , "t.stg" , templates ) ; org . stringtemplate . v4 . STGroup group = new org . stringtemplate . v4 . ST... | org . junit . Assert . assertEquals ( expecting , t . render ( ) ) |
readBitsAcrossIntBoundary ( ) { final byte [ ] data = new byte [ ] { 0 , 0 , 0 , 3 , ( ( byte ) ( 192 ) ) } ; final java . io . ByteArrayInputStream stream = new java . io . ByteArrayInputStream ( data ) ; final com . flagstone . transform . coder . BigDecoder fixture = new com . flagstone . transform . coder . BigDeco... | org . junit . Assert . assertEquals ( ( - 1 ) , fixture . readBits ( 4 , true ) ) |
keepsSystemId ( ) { org . xmlunit . input . NormalizedSource s = new org . xmlunit . input . NormalizedSource ( new javax . xml . transform . dom . DOMSource ( doc , "foo" ) ) ; "<AssertPlaceHolder>" ; } getSystemId ( ) { return systemId ; } | org . junit . Assert . assertEquals ( "foo" , s . getSystemId ( ) ) |
getMimeType ( ) { java . nio . file . Path bundlePath = org . apache . taverna . robundle . utils . TemporaryFiles . temporaryBundle ( ) ; try ( org . apache . taverna . robundle . fs . BundleFileSystem bundleFs = org . apache . taverna . robundle . fs . BundleFileSystemProvider . newFileSystemFromNew ( bundlePath , "a... | org . junit . Assert . assertEquals ( "application/x-test" , org . apache . taverna . robundle . Bundles . getMimeType ( bundle ) ) |
testCompareToEqualsNullType1 ( ) { opennlp . tools . util . Span a = new opennlp . tools . util . Span ( 30 , 1000 ) ; opennlp . tools . util . Span b = new opennlp . tools . util . Span ( 30 , 1000 , "b" ) ; "<AssertPlaceHolder>" ; } compareTo ( opennlp . tools . util . Span ) { if ( ( getStart ( ) ) < ( s . getStart ... | org . junit . Assert . assertEquals ( true , ( ( a . compareTo ( b ) ) == 1 ) ) |
testExecuteCommandWithNullCmd ( ) { com . vmware . vrack . hms . utils . SshUtilTest . logger . info ( "[TS]<sp>:<sp>testExecuteCommandWithNullCmd" ) ; java . lang . String username = "root" ; java . lang . String password = "root123" ; java . lang . String hostname = "10.28.197.23" ; int port = 22 ; java . util . Prop... | org . junit . Assert . assertNull ( result ) |
testEndsWithPattern ( ) { java . lang . String [ ] bogusPatterns = new java . lang . String [ ] { "*.html" , "*.ico" , "*.css" } ; java . lang . String [ ] bogusSources = new java . lang . String [ ] { "/index.html" , "/favicon.ico" , "/druid.css" } ; boolean result = false ; for ( int i = 0 ; i < ( bogusSources . leng... | org . junit . Assert . assertThat ( true , org . hamcrest . CoreMatchers . equalTo ( result ) ) |
testToGetterNames_Value ( ) { java . lang . String result = makeResults ( "Value" , false ) ; "<AssertPlaceHolder>" ; } makeResults ( java . lang . String , boolean ) { java . lang . String lombokResult = de . plushnikov . intellij . plugin . thirdparty . LombokHandlerUtil . toGetterName ( de . plushnikov . intellij . ... | org . junit . Assert . assertThat ( result , org . hamcrest . CoreMatchers . equalTo ( "Value" ) ) |
testBusinessObjectDataSearchWithPartitionValueRangeFiltersNegative ( ) { org . finra . herd . model . jpa . BusinessObjectDataEntity businessObjectDataEntity = createBusinessObjectEntityForPartitionValueFilterTest ( ) ; java . lang . String namespace = businessObjectDataEntity . getBusinessObjectFormat ( ) . getBusines... | org . junit . Assert . assertEquals ( 0 , result . size ( ) ) |
testGetDouble ( ) { org . gradoop . common . model . impl . properties . PropertyValue p = org . gradoop . common . model . impl . properties . PropertyValue . create ( org . gradoop . common . model . impl . properties . DOUBLE_VAL_5 ) ; "<AssertPlaceHolder>" ; } getDouble ( ) { return get ( java . lang . Double . cla... | org . junit . Assert . assertEquals ( org . gradoop . common . model . impl . properties . DOUBLE_VAL_5 , p . getDouble ( ) , 0 ) |
testFetchByPrimaryKeyMissing ( ) { long pk = com . liferay . portal . kernel . test . util . RandomTestUtil . nextLong ( ) ; com . liferay . portal . security . audit . storage . model . AuditEvent missingAuditEvent = _persistence . fetchByPrimaryKey ( pk ) ; "<AssertPlaceHolder>" ; } fetchByPrimaryKey ( long ) { retur... | org . junit . Assert . assertNull ( missingAuditEvent ) |
shouldBeSameInstance ( ) { final java . util . Set < org . apache . tinkerpop . gremlin . jsr223 . GremlinScriptEngine > scriptEngines = new java . util . HashSet ( ) ; java . util . stream . IntStream . range ( 0 , 100 ) . forEach ( ( i ) -> scriptEngines . add ( org . apache . tinkerpop . gremlin . jsr223 . CachedGre... | org . junit . Assert . assertEquals ( 1 , scriptEngines . size ( ) ) |
shortenText ( ) { java . lang . String longText = "hello<sp>world<sp>hello<sp>world<sp>hello<sp>world<sp>hello<sp>world<sp>hello<sp>world<sp>hello<sp>world<sp>hello<sp>world<sp>hello<sp>world<sp>hello<sp>world" ; java . lang . String shortenedText = org . oscm . string . Strings . shortenText ( longText , 20 ) ; "<Asse... | org . junit . Assert . assertTrue ( ( ( shortenedText . length ( ) ) == 20 ) ) |
testRemove ( ) { for ( org . openscience . cdk . graph . MinimalPathIterator i = new org . openscience . cdk . graph . MinimalPathIterator ( g , "a" , "l" ) ; i . hasNext ( ) ; ) { "<AssertPlaceHolder>" ; i . remove ( ) ; } } next ( ) { if ( ! ( nextIsKnown ) ) hasNext ( ) ; nextIsKnown = false ; if ( ! ( hasNext ) ) t... | org . junit . Assert . assertTrue ( ( ( ( ( java . util . List ) ( i . next ( ) ) ) . size ( ) ) == 5 ) ) |
testLogSoftmaxVector ( ) { org . nd4j . linalg . api . ndarray . INDArray temp = org . nd4j . linalg . factory . Nd4j . create ( new double [ ] { 1.0 , 2.0 , 3.0 , 4.0 } ) ; org . nd4j . linalg . api . ndarray . INDArray logsoftmax = org . nd4j . linalg . factory . Nd4j . getExecutioner ( ) . execAndReturn ( new org . ... | org . junit . Assert . assertEquals ( assertion , logsoftmax ) |
givenAChildViewWithBindingAttributes_whenInflateView_thenAChildViewBindingAttributesShouldBeAdded ( ) { declareAChildView ( ) ; org . robobinding . binder . InflatedViewWithRoot inflatedView = bindingViewInflater . inflateView ( layoutId ) ; "<AssertPlaceHolder>" ; } numberOfChildViewBindingAttributes ( org . robobindi... | org . junit . Assert . assertThat ( numberOfChildViewBindingAttributes ( inflatedView ) , org . hamcrest . CoreMatchers . equalTo ( 1 ) ) |
testLocalMeanThresholdIntegral ( ) { ops . run ( net . imagej . ops . threshold . localMean . LocalMeanThresholdIntegral . class , out , in , new net . imglib2 . algorithm . neighborhood . RectangleShape ( 3 , false ) , new net . imglib2 . outofbounds . OutOfBoundsMirrorFactory < net . imglib2 . type . numeric . intege... | org . junit . Assert . assertEquals ( true , out . firstElement ( ) . get ( ) ) |
testGetElementsByEntityIdWithViewRestrictedByGroupAndAPostTransformFilter ( ) { final uk . gov . gchq . gaffer . graph . Graph graph = uk . gov . gchq . gaffer . mapstore . impl . GetAllElementsHandlerTest . getGraph ( ) ; final uk . gov . gchq . gaffer . operation . impl . add . AddElements addElements = new uk . gov ... | org . junit . Assert . assertEquals ( expectedResults , resultsSet ) |
replaceValueTokens ( ) { jetbrains . jetpad . hybrid . BaseHybridEditorEditingTest . type ( "aaaa" ) ; select ( 0 , true ) ; jetbrains . jetpad . hybrid . BaseHybridEditorEditingTest . complete ( ) ; jetbrains . jetpad . hybrid . BaseHybridEditorEditingTest . type ( "aaaa" ) ; "<AssertPlaceHolder>" ; } tokens ( ) { ret... | org . junit . Assert . assertEquals ( 1 , sync . tokens ( ) . size ( ) ) |
testGetCommandSize ( ) { tested . register ( command ) ; tested . register ( command1 ) ; int size = tested . getCommandHistory ( ) . size ( ) ; "<AssertPlaceHolder>" ; } size ( ) { return rowData . size ( ) ; } | org . junit . Assert . assertEquals ( 2 , size ) |
testConfigPassword ( ) { final org . kie . server . api . model . KieServerConfig serverConfig = new org . kie . server . api . model . KieServerConfig ( ) ; final java . lang . String defaultPassword = "default" ; serverConfig . addConfigItem ( new org . kie . server . api . model . KieServerConfigItem ( org . kie . s... | org . junit . Assert . assertEquals ( defaultPassword , password ) |
testInsert_ImmutablePerson_AllNulls ( ) { com . jmethods . catatumbo . entities . ImmutablePerson entity = com . jmethods . catatumbo . entities . ImmutablePerson . getSample2 ( ) ; com . jmethods . catatumbo . entities . ImmutablePerson entity2 = com . jmethods . catatumbo . EntityManagerTest . em . insert ( entity ) ... | org . junit . Assert . assertEquals ( entity2 , entity3 ) |
c ( ) { org . junit . contrib . assumes . AssumesTest . UntestedAssumptionsAreAssumedTrue . log += "c" ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertThat ( true , org . hamcrest . CoreMatchers . is ( false ) ) |
testGetMaxHistoryEntries ( ) { hudson . plugins . jobConfigHistory . JobConfigHistory sut = createSut ( ) ; sut . configure ( null , createFormData ( ) ) ; java . lang . String expResult = "5" ; java . lang . String result = sut . getMaxHistoryEntries ( ) ; "<AssertPlaceHolder>" ; } getMaxHistoryEntries ( ) { return ma... | org . junit . Assert . assertEquals ( expResult , result ) |
getUser ( ) { com . foxinmy . weixin4j . mp . model . User user = userApi . getUser ( "owGBftyJWx21nqKlWpI3po5K_Q9o" ) ; "<AssertPlaceHolder>" ; System . out . println ( user ) ; following ( ) ; } getUser ( java . lang . String ) { return getUser ( openId , Lang . zh_CN ) ; } | org . junit . Assert . assertNotNull ( user ) |
testBuildWithDisabledDefaultConstraints ( ) { unit . setActive ( false ) ; unit . setSecurity ( false ) ; org . lnu . is . multysearch . person . PersonList context = new org . lnu . is . multysearch . person . PersonList ( ) ; java . lang . String expectedQuery = "SELECT<sp>e<sp>FROM<sp>Person<sp>e<sp>" ; org . lnu . ... | org . junit . Assert . assertEquals ( expectedQuery , actualQuery ) |
testTwentySwitchTopologyLevel3 ( ) { org . opennms . netmgt . enlinkd . TwentyNodeTopology topology = new org . opennms . netmgt . enlinkd . TwentyNodeTopology ( ) ; org . opennms . netmgt . enlinkd . service . api . BroadcastDomain domain = new org . opennms . netmgt . enlinkd . service . api . BroadcastDomain ( ) ; o... | org . junit . Assert . assertEquals ( 0 , ndbtB . getFailed ( ) . size ( ) ) |
testParseBooleanLiteral_space ( ) { java . lang . String ttl = "<http://www.ex.com/s><sp><http://www.ex.com/b><sp>true<sp>.\n" ; org . eclipse . rdf4j . model . Model m = org . eclipse . rdf4j . rio . Rio . parse ( new java . io . StringReader ( ttl ) , "http://ex/" , RDFFormat . TURTLE ) ; "<AssertPlaceHolder>" ; } si... | org . junit . Assert . assertEquals ( 1 , m . size ( ) ) |
testParseZeroX ( ) { java . lang . String source = ( ( ( ( ( "{0" + ( getDecimalCharacter ( ) ) ) + "0;<sp>-1" ) + ( getDecimalCharacter ( ) ) ) + "4343;<sp>1" ) + ( getDecimalCharacter ( ) ) ) + "6333}" ; org . apache . commons . math4 . linear . ArrayRealVector expected = new org . apache . commons . math4 . linear .... | org . junit . Assert . assertEquals ( expected , actual ) |
produceExcelReport ( ) { java . util . List < net . rrm . ehour . report . reports . element . FlatReportElement > elements = SkinConfigPanel . TimesheetExportDummyDataGenerator . createMonthData ( getConfig ( ) ) ; net . rrm . ehour . report . reports . ReportData data = new net . rrm . ehour . report . reports . Repo... | org . junit . Assert . assertTrue ( ( ( excelData . length ) > 0 ) ) |
testConstructor_withCapacity ( ) { org . jparsec . internal . util . IntList intList = new org . jparsec . internal . util . IntList ( 1 ) ; "<AssertPlaceHolder>" ; } size ( ) { return len ; } | org . junit . Assert . assertEquals ( 0 , intList . size ( ) ) |
testDdl_TYPE_BINARY ( ) { java . lang . String ddl = ( "CREATE<sp>FOREIGN<sp>TABLE<sp>ONE_TYPE<sp>(" + ( org . teiid . designer . vdb . dynamic . TestModelToDdlGenerator . BQT2_TYPE_DDL . TYPE_BINARY ) ) + ")<sp>OPTIONS(UPDATABLE<sp>'TRUE');" ; java . lang . String expectedDdl = ( "CREATE<sp>FOREIGN<sp>TABLE<sp>ONE_TYP... | org . junit . Assert . assertEquals ( expectedDdl , generatedDdl ) |
testJavascriptFormType ( ) { long count = repositoryService . createProcessDefinitionQuery ( ) . count ( ) ; "<AssertPlaceHolder>" ; org . activiti . engine . repository . ProcessDefinition processDefinition = repositoryService . createProcessDefinitionQuery ( ) . processDefinitionKey ( "leave" ) . singleResult ( ) ; o... | org . junit . Assert . assertEquals ( 1 , count ) |
validate_TimestampAndSampledValueIsValid_returnTrue ( ) { meterValue . setTimestamp ( java . util . Calendar . getInstance ( ) ) ; meterValue . setSampledValue ( aList ( sampledValueMock ) ) ; when ( sampledValueMock . validate ( ) ) . thenReturn ( true ) ; boolean isValid = meterValue . validate ( ) ; "<AssertPlaceHol... | org . junit . Assert . assertThat ( isValid , org . hamcrest . CoreMatchers . is ( true ) ) |
testOk ( ) { final nl . moderniseringgba . isc . esb . message . lo3 . impl . Ii01Bericht ii01Bericht = new nl . moderniseringgba . isc . esb . message . lo3 . impl . Ii01Bericht ( ) ; ii01Bericht . setBronGemeente ( "1234" ) ; ii01Bericht . setDoelGemeente ( "5678" ) ; ii01Bericht . set ( Lo3CategorieEnum . PERSOON , ... | org . junit . Assert . assertEquals ( null , subject . execute ( parameters ) ) |
test_GetTextBox_By_AutomationId ( ) { when ( element . findFirst ( mmarquee . automation . BaseAutomationTest . isTreeScope ( TreeScope . Descendants ) , any ( ) ) ) . thenReturn ( targetElement ) ; mmarquee . automation . controls . AutomationTextBox textBox = spyWndw . getTextBox ( mmarquee . automation . controls . ... | org . junit . Assert . assertEquals ( targetElement , textBox . getElement ( ) ) |
testTimerStartResume ( ) { try { com . igumnov . common . Benchmark . timerStart ( ) ; com . igumnov . common . Benchmark . timerResume ( ) ; } catch ( java . lang . Exception e ) { "<AssertPlaceHolder>" ; } } timerResume ( ) { com . igumnov . common . Benchmark . timerResume ( com . igumnov . common . Benchmark . time... | org . junit . Assert . assertTrue ( true ) |
testGetBuffer ( ) { io . netty . buffer . ByteBuf buffer = io . netty . buffer . Unpooled . buffer ( 1024 ) ; org . apache . qpid . jms . provider . amqp . message . AmqpWritableBuffer writable = new org . apache . qpid . jms . provider . amqp . message . AmqpWritableBuffer ( buffer ) ; "<AssertPlaceHolder>" ; } getBuf... | org . junit . Assert . assertSame ( buffer , writable . getBuffer ( ) ) |
shouldRejectSelfSignedCertificateWithCRLDP ( ) { boolean hasFailure = parseCertificate ( "badRootBadCRLDP.cer" ) ; "<AssertPlaceHolder>" ; } parseCertificate ( java . lang . String ) { java . io . File file = new java . io . File ( net . ripe . rpki . commons . interop . BBNCertificateConformanceTest . PATH_TO_BBN_OBJE... | org . junit . Assert . assertTrue ( hasFailure ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.