input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
datumIngangDeelsOnbekend ( ) { final nl . bzk . algemeenbrp . dal . domein . brp . entity . ToegangBijhoudingsautorisatie toegang = new nl . bzk . algemeenbrp . dal . domein . brp . entity . ToegangBijhoudingsautorisatie ( new nl . bzk . algemeenbrp . dal . domein . brp . entity . PartijRol ( new nl . bzk . algemeenbrp... | org . junit . Assert . assertEquals ( 1 , errorCount ( toegang ) ) |
testGetFileNameReturnsNullWhenTemplatesAreInvolved ( ) { final java . lang . String input = "/wordpress/templates/bazinga/frob.txt" ; final java . lang . String output = org . microbean . helm . chart . StreamOrientedChartLoader . getOrdinaryFileName ( input ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertNull ( output ) |
testExtractBaseDn ( ) { java . lang . String dn = "cn=user1,ou=CORP1,dc=mycompany,dc=com" ; java . lang . String expected = "ou=CORP1,dc=mycompany,dc=com" ; java . lang . String actual = org . apache . hive . service . auth . ldap . LdapUtils . extractBaseDn ( dn ) ; "<AssertPlaceHolder>" ; } extractBaseDn ( java . lan... | org . junit . Assert . assertEquals ( expected , actual ) |
runTest ( ) { boolean result = checkNoError ( "Social_Profiles_Get_Title" ) ; "<AssertPlaceHolder>" ; } getNoErrorMsg ( ) { return noErrorMsg ; } | org . junit . Assert . assertTrue ( getNoErrorMsg ( ) , result ) |
testInsertAndSelect ( ) { cc . blynk . server . db . model . FlashedToken [ ] list = new cc . blynk . server . db . model . FlashedToken [ 1 ] ; java . lang . String token = java . util . UUID . randomUUID ( ) . toString ( ) . replace ( "-" , "" ) ; cc . blynk . server . db . model . FlashedToken flashedToken = new cc ... | org . junit . Assert . assertEquals ( flashedToken , selected ) |
testBlasGemm5 ( ) { if ( org . nd4j . linalg . factory . Nd4j . getExecutioner ( ) . getClass ( ) . getSimpleName ( ) . toLowerCase ( ) . contains ( "cuda" ) ) return ; lombok . val A = org . nd4j . linalg . factory . Nd4j . linspace ( 1 , 12 , 12 , DataType . DOUBLE ) . reshape ( 'c' , 4 , 3 ) . dup ( 'f' ) ; lombok .... | org . junit . Assert . assertEquals ( exp , res ) |
testDebugString ( ) { org . apache . commons . jexl3 . internal . introspection . MethodKey c = org . apache . commons . jexl3 . internal . introspection . MethodKeyTest . KEY_LIST [ 0 ] ; java . lang . String str = c . debugString ( ) ; "<AssertPlaceHolder>" ; } debugString ( ) { java . lang . StringBuilder builder = ... | org . junit . Assert . assertNotNull ( str ) |
testEquals4 ( ) { line = line . increment ( org . jacoco . core . internal . analysis . CounterImpl . getInstance ( 111 , 222 ) , org . jacoco . core . internal . analysis . CounterImpl . getInstance ( 333 , 4440 ) ) ; org . jacoco . core . internal . analysis . LineImpl line2 = LineImpl . EMPTY ; line2 = line2 . incre... | org . junit . Assert . assertFalse ( line . equals ( line2 ) ) |
testGnumericStrings ( ) { compareToDefaults ( new org . apache . poi . hssf . usermodel . TestHSSFPalette . ColorComparator ( ) { @ org . apache . poi . hssf . usermodel . Override public void compare ( org . apache . poi . hssf . util . HSSFColor expected , org . apache . poi . hssf . util . HSSFColor palette ) { "<As... | org . junit . Assert . assertEquals ( expected . getHexString ( ) , palette . getHexString ( ) ) |
pruneCheckpoints ( ) { final int chkCount = 3 ; java . util . List < org . apache . flink . runtime . checkpoint . TaskStateSnapshot > taskStateSnapshots = storeStates ( chkCount ) ; taskLocalStateStore . pruneMatchingCheckpoints ( ( long chk ) -> chk != ( chkCount - 1 ) ) ; for ( int i = 0 ; i < ( chkCount - 1 ) ; ++ ... | org . junit . Assert . assertNull ( taskLocalStateStore . retrieveLocalState ( i ) ) |
testWriteValues ( ) { testStreaming ( new com . threerings . nexus . io . JVMIOTest . StreamTester ( ) { public void writeTest ( com . threerings . nexus . io . Streamable . Output out ) { out . writeValues ( Widget . WS . size ( ) , Widget . WS . iterator ( ) ) ; } public void readTest ( com . threerings . nexus . io ... | org . junit . Assert . assertEquals ( Widget . WS , into ) |
testGetReceievedAddressesTest_nullAddressCollection_returnEmpty ( ) { final java . util . Set < java . lang . String > addresses = notifDao . getReceivedAddresses ( "test" , null ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertEquals ( 0 , addresses . size ( ) ) |
testSearchCountByType ( ) { int initialCount = com . liferay . dynamic . data . mapping . service . DDMStructureLocalServiceUtil . searchCount ( com . liferay . portal . kernel . test . util . TestPropsValues . getCompanyId ( ) , new long [ ] { group . getGroupId ( ) } , com . liferay . dynamic . data . mapping . servi... | org . junit . Assert . assertEquals ( ( initialCount + 1 ) , count ) |
testBasicRoleWithDefaultsWildcardPrefix ( ) { org . apache . activemq . artemis . core . server . management . JMXAccessControlList controlList = new org . apache . activemq . artemis . core . server . management . JMXAccessControlList ( ) ; controlList . addToDefaultAccess ( "setSomething" , "admin" ) ; controlList . ... | org . junit . Assert . assertArrayEquals ( roles . toArray ( ) , new java . lang . String [ ] { "admin" } ) |
bothMatrixIsTrue ( ) { "<AssertPlaceHolder>" ; } matrix ( ) { return ( ( this ) == ( org . jenkinsci . plugins . postbuildscript . model . ExecuteOn . MATRIX ) ) || ( ( this ) == ( org . jenkinsci . plugins . postbuildscript . model . ExecuteOn . BOTH ) ) ; } | org . junit . Assert . assertThat ( ExecuteOn . BOTH . matrix ( ) , org . hamcrest . CoreMatchers . is ( true ) ) |
getHeaderHtml ( ) { when ( markdownProcessor . headerMarkdownToHtml ( de . blizzy . documentr . markdown . PageRendererTest . MARKDOWN , de . blizzy . documentr . markdown . PageRendererTest . PROJECT , de . blizzy . documentr . markdown . PageRendererTest . BRANCH , de . blizzy . documentr . markdown . PageRendererTes... | org . junit . Assert . assertEquals ( de . blizzy . documentr . markdown . PageRendererTest . HTML , result ) |
testCleanAllProjects ( ) { java . lang . String [ ] args = new java . lang . String [ ] { "--clean" , "--projectlocations" , proot . toString ( ) , "--buildType" , "allprojects" } ; new org . eclipse . n4js . hlc . base . N4jscBase ( ) . doMain ( args ) ; "<AssertPlaceHolder>" ; } countFilesCompiledToES ( java . lang .... | org . junit . Assert . assertEquals ( 0 , countFilesCompiledToES ( proot . toString ( ) ) ) |
basicLongMixLiteralBsTest ( ) { final org . eclipse . rdf4j . query . algebra . evaluation . QueryBindingSet bs = new org . eclipse . rdf4j . query . algebra . evaluation . QueryBindingSet ( ) ; bs . addBinding ( "X" , org . apache . rya . indexing . pcj . storage . accumulo . AccumuloPcjSerializerTest . VF . createLit... | org . junit . Assert . assertEquals ( bs , newBs ) |
test_withDayOfMonth_noChange_same ( ) { java . time . LocalDate t = TEST_2007_07_15 . withDayOfMonth ( 15 ) ; "<AssertPlaceHolder>" ; } withDayOfMonth ( int ) { if ( ( this . day ) == dayOfMonth ) { return this ; } return java . time . LocalDate . of ( year , month , dayOfMonth ) ; } | org . junit . Assert . assertSame ( t , TEST_2007_07_15 ) |
testCDSDeletionInExonReverse ( ) { de . charite . compbio . jannovar . reference . GenomeVariant change = new de . charite . compbio . jannovar . reference . GenomeVariant ( new de . charite . compbio . jannovar . reference . GenomePosition ( de . charite . compbio . jannovar . reference . TranscriptSequenceChangeHelpe... | org . junit . Assert . assertEquals ( expectedBuilder . toString ( ) , resultTranscript ) |
writeHandshakeMessage ( ) { java . util . UUID uuid = java . util . UUID . randomUUID ( ) ; cocaine . message . Message msg = cocaine . message . Messages . handshake ( uuid ) ; byte [ ] bytes = pack . write ( java . util . Arrays . asList ( 0 , 0 , java . util . Arrays . asList ( uuid ) ) ) ; byte [ ] result = pack . ... | org . junit . Assert . assertArrayEquals ( bytes , result ) |
testGetFieldCompletionsForSomethingThatDoesNotReturnFields ( ) { org . uberfire . client . callbacks . Callback < org . kie . soup . project . datamodel . oracle . ModelField [ ] > callback = spy ( new org . uberfire . client . callbacks . Callback < org . kie . soup . project . datamodel . oracle . ModelField [ ] > ( ... | org . junit . Assert . assertEquals ( 0 , result . length ) |
testInjectionTargetEjblocal31 ( ) { java . util . List < java . lang . String > errors = testXMLMergeHelper ( 31 , "InjectionTargetEjblocal" ) ; "<AssertPlaceHolder>" ; } toString ( ) { return this . toString ( "" ) ; } | org . junit . Assert . assertTrue ( errors . toString ( ) , errors . isEmpty ( ) ) |
deltaSecsTruncatesFractionalSecondsTest ( ) { try ( org . apache . storm . utils . Time . SimulatedTime t = new org . apache . storm . utils . Time . SimulatedTime ( ) ) { int current = org . apache . storm . utils . Time . currentTimeSecs ( ) ; org . apache . storm . utils . Time . advanceTime ( 1500 ) ; "<AssertPlace... | org . junit . Assert . assertEquals ( org . apache . storm . utils . Time . deltaSecs ( current ) , 1 , 0 ) |
t02_get_file ( ) { this . t01_create_file ( ) ; if ( ( this . vfs ) != null ) { java . lang . String filename = "hello.txt" ; droidefense . vfs . model . base . IVirtualNode file = this . vfs . get ( filename ) ; "<AssertPlaceHolder>" ; } } get ( java . lang . String ) { if ( key != null ) { return storage . get ( key ... | org . junit . Assert . assertNotNull ( file ) |
testAutomappedDoesNotEqualNull ( ) { boolean b = org . davidmoten . rx . jdbc . Database . test ( ) . select ( "select<sp>name,<sp>score<sp>from<sp>person<sp>where<sp>name=?" ) . parameterStream ( io . reactivex . Flowable . just ( "FRED" ) ) . autoMap ( org . davidmoten . rx . jdbc . DatabaseTest . Person2 . class ) .... | org . junit . Assert . assertFalse ( b ) |
saveObs_shouldCreateNewFileFromComplexDataForNewObs ( ) { executeDataSet ( org . openmrs . api . ObsServiceTest . COMPLEX_OBS_XML ) ; org . openmrs . api . ObsService os = org . openmrs . api . context . Context . getObsService ( ) ; org . openmrs . api . ConceptService cs = org . openmrs . api . context . Context . ge... | org . junit . Assert . assertTrue ( createdFile . exists ( ) ) |
testDiscoverServices ( ) { org . eclipse . kura . example . ble . tisensortag . tinyb . TiSensorTagBuilder builder = new org . eclipse . kura . example . ble . tisensortag . tinyb . TiSensorTagBuilder ( true , true ) . addService ( TiSensorTagGatt . UUID_TEMP_SENSOR_SERVICE , mock ( org . eclipse . kura . bluetooth . l... | org . junit . Assert . assertEquals ( 8 , services . size ( ) ) |
test ( ) { com . arjuna . ats . arjuna . common . Uid txId = new com . arjuna . ats . arjuna . common . Uid ( ) ; org . omg . CosTransactions . otid_t tid = com . arjuna . ats . jts . utils . Utility . uidToOtid ( txId ) ; com . arjuna . ats . arjuna . common . Uid u = com . arjuna . ats . jts . utils . Utility . otidT... | org . junit . Assert . assertTrue ( txId . equals ( u ) ) |
testShBinaryWithMappedResources ( ) { java . util . List < java . lang . String > lines = testMappedResources ( "same_cell" ) ; java . lang . String expectedPlatform = com . facebook . buck . util . environment . Platform . detect ( ) . getPrintableName ( ) ; java . util . List < java . lang . String > expected = com .... | org . junit . Assert . assertEquals ( expected , lines ) |
testDepth ( ) { root . add ( A . add ( B . add ( C ) ) ) ; "<AssertPlaceHolder>" ; } depth ( ) { int re = 0 ; org . nutz . lang . util . Node < T > nd = this ; while ( null != ( nd . parent ( ) ) ) { re ++ ; nd = nd . parent ( ) ; } return re ; } | org . junit . Assert . assertEquals ( 3 , C . depth ( ) ) |
shouldTagImage ( ) { final javax . ws . rs . core . Response response = postResponse ( target ( "images" ) . path ( "ubuntu:latest" ) . path ( "tag" ) . queryParam ( "repo" , "ubuntu" ) . queryParam ( "tag" , "test" ) ) ; "<AssertPlaceHolder>" ; response . close ( ) ; } | org . junit . Assert . assertEquals ( 200 , response . getStatus ( ) ) |
getUniqueUserId ( ) { java . lang . String user = "vmmtestuser" ; java . lang . String uniqueUserId = "vmmtestuser" ; com . ibm . websphere . simplicity . log . Log . info ( com . ibm . ws . security . wim . adapter . ldap . fat . URAPIs_TDSLDAPTest_URAttrMappingVar1 . c , "getUniqueUserId" , "Checking<sp>with<sp>a<sp>... | org . junit . Assert . assertEquals ( uniqueUserId , com . ibm . ws . security . wim . adapter . ldap . fat . URAPIs_TDSLDAPTest_URAttrMappingVar1 . servlet . getUniqueUserId ( user ) ) |
testJUHashMap1 ( ) { final int count = 100000 ; final java . util . HashMap map = new java . util . HashMap ( ) ; "<AssertPlaceHolder>" ; final long start = java . lang . System . currentTimeMillis ( ) ; for ( int idx = 0 ; idx < count ; idx ++ ) { final java . lang . String key = "key" + idx ; final java . lang . Stri... | org . junit . Assert . assertNotNull ( map ) |
testDeleting ( ) { searchDatabase . storeMediaPackage ( mediaPackage , accessControlList , new java . util . Date ( ) ) ; java . util . Date deletionDate = new java . util . Date ( ) ; searchDatabase . deleteMediaPackage ( mediaPackage . getIdentifier ( ) . toString ( ) , deletionDate ) ; "<AssertPlaceHolder>" ; } getD... | org . junit . Assert . assertEquals ( deletionDate , searchDatabase . getDeletionDate ( mediaPackage . getIdentifier ( ) . toString ( ) ) ) |
testAvroBinaryDatumReadFromField ( ) { java . util . List < java . lang . String > expectedRows = java . util . Arrays . asList ( "1;aString" ) ; byte [ ] datumBytes = java . nio . file . Files . readAllBytes ( new java . io . File ( getFilePath ( "/avro/flatschema.datum" ) ) . toPath ( ) ) ; org . pentaho . hadoop . s... | org . junit . Assert . assertEquals ( expectedRows , generateDataSample ( recordReader , inputFields ) ) |
testSeekLongs ( ) { org . apache . trevni . TestColumnFile . FILE . delete ( ) ; org . apache . trevni . ColumnFileWriter out = new org . apache . trevni . ColumnFileWriter ( createFileMeta ( ) , new org . apache . trevni . ColumnMetaData ( "test" , ValueType . LONG ) ) ; java . util . Random random = org . apache . tr... | org . junit . Assert . assertEquals ( seekValues [ i ] , v . next ( ) ) |
Iterate_Descending_Tail_Map ( ) { org . javersion . util . PersistentTreeMap < java . lang . Integer , java . lang . Integer > map = mapForRangeTest ( ) ; "<AssertPlaceHolder>" ; } mapForRangeTest ( ) { org . javersion . util . PersistentTreeMap < java . lang . Integer , java . lang . Integer > map = emptyMap ( ) ; for... | org . junit . Assert . assertThat ( keys ( map . range ( 7 , true , null , false , false ) ) , contains ( 9 , 7 ) ) |
defaultConstructor ( ) { final java . util . concurrent . atomic . AtomicInteger numWrites = new java . util . concurrent . atomic . AtomicInteger ( ) ; final org . apache . commons . io . output . ByteArrayOutputStream baos = getByteArrayOutputStream ( numWrites ) ; final org . apache . commons . io . output . Chunked... | org . junit . Assert . assertEquals ( 2 , numWrites . get ( ) ) |
testGetEntitiesWithLimit ( ) { context . setEntityType ( TimelineEntityType . YARN_CONTAINER . toString ( ) ) ; timelineReader . serviceInit ( conf ) ; org . apache . hadoop . yarn . server . timelineservice . reader . TimelineDataToRetrieve dataToRetrieve = new org . apache . hadoop . yarn . server . timelineservice .... | org . junit . Assert . assertEquals ( 2 , actualEntities . size ( ) ) |
set_value_and_ttl ( ) { scouter . server . db . KeyValueStoreRW . set ( scouter . server . db . KeyValueStoreRWTest . vutDiv , scouter . server . db . KeyValueStoreRWTest . vutKey1 , scouter . server . db . KeyValueStoreRWTest . vutValue1 , 3 ) ; "<AssertPlaceHolder>" ; } get ( java . lang . String , java . lang . Stri... | org . junit . Assert . assertEquals ( scouter . server . db . KeyValueStoreRWTest . vutValue1 , scouter . server . db . KeyValueStoreRW . get ( scouter . server . db . KeyValueStoreRWTest . vutDiv , scouter . server . db . KeyValueStoreRWTest . vutKey1 ) ) |
shouldHandleInstant ( ) { final java . time . Instant o = java . time . Instant . ofEpochMilli ( java . lang . System . currentTimeMillis ( ) ) ; "<AssertPlaceHolder>" ; } serializeDeserialize ( org . apache . tinkerpop . shaded . jackson . databind . ObjectMapper , java . lang . Object , java . lang . Class ) { try ( ... | org . junit . Assert . assertEquals ( o , serializeDeserialize ( mapper , o , java . time . Instant . class ) ) |
testCase7 ( ) { org . evosuite . testcase . DefaultTestCase tc = buildTestCase7 ( ) ; java . util . List < org . evosuite . symbolic . BranchCondition > branch_conditions = executeTest ( tc ) ; "<AssertPlaceHolder>" ; } size ( ) { return theTest . size ( ) ; } | org . junit . Assert . assertEquals ( 0 , branch_conditions . size ( ) ) |
test2 ( ) { org . jerlang . type . Str expected = org . jerlang . type . Str . of ( "AAECAwQFBgcICQ==" ) ; org . jerlang . type . Term result = apply ( org . jerlang . stdlib . Base64Test . base64test , org . jerlang . stdlib . Base64Test . test2 , nil ) ; "<AssertPlaceHolder>" ; } apply ( org . jerlang . type . Term ,... | org . junit . Assert . assertEquals ( expected , result ) |
configLoading ( ) { java . util . Properties p = new java . util . Properties ( ) ; p . put ( "foo" , "bar" ) ; p . put ( "a" , "b" ) ; java . io . File config = new java . io . File ( temporaryFolder . getRoot ( ) , "test.cfg" ) ; try ( java . io . OutputStream os = org . apache . commons . io . FileUtils . openOutput... | org . junit . Assert . assertEquals ( "bar" , p2 . getProperty ( "foo" ) ) |
testGetNetty ( ) { org . apache . maven . artifact . versioning . ArtifactVersion version = ArtifactRetriever . DEFAULT . getLatestReleaseVersion ( "io.netty" , "netty-handler" ) ; "<AssertPlaceHolder>" ; } getLatestReleaseVersion ( java . lang . String , java . lang . String ) { return getLatestReleaseVersion ( groupI... | org . junit . Assert . assertNotNull ( version ) |
testMapInhoud2012 ( ) { final java . sql . Timestamp timestamp = new java . sql . Timestamp ( nl . bzk . migratiebrp . conversie . model . brp . attribuut . BrpDatumTijd . fromDatumTijd ( 20121218131000L , null ) . getJavaDate ( ) . getTime ( ) ) ; final nl . bzk . algemeenbrp . dal . domein . brp . entity . Administra... | org . junit . Assert . assertNotNull ( result ) |
consumeGeneratedCursorAndCloseIt ( ) { java . lang . Object value = flowRunner ( "consumeGeneratedStream" ) . withPayload ( data ) . run ( ) . getMessage ( ) . getPayload ( ) . getValue ( ) ; "<AssertPlaceHolder>" ; } getValue ( ) { return value ; } | org . junit . Assert . assertThat ( value , org . hamcrest . CoreMatchers . is ( data ) ) |
testDismissCache_addLongRange ( ) { org . roaringbitmap . FastRankRoaringBitmap fast = prepareFastWithComputedCache ( ) ; fast . add ( 0L , 2L ) ; "<AssertPlaceHolder>" ; } isCacheDismissed ( ) { return ! ( cumulatedCardinalitiesCacheIsValid ) ; } | org . junit . Assert . assertTrue ( fast . isCacheDismissed ( ) ) |
testSetMapKey ( ) { recode . addMapItem ( key1 , c1 ) ; recode . addMapItem ( key2 , c2 ) ; recode . addMapItem ( key3 , c3 ) ; recode . setKey ( 1 , "youhou" ) ; "<AssertPlaceHolder>" ; } getMapItemKey ( int ) { return org . orbisgis . coremap . renderer . se . parameter . Recode . getMapItem ( i ) . getKey ( ) ; } | org . junit . Assert . assertTrue ( recode . getMapItemKey ( 1 ) . equals ( "youhou" ) ) |
existingDocumentNonTerminalFromUIDeprecated ( ) { org . xwiki . model . reference . DocumentReference documentReference = new org . xwiki . model . reference . DocumentReference ( "xwiki" , java . util . Arrays . asList ( "Main" ) , "WebHome" ) ; com . xpn . xwiki . doc . XWikiDocument document = mock ( com . xpn . xwi... | org . junit . Assert . assertNull ( result ) |
callback ( ) { final java . lang . String result = "I<sp>was<sp>here!" ; alluxio . job . JobConfig jobConfig = new alluxio . job . TestJobConfig ( "unused" ) ; alluxio . job . meta . JobInfo a = new alluxio . job . meta . JobInfo ( 0L , jobConfig , new com . google . common . base . Function < alluxio . job . meta . Jo... | org . junit . Assert . assertEquals ( result , a . getResult ( ) ) |
testCountSort ( ) { int arr_size = 10 ; java . lang . Integer [ ] values1 = new java . lang . Integer [ arr_size ] ; int [ ] values2 = new int [ arr_size ] ; for ( int i = 0 ; i < arr_size ; i ++ ) { values2 [ i ] = ( ( int ) ( arr_size * ( java . lang . Math . random ( ) ) ) ) ; values1 [ i ] = values2 [ i ] ; } ssj .... | org . junit . Assert . assertTrue ( values1 [ i ] . equals ( values2 [ i ] ) ) |
dumpActual_path ( ) { java . io . File target = new java . io . File ( "target/testing/dump/actual-path.xls" ) ; target . delete ( ) ; com . asakusafw . testdriver . JobFlowTester tester = new com . asakusafw . testdriver . JobFlowTester ( getClass ( ) ) ; tester . setFrameworkHomePath ( framework . getHome ( ) ) ; tes... | org . junit . Assert . assertThat ( target . exists ( ) , is ( true ) ) |
listBindingsGlobal ( ) { javax . naming . Context context = test . ContextTest . ejbContainer . getContext ( ) ; javax . naming . NamingEnumeration < javax . naming . Binding > list = context . listBindings ( "java:global" ) ; "<AssertPlaceHolder>" ; System . out . println ( ( "Got<sp>Binding:<sp>" + ( toString ( list ... | org . junit . Assert . assertNotNull ( list ) |
runTest ( ) { boolean result = checkNoError ( "Social_ActivityStreams_Search" ) ; "<AssertPlaceHolder>" ; } getNoErrorMsg ( ) { return noErrorMsg ; } | org . junit . Assert . assertTrue ( getNoErrorMsg ( ) , result ) |
testUploadFiles ( ) { org . springframework . ui . ModelMap model = new org . springframework . ui . ModelMap ( ) ; java . lang . String path = "test-upload-path" ; scriptController . addFolder ( getTestUser ( ) , "" , path , model ) ; java . lang . String upFileName = "Uploaded" ; org . springframework . web . multipa... | org . junit . Assert . assertThat ( searchResult . size ( ) , org . hamcrest . Matchers . is ( 1 ) ) |
testKMeansRunner ( ) { org . locationtech . geowave . test . TestUtils . testLocalIngest ( inputDataStore , DimensionalityType . SPATIAL , org . locationtech . geowave . test . spark . GeoWaveSparkKMeansIT . HAIL_SHAPEFILE_FILE , 1 ) ; long mark = java . lang . System . currentTimeMillis ( ) ; final org . locationtech ... | org . junit . Assert . assertTrue ( "kmeans-hulls-test" 1 , ( ( clusterModel . clusterCenters ( ) . length ) == ( hullsRDD . count ( ) ) ) ) |
testClient ( ) { javax . net . ssl . SSLSocketFactory factory = context . getSocketFactory ( ) ; sslnpn . ssl . SSLSocketImpl socket = ( ( sslnpn . ssl . SSLSocketImpl ) ( factory . createSocket ( ) ) ) ; socket . setNextProtocolNegotiationFallbackAndChoices ( "http/1.1" , "spdy/2" , "http/1.1" ) ; socket . setNextProt... | org . junit . Assert . assertEquals ( "spdy/2" , protocol ) |
testGetBedDemographicStatuses ( ) { org . oscarehr . common . model . BedDemographicStatus bDS1 = new org . oscarehr . common . model . BedDemographicStatus ( ) ; org . oscarehr . common . dao . utils . EntityDataGenerator . generateTestDataForModelClass ( bDS1 ) ; dao . persist ( bDS1 ) ; org . oscarehr . common . mod... | org . junit . Assert . assertTrue ( true ) |
testBrokenListing ( ) { nl . pvanassen . steam . store . item . ListingPageScriptHandle handle = new nl . pvanassen . steam . store . item . ListingPageScriptHandle ( new org . codehaus . jackson . map . ObjectMapper ( ) ) ; try ( java . io . InputStream stream = nl . pvanassen . steam . store . StreamHelper . getStrea... | org . junit . Assert . assertNotNull ( point ) |
testMatchExactlyVlanNull ( ) { actions = new java . util . HashMap < java . lang . String , java . lang . String > ( ) { { put ( "type" , "aaa" ) ; put ( "eth_type" , "12" ) ; } } ; target = new org . o3project . odenos . core . component . network . flow . query . OFPFlowActionPopMplsQuery ( actions ) ; org . o3projec... | org . junit . Assert . assertThat ( target . matchExactly ( ( ( org . o3project . odenos . core . component . network . flow . basic . FlowAction ) ( action ) ) ) , org . hamcrest . CoreMatchers . is ( true ) ) |
getHashLengthSHA1 ( ) { final org . apache . commons . codec . binary . Hex hex = new org . apache . commons . codec . binary . Hex ( ) ; final byte [ ] hash = hex . decode ( "deadbeefdeadbeefdeadbeefdeadbeefdeadbeef" . getBytes ( ) ) ; final byte [ ] entryID = com . lightboxtechnologies . spectrum . FsEntryUtils . mak... | org . junit . Assert . assertEquals ( KeyUtils . SHA1_LEN , com . lightboxtechnologies . spectrum . KeyUtils . getHashLength ( rowKey ) ) |
testCustomReplicationEndpoint ( ) { admin . addPeer ( "testCustomReplicationEndpoint" , new org . apache . hadoop . hbase . replication . ReplicationPeerConfig ( ) . setClusterKey ( org . apache . hadoop . hbase . zookeeper . ZKConfig . getZooKeeperClusterKey ( conf1 ) ) . setReplicationEndpointImpl ( org . apache . ha... | org . junit . Assert . assertEquals ( 0 , org . apache . hadoop . hbase . replication . TestReplicationEndpoint . ReplicationEndpointForTest . replicateCount . get ( ) ) |
cloneAsVersionTest ( ) { final org . opendaylight . controller . cluster . access . commands . TransactionAbortSuccess clone = org . opendaylight . controller . cluster . access . commands . TransactionAbortSuccessTest . OBJECT . cloneAsVersion ( ABIVersion . BORON ) ; "<AssertPlaceHolder>" ; } cloneAsVersion ( org . o... | org . junit . Assert . assertEquals ( org . opendaylight . controller . cluster . access . commands . TransactionAbortSuccessTest . OBJECT , clone ) |
toHex ( ) { byte [ ] data = "hello<sp>world" . getBytes ( ) ; java . lang . String hexData = be . fedict . eid . applet . Controller . toHex ( data ) ; byte [ ] result = org . bouncycastle . util . encoders . Hex . decode ( hexData ) ; "<AssertPlaceHolder>" ; } toHex ( byte [ ] ) { java . lang . StringBuffer stringBuff... | org . junit . Assert . assertArrayEquals ( data , result ) |
testSetArrowSizeDimListKONotSameSize ( ) { final java . util . List < java . util . Optional < java . lang . Double > > vals = java . util . Arrays . asList ( java . util . Optional . of ( arr1 . getArrowSizeDim ( ) ) , java . util . Optional . of ( arr2 . getArrowSizeDim ( ) ) ) ; group . setArrowSizeDimList ( java . ... | org . junit . Assert . assertEquals ( vals , java . util . Arrays . asList ( java . util . Optional . of ( arr1 . getArrowSizeDim ( ) ) , java . util . Optional . of ( arr2 . getArrowSizeDim ( ) ) ) ) |
testToString ( ) { java . lang . StringBuilder sb = new java . lang . StringBuilder ( ) ; sb . append ( "ServerHelloMessage:" ) ; sb . append ( "\n<sp>Protocol<sp>Version:<sp>" ) . append ( "null" ) ; sb . append ( "\n<sp>Server<sp>Unix<sp>Time:<sp>" ) . append ( "null" ) ; sb . append ( "\n<sp>Server<sp>Random:<sp>" )... | org . junit . Assert . assertEquals ( message . toString ( ) , sb . toString ( ) ) |
test_shouldChangeJavaOpts ( ) { createApplication ( ) ; try { org . springframework . shell . core . CommandResult result = addJvmOption ( "-Dkey=value" ) ; "<AssertPlaceHolder>" ; } finally { removeApplication ( ) ; } } isSuccessfulCommand ( ) { return new fr . treeptik . cloudunit . cli . integration . ShellMatchers ... | org . junit . Assert . assertThat ( result , isSuccessfulCommand ( ) ) |
testDatumHuwelijkVolledig ( ) { nl . bzk . brp . model . bericht . kern . HuwelijkGeregistreerdPartnerschapBericht huwelijk = new nl . bzk . brp . util . RelatieBuilder < nl . bzk . brp . model . bericht . kern . HuwelijkGeregistreerdPartnerschapBericht > ( ) . bouwHuwlijkRelatie ( ) . setDatumAanvang ( 20080404 ) . ge... | org . junit . Assert . assertEquals ( 0 , meldingen . size ( ) ) |
elapsedTimeWorksIfNoElapsedTime ( ) { "<AssertPlaceHolder>" ; } elapsedTime ( long , long ) { if ( end > start ) return end - start ; return ( ( ( Long . MAX_VALUE ) - start ) + 1 ) + ( end - ( Long . MIN_VALUE ) ) ; } | org . junit . Assert . assertEquals ( 0L , impl . elapsedTime ( 1L , 1L ) ) |
testFileLengthMaxIntPlusOne ( ) { final java . io . File file = org . apache . hc . core5 . http . nio . entity . TestFileEntityProducer . tempFolder . newFile ( "test.bin" ) ; try ( java . io . RandomAccessFile raFile = new java . io . RandomAccessFile ( file , "rw" ) ) { final long expectedLength = 1L + ( Integer . M... | org . junit . Assert . assertEquals ( expectedLength , fileEntityProducer . getContentLength ( ) ) |
testRegelGaatNietAfZowelRedenVervallenAlsDatumBekend ( ) { final nl . bzk . brp . model . bericht . kern . PersoonBericht persoonBericht = new nl . bzk . brp . model . bericht . kern . PersoonBericht ( ) ; persoonBericht . setReisdocumenten ( new java . util . ArrayList < nl . bzk . brp . model . bericht . kern . Perso... | org . junit . Assert . assertTrue ( berichtEntiteits . isEmpty ( ) ) |
testSerializationAsByteArray ( ) { java . nio . ByteBuffer buff = util . serialize ( msg ) ; org . apache . accumulo . core . securityImpl . thrift . TAuthenticationTokenIdentifier copy = new org . apache . accumulo . core . securityImpl . thrift . TAuthenticationTokenIdentifier ( ) ; byte [ ] array = new byte [ buff .... | org . junit . Assert . assertEquals ( msg , copy ) |
getAdellijkeTitelTestOK ( ) { final nl . bzk . migratiebrp . conversie . model . brp . attribuut . BrpAdellijkeTitelCode atCode = new nl . bzk . migratiebrp . conversie . model . brp . attribuut . BrpAdellijkeTitelCode ( "B" ) ; final nl . bzk . migratiebrp . synchronisatie . dal . domein . brp . kern . entity . Adelli... | org . junit . Assert . assertEquals ( expected , resultAt ) |
testLayerNormOP ( ) { final org . nd4j . linalg . api . ndarray . INDArray random = org . nd4j . linalg . factory . Nd4j . rand ( new int [ ] { 10 , 4 } ) ; final org . nd4j . linalg . api . ndarray . INDArray standardized = random . ulike ( ) ; org . nd4j . linalg . factory . Nd4j . getExecutioner ( ) . exec ( new org... | org . junit . Assert . assertEquals ( res , output ) |
testV8ValueInteger_StringRepresentation ( ) { "<AssertPlaceHolder>" ; } getStringRepresentation ( int ) { switch ( type ) { case com . eclipsesource . v8 . V8Value . NULL : return "String" 7 ; case com . eclipsesource . v8 . V8Value . INTEGER : return "Integer" ; case com . eclipsesource . v8 . V8Value . DOUBLE : retur... | org . junit . Assert . assertEquals ( "Integer" , com . eclipsesource . v8 . V8Value . getStringRepresentation ( 1 ) ) |
testGetCurrentContentHash ( ) { final java . lang . Integer expectedContentHash = 42 ; doReturn ( expectedContentHash ) . when ( presenter ) . getCurrentDiagramHash ( ) ; final java . lang . Integer actualContentHash = presenter . getCurrentContentHash ( ) ; "<AssertPlaceHolder>" ; } getCurrentContentHash ( ) { return ... | org . junit . Assert . assertEquals ( expectedContentHash , actualContentHash ) |
testCreateConnection ( ) { org . apache . qpid . jms . JmsConnectionFactory factory = new org . apache . qpid . jms . JmsConnectionFactory ( getBrokerAmqpConnectionURI ( ) ) ; connection = factory . createConnection ( ) ; "<AssertPlaceHolder>" ; connection . close ( ) ; } createConnection ( ) { return createConnection ... | org . junit . Assert . assertNotNull ( connection ) |
testDescriptorParsingEnvironment ( ) { com . ning . atlas . JRubyTemplateParser p = new com . ning . atlas . JRubyTemplateParser ( ) ; com . ning . atlas . Descriptor d = p . parseDescriptor ( new java . io . File ( "src/test/ruby/ex1/simple-environment.rb" ) ) ; "<AssertPlaceHolder>" ; } getEnvironments ( ) { return c... | org . junit . Assert . assertThat ( d . getEnvironments ( ) . size ( ) , org . hamcrest . CoreMatchers . equalTo ( 1 ) ) |
testUsingPassword ( ) { byte [ ] plaintext = org . cryptonode . jncryptor . AES256JNCryptorOutputStreamTest . getRandomBytes ( 127 ) ; final java . lang . String password = "Testing1234" ; java . io . ByteArrayOutputStream byteStream = new java . io . ByteArrayOutputStream ( ) ; org . cryptonode . jncryptor . AES256JNC... | org . junit . Assert . assertArrayEquals ( plaintext , result ) |
testGetSumOfFileSizesEmpty ( ) { java . util . List < java . lang . Long > list = new java . util . LinkedList ( ) ; long fileSizes = tableIndexDAO . getSumOfFileSizes ( list ) ; "<AssertPlaceHolder>" ; } getSumOfFileSizes ( java . util . List ) { org . sagebionetworks . util . ValidateArgument . required ( rowIds , "r... | org . junit . Assert . assertEquals ( 0 , fileSizes ) |
testPosPosSameLength ( ) { java . lang . String numA = "283746278342837476784564875684767" ; java . lang . String numB = "293478573489347658763745839457637" ; java . lang . String res = "71412358434940908477702819237626" ; java . math . BigInteger aNumber = new java . math . BigInteger ( numA ) ; java . math . BigInteg... | org . junit . Assert . assertTrue ( res . equals ( result . toString ( ) ) ) |
getBatchTimeoutShouldReturnMaxBatchTimeout ( ) { org . apache . metron . writer . BatchTimeoutPolicy batchTimeoutPolicy = new org . apache . metron . writer . BatchTimeoutPolicy ( maxBatchTimeout ) ; when ( configurations . getBatchTimeout ( sensor1 ) ) . thenReturn ( 0 ) ; "<AssertPlaceHolder>" ; } getBatchTimeout ( j... | org . junit . Assert . assertEquals ( ( ( maxBatchTimeout ) * 1000 ) , batchTimeoutPolicy . getBatchTimeout ( sensor1 , configurations ) ) |
chainPipeFunctionCallCombination ( ) { io . burt . jmespath . Expression < java . lang . Object > expected = Sequence ( Sequence ( Sequence ( Property ( "foo" ) , Property ( "bar" ) ) , FlattenArray ( ) ) , FunctionCall ( "sort" , java . util . Arrays . asList ( Current ( ) ) ) ) ; io . burt . jmespath . Expression < j... | org . junit . Assert . assertThat ( actual , org . hamcrest . Matchers . is ( expected ) ) |
testIsAfterLast2 ( ) { org . teiid . jdbc . ResultSetImpl cs = helpExecuteQuery ( ) ; "<AssertPlaceHolder>" ; cs . close ( ) ; } isAfterLast ( ) { if ( ( getFinalRowNumber ( ) ) == ( - 1 ) ) { return false ; } return ( ( ! ( hasNext ( ) ) ) && ( ( this . getAbsoluteRowNumber ( ) ) > ( org . teiid . jdbc . ResultSetImpl... | org . junit . Assert . assertTrue ( ( ! ( cs . isAfterLast ( ) ) ) ) |
squarePlanarZShapeTest ( ) { org . openscience . cdk . interfaces . IAtom atomA = new org . openscience . cdk . Atom ( "C" , new javax . vecmath . Point3d ( 1 , 2 , 0 ) ) ; org . openscience . cdk . interfaces . IAtom atomB = new org . openscience . cdk . Atom ( "C" , new javax . vecmath . Point3d ( 1 , 1 , 0 ) ) ; org... | org . junit . Assert . assertEquals ( SquarePlanarShape . Z_SHAPE , shape ) |
test_g_1 ( ) { symbolic_examples . symbolic_example_10 . NopolExample p = new symbolic_examples . symbolic_example_10 . NopolExample ( ) ; "<AssertPlaceHolder>" ; } g ( int ) { int resg = 0 ; resg = x * 3 ; return resg ; } | org . junit . Assert . assertTrue ( ( ( p . g ( 1 ) ) < 3 ) ) |
nextItemId_tableNewlyAddedItem_returnsNewlyAdded ( ) { java . lang . Object lastId = container . lastItemId ( ) ; java . lang . Object id = container . addItem ( ) ; "<AssertPlaceHolder>" ; } nextItemId ( java . lang . Object ) { int index = ( indexOfId ( itemId ) ) + 1 ; try { return getIdByIndex ( index ) ; } catch (... | org . junit . Assert . assertEquals ( id , container . nextItemId ( lastId ) ) |
testForEachRemainingKeepsDuplicateSequenceIdEventsInSameStream ( ) { java . util . List < org . axonframework . eventhandling . DomainEventMessage > expectedMessages = java . util . Arrays . asList ( event1 , event1 , event2 , event3 , event4 , event4 , event5 ) ; org . axonframework . eventsourcing . eventstore . Doma... | org . junit . Assert . assertEquals ( expectedMessages , actualMessages ) |
primitiveShort ( ) { model . setMyPrimitiveShort ( ( ( short ) ( 1 ) ) ) ; com . google . appengine . api . datastore . Entity entity = meta . modelToEntity ( model ) ; com . google . appengine . api . datastore . Key key = ds . put ( entity ) ; com . google . appengine . api . datastore . Entity entity2 = ds . get ( k... | org . junit . Assert . assertThat ( model2 . getMyPrimitiveShort ( ) , org . hamcrest . CoreMatchers . is ( ( ( short ) ( 1 ) ) ) ) |
testIsUI4 ( ) { boolean isUI = com . vaadin . client . componentlocator . LocatorUtil . isUIElement ( "//com.vaadin.ui.UI[0]" ) ; "<AssertPlaceHolder>" ; } isUIElement ( java . lang . String ) { java . lang . String regex = "^\\/{0,2}(com\\.vaadin\\.ui\\.)?V?UI[\\/\\[]?" ; com . google . gwt . regexp . shared . RegExp ... | org . junit . Assert . assertTrue ( isUI ) |
shouldEventMessages ( ) { final com . calclab . emite . xtesting . handlers . MessageReceivedTestHandler handler = new com . calclab . emite . xtesting . handlers . MessageReceivedTestHandler ( ) ; session . addMessageReceivedHandler ( handler ) ; final com . calclab . emite . core . stanzas . Message message = new com... | org . junit . Assert . assertTrue ( handler . isCalledOnce ( ) ) |
givenTermQuery_whenUseCustomAnalyzer_thenCorrect ( ) { com . baeldung . lucene . InMemoryLuceneIndex luceneIndex = new com . baeldung . lucene . InMemoryLuceneIndex ( new org . apache . lucene . store . RAMDirectory ( ) , new com . baeldung . lucene . MyCustomAnalyzer ( ) ) ; luceneIndex . indexDocument ( "introduction... | org . junit . Assert . assertEquals ( 1 , documents . size ( ) ) |
shouldProvideDdlFile ( ) { importer . setDdlFileName ( org . teiid . designer . ddl . importer . DdlImporterTest . TEST_DDL_FILE . getAbsolutePath ( ) ) ; "<AssertPlaceHolder>" ; } ddlFileName ( ) { return ddlFileName ; } | org . junit . Assert . assertThat ( importer . ddlFileName ( ) , org . hamcrest . core . Is . is ( org . teiid . designer . ddl . importer . DdlImporterTest . TEST_DDL_FILE . getAbsolutePath ( ) ) ) |
shouldPersist ( ) { java . util . Calendar cal = new java . util . GregorianCalendar ( ) ; cal . add ( Calendar . MONTH , 1 ) ; net . rrm . ehour . persistence . project . dao . ProjectAssignment assignment = net . rrm . ehour . persistence . project . dao . ProjectAssignmentObjectMother . createProjectAssignment ( new... | org . junit . Assert . assertNotNull ( assignment . getAssignmentId ( ) ) |
testINDArrayIndexingLessThanRankFourDimension ( ) { org . nd4j . linalg . api . ndarray . INDArray x = org . nd4j . linalg . factory . Nd4j . linspace ( 1 , 16 , 16 ) . reshape ( 'c' , 2 , 2 , 2 , 2 ) ; org . nd4j . linalg . api . ndarray . INDArray indexes = org . nd4j . linalg . factory . Nd4j . create ( new double [... | org . junit . Assert . assertEquals ( assertion , getTest ) |
filterByUnitTest ( ) { java . util . List < javax . measure . Quantity < javax . measure . quantity . Time > > times = new java . util . ArrayList ( getTimes ( ) ) ; times . add ( timeFactory . create ( 30 , Units . HOUR ) ) ; java . util . List < javax . measure . Quantity < javax . measure . quantity . Time > > list ... | org . junit . Assert . assertEquals ( java . lang . Integer . valueOf ( 2 ) , java . lang . Integer . valueOf ( list . size ( ) ) ) |
testValidBijective ( ) { com . github . anno4j . Anno4j anno4j = new com . github . anno4j . Anno4j ( ) ; com . github . anno4j . ValidatedTransaction transaction = anno4j . createValidatedTransaction ( ) ; transaction . begin ( ) ; com . github . anno4j . transaction . ValidatedTransactionTest . SpecialTestResource re... | org . junit . Assert . assertFalse ( exceptionThrown ) |
getProviders_shouldNotReturnRetiredProvidersIfIncludeRetiredIsFalse ( ) { java . util . List < org . openmrs . Provider > providers = service . getProviders ( null , null , null , null , false ) ; "<AssertPlaceHolder>" ; } size ( ) { return getMemberships ( ) . stream ( ) . filter ( ( m ) -> ! ( m . getVoided ( ) ) ) .... | org . junit . Assert . assertEquals ( 7 , providers . size ( ) ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.