input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
testVerschillendeDatums5 ( ) { java . util . List < nl . bzk . brp . model . validatie . Melding > meldingen = brby0527 . executeer ( null , maakPersoonMetPlaats ( maakGemeente ( ( ( short ) ( 24 ) ) , "gemeente" , 19920101 , 200020101 ) ) , maakActie ( "id.actie1" , 19920101 , 200020101 ) ) ; "<AssertPlaceHolder>" ; }... | org . junit . Assert . assertEquals ( 0 , meldingen . size ( ) ) |
readProjectAllAsRoleAdmin ( ) { for ( org . apache . kylin . metadata . project . ProjectInstance project : org . apache . ranger . authorization . kylin . authorizer . RangerKylinAuthorizerTest . uuid2Projects . values ( ) ) { boolean result = aclEvaluate . hasProjectReadPermission ( project ) ; "<AssertPlaceHolder>" ... | org . junit . Assert . assertTrue ( result ) |
menuShouldHaveItems ( ) { final java . util . List < lcmc . common . ui . utils . UpdatableItem > items = blockDevMenu . getPulldownMenu ( blockDevInfoStub ) ; verify ( menuItemStub , times ( 6 ) ) . predicate ( ( ( lcmc . common . domain . Predicate ) ( anyObject ( ) ) ) ) ; verify ( menuItemStub , times ( 19 ) ) . vi... | org . junit . Assert . assertEquals ( 20 , items . size ( ) ) |
testLoadSaveFalse ( ) { final org . pentaho . reporting . engine . classic . extensions . datasources . kettle . KettleDataFactory kettleDataFactory = new org . pentaho . reporting . engine . classic . extensions . datasources . kettle . KettleDataFactory ( ) ; org . pentaho . reporting . engine . classic . extensions ... | org . junit . Assert . assertFalse ( test . isStopOnError ( ) ) |
testFixAbsoluteFilePath ( ) { java . lang . String actualObj = m . fixFilePath ( "/projects/topic_17576/iur-service-client/target/classes" ) ; "<AssertPlaceHolder>" ; } fixFilePath ( java . lang . String ) { return fixFilePath ( new java . io . File ( path ) ) ; } | org . junit . Assert . assertEquals ( "/projects/topic_17576/iur-service-client/target/classes" , actualObj ) |
basicCase ( ) { org . eclipse . collections . impl . block . function . CaseFunction < java . lang . Integer , java . lang . Integer > function = new org . eclipse . collections . impl . block . function . CaseFunction ( ) ; function . addCase ( ( ignored ) -> true , org . eclipse . collections . impl . block . factory... | org . junit . Assert . assertEquals ( fortyTwo , function . valueOf ( fortyTwo ) ) |
testHandleContentAdapter ( ) { org . eclipse . emf . ecore . EPackage root = createExample ( ) ; org . eclipse . emf . ecore . util . EContentAdapter eContentAdapter = new org . eclipse . emf . ecore . util . EContentAdapter ( ) ; root . eAdapters ( ) . add ( eContentAdapter ) ; org . eclipse . xtext . parser . antlr .... | org . junit . Assert . assertEquals ( 0 , root . eAdapters ( ) . size ( ) ) |
givenArrayOfPrimitiveType_whenCopiedViaSystemsArrayCopy_thenSuccessful ( ) { int [ ] array = new int [ ] { 23 , 43 , 55 } ; int [ ] copiedArray = new int [ 3 ] ; java . lang . System . arraycopy ( array , 0 , copiedArray , 0 , 3 ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertArrayEquals ( copiedArray , array ) |
testConvertToDatumLong ( ) { long expected = 123456789L ; org . talend . daikon . avro . converter . AvroConverter < java . lang . Object , java . lang . Object > converter = org . talend . codegen . converter . IdentityConverter . getInstance ( ) ; long actual = ( ( java . lang . Long ) ( converter . convertToDatum ( ... | org . junit . Assert . assertEquals ( expected , actual ) |
testResolveParentRelativeVolumePathWithNoParent ( ) { java . lang . String relativePath = io . fabric8 . maven . docker . util . PathTestUtil . join ( io . fabric8 . maven . docker . util . VolumeBindingUtilTest . SEP , ( ( io . fabric8 . maven . docker . util . PathTestUtil . DOT ) + ( io . fabric8 . maven . docker . ... | org . junit . Assert . assertEquals ( expectedBindingString , relativizedVolumeString ) |
testExtract_invalidXml_returnsEmptyMap ( ) { java . util . Map < java . lang . String , java . lang . String > ret = xmlFieldExtractor . extract ( new java . io . ByteArrayInputStream ( "this<sp>is<sp>not<sp>XML" . getBytes ( com . google . api . ads . common . lib . utils . UTF_8 ) ) , new java . lang . String [ ] { "... | org . junit . Assert . assertEquals ( 0 , ret . size ( ) ) |
testCreateComplexJobTriggerDayOfMonthRecurrences ( ) { "<AssertPlaceHolder>" ; } createComplexJobTriggerDayOfMonthRecurrences ( ) { return new org . pentaho . platform . plugin . services . importexport . exportManifest . bindings . ComplexJobTrigger . DayOfMonthRecurrences ( ) ; } | org . junit . Assert . assertNotNull ( factory . createComplexJobTriggerDayOfMonthRecurrences ( ) ) |
testValidateTable_pk_with_one_column ( ) { final com . restlet . sqlimport . report . Report report = new com . restlet . sqlimport . report . Report ( ) ; final com . restlet . sqlimport . validation . DatabaseValidator databaseValidator = new com . restlet . sqlimport . validation . DatabaseValidator ( report ) ; fin... | org . junit . Assert . assertTrue ( report . getReportLines ( ) . isEmpty ( ) ) |
testTransformAnyParameters ( ) { org . hawkular . apm . api . model . config . instrumentation . jvm . JVM ir = new org . hawkular . apm . api . model . config . instrumentation . jvm . JVM ( ) ; org . hawkular . apm . api . model . config . instrumentation . jvm . FreeFormAction im = new org . hawkular . apm . api . m... | org . junit . Assert . assertEquals ( expected , transformed ) |
testChooseOneTransportFirst ( org . apache . servicecomb . core . Transport , org . apache . servicecomb . core . Transport ) { new mockit . Expectations ( ) { { t1 . getOrder ( ) ; result = 1 ; t1 . canInit ( ) ; result = true ; t2 . getOrder ( ) ; result = 2 ; } } ; org . apache . servicecomb . core . transport . Tra... | org . junit . Assert . assertEquals ( t1 , manager . chooseOneTransport ( group ) ) |
shouldSeeCmisTypesAsJcrTypes ( ) { javax . jcr . nodetype . NodeTypeManager manager = getSession ( ) . getWorkspace ( ) . getNodeTypeManager ( ) ; javax . jcr . nodetype . NodeTypeIterator it = manager . getNodeType ( "nt:file" ) . getDeclaredSubtypes ( ) ; while ( it . hasNext ( ) ) { javax . jcr . nodetype . NodeType... | org . junit . Assert . assertTrue ( ( nodeType != null ) ) |
testUpdateMediaInfoTop250 ( ) { com . moviejukebox . plugin . FilmwebPluginTest . LOG . info ( "testUpdateMediaInfoTop250" ) ; com . moviejukebox . model . Movie movie = new com . moviejukebox . model . Movie ( ) ; movie . setId ( FilmwebPlugin . FILMWEB_PLUGIN_ID , "http://www.filmweb.pl/Ojciec.Chrzestny" ) ; filmwebP... | org . junit . Assert . assertEquals ( 3 , movie . getTop250 ( ) ) |
testListGetStringColumn ( ) { org . jdesktop . swingx . decorator . ComponentAdapterTest . JXListT list = new org . jdesktop . swingx . decorator . ComponentAdapterTest . JXListT ( org . jdesktop . test . AncientSwingTeam . createNamedColorListModel ( ) ) ; list . setCellRenderer ( new org . jdesktop . swingx . rendere... | org . junit . Assert . assertEquals ( text , adapter . getString ( 0 ) ) |
getAllPatientIdentifierTypes_shouldNotReturnNullExcludingRetired ( ) { "<AssertPlaceHolder>" ; } getAllPatientIdentifierTypes ( boolean ) { org . hibernate . Criteria criteria = sessionFactory . getCurrentSession ( ) . createCriteria ( org . openmrs . PatientIdentifierType . class ) ; if ( ! includeRetired ) { criteria... | org . junit . Assert . assertNotNull ( dao . getAllPatientIdentifierTypes ( false ) ) |
whenCrossParameterValidationWithInvalidParameters_thenCorrectNumberOfVoilations ( ) { org . baeldung . javaxval . methodvalidation . model . ReservationManagement object = new org . baeldung . javaxval . methodvalidation . model . ReservationManagement ( ) ; java . lang . reflect . Method method = org . baeldung . java... | org . junit . Assert . assertEquals ( 1 , violations . size ( ) ) |
testFewBytesToLong ( ) { java . nio . ByteBuffer bb = java . nio . ByteBuffer . wrap ( new byte [ ] { 0 , 0 , 0 , 0 , 0 , 0 , 0 , 1 , 0 , 0 } ) ; long l = bb . getLong ( ) ; "<AssertPlaceHolder>" ; } getLong ( ) { if ( ( ( data . limit ( ) ) - ( data . position ( ) ) ) == 8 ) return data . duplicate ( ) . getLong ( ) ;... | org . junit . Assert . assertEquals ( 1 , l ) |
testReferentialConstraintNull ( ) { org . apache . olingo . odata2 . api . edm . provider . Association association = new org . apache . olingo . odata2 . api . edm . provider . Association ( ) . setName ( "association" ) ; org . apache . olingo . odata2 . api . edm . EdmAssociation edmAssociation = new org . apache . ... | org . junit . Assert . assertNull ( edmAssociation . getReferentialConstraint ( ) ) |
testMinWidthPassesMinWidthToCondition ( ) { com . eclipsesource . tabris . passepartout . Condition condition = com . eclipsesource . tabris . passepartout . PassePartout . minWidth ( com . eclipsesource . tabris . passepartout . PassePartout . px ( 100 ) ) ; boolean complies = condition . compliesWith ( new com . ecli... | org . junit . Assert . assertTrue ( complies ) |
userImplShouldCaptureRolesFromConstructor ( ) { org . jboss . errai . security . shared . api . identity . User user = new org . jboss . errai . security . shared . api . identity . UserImpl ( "test" , java . util . Arrays . asList ( new org . jboss . errai . security . shared . api . RoleImpl ( "a" ) , new org . jboss... | org . junit . Assert . assertTrue ( user . getRoles ( ) . contains ( new org . jboss . errai . security . shared . api . RoleImpl ( "a" ) ) ) |
shouldMineCountDecreaseByOne_whenMineIsDestroyed ( ) { placeMineUpFromSapper ( ) ; int minesCount = board . getMinesCount ( ) ; board . useMineDetectorToGivenDirection ( Direction . UP ) ; int minesCountWhenMineDestroyed = board . getMinesCount ( ) ; "<AssertPlaceHolder>" ; } getMinesCount ( ) { return getMines ( ) . s... | org . junit . Assert . assertEquals ( minesCount , ( minesCountWhenMineDestroyed + 1 ) ) |
testMalformedDateHeaderIsIgnored ( ) { final org . apache . hc . core5 . http . Header [ ] headers = new org . apache . hc . core5 . http . Header [ ] { new org . apache . hc . core5 . http . message . BasicHeader ( "Date" , "asdf" ) } ; entry = new org . apache . hc . client5 . http . cache . HttpCacheEntry ( new java... | org . junit . Assert . assertNull ( entry . getDate ( ) ) |
testGivenMTLBuyWithOneLOSellWhenQuantityOfMTLOrderIsBigger ( ) { vn . com . vndirect . exchangesimulator . model . NewOrderSingle order = vn . com . vndirect . exchangesimulator . matching . OrderFactory . createLOSell ( "VND" , 1000 , 13000 ) ; sm . push ( order ) ; vn . com . vndirect . exchangesimulator . model . Ne... | org . junit . Assert . assertEquals ( 3 , reports . size ( ) ) |
testParseZeroX ( ) { java . lang . String source = ( ( ( ( ( "{0" + ( getDecimalCharacter ( ) ) ) + "0;<sp>-1" ) + ( getDecimalCharacter ( ) ) ) + "4343;<sp>1" ) + ( getDecimalCharacter ( ) ) ) + "6333}" ; org . hipparchus . linear . ArrayRealVector expected = new org . hipparchus . linear . ArrayRealVector ( new doubl... | org . junit . Assert . assertEquals ( expected , actual ) |
testIsRegionOverflowToDiskWhenEvictionActionIsOverflowToDisk ( ) { 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 ... | org . junit . Assert . assertTrue ( function . isOverflowToDisk ( mockRegion ) ) |
testCurrent ( ) { tec . units . ri . spi . DimensionalModel model = tec . units . ri . spi . DimensionalModel . current ( ) ; "<AssertPlaceHolder>" ; } current ( ) { return tec . units . ri . spi . DimensionalModel . currentModel ; } | org . junit . Assert . assertNotNull ( model ) |
distributePorts_GivenNoPortsOnRightSide_NothingHappens ( ) { org . eclipse . elk . alg . layered . graph . LNode [ ] leftNodes = addNodesToLayer ( 2 , makeLayer ( getGraph ( ) ) ) ; org . eclipse . elk . alg . layered . graph . LNode middleNode = addNodeToLayer ( makeLayer ( getGraph ( ) ) ) ; addNodesToLayer ( 2 , mak... | org . junit . Assert . assertThat ( middleNode . getPorts ( ) , org . hamcrest . CoreMatchers . is ( expectedPortOrderRightNode ) ) |
shouldReturnFalseWhenChildDiseaseReportedIsNotMalaria ( ) { boolean didRuleSucceed = rule . apply ( new org . ei . drishti . util . SafeMap ( mapOf ( "reportChildDisease" , "diarrhea_dehydration" ) ) ) ; "<AssertPlaceHolder>" ; } mapOf ( Key , Value ) { java . util . HashMap < Key , Value > normalMap = new java . util ... | org . junit . Assert . assertFalse ( didRuleSucceed ) |
toJSON_axisWithStops_StopsCorrectlySerialized ( ) { com . vaadin . addon . charts . model . YAxis yaxis = new com . vaadin . addon . charts . model . YAxis ( ) ; com . vaadin . addon . charts . model . Stop stop1 = new com . vaadin . addon . charts . model . Stop ( 0.1F , com . vaadin . addon . charts . model . style .... | org . junit . Assert . assertEquals ( expected , toJSON ( yaxis ) ) |
testStudyGraphPresentationModel ( ) { org . drugis . addis . presentation . TreatmentDefinitionsGraphModel model = d_wizard . getRawAlternativesGraph ( ) ; d_wizard . getIndicationModel ( ) . setValue ( org . drugis . addis . ExampleData . buildIndicationDepression ( ) ) ; d_wizard . getOutcomeMeasureModel ( ) . setVal... | org . junit . Assert . assertEquals ( drugs , model . getDefinitions ( ) ) |
simpleLookupForMissingKeyUsingDefaultValue ( ) { org . constretto . ConstrettoConfiguration constrettoConfiguration = prepareTests ( ) ; java . lang . Integer value = constrettoConfiguration . evaluateTo ( "missing.key" , Integer . MIN_VALUE ) ; "<AssertPlaceHolder>" ; } evaluateTo ( java . lang . Class , java . lang .... | org . junit . Assert . assertEquals ( new java . lang . Integer ( Integer . MIN_VALUE ) , value ) |
listTest ( ) { org . easycassandra . bean . model . Person person = getPerson ( ) ; person . setId ( 1L ) ; dao . insert ( person ) ; "<AssertPlaceHolder>" ; } listAll ( ) { return persistence . findAll ( baseClass ) ; } | org . junit . Assert . assertTrue ( ( ( dao . listAll ( ) . size ( ) ) > 0 ) ) |
signAndVerify2 ( ) { java . lang . String str = "wx2421b1c4370ec43b<sp><sp>JSAPI<sp>10000100<sp>1add1a30ac87aa2db72f57a2375d8fec<sp>http://wxpay.wxutil.com/pub_v2/pay/notify.v2.php<sp>oUpF8uMuAJO_M2pxb1Q9zNjWeS6o<sp>1415659990<sp>14.23.150.211<sp>1<sp>JSAPI<sp>0CB01533B8C1EF103065174F50BCA001" ; byte [ ] data = cn . hu... | org . junit . Assert . assertTrue ( verify ) |
testValueValid ( ) { java . util . Set < javax . validation . ConstraintViolation < org . kie . workbench . common . stunner . cm . definition . property . diagram . Version > > violations = this . validator . validate ( tested ) ; "<AssertPlaceHolder>" ; } isEmpty ( ) { return violations . isEmpty ( ) ; } | org . junit . Assert . assertTrue ( violations . isEmpty ( ) ) |
testGetSQLShareHistory ( ) { classUnderTest . setSQLShareHistory ( true ) ; "<AssertPlaceHolder>" ; } getSQLShareHistory ( ) { return _sqlShareHistory ; } | org . junit . Assert . assertEquals ( true , classUnderTest . getSQLShareHistory ( ) ) |
testGetAllOperationsFor_withEmtpyMessage ( ) { java . lang . String json = "{<sp>\"head\"<sp>:<sp>{},<sp>\"operations\"<sp>:<sp>[]<sp>}" ; org . eclipse . rap . rwt . internal . protocol . ClientMessage message = new org . eclipse . rap . rwt . internal . protocol . ClientMessage ( org . eclipse . rap . json . JsonObje... | org . junit . Assert . assertTrue ( operations . isEmpty ( ) ) |
readWriteSquareAndTriangle ( ) { java . lang . String inputString = de . javagl . obj . TestObjWriter . readResourceAsString ( "/squareAndTriangle.obj" ) ; de . javagl . obj . Obj obj = de . javagl . obj . ObjReader . read ( new java . io . ByteArrayInputStream ( inputString . getBytes ( ) ) ) ; java . io . ByteArrayOu... | org . junit . Assert . assertEquals ( inputString , outputString ) |
testIsSerializable ( ) { java . lang . String item = "foo" ; combo . add ( item ) ; org . eclipse . swt . widgets . Combo deserializedCombo = serializeAndDeserialize ( combo ) ; "<AssertPlaceHolder>" ; } getItem ( int ) { checkWidget ( ) ; if ( ! ( hasChildren ) ) { throw new java . lang . IllegalArgumentException ( "G... | org . junit . Assert . assertEquals ( item , deserializedCombo . getItem ( 0 ) ) |
testToConnectSupportsOptionalValues ( ) { com . blueapron . connect . protobuf . ProtobufData protobufData = new com . blueapron . connect . protobuf . ProtobufData ( com . blueapron . connect . protobuf . NestedTestProtoOuterClass . NestedTestProto . class , LEGACY_NAME ) ; org . apache . kafka . connect . data . Sche... | org . junit . Assert . assertNull ( protobufData . toConnectData ( schema , null ) ) |
testIntronic ( ) { java . lang . String [ ] legacyVariantStrings = new java . lang . String [ ] { "XXX:IVS3+3del" , "XXX:IVS3-3delT" , "XXX:IVS3-3delTCT" , "XXX:IVS3-3del3" } ; for ( java . lang . String legacyVariantString : legacyVariantStrings ) { de . charite . compbio . jannovar . hgvs . legacy . LegacyVariant var... | org . junit . Assert . assertEquals ( legacyVariantString , variant . toLegacyString ( ) ) |
testDataSources_1 ( ) { java . util . Collection < java . lang . String > names = org . teiid . runtime . TestEmbeddedServerAdmin . admin . getDataSourceNames ( ) ; "<AssertPlaceHolder>" ; } size ( ) { return size ; } | org . junit . Assert . assertEquals ( 0 , names . size ( ) ) |
testMethod ( ) { final boolean [ ] result = new boolean [ ] { false } ; result [ 0 ] = new edu . rice . pcdp . await . TestAwait1c ( ) . run ( ) ; "<AssertPlaceHolder>" ; } run ( ) { edu . rice . pcdp . PCDP . finish ( ( ) -> { final int acc0 = 1 ; async ( ( ) -> { int acc1 = 2 ; async ( ( ) -> { int acc2 = 3 ; async (... | org . junit . Assert . assertEquals ( true , result [ 0 ] ) |
constructorSucceedOn5Levels ( ) { final java . util . Map < java . lang . String , java . lang . Object > rawMap = new java . util . HashMap < java . lang . String , java . lang . Object > ( ) { { put ( tests . unit . com . microsoft . azure . sdk . iot . deps . twin . TwinCollectionTest . VALID_KEY_NAME , tests . unit... | org . junit . Assert . assertNotNull ( twinCollection ) |
testGetConsumer ( ) { com . t1t . apim . rest . KongConsumer cons = createTestConsumer ( ) ; com . t1t . apim . rest . KongConsumer regCons = com . t1t . apim . rest . KongClientIntegrationTest . kongClient . createConsumer ( cons ) ; "<AssertPlaceHolder>" ; com . t1t . apim . rest . KongClientIntegrationTest . kongCli... | org . junit . Assert . assertNotNull ( regCons ) |
rejectKeysValues ( ) { com . gs . collections . api . multimap . ImmutableMultimap < java . lang . String , java . lang . String > multimap = this . < java . lang . String , java . lang . String > classUnderTest ( ) . newWith ( "One" , "1" ) . newWith ( "Two" , "2" ) ; com . gs . collections . api . multimap . Immutabl... | org . junit . Assert . assertEquals ( this . classUnderTest ( ) . newWith ( "One" , "1" ) , rejectedMultimap ) |
testGetFactType ( ) { final org . drools . workbench . screens . guided . dtable . client . wizard . column . plugins . commons . PatternWrapper pattern = mock ( org . drools . workbench . screens . guided . dtable . client . wizard . column . plugins . commons . PatternWrapper . class ) ; final java . lang . String ex... | org . junit . Assert . assertEquals ( expectedFactType , factType ) |
testDefault ( ) { "<AssertPlaceHolder>" ; } favoritesCollection ( ) { return ch . cyberduck . core . FolderBookmarkCollection . FAVORITES_COLLECTION ; } | org . junit . Assert . assertNotNull ( ch . cyberduck . core . FolderBookmarkCollection . favoritesCollection ( ) ) |
testGetMaskAll ( ) { long inMask = 127 ; org . sagebionetworks . repo . model . table . QueryOptions options = new org . sagebionetworks . repo . model . table . QueryOptions ( ) . withMask ( inMask ) ; long mask = options . getPartMask ( ) ; "<AssertPlaceHolder>" ; } getPartMask ( ) { long partMask = 0 ; if ( this . r... | org . junit . Assert . assertEquals ( inMask , mask ) |
testBug1864222 ( ) { org . jfree . data . time . TimeSeries s = new org . jfree . data . time . TimeSeries ( "S" ) ; s . add ( new org . jfree . data . time . Day ( 19 , 8 , 2005 ) , 1 ) ; s . add ( new org . jfree . data . time . Day ( 31 , 1 , 2006 ) , 1 ) ; boolean pass = true ; try { s . createCopy ( new org . jfre... | org . junit . Assert . assertTrue ( pass ) |
testGetMessage ( ) { java . lang . String url = "http://localhost/wiki/index.php" ; net . sourceforge . jwbf . core . actions . GetPage testee = new net . sourceforge . jwbf . core . actions . GetPage ( url ) ; net . sourceforge . jwbf . core . actions . util . HttpAction expected = net . sourceforge . jwbf . core . ac... | org . junit . Assert . assertEquals ( expected , testee . getNextMessage ( ) ) |
reusesIdWhenHeaderPresent ( ) { java . lang . String headerId = java . util . UUID . randomUUID ( ) . toString ( ) ; when ( request . getHeader ( configuration . getHeaderName ( ) ) ) . thenReturn ( headerId ) ; requestTrackerServletFilter . doFilter ( request , response , chain ) ; java . lang . String idInLog = org .... | org . junit . Assert . assertThat ( idInLog , org . hamcrest . CoreMatchers . equalTo ( headerId ) ) |
discardComponentUnknown ( ) { try { deleteAt ( aResourceURI ( "<exception>" ) , org . silverpeas . admin . web . PersonalComponentEntity . class ) ; org . junit . Assert . fail ( "A<sp>user<sp>shouldn't<sp>discard<sp>an<sp>unknown<sp>component" ) ; } catch ( final com . sun . jersey . api . client . UniformInterfaceExc... | org . junit . Assert . assertThat ( receivedStatus , org . hamcrest . Matchers . is ( unauthorized ) ) |
testConcat_1 ( ) { lombok . val row1 = org . nd4j . linalg . factory . Nd4j . create ( new double [ ] { 1 , 1 , 1 , 1 } , new long [ ] { 1 , 4 } ) ; lombok . val row2 = org . nd4j . linalg . factory . Nd4j . create ( new double [ ] { 2 , 2 , 2 , 2 } , new long [ ] { 1 , 4 } ) ; lombok . val row3 = org . nd4j . linalg .... | org . junit . Assert . assertEquals ( exp , z ) |
mustIdentifyAsPrefix ( ) { com . offbynull . actors . address . Address parent = com . offbynull . actors . address . Address . of ( "one" , "two" ) ; com . offbynull . actors . address . Address fixture = com . offbynull . actors . address . Address . of ( "one" , "two" , "three" ) ; "<AssertPlaceHolder>" ; } isPrefix... | org . junit . Assert . assertTrue ( parent . isPrefixOf ( fixture ) ) |
createBodyShouldReturnTheShortMessageIfTheCommandIsAMessageRequest ( ) { org . jsmpp . bean . DeliverSm command = new org . jsmpp . bean . DeliverSm ( ) ; command . setShortMessage ( "Hello<sp>SMPP<sp>world!" . getBytes ( ) ) ; message = new org . apache . camel . component . smpp . SmppMessage ( camelContext , command... | org . junit . Assert . assertEquals ( "Hello<sp>SMPP<sp>world!" , message . createBody ( ) ) |
testDeleteChangedProperty ( ) { theirRoot . getTree ( "/" ) . setProperty ( "a" , org . apache . jackrabbit . oak . plugins . commit . DefaultThreeWayConflictHandlerOursTest . THEIR_VALUE ) ; ourRoot . getTree ( "/" ) . removeProperty ( "a" ) ; theirRoot . commit ( ) ; ourRoot . commit ( ) ; org . apache . jackrabbit .... | org . junit . Assert . assertNull ( p ) |
testFeatureType2Creation ( ) { reload ( false ) ; final org . opengis . feature . FeatureType refType = org . geotoolkit . db . postgres . PostgresComplexTypeTest . FTYPE_COMPLEX2 ; store . createFeatureType ( refType ) ; "<AssertPlaceHolder>" ; final org . opengis . util . GenericName name = store . getNames ( ) . ite... | org . junit . Assert . assertEquals ( 1 , store . getNames ( ) . size ( ) ) |
oneEmail ( ) { ru . otus . l42 . LotteryMachine machine = new ru . otus . l42 . LotteryMachine ( 2 ) ; java . util . List < java . lang . String > result = machine . draw ( java . util . Collections . singletonList ( "test" ) ) ; "<AssertPlaceHolder>" ; } size ( ) { throw new java . lang . UnsupportedOperationException... | org . junit . Assert . assertEquals ( 1 , result . size ( ) ) |
testAutoAssignForEmptyResult ( ) { java . util . Map < java . lang . String , java . util . List < java . lang . String > > hostGroups = singletonMap ( "group1" , asList ( "host1" ) ) ; org . springframework . test . util . ReflectionTestUtils . setField ( clusterCommands , "hostGroups" , hostGroups ) ; when ( context ... | org . junit . Assert . assertEquals ( hostGroups , result ) |
testTemplate ( ) { org . kefirsf . bb . conf . Code code = new org . kefirsf . bb . conf . Code ( ) ; org . kefirsf . bb . conf . Template template = createTemplate ( ) ; code . setTemplate ( template ) ; "<AssertPlaceHolder>" ; } getTemplate ( ) { return template ; } | org . junit . Assert . assertEquals ( template , code . getTemplate ( ) ) |
testRenewerParam ( ) { final org . apache . hadoop . hdfs . web . resources . RenewerParam p = new org . apache . hadoop . hdfs . web . resources . RenewerParam ( RenewerParam . DEFAULT ) ; "<AssertPlaceHolder>" ; } getValue ( ) { return sb . toString ( ) ; } | org . junit . Assert . assertEquals ( null , p . getValue ( ) ) |
testIsCacheServerUsingDiskStoreWhenUsingDefaultDiskStore ( ) { final com . gemstone . gemfire . cache . server . CacheServer mockCacheServer = mockContext . mock ( com . gemstone . gemfire . cache . server . CacheServer . class , "CacheServer" ) ; final com . gemstone . gemfire . cache . server . ClientSubscriptionConf... | org . junit . Assert . assertTrue ( function . isUsingDiskStore ( mockCacheServer , mockDiskStore ) ) |
removeTopicByIdAddedToGroupTest ( ) { org . kaaproject . kaa . common . dto . TopicDto topic = generateTopicDto ( null , null ) ; org . kaaproject . kaa . common . dto . EndpointGroupDto groupDto = generateEndpointGroupDto ( topic . getApplicationId ( ) ) ; endpointService . addTopicToEndpointGroup ( groupDto . getId (... | org . junit . Assert . assertNull ( found ) |
testConvertEmpty ( ) { java . lang . Double result = underTest . convert ( "" ) ; "<AssertPlaceHolder>" ; } convert ( java . lang . String ) { if ( "S" . equalsIgnoreCase ( value ) ) { return Size . TINY ; } else if ( "M" . equalsIgnoreCase ( value ) ) { return Size . NORMAL ; } else if ( "L" . equalsIgnoreCase ( value... | org . junit . Assert . assertNull ( result ) |
objectShouldNotBeEqualsWhenObjectIsOtherClass ( ) { org . eclipse . che . ide . ext . java . jdi . client . debug . DebuggerView testObject = mock ( org . eclipse . che . ide . ext . java . jdi . client . debug . DebuggerView . class ) ; boolean isEquals = debuggerVariable . equals ( testObject ) ; "<AssertPlaceHolder>... | org . junit . Assert . assertThat ( isEquals , org . hamcrest . CoreMatchers . is ( false ) ) |
testReductionGlobal ( ) { org . datavec . local . transforms . transform . List < org . datavec . local . transforms . transform . List < org . datavec . api . writable . Writable > > in = org . datavec . local . transforms . transform . Arrays . asList ( org . datavec . local . transforms . transform . Arrays . < org ... | org . junit . Assert . assertEquals ( expOut , out ) |
testSerialization ( ) { org . apache . commons . math4 . geometry . Space s1 = org . apache . commons . math4 . geometry . spherical . oned . Sphere1D . getInstance ( ) ; org . apache . commons . math4 . geometry . Space deserialized = ( ( org . apache . commons . math4 . geometry . Space ) ( org . apache . commons . m... | org . junit . Assert . assertTrue ( ( s1 == deserialized ) ) |
testGetAllGlobal ( ) { config . putGlobal ( "section1.int" , 1 ) ; config . putGlobal ( "section1.subsection.string" , "2" ) ; config . putGlobal ( "section1.subsection.subsub.int" , 1 ) ; config . putGlobal ( "section2.int" , 3 ) ; config . putGlobal ( "section2.subsection.string" , "4" ) ; java . util . Map < java . ... | org . junit . Assert . assertEquals ( expected , all ) |
testCreateNull ( ) { com . j256 . ormlite . dao . Dao < com . j256 . ormlite . dao . Foo , java . lang . Integer > dao = createDao ( com . j256 . ormlite . dao . Foo . class , true ) ; "<AssertPlaceHolder>" ; } create ( T ) { checkForInitialized ( ) ; if ( data == null ) { return 0 ; } if ( data instanceof com . j256 .... | org . junit . Assert . assertEquals ( 0 , dao . create ( ( ( com . j256 . ormlite . dao . Foo ) ( null ) ) ) ) |
determinesFacingRight ( ) { com . fundynamic . d2tm . math . Vector2D coordinatesToFaceTo = unitAbsoluteMapCoordinates . add ( create ( 1 , 0 ) ) ; "<AssertPlaceHolder>" ; } determine ( com . fundynamic . d2tm . math . Vector2D , com . fundynamic . d2tm . math . Vector2D ) { boolean left = ( to . getXAsInt ( ) ) < ( fr... | org . junit . Assert . assertEquals ( com . fundynamic . d2tm . game . entities . units . RIGHT , determine ( unitAbsoluteMapCoordinates , coordinatesToFaceTo ) ) |
testTransient ( ) { java . lang . reflect . Field field = getClass ( ) . getDeclaredField ( "trnsient" ) ; org . seasar . extension . jdbc . PropertyMeta propertyMeta = propertyMetaFactory . createPropertyMeta ( field , new org . seasar . extension . jdbc . EntityMeta ( ) ) ; org . seasar . extension . jdbc . gen . des... | org . junit . Assert . assertNull ( columnDesc ) |
addFailureDelegatesToNotifier ( ) { org . junit . runner . Result result = new org . junit . runner . Result ( ) ; org . junit . runner . notification . RunListener listener = result . createListener ( ) ; org . junit . runner . notification . RunNotifier notifier = new org . junit . runner . notification . RunNotifier... | org . junit . Assert . assertEquals ( 1 , result . getFailureCount ( ) ) |
testDockerLoginNoConfig ( ) { executeWithTempHomeDir ( new io . fabric8 . maven . docker . util . AuthConfigFactoryTest . HomeDirExecutor ( ) { @ io . fabric8 . maven . docker . util . Override public void exec ( java . io . File dir ) throws java . io . IOException , org . apache . maven . plugin . MojoExecutionExcept... | org . junit . Assert . assertNull ( config ) |
testHandleAliveResponseNoNeedDiscovery ( ) { org . openkilda . wfm . topology . floodlightrouter . service . FloodlightTracker floodlightTracker = new org . openkilda . wfm . topology . floodlightrouter . service . FloodlightTracker ( floodlights , org . openkilda . wfm . topology . floodlightrouter . service . Floodli... | org . junit . Assert . assertFalse ( floodlightTracker . handleAliveResponse ( org . openkilda . wfm . topology . floodlightrouter . service . FloodlightTrackerTest . REGION_ONE , responseTime ) ) |
testInstanceDefinitionForUnknownValue ( ) { "<AssertPlaceHolder>" ; } instanceDefinitionFor ( com . cronutils . model . CronType ) { switch ( cronType ) { case CRON4J : return com . cronutils . model . definition . CronDefinitionBuilder . cron4j ( ) ; case QUARTZ : return com . cronutils . model . definition . CronDefi... | org . junit . Assert . assertNotNull ( com . cronutils . model . definition . CronDefinitionBuilder . instanceDefinitionFor ( null ) ) |
testToArray ( ) { final int cap = 100 ; final java . util . concurrent . BlockingQueue < java . lang . Integer > dbq = new com . conversantmedia . util . concurrent . PushPullBlockingQueue < java . lang . Integer > ( cap ) ; for ( int i = 0 ; i < cap ; i ++ ) { dbq . offer ( java . lang . Integer . valueOf ( i ) ) ; } ... | org . junit . Assert . assertEquals ( objArray [ i ] , java . lang . Integer . valueOf ( i ) ) |
testTreeSet ( ) { org . simpleflatmapper . util . TypeReference < java . util . TreeSet < java . lang . String > > typeReference = new org . simpleflatmapper . util . TypeReference < java . util . TreeSet < java . lang . String > > ( ) { } ; "<AssertPlaceHolder>" ; } testSet ( org . simpleflatmapper . util . TypeRefere... | org . junit . Assert . assertTrue ( ( ( testSet ( typeReference ) ) instanceof java . util . TreeSet ) ) |
testCacheGroupingSuggestionsAllRejected ( ) { org . mockito . Mockito . doNothing ( ) . when ( groupingSuggestionsCacheManager ) . putGroupingSuggestions ( org . mockito . Mockito . eq ( "orcid" ) , suggestionListCaptor . capture ( ) ) ; org . mockito . Mockito . when ( groupingSuggestionDao . findGroupingSuggestionIdA... | org . junit . Assert . assertTrue ( retrieved . isEmpty ( ) ) |
testWriteOneByte ( ) { bsos . write ( 1 ) ; org . jerlang . type . BitString expected = new org . jerlang . type . BitString ( new byte [ ] { 1 } ) ; "<AssertPlaceHolder>" ; } toBitString ( ) { if ( ( bitOffset ) == 0 ) { return new org . jerlang . type . Binary ( bytes . toByteArray ( ) ) ; } else { bytes . write ( cu... | org . junit . Assert . assertEquals ( expected , bsos . toBitString ( ) ) |
testSimpleCondition ( ) { io . cdap . cdap . etl . common . PipelinePhase phase4 = io . cdap . cdap . etl . common . PipelinePhase . builder ( pluginTypes ) . addStage ( io . cdap . cdap . etl . proto . v2 . spec . StageSpec . builder ( "condition.connector" , io . cdap . cdap . etl . planner . PipelinePlannerTest . co... | org . junit . Assert . assertEquals ( expected , actual ) |
testEquality ( ) { javax . measure . Quantity < javax . measure . quantity . Length > value = tec . units . ri . quantity . Quantities . getQuantity ( new java . lang . Double ( 10 ) , Units . METRE ) ; javax . measure . Quantity < javax . measure . quantity . Length > anotherValue = tec . units . ri . quantity . Quant... | org . junit . Assert . assertEquals ( value , anotherValue ) |
testStaticNat ( ) { long vlanId = 123 ; java . util . List < com . cloud . agent . api . to . StaticNatRuleTO > rules = new java . util . ArrayList < com . cloud . agent . api . to . StaticNatRuleTO > ( ) ; com . cloud . agent . api . to . StaticNatRuleTO active = new com . cloud . agent . api . to . StaticNatRuleTO ( ... | org . junit . Assert . assertTrue ( answer . getResult ( ) ) |
testGetConnectionFromRepository ( ) { org . talend . core . model . metadata . builder . connection . DatabaseConnection conn = ( ( org . talend . core . model . metadata . builder . connection . DatabaseConnection ) ( org . talend . core . model . metadata . MetadataToolHelper . getConnectionFromRepository ( org . tal... | org . junit . Assert . assertEquals ( conn . getId ( ) , org . talend . core . model . metadata . MetadataToolHelperTest . connection . getId ( ) ) |
testGetEntriesCountInSameCompany ( ) { addEntry ( 0 , 0 ) ; int entriesCount = com . liferay . announcements . kernel . service . AnnouncementsEntryLocalServiceUtil . getEntriesCount ( _user . getCompanyId ( ) , 0 , 0 , false ) ; "<AssertPlaceHolder>" ; } getCompanyId ( ) { return _companyId ; } | org . junit . Assert . assertEquals ( 1 , entriesCount ) |
test_isValidForSqlQuery_String_null_andNullable ( ) { ch . puzzle . itc . mobiliar . business . deploy . entity . CustomFilter c = ch . puzzle . itc . mobiliar . business . deploy . entity . CustomFilter . builder ( stringType ) . filterDisplayName ( "filter<sp>DisplayName" ) . deploymentTableColumnName ( "deploymentTa... | org . junit . Assert . assertTrue ( c . isValidForSqlQuery ( ) ) |
isNotebookPublicTest ( ) { org . apache . zeppelin . conf . ZeppelinConfiguration conf = new org . apache . zeppelin . conf . ZeppelinConfiguration ( this . getClass ( ) . getResource ( "/zeppelin-site.xml" ) ) ; boolean isIt = conf . isNotebookPublic ( ) ; "<AssertPlaceHolder>" ; } isNotebookPublic ( ) { return getBoo... | org . junit . Assert . assertTrue ( isIt ) |
testStripLeadingAndTailingQuotesNull ( ) { java . lang . String result = org . sagebionetworks . table . query . model . DerivedColumn . stripLeadingAndTailingQuotes ( null ) ; "<AssertPlaceHolder>" ; } stripLeadingAndTailingQuotes ( java . lang . String ) { if ( input == null ) { return null ; } java . lang . StringBu... | org . junit . Assert . assertEquals ( null , result ) |
testGetSecurityFunction ( ) { when ( securityFunctionDaoHelper . getSecurityFunctionEntity ( org . finra . herd . service . impl . SECURITY_FUNCTION ) ) . thenReturn ( org . finra . herd . service . impl . SecurityFunctionServiceImplTest . SECURITY_FUNCTION_ENTITY ) ; when ( alternateKeyHelper . validateStringParameter... | org . junit . Assert . assertEquals ( org . finra . herd . service . impl . SECURITY_FUNCTION , securityFunction . getSecurityFunctionName ( ) ) |
testGetName1 ( ) { org . dresdenocl . pivotmodel . PrimitiveType type ; java . lang . String msg ; msg = "The<sp>adaptation<sp>of<sp>PrimitiveType.getName()<sp>seems<sp>to<sp>be<sp>wrong." ; for ( java . lang . String aTypesName : org . dresdenocl . metamodels . test . tests . TestPrimitiveType . allPrimitiveTypes . ke... | org . junit . Assert . assertNotNull ( msg , type . getName ( ) ) |
testConvertToDatumBytes ( ) { byte [ ] expected = new byte [ ] { 0 , 1 , 2 , 3 } ; org . talend . daikon . avro . converter . AvroConverter < java . lang . Object , java . lang . Object > converter = org . talend . codegen . converter . IdentityConverter . getInstance ( ) ; byte [ ] actual = ( ( byte [ ] ) ( converter ... | org . junit . Assert . assertEquals ( expected , actual ) |
testEncryptionWithIvWithTagLengthWithAdditionAuthenticatedData ( ) { de . rub . nds . tlsattacker . core . crypto . cipher . NullCipher cipher = new de . rub . nds . tlsattacker . core . crypto . cipher . NullCipher ( ) ; byte [ ] bEncrypted = cipher . encrypt ( bIV , iTag , bAuth , bMessage ) ; "<AssertPlaceHolder>" ;... | org . junit . Assert . assertArrayEquals ( bMessage , bEncrypted ) |
testTarPrefixWithoutTrailingSlash ( ) { commitBazAndFooSlashBar ( ) ; byte [ ] result = org . eclipse . jgit . pgm . CLIGitCommand . executeRaw ( "git<sp>archive<sp>--prefix=my-<sp>--format=tar<sp>master" , db ) . outBytes ( ) ; java . lang . String [ ] expect = new java . lang . String [ ] { "my-baz" , "my-foo/" , "my... | org . junit . Assert . assertArrayEquals ( expect , actual ) |
testDataStore ( ) { final org . geotoolkit . data . FeatureStore store = getDataStore ( ) ; "<AssertPlaceHolder>" ; } getDataStore ( ) { return store ; } | org . junit . Assert . assertNotNull ( store ) |
shouldGetItselfWhenSelectCastable ( ) { cn . jimmyshi . beanquery . selectors . BeanSelector < java . util . Set > setBeanSelector = new cn . jimmyshi . beanquery . selectors . BeanSelector < java . util . Set > ( java . util . Set . class ) ; java . util . Set item = new java . util . HashSet ( ) ; java . util . Set r... | org . junit . Assert . assertSame ( item , result ) |
testRun2 ( ) { final int [ ] counter = new int [ ] { 2 } ; org . opencastproject . util . ReflectionUtil . run ( new org . opencastproject . util . ReflectionUtilTest . Bla ( ) { @ org . opencastproject . util . Override public java . lang . String getId ( ) { ( counter [ 0 ] ) -- ; return null ; } @ org . opencastproj... | org . junit . Assert . assertEquals ( 1 , counter [ 0 ] ) |
constructFromUriAndBack ( ) { java . net . URI uri = java . net . URI . create ( "http://apache.org/foo/bar?foo=bar&a=b&c=d&y=z&foo=zoo#foo" ) ; org . jasig . cas . client . util . URIBuilder builder = new org . jasig . cas . client . util . URIBuilder ( uri ) ; "<AssertPlaceHolder>" ; } build ( ) { try { return new ja... | org . junit . Assert . assertEquals ( uri , builder . build ( ) ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.