input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
dataFileMigrationForExistingHostedRepoJSON ( ) { final org . commonjava . indy . subsys . datafile . DataFile dir = dfm . getDataFile ( org . commonjava . indy . flat . data . DataFileStoreUtils . INDY_STORE , hosted . singularEndpointName ( ) ) ; dir . mkdirs ( ) ; final org . commonjava . indy . subsys . datafile . D... | org . junit . Assert . assertThat ( result , org . hamcrest . CoreMatchers . equalTo ( false ) ) |
testBug321536 ( ) { org . eclipse . xtext . builder . builderState . impl . ResourceDescriptionImpl result = ( ( org . eclipse . xtext . builder . builderState . impl . ResourceDescriptionImpl ) ( BuilderStateFactory . eINSTANCE . createResourceDescription ( ) ) ) ; org . eclipse . emf . common . util . URI uri = org .... | org . junit . Assert . assertEquals ( uri , uriAfterSave ) |
shardRollUpInOrNode ( ) { org . calrissian . mango . criteria . domain . Node node = org . calrissian . mango . criteria . builder . QueryBuilder . create ( ) . or ( ) . eq ( "key3" , "val3" ) . or ( ) . eq ( "key2" , "val2" ) . eq ( "key1" , "val1" ) . end ( ) . end ( ) . build ( ) ; org . calrissian . accumulorecipes... | org . junit . Assert . assertEquals ( 4 , visitor . getShards ( ) . size ( ) ) |
delete_Null ( ) { try { datastore . delete ( null ) ; org . junit . Assert . fail ( ) ; } catch ( at . ac . tuwien . infosys . jcloudscale . datastore . api . DatastoreException e ) { "<AssertPlaceHolder>" ; } } getMessage ( ) { return message ; } | org . junit . Assert . assertNotNull ( e . getMessage ( ) ) |
stubTest2 ( ) { com . rhwayfun . springboot . quickstart . doamin . User user = new com . rhwayfun . springboot . quickstart . doamin . User ( ) ; user . setAge ( 2 ) ; user . setId ( 1 ) ; user . setHobbies ( com . google . common . collect . Lists . newArrayList ( "" ) ) ; com . rhwayfun . springboot . quickstart . d... | org . junit . Assert . assertEquals ( mainService . getUser ( 1 ) , user2 ) |
testWriteOneBit ( ) { org . jerlang . type . BitString bitString = new org . jerlang . type . BitString ( new int [ ] { 1 << 7 } , 7 ) ; bsos . write ( bitString ) ; "<AssertPlaceHolder>" ; } toBitString ( ) { if ( ( bitOffset ) == 0 ) { return new org . jerlang . type . Binary ( bytes . toByteArray ( ) ) ; } else { by... | org . junit . Assert . assertEquals ( bitString , bsos . toBitString ( ) ) |
extensionsCountIsCorrect ( ) { "<AssertPlaceHolder>" ; } getExtensionsCount ( ) { return ( certificate . getCriticalExtensionOIDs ( ) . size ( ) ) + ( certificate . getNonCriticalExtensionOIDs ( ) . size ( ) ) ; } | org . junit . Assert . assertEquals ( 8 , certificate . getExtensionsCount ( ) ) |
issuanceProtocolIdemix ( ) { java . lang . String engineSuffix = "idemix" ; this . deleteStorageDirectory ( "user_storage" ) ; eu . abc4trust . services . user . UserServiceFactory userServiceFactory = new eu . abc4trust . services . user . UserServiceFactory ( ) ; eu . abc4trust . services . TestScenarioFactory testSc... | org . junit . Assert . assertNotNull ( credentialDescription ) |
testLastHourNext ( ) { org . jfree . data . time . Hour last = new org . jfree . data . time . Hour ( 23 , new org . jfree . data . time . Day ( 31 , org . jfree . date . MonthConstants . DECEMBER , 9999 ) ) ; org . jfree . data . time . Hour next = ( ( org . jfree . data . time . Hour ) ( last . next ( ) ) ) ; "<Asser... | org . junit . Assert . assertNull ( next ) |
testCNNBackpropagation2 ( ) { com . github . neuralnetworks . tensor . Matrix seqResult = testCNNBackpropagation2 ( Runtime . CPU_SEQ ) ; com . github . neuralnetworks . tensor . Matrix openclResult = testCNNBackpropagation2 ( Runtime . OPENCL ) ; "<AssertPlaceHolder>" ; } isEqual ( com . github . neuralnetworks . tens... | org . junit . Assert . assertTrue ( isEqual ( seqResult , openclResult ) ) |
testIsStarted ( ) { "<AssertPlaceHolder>" ; } isStarted ( ) { if ( io . joynr . jeeintegration . messaging . JeeServletMessageReceiver . LOG . isDebugEnabled ( ) ) { io . joynr . jeeintegration . messaging . JeeServletMessageReceiver . LOG . debug ( java . lang . String . format ( "isStarted<sp>called<sp>-<sp>returning... | org . junit . Assert . assertFalse ( subject . isStarted ( ) ) |
testStaticDirectoryClassPathWhenFileNotInFileSystemInDevMode ( ) { org . mockito . Mockito . when ( ninjaProperties . isDev ( ) ) . thenReturn ( true ) ; ninja . AssetsControllerHelper assetsControllerHelper = org . mockito . Mockito . mock ( ninja . AssetsControllerHelper . class , Mockito . CALLS_REAL_METHODS ) ; ass... | org . junit . Assert . assertEquals ( 200 , resultCaptor . getValue ( ) . getStatusCode ( ) ) |
reactionNullTest ( ) { org . marc . everest . rmim . uv . cdar2 . pocd_mt000040uv . EntryRelationship entryRelationship = org . oscarehr . e2e . model . export . body . AllergiesModelTest . nullAllergiesModel . getReaction ( ) ; "<AssertPlaceHolder>" ; } getReaction ( ) { return new org . oscarehr . e2e . model . expor... | org . junit . Assert . assertNull ( entryRelationship ) |
setValueTestUncheck ( ) { wd . open ( org . finra . jtaf . ewd . widget . element . html . CheckBoxTest . url ) ; org . finra . jtaf . ewd . widget . ICheckBox c = new org . finra . jtaf . ewd . widget . element . html . CheckBox ( "//input[@id='testUncheckBox']" ) ; org . finra . jtaf . ewd . widget . IElement content... | org . junit . Assert . assertEquals ( exp , content . getText ( ) ) |
testBuildWithParameters ( ) { java . lang . String abbrName = "TestString" ; java . lang . String name = "fsdds" ; org . lnu . is . domain . timesheet . type . TimeSheetType context = new org . lnu . is . domain . timesheet . type . TimeSheetType ( ) ; context . setAbbrName ( abbrName ) ; context . setName ( name ) ; j... | org . junit . Assert . assertEquals ( expectedQuery , actualQuery ) |
deveObterOqueServicoFoiSetado ( ) { final com . fincatto . documentofiscal . nfe400 . classes . cadastro . NFInfoConsultaCadastro infoConsultaCadastro = new com . fincatto . documentofiscal . nfe400 . classes . cadastro . NFInfoConsultaCadastro ( ) ; infoConsultaCadastro . setServico ( "CONS-CAD" ) ; "<AssertPlaceHolde... | org . junit . Assert . assertEquals ( "CONS-CAD" , infoConsultaCadastro . getServico ( ) ) |
testCampoGrande ( ) { java . util . List < com . graphhopper . routing . util . TestAlgoCollector . OneRun > list = new java . util . ArrayList ( ) ; list . add ( new com . graphhopper . routing . util . TestAlgoCollector . OneRun ( ( - 20.4 ) , ( - 54.6 ) , ( - 20.6 ) , ( - 54.54 ) , 25516 , 271 ) ) ; list . add ( new... | org . junit . Assert . assertEquals ( testCollector . toString ( ) , 0 , testCollector . errors . size ( ) ) |
testRemoveBytes0AssumesNegativeIsAll ( ) { buffer = org . smpp . util . ByteBufferTest . bufferOf ( org . smpp . util . ByteBufferTest . A , org . smpp . util . ByteBufferTest . B , org . smpp . util . ByteBufferTest . C ) ; buffer . removeBytes0 ( ( - 1 ) ) ; "<AssertPlaceHolder>" ; } length ( ) { if ( ( buffer ) == n... | org . junit . Assert . assertEquals ( 0 , buffer . length ( ) ) |
correctNodeIdShouldBeReturned ( ) { try ( org . neo4j . graphdb . Transaction tx = database . beginTx ( ) ) { "<AssertPlaceHolder>" ; } } cachingNode ( ) { return new com . graphaware . module . relcount . cache . DegreeCachingNode ( database . getNodeById ( 0 ) , com . graphaware . runtime . config . FluentRuntimeConf... | org . junit . Assert . assertEquals ( 0L , cachingNode ( ) . getId ( ) ) |
shouldGetBaseActivityPackageName ( ) { createRunningTaskInfo ( ) . baseActivity = new android . content . ComponentName ( com . navercorp . utilset . ui . ActivityUtilsTest . INSTALLED_PACKAGE , "" ) ; java . lang . String packageName = com . navercorp . utilset . ui . ActivityUtils . getBaseActivityPackageName ( conte... | org . junit . Assert . assertThat ( packageName , org . hamcrest . CoreMatchers . is ( com . navercorp . utilset . ui . ActivityUtilsTest . INSTALLED_PACKAGE ) ) |
testGetConnection ( ) { com . ctrip . platform . dal . dao . client . DalTransaction test = null ; try { test = new com . ctrip . platform . dal . dao . client . DalTransaction ( getDalConnection ( ) , com . ctrip . platform . dal . dao . client . DalTransactionTest . logicDbName ) ; "<AssertPlaceHolder>" ; } catch ( j... | org . junit . Assert . assertNotNull ( test . getConnection ( ) ) |
testMemSet_partialBlock ( ) { a = create ( 2 , 5 , 0 , null ) ; int [ ] data = new int [ ] { 1 , 2 , 3 , 4 , 5 } ; int [ ] expected = new int [ ] { 1 , 9 , 9 , 9 , 5 } ; int [ ] out = new int [ 5 ] ; int p1 = a . malloc ( ) ; a . setInts ( p1 , 0 , data , 0 , a . blockSize ( ) ) ; a . memSet ( p1 , 1 , 3 , 9 ) ; a . ge... | org . junit . Assert . assertArrayEquals ( expected , out ) |
testCreateDropCreateTempTableSimpleDerby ( ) { final java . lang . String tmpCreate = "DECLARE<sp>GLOBAL<sp>TEMPORARY<sp>TABLE<sp>%s.%s<sp>%s<sp>not<sp>logged<sp>on<sp>commit<sp>preserve<sp>rows" ; try ( java . sql . Connection connection = methodWatcher . createConnection ( ) ) { com . splicemachine . derby . test . f... | org . junit . Assert . assertEquals ( 5 , com . splicemachine . derby . test . framework . SpliceUnitTest . resultSetSize ( resultSet ) ) |
reverseForEach ( ) { org . eclipse . collections . api . list . ImmutableList < java . lang . Integer > list = Lists . immutable . empty ( ) ; org . eclipse . collections . api . list . MutableList < java . lang . Integer > result = Lists . mutable . empty ( ) ; list . reverseForEach ( org . eclipse . collections . imp... | org . junit . Assert . assertEquals ( list , result ) |
testGetFirstPacketFromTimeout ( ) { com . digi . xbee . api . RemoteXBeeDevice mockedRemoteDevice = org . mockito . Mockito . mock ( com . digi . xbee . api . RemoteXBeeDevice . class ) ; org . mockito . Mockito . when ( mockedRemoteDevice . get64BitAddress ( ) ) . thenReturn ( com . digi . xbee . api . models . XBeePa... | org . junit . Assert . assertNull ( xbeePacket ) |
testModelChanged ( ) { final java . util . HashSet < java . lang . Integer > oldKeys = new java . util . HashSet ( model . getTrackModel ( ) . trackIDs ( true ) ) ; final fiji . plugin . trackmate . features . track . TrackSpeedStatisticsAnalyzerTest . TestTrackSpeedStatisticsAnalyzer analyzer = new fiji . plugin . tra... | org . junit . Assert . assertTrue ( analyzer . hasBeenCalled ) |
testSetPublicationStatuses4 ( ) { this . statuses = null ; this . solrSearchResult . setPublicationStatuses ( this . statuses ) ; "<AssertPlaceHolder>" ; } getPublicationStatuses ( ) { if ( ( this . publicationStatuses ) == null ) { this . publicationStatuses = new java . util . ArrayList ( ) ; } return this . publicat... | org . junit . Assert . assertEquals ( new java . util . ArrayList ( ) , solrSearchResult . getPublicationStatuses ( ) ) |
testFetchByPrimaryKeysWithMultiplePrimaryKeysWhereNoPrimaryKeysExist ( ) { long pk1 = com . liferay . portal . kernel . test . util . RandomTestUtil . nextLong ( ) ; long pk2 = com . liferay . portal . kernel . test . util . RandomTestUtil . nextLong ( ) ; java . util . Set < java . io . Serializable > primaryKeys = ne... | org . junit . Assert . assertTrue ( roles . isEmpty ( ) ) |
test_CaptureEnPassantFromAFile ( ) { classUnderTest = addWhitePawn ( GenericPosition . a5 ) ; addBlackPawn ( GenericPosition . b7 ) ; pm = new eubos . board . pieces . PositionManager ( new eubos . board . Board ( pl ) , eubos . board . pieces . Piece . Colour . white ) ; pm . performMove ( new eubos . board . pieces .... | org . junit . Assert . assertTrue ( ml . contains ( expectedMove ) ) |
isOrWithIndexAndLowerCaseWorking ( ) { if ( isBatoo ( ) ) { return ; } final java . lang . String query = "select<sp>r<sp>from<sp>RegularEntityTwo<sp>r<sp>" + ( ( ( ( "<sp>where<sp>r.id<sp>in<sp>(<sp>" + "select<sp>sub.id<sp>from<sp>RegularEntityOne<sp>sub<sp>where<sp>(" ) + "(lower(sub.stringAttribute)<sp>=<sp>lower('... | org . junit . Assert . assertTrue ( ( ( resultFromJPQL . size ( ) ) > 0 ) ) |
testWriteIntegerValueThenChangeToDouble ( ) { java . util . List < com . google . firebase . database . DatabaseReference > refs = com . google . firebase . testing . IntegrationTestUtils . getRandomNode ( com . google . firebase . database . integration . EventTestIT . masterApp , 1 ) ; com . google . firebase . datab... | org . junit . Assert . assertTrue ( readHelper . waitForEvents ( ) ) |
test_registeredCurrencies ( ) { java . util . List < org . joda . money . CurrencyUnit > curList = org . joda . money . CurrencyUnit . registeredCurrencies ( ) ; boolean found = false ; for ( org . joda . money . CurrencyUnit currencyUnit : curList ) { if ( currencyUnit . getCode ( ) . equals ( "GBP" ) ) { found = true... | org . junit . Assert . assertTrue ( found ) |
testGetCommonResponse ( ) { com . aliyuncs . auth . Credential credential = mock ( com . aliyuncs . auth . Credential . class ) ; when ( credential . getSecurityToken ( ) ) . thenReturn ( null ) ; com . aliyuncs . profile . DefaultProfile profile = mock ( com . aliyuncs . profile . DefaultProfile . class ) ; when ( pro... | org . junit . Assert . assertTrue ( ( ( spyClient . getCommonResponse ( commonRequest ) ) instanceof com . aliyuncs . CommonResponse ) ) |
testFromEbXMLEmpty ( ) { org . openehealth . ipf . commons . ihe . xds . core . requests . query . GetFoldersForDocumentQuery result = new org . openehealth . ipf . commons . ihe . xds . core . requests . query . GetFoldersForDocumentQuery ( ) ; transformer . fromEbXML ( result , ebXML ) ; "<AssertPlaceHolder>" ; } fro... | org . junit . Assert . assertEquals ( new org . openehealth . ipf . commons . ihe . xds . core . requests . query . GetFoldersForDocumentQuery ( ) , result ) |
testOptionCanHaveADefaultValue ( ) { cli . defineOption ( info . novatec . testit . livingdoc . util . cli . OptionBuilder . create ( "block<sp>size" ) . withShortForm ( "-b" ) . wantsArgument ( "SIZE" ) . asType ( int . class ) . defaultingTo ( 1024 ) ) ; cli . parse ( ) ; "<AssertPlaceHolder>" ; } getOptionValue ( ja... | org . junit . Assert . assertEquals ( 1024 , cli . getOptionValue ( "block<sp>size" ) ) |
testInsertColumn_NoShiftData2 ( ) { org . eclipse . swt . widgets . Table table = new org . eclipse . swt . widgets . Table ( shell , org . eclipse . swt . SWT . BORDER ) ; org . eclipse . swt . widgets . TableItem item = new org . eclipse . swt . widgets . TableItem ( table , org . eclipse . swt . SWT . NONE ) ; item ... | org . junit . Assert . assertEquals ( "cell0" , item . getText ( 0 ) ) |
testParseSizeBigInt ( ) { java . lang . String typeString = "bigint(20)" ; java . lang . Integer size = org . sagebionetworks . table . cluster . MySqlColumnType . parseSize ( typeString ) ; "<AssertPlaceHolder>" ; } parseSize ( java . lang . String ) { java . lang . String [ ] split = typeString . split ( "\\(" ) ; if... | org . junit . Assert . assertEquals ( new java . lang . Integer ( 20 ) , size ) |
isMultipleJoinFetch4LevelsWorking ( ) { final com . uaihebert . model . EasyCriteria < com . uaihebert . model . test . Person > easyCriteria = com . uaihebert . uaicriteria . base . element . EasyCriteriaFactory . createQueryCriteria ( getEntityManager ( ) , com . uaihebert . model . test . Person . class ) ; easyCrit... | org . junit . Assert . assertTrue ( ( ( result . size ( ) ) > 0 ) ) |
testReadIndexNegativeWithParam ( ) { com . twelvemonkeys . imageio . util . ImageReader reader = createReader ( ) ; com . twelvemonkeys . imageio . util . ImageReaderAbstractTest . TestData data = getTestData ( ) . get ( 0 ) ; reader . setInput ( data . getInputStream ( ) ) ; java . awt . image . BufferedImage image = ... | org . junit . Assert . assertNull ( image ) |
testListConfigurationNull ( ) { org . osgi . service . cm . Configuration config = cm . createFactoryConfiguration ( "test" , null ) ; config . update ( ) ; try { org . osgi . service . cm . Configuration [ ] configs = cm . listConfigurations ( null ) ; "<AssertPlaceHolder>" ; } finally { config . delete ( ) ; } } list... | org . junit . Assert . assertTrue ( ( ( configs != null ) && ( ( configs . length ) > 0 ) ) ) |
testForwardScanForRecordBeforeLedger ( ) { java . lang . String streamName = runtime . getMethodName ( ) ; org . apache . distributedlog . BKDistributedLogManager bkdlm = ( ( org . apache . distributedlog . BKDistributedLogManager ) ( createNewDLM ( conf , streamName ) ) ) ; long txid = 1 ; txid += org . apache . distr... | org . junit . Assert . assertEquals ( new org . apache . distributedlog . DLSN ( 2 , 0 , 0 ) , logrec . getDlsn ( ) ) |
testMutableMultiply_double ( ) { jsat . linear . GenericMatrixTest . TestImp AtTwo = new jsat . linear . GenericMatrixTest . TestImp ( new double [ ] [ ] { new double [ ] { 1 * 2 , 5 * 2 , 4 * 2 , 8 * 2 , 9 * 2 } , new double [ ] { 1 * 2 , 5 * 2 , 7 * 2 , 3 * 2 , 7 * 2 } , new double [ ] { 0 * 2 , 3 * 2 , 8 * 2 , 5 * 2... | org . junit . Assert . assertEquals ( AtTwo , aCopy ) |
hashCode_onEqualObjcets_shouldReturnSameHashCode ( ) { org . openengsb . core . api . model . QueryRequest a = org . openengsb . core . api . model . QueryRequest . create ( ) . setTimestamp ( timestamp ) . addParameter ( "foo" , "bar" ) . addParameter ( "answer" , 42 ) . setContextId ( "someContext" ) ; org . openengs... | org . junit . Assert . assertThat ( a . hashCode ( ) , org . hamcrest . Matchers . is ( b . hashCode ( ) ) ) |
shouldHaveSameHashCodeGivenSelfWithContents ( ) { uk . co . webamoeba . mockito . collections . util . OrderedSet < java . lang . Object > orderedSet = new uk . co . webamoeba . mockito . collections . util . OrderedSet < java . lang . Object > ( java . util . Arrays . < java . lang . Object > asList ( "JKL" , 4L ) ) ;... | org . junit . Assert . assertEquals ( 0 , delta ) |
testLoadedFromUnitOfWorkAfterCreate ( ) { org . axonframework . modelling . saga . Saga < java . lang . Object > saga = testSubject . createInstance ( org . axonframework . common . IdentifierFactory . getInstance ( ) . generateIdentifier ( ) , Object :: new ) ; saga . getAssociationValues ( ) . add ( new org . axonfra... | org . junit . Assert . assertSame ( saga , saga2 ) |
testDeleteParentPageWithChangedParentChild ( ) { com . liferay . wiki . util . test . WikiTestUtil . addPage ( com . liferay . portal . kernel . test . util . TestPropsValues . getUserId ( ) , _group . getGroupId ( ) , _node . getNodeId ( ) , "ParentPage1" , true ) ; com . liferay . wiki . util . test . WikiTestUtil . ... | org . junit . Assert . assertEquals ( "ChildPage" , childPage . getTitle ( ) ) |
whenInverseBidiMap_thenInverseKeyValue ( ) { org . apache . commons . collections4 . BidiMap < java . lang . String , java . lang . String > map = new org . apache . commons . collections4 . bidimap . DualHashBidiMap ( ) ; map . put ( "key1" , "value1" ) ; map . put ( "key2" , "value2" ) ; org . apache . commons . coll... | org . junit . Assert . assertTrue ( ( ( rMap . containsKey ( "value1" ) ) && ( rMap . containsKey ( "value2" ) ) ) ) |
testQueryOne ( ) { com . xkcoding . orm . mybatis . plus . entity . User user = userService . getById ( 1L ) ; "<AssertPlaceHolder>" ; log . debug ( "user=<sp>{}" , user ) ; } | org . junit . Assert . assertNotNull ( user ) |
delete_shouldNotDeleteParentDirectory ( ) { java . io . File parent = new java . io . File ( "delete_shouldNotDeleteParentDirectory" ) ; java . io . File child = new java . io . File ( parent , "child" ) ; parent . mkdir ( ) ; child . createNewFile ( ) ; com . silentcircle . silenttext . util . IOUtils . delete ( child... | org . junit . Assert . assertTrue ( parent . exists ( ) ) |
testPointIndexing ( ) { int slices = 5 ; int rows = 5 ; int cols = 5 ; int l = ( slices * rows ) * cols ; org . nd4j . linalg . api . ndarray . INDArray A = org . nd4j . linalg . factory . Nd4j . linspace ( 1 , l , l ) . reshape ( slices , rows , cols ) ; for ( int s = 0 ; s < slices ; s ++ ) { org . nd4j . linalg . in... | org . junit . Assert . assertEquals ( failureMessage , aView , sameView ) |
testGraphStepHasLabelWithin ( ) { this . sqlgGraph . addVertex ( T . label , "A" ) ; this . sqlgGraph . addVertex ( T . label , "B" ) ; this . sqlgGraph . addVertex ( T . label , "C" ) ; this . sqlgGraph . addVertex ( T . label , "D" ) ; this . sqlgGraph . tx ( ) . commit ( ) ; org . apache . tinkerpop . gremlin . proc... | org . junit . Assert . assertEquals ( 2 , traversal . toList ( ) . size ( ) ) |
synchronous ( ) { org . sqlite . SQLiteConfig config = new org . sqlite . SQLiteConfig ( ) ; config . setSynchronous ( SynchronousMode . OFF ) ; java . sql . Connection conn = java . sql . DriverManager . getConnection ( "jdbc:sqlite:" , config . toProperties ( ) ) ; java . sql . Statement stat = conn . createStatement... | org . junit . Assert . assertEquals ( 0 , synchronous ) |
testMaakHisLeeg ( ) { final nl . bzk . algemeenbrp . dal . domein . brp . entity . Partij partij = new nl . bzk . algemeenbrp . dal . domein . brp . entity . Partij ( "testpartij" , "001234" ) ; partij . setDatumIngang ( 19700101 ) ; "<AssertPlaceHolder>" ; } maakHistorie ( nl . bzk . brp . model . beheer . autaut . To... | org . junit . Assert . assertNotNull ( subject . maakHistorie ( partij ) ) |
bindingsAreWorking ( ) { java . lang . String expression = "print($ROW);<sp>print($ROW.numberOfColumns);$ROW" ; com . airhacks . enhydrator . in . Row row = new com . airhacks . enhydrator . in . Row ( ) ; row . addColumn ( ( - 1 ) , "chief" , "duke" ) ; row . addColumn ( ( - 1 ) , "master" , "juggy" ) ; com . airhacks... | org . junit . Assert . assertFalse ( execute . isEmpty ( ) ) |
testMatchesWithoutFilters ( ) { boolean matches = matcher . matches ( ) ; "<AssertPlaceHolder>" ; } matches ( ) { return ( matchesHttpService ( ) ) && ( matchesConfigurator ( ) ) ; } | org . junit . Assert . assertTrue ( matches ) |
testAsLong ( ) { org . apache . tajo . datum . Datum d = org . apache . tajo . datum . DatumFactory . createInt8 ( 5L ) ; "<AssertPlaceHolder>" ; } asInt8 ( ) { throw new org . apache . tajo . exception . TajoRuntimeException ( new org . apache . tajo . exception . InvalidValueForCastException ( type , INT8 ) ) ; } | org . junit . Assert . assertEquals ( 5L , d . asInt8 ( ) ) |
readCharSequence ( ) { net . openhft . chronicle . wire . Wire wire = createWire ( ) ; wire . write ( ) . object ( "hello<sp>world" ) ; java . lang . CharSequence s = wire . read ( ) . object ( net . openhft . chronicle . wire . CharSequence . class ) ; "<AssertPlaceHolder>" ; } object ( net . openhft . chronicle . wir... | org . junit . Assert . assertEquals ( "hello<sp>world" , s ) |
testGetGeneration ( ) { org . dcache . nfs . vfs . Stat stat = new org . dcache . nfs . vfs . Stat ( ) ; stat . setGeneration ( 1 ) ; "<AssertPlaceHolder>" ; } getGeneration ( ) { return generation ; } | org . junit . Assert . assertEquals ( 1 , stat . getGeneration ( ) ) |
testAccumulation1 ( ) { org . nd4j . linalg . api . ndarray . INDArray array1 = org . nd4j . linalg . factory . Nd4j . create ( 100 ) . assign ( 1.0 ) ; org . nd4j . linalg . api . ndarray . INDArray array2 = org . nd4j . linalg . factory . Nd4j . create ( 100 ) . assign ( 2.0 ) ; org . nd4j . linalg . api . ndarray . ... | org . junit . Assert . assertEquals ( exp , accum ) |
testNietVervallenGeenAapassingGeldigheidActieInhoudGeldigMaterieel ( ) { final nl . bzk . brp . model . hisvolledig . momentview . kern . PersoonUitgeslotenActiesPredikaat persoonViewOpActiesPredikaat = new nl . bzk . brp . model . hisvolledig . momentview . kern . PersoonUitgeslotenActiesPredikaat ( ) ; final nl . bzk... | org . junit . Assert . assertTrue ( persoonViewOpActiesPredikaat . evaluate ( materieelVerantwoordbaar ) ) |
getLargeClobFromResultSet ( ) { java . lang . String clobString = buildClobString ( ( ( ResultSetHelperService . CLOBBUFFERSIZE ) + 1 ) ) ; java . lang . String [ ] expectedNames = new java . lang . String [ ] { "Clob" , "Null" } ; java . lang . String [ ] realValues = new java . lang . String [ ] { clobString , null }... | org . junit . Assert . assertArrayEquals ( expectedValues , columnValues ) |
whenFilterListByName_thenSizeShouldBe4 ( ) { java . util . List < com . baeldung . distinct . Person > personListFiltered = org . eclipse . collections . impl . utility . ListIterate . distinct ( personList , org . eclipse . collections . impl . block . factory . HashingStrategies . fromFunction ( Person :: getName ) )... | org . junit . Assert . assertTrue ( ( ( personListFiltered . size ( ) ) == 4 ) ) |
testNonSerializable ( ) { org . apache . flink . api . java . functions . MapCreator creator = new org . apache . flink . api . java . functions . NonSerializableMapCreator ( ) ; org . apache . flink . api . common . functions . MapFunction < java . lang . Integer , java . lang . Integer > map = creator . getMap ( ) ; ... | org . junit . Assert . assertEquals ( result , 4 ) |
testMoveBelow_ignoresWidgetWithDifferentParent ( ) { org . eclipse . swt . widgets . Control child1 = new org . eclipse . swt . widgets . Label ( shell , org . eclipse . swt . SWT . NONE ) ; org . eclipse . swt . widgets . Control child2 = new org . eclipse . swt . widgets . Label ( shell , org . eclipse . swt . SWT . ... | org . junit . Assert . assertArrayEquals ( new org . eclipse . swt . widgets . Control [ ] { child1 , child2 } , shell . getChildren ( ) ) |
testDynamicQueryByPrimaryKeyMissing ( ) { com . liferay . portal . kernel . dao . orm . DynamicQuery dynamicQuery = com . liferay . portal . kernel . dao . orm . DynamicQueryFactoryUtil . forClass ( com . liferay . document . library . kernel . model . DLFileEntryType . class , _dynamicQueryClassLoader ) ; dynamicQuery... | org . junit . Assert . assertEquals ( 0 , result . size ( ) ) |
peekAndRemove_NotFresh ( ) { cache . put ( org . cache2k . test . core . BasicCacheOperationsWithoutCustomizationsTest . KEY , org . cache2k . test . core . BasicCacheOperationsWithoutCustomizationsTest . VALUE ) ; cache . expireAt ( org . cache2k . test . core . BasicCacheOperationsWithoutCustomizationsTest . KEY , Ex... | org . junit . Assert . assertNull ( v ) |
testIsExecutableSuccess ( ) { java . lang . String command = ( "<sp>" + ( createCorrectCommand ( ) ) ) + "<sp>" ; "<AssertPlaceHolder>" ; } isExecutableCommand ( java . lang . String ) { boolean executable = command . trim ( ) . matches ( ( ( org . oscm . dbtask . DatabaseUpgradeTask . COMMAND_IDENTIFIER ) + "[a-zA-Z]*... | org . junit . Assert . assertTrue ( org . oscm . dbtask . DatabaseUpgradeTask . isExecutableCommand ( command ) ) |
getProviders_shouldReturnProviderStubsWhoseProviderNamesEndWithAGivenString ( ) { org . openmrs . api . ProviderService providerService = org . openmrs . api . context . Context . getProviderService ( ) ; java . lang . String search = "Sanga" ; java . util . List < org . openmrs . Provider > providers = providerService... | org . junit . Assert . assertTrue ( providerStubs . contains ( new org . openmrs . module . htmlformentry . element . ProviderStub ( provider ) ) ) |
testIntermediateCatchEventMessageCorrelation ( ) { org . camunda . bpm . model . bpmn . BpmnModelInstance model = org . camunda . bpm . model . bpmn . Bpmn . createExecutableProcess ( "Process_1" ) . startEvent ( ) . subProcess ( "SubProcess_1" ) . embeddedSubProcess ( ) . startEvent ( ) . intermediateCatchEvent ( "Sub... | org . junit . Assert . assertEquals ( 2 , uncorrelatedExecutions . size ( ) ) |
restoreState ( ) { java . util . Map < java . lang . String , java . lang . String > data = new java . util . HashMap ( ) ; data . put ( "pages" , "100" ) ; org . testfx . util . WaitForAsyncUtils . waitForAsyncFx ( 2000 , ( ) -> victim . restoreStateFrom ( data ) ) ; org . pdfsam . ui . commons . ValidableTextField fi... | org . junit . Assert . assertEquals ( "100" , field . getText ( ) ) |
shouldRejectNullAddress ( ) { vip . setAddress ( null ) ; org . openstack . atlas . api . validation . results . ValidatorResult result = cTest . validate ( vip , org . openstack . atlas . api . mgmt . validation . validators . POST ) ; "<AssertPlaceHolder>" ; } resultMessage ( org . openstack . atlas . api . validatio... | org . junit . Assert . assertFalse ( resultMessage ( result , org . openstack . atlas . api . mgmt . validation . validators . POST ) , result . passedValidation ( ) ) |
testFrontendUrlWithMultipleUrlIpport ( ) { java . util . Map < java . net . URI , java . net . URI > ipports = new java . util . HashMap ( ) ; ipports . put ( com . vsct . supervision . notification . model . AlarmMapperTest . DEFAULT_GRAPHITE_URL , com . vsct . supervision . notification . model . AlarmMapperTest . DE... | org . junit . Assert . assertEquals ( com . vsct . supervision . notification . model . AlarmMapperTest . OTHER_GRAPHITE_IPPORT , backendAlarm . getGraphiteBaseUrl ( ) ) |
testAdd ( ) { ru . lessons . lesson_4 . Calculator calculator = new ru . lessons . lesson_4 . Calculator ( ) ; calculator . add ( 1 , 1 ) ; "<AssertPlaceHolder>" ; } getResult ( ) { return this . result ; } | org . junit . Assert . assertEquals ( 2 , calculator . getResult ( ) ) |
testCuboidCounts5 ( ) { org . apache . kylin . cube . model . CubeDesc cube = getStreamingCubeDesc ( ) ; org . apache . kylin . cube . cuboid . CuboidScheduler cuboidScheduler = cube . getInitialCuboidScheduler ( ) ; int [ ] counts = org . apache . kylin . cube . cuboid . CuboidCLI . calculateAllLevelCount ( cube ) ; p... | org . junit . Assert . assertEquals ( cuboidScheduler . getCuboidCount ( ) , sum ) |
testCanConnectToTargetWithLoop2 ( ) { try { org . talend . core . model . components . IComponent component = org . talend . core . ui . component . ComponentsFactoryProvider . getInstance ( ) . get ( "tJava" , ComponentCategory . CATEGORY_4_DI . getName ( ) ) ; org . talend . designer . core . ui . editor . nodes . No... | org . junit . Assert . assertTrue ( ( ! canConnect ) ) |
testToStringFromString ( ) { java . lang . Object result = com . orientechnologies . orient . core . metadata . schema . OType . convert ( "foo" , java . lang . String . class ) ; "<AssertPlaceHolder>" ; } convert ( java . lang . Object , java . lang . Class ) { if ( iValue == null ) return null ; if ( iTargetClass == ... | org . junit . Assert . assertEquals ( result , "foo" ) |
isDefaultSequenceFlow_shouldReturnFalse_WhenSequenceFlowourceRefIsInclusiveGateway_andDefaultIsSet ( ) { final org . omg . spec . bpmn . model . TProcess process = ModelFactory . eINSTANCE . createTProcess ( ) ; process . setId ( "processId" ) ; final java . util . List < org . omg . spec . bpmn . model . TProcess > pr... | org . junit . Assert . assertTrue ( bpmnToProc . isSequenceFlowDefault ( sequenceFlow , sequenceFlowId ) ) |
autorisatieOngeldigPartijRolDatumEindeInVerleden ( ) { toegangLeveringsAutorisatie . getGeautoriseerde ( ) . setDatumEinde ( nl . bzk . algemeenbrp . util . common . DatumUtil . gisteren ( ) ) ; final boolean isGeldig = service . isAutorisatieGeldig ( toegangLeveringsAutorisatie , dienst ) ; "<AssertPlaceHolder>" ; } i... | org . junit . Assert . assertFalse ( isGeldig ) |
testGetRegionDiskStoreNameWhenUnspecified ( ) { final com . gemstone . gemfire . cache . Region mockRegion = mockContext . mock ( com . gemstone . gemfire . cache . Region . class , "Region" ) ; final com . gemstone . gemfire . cache . RegionAttributes mockRegionAttributes = mockContext . mock ( com . gemstone . gemfir... | org . junit . Assert . assertEquals ( DiskStoreDetails . DEFAULT_DISK_STORE_NAME , function . getDiskStoreName ( mockRegion ) ) |
testCreateMissingTrigger ( ) { org . mockito . Mockito . when ( dao . find ( org . sakaiproject . component . app . scheduler . ScheduledInvocationTest . COMPONENT_ID , org . sakaiproject . component . app . scheduler . ScheduledInvocationTest . CONTEXT ) ) . thenReturn ( java . util . Collections . singleton ( "uuid" ... | org . junit . Assert . assertNotNull ( uuid ) |
testSerde ( ) { boolean print = true ; org . nd4j . linalg . factory . Nd4j . getRandom ( ) . setSeed ( 12345 ) ; org . deeplearning4j . eval . Evaluation evaluation = new org . deeplearning4j . eval . Evaluation ( ) ; org . deeplearning4j . eval . EvaluationBinary evaluationBinary = new org . deeplearning4j . eval . E... | org . junit . Assert . assertEquals ( e . toJson ( ) , fromJson . toJson ( ) ) |
testGetPersoonElementen ( ) { nl . bzk . brp . bijhouding . bericht . model . FamilierechtelijkeBetrekkingElement familierechtelijkeBetrekkingElement = maakFamilierechtelijkeBetrekkingElement ( 20160101 , 19900101 , null , null , false , false , null , "12345" , SoortPersoon . INGESCHREVENE , null , new java . lang . I... | org . junit . Assert . assertEquals ( 3 , familierechtelijkeBetrekkingElement . getPersoonElementen ( ) . size ( ) ) |
testFormulaWithString ( ) { org . apache . poi . ss . formula . ptg . Ptg [ ] ptgs = org . apache . poi . hssf . model . TestFormulaParser . parseFormula ( "\"hello\"<sp>&<sp>\"world\"<sp>" ) ; "<AssertPlaceHolder>" ; } parseFormula ( java . lang . String ) { return org . apache . poi . hssf . model . TestFormulaParser... | org . junit . Assert . assertEquals ( 3 , ptgs . length ) |
dataPointsArrayFieldMayContainNullValue ( ) { java . util . List < org . junit . experimental . theories . PotentialAssignment > valueSources = allMemberValuesFor ( org . junit . tests . experimental . theories . internal . AllMembersSupplierTest . HasDataPointsFieldWithNullValue . class , java . lang . Object . class ... | org . junit . Assert . assertThat ( valueSources . size ( ) , org . hamcrest . CoreMatchers . is ( 2 ) ) |
shouldSetPort ( ) { restMockService . setPort ( 1234 ) ; "<AssertPlaceHolder>" ; } getPort ( ) { return port ; } | org . junit . Assert . assertThat ( restMockService . getPort ( ) , org . hamcrest . core . Is . is ( 1234 ) ) |
ShouldGetArrayForNull ( ) { org . atomhopper . jdbc . query . PostgreSQLTextArray array = new org . atomhopper . jdbc . query . PostgreSQLTextArray ( null ) ; "<AssertPlaceHolder>" ; } getArray ( ) { return ( stringArray ) == null ? null : java . util . Arrays . copyOf ( stringArray , stringArray . length ) ; } | org . junit . Assert . assertNull ( array . getArray ( ) ) |
testDecimalMin ( ) { boolean expResult = true ; javax . xml . xpath . XPathExpression expr = xpath . compile ( "//xs:element[@name='decimalMinField']//xs:minInclusive/@value<sp>=<sp>6" ) ; boolean result = ( ( java . lang . Boolean ) ( expr . evaluate ( schemaDocument , XPathConstants . BOOLEAN ) ) ) ; "<AssertPlaceHol... | org . junit . Assert . assertEquals ( expResult , result ) |
testGetDDLRecordAsJSONObject ( ) { com . liferay . dynamic . data . mapping . model . DDMForm ddmForm = com . liferay . dynamic . data . mapping . test . util . DDMFormTestUtil . createDDMForm ( "TextField1" ) ; com . liferay . dynamic . data . mapping . storage . DDMFormValues ddmFormValues = com . liferay . dynamic .... | org . junit . Assert . assertEquals ( StringPool . BLANK , jsonObject . getString ( "TextField1" ) ) |
firstCustomerScheduleIsAlwaysTheClosestMatchingDayOfWeekAndDoesNotTakeIntoAccountMonthlyMeetingFrequency ( ) { applicableCalendarEvents = new org . mifos . domain . builders . CalendarEventBuilder ( ) . build ( ) ; org . joda . time . DateTime tue19thOfApril = new org . joda . time . DateTime ( ) . withDate ( 2011 , 4 ... | org . junit . Assert . assertThat ( firstCenterDate , org . hamcrest . CoreMatchers . is ( mon18thOfMay ) ) |
testEmptyMap ( ) { org . zeromq . ZFrame frame = new org . zeromq . ZFrame ( new byte [ 1 ] ) ; org . zeromq . proto . ZNeedle needle = new org . zeromq . proto . ZNeedle ( frame ) ; needle . putMap ( java . util . Collections . emptyMap ( ) ) ; needle = new org . zeromq . proto . ZNeedle ( frame ) ; "<AssertPlaceHolde... | org . junit . Assert . assertThat ( needle . getMap ( ) , org . hamcrest . CoreMatchers . is ( java . util . Collections . emptyMap ( ) ) ) |
shouldNotLoadNullValues ( ) { org . jsr107 . tck . integration . NullValueCacheLoader < java . lang . String , java . lang . String > cacheLoader = new org . jsr107 . tck . integration . NullValueCacheLoader ( ) ; cacheLoaderServer . setCacheLoader ( cacheLoader ) ; java . util . HashSet < java . lang . String > keys =... | org . junit . Assert . assertThat ( map . size ( ) , org . hamcrest . CoreMatchers . is ( 0 ) ) |
shouldTranslateViewIndexesToOriginal ( ) { int [ ] shape = new int [ ] { 4 , 2 , 3 } ; double [ ] values = new double [ ] { 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 } ; int [ ] [ ] indices = new int [ ] [ ] { new int [ ] { 0 , 0 , 2 } , new int [ ] { 0 , 1 , 1 } , new int [ ] { 1 , 0 , 0 } , new int [ ] { 1 , 0 , 1 } , new in... | org . junit . Assert . assertArrayEquals ( exceptedIdx , originalIdx ) |
testFindMatchingClass ( ) { org . kuali . rice . core . api . criteria . QueryResults findMatchingResult = mock ( org . kuali . rice . core . api . criteria . QueryResults . class ) ; org . kuali . rice . core . api . criteria . QueryByCriteria query = QueryByCriteria . Builder . create ( ) . build ( ) ; when ( mockPro... | org . junit . Assert . assertSame ( findMatchingResult , service . findMatching ( java . lang . Object . class , query ) ) |
testGetSecurityPlugins ( ) { System . out . println ( "getSecurityPlugins" ) ; java . util . ArrayList < com . pearson . docussandra . plugininterfaces . SecurityPlugin > result = com . pearson . docussandra . plugins . PluginHolderTest . ph . getSecurityPlugins ( ) ; "<AssertPlaceHolder>" ; } getSecurityPlugins ( ) { ... | org . junit . Assert . assertNotNull ( result ) |
shouldInitialise ( ) { uk . co . webamoeba . mockito . collections . inject . CollectionOfMocksInitialiserTest . ClassWithAnnnotations object = new uk . co . webamoeba . mockito . collections . inject . CollectionOfMocksInitialiserTest . ClassWithAnnnotations ( ) ; java . lang . reflect . Field field = getField ( objec... | org . junit . Assert . assertSame ( collection , object . collection ) |
testReloadNull ( ) { initializeExpectedAddress ( 3 ) ; expect ( compute . getOptions ( ) ) . andReturn ( mockOptions ) ; expect ( compute . getAddress ( com . google . cloud . compute . deprecated . AddressTest . REGION_ADDRESS_ID ) ) . andReturn ( null ) ; replay ( compute ) ; initializeAddress ( ) ; "<AssertPlaceHold... | org . junit . Assert . assertNull ( address . reload ( ) ) |
testLockAdministratieveHandelingTweeKeerMetDaardoorNegatiefResultaat ( ) { tryLockFromSql ( ) ; final boolean resultaat = administratieveHandelingLockRepository . vergrendelAlsNogNietIsVerwerkt ( nl . bzk . brp . levering . dataaccess . repository . lezenschrijven . AdministratieveHandelingVergrendelRepositoryIntegrati... | org . junit . Assert . assertFalse ( resultaat ) |
testAddResourceCommandsWithBuildFileParentOfSrcDirectory ( ) { com . facebook . buck . core . rules . SourcePathRuleFinder ruleFinder = new com . facebook . buck . core . rules . SourcePathRuleFinder ( new com . facebook . buck . core . rules . resolver . impl . TestActionGraphBuilder ( ) ) ; com . facebook . buck . co... | org . junit . Assert . assertEquals ( expected , step . buildSteps ( ) ) |
testIsModifiedOnNewFile_shouldReturnTrue ( ) { writeToCache ( "/test_file.txt" ) ; commitToMaster ( ) ; initGitFileSystem ( ) ; write ( gfs . getPath ( "/test_file.txt" ) , someBytes ( ) ) ; com . beijunyi . parallelgit . filesystem . io . GitFileAttributes attributes = readGitAttributes ( "/test_file.txt" ) ; "<Assert... | org . junit . Assert . assertTrue ( attributes . isModified ( ) ) |
nodeTypeIndexDisabling_typeNotExist ( ) { org . apache . jackrabbit . oak . plugins . index . IndexUtils . createIndexDefinition ( rootBuilder . child ( org . apache . jackrabbit . oak . plugins . index . IndexConstants . INDEX_DEFINITIONS_NAME ) , "fooIndex" , true , false , com . google . common . collect . Immutable... | org . junit . Assert . assertTrue ( disabledIndexes . isEmpty ( ) ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.