input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
testIsClusterPreviewCommandAvailableForNoAssignments ( ) { when ( context . isFocusOnClusterBuild ( ) ) . thenReturn ( true ) ; org . springframework . test . util . ReflectionTestUtils . setField ( clusterCommands , "hostGroups" , singletonMap ( "group1" , emptyList ( ) ) ) ; boolean result = clusterCommands . isClust... | org . junit . Assert . assertFalse ( result ) |
testSimpleFlag ( ) { org . evosuite . Properties . TARGET_CLASS = com . examples . with . different . packagename . FlagExample1 . class . getCanonicalName ( ) ; java . lang . Class < ? > originalClass = org . evosuite . instrumentation . testability . TestTestabilityTransformation . defaultClassloader . loadClass ( co... | org . junit . Assert . assertEquals ( originalResult , instrumentedResult ) |
checkBatchMode_when_onCascadeSet ( ) { io . ebean . TxScope scope = new io . ebean . TxScope ( ) ; scope . setBatchSize ( 100 ) ; scope . setBatchOnCascade ( PersistBatch . ALL ) ; scope . checkBatchMode ( ) ; "<AssertPlaceHolder>" ; } getBatch ( ) { return batch ; } | org . junit . Assert . assertNull ( scope . getBatch ( ) ) |
testSuperclassDoesntSaveOverSubclass ( ) { com . github . droidfu . cachefu . ModelCache modelCache = new com . github . droidfu . cachefu . ModelCache ( 2 , 1 , 1 ) ; java . lang . String id = "123" ; com . github . droidfu . cachefu . SuperclassCachedObjectTest . SubclassTestObject subclassTestObject = new com . gith... | org . junit . Assert . assertEquals ( "this<sp>is<sp>a<sp>test" , subclassTestObject . getTestString ( ) ) |
returnsDefaultValueWhenListOfPathSegmentsIsEmpty ( ) { when ( parameter . getDefaultValue ( ) ) . thenReturn ( "default<sp>value" ) ; when ( typeProducer . createValue ( eq ( "foo" ) , emptyMultivaluedMap ( ) , eq ( "default<sp>value" ) ) ) . thenReturn ( "default<sp>value" ) ; when ( applicationContext . getUriInfo ( ... | org . junit . Assert . assertEquals ( "default<sp>value" , resolvedMatrixParameter ) |
Memcached ( ) { java . lang . String cellName = "cellCacheTestCell" ; java . util . Map < java . lang . String , java . lang . Object > cell = new java . util . HashMap < java . lang . String , java . lang . Object > ( ) ; java . lang . reflect . Constructor < com . fujitsu . dc . core . utils . MemcachedClient > c = c... | org . junit . Assert . assertEquals ( cell , cache ) |
testReportDelay ( ) { final com . net2plan . interfaces . networkDesign . IReport report = new com . net2plan . examples . ocnbook . reports . Report_delay ( ) ; java . util . Map < java . lang . String , java . util . List < java . lang . String > > testingParameters = new java . util . HashMap ( ) ; java . util . Lis... | org . junit . Assert . assertTrue ( ( ( result . length ( ) ) > 100 ) ) |
testGetNumberFormat ( ) { "<AssertPlaceHolder>" ; } getNumberFormat ( ) { return numberFormat ; } | org . junit . Assert . assertNotNull ( context . getNumberFormat ( ) ) |
testKieSession ( ) { org . kie . api . runtime . KieSession ksession = ( ( org . kie . api . runtime . KieSession ) ( org . kie . spring . tests . KieSpringExpressionTest . context . getBean ( "ksession2" ) ) ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertNotNull ( ksession ) |
testUserDetails ( ) { final com . codeabovelab . dm . common . security . ExtendedUserDetailsImpl . Builder b = new com . codeabovelab . dm . common . security . ExtendedUserDetailsImpl . Builder ( ) ; b . setUsername ( "one" ) ; b . setPassword ( "secret" ) ; b . setTitle ( "test<sp>user" ) ; b . setEmail ( "e@e.e" ) ... | org . junit . Assert . assertEquals ( expected , actual ) |
testBuildWithComplicated ( ) { java . lang . String query = "SELECT<sp>FROM<sp>SMTH<sp>%s" ; java . lang . String condition = "condition<sp>" ; java . lang . Object parameter = new java . lang . Object ( ) ; java . lang . String condition1 = "condition1<sp>" ; java . lang . Object nullParameter = null ; java . lang . S... | org . junit . Assert . assertEquals ( expected , actual ) |
testReproducibleIds ( ) { java . lang . String id1 = idGenerator . createId ( "x" ) ; java . lang . String id2 = new org . eclipse . swt . internal . widgets . IdGenerator ( ) . createId ( "x" ) ; "<AssertPlaceHolder>" ; } createId ( java . lang . Object ) { if ( object instanceof org . eclipse . swt . widgets . Displa... | org . junit . Assert . assertEquals ( id1 , id2 ) |
testSeekHeadSize ( ) { org . jcodec . containers . mkv . SeekHeadFactory a = new org . jcodec . containers . mkv . SeekHeadFactory ( ) ; a . add ( org . jcodec . containers . mkv . SeekHeadFactoryTest . createFakeElement ( Info . id , ( ( 255 - 4 ) - 2 ) ) ) ; a . add ( org . jcodec . containers . mkv . SeekHeadFactory... | org . junit . Assert . assertEquals ( a . estimateSize ( ) , computeSize ) |
testGetEdmReferentialConstraintRole ( ) { try { com . sap . core . odata . processor . core . jpa . model . JPAEdmReferentialConstraintRoleTest . objJPAEdmReferentialConstraintRole . getBuilder ( ) . build ( ) ; } catch ( com . sap . core . odata . processor . api . jpa . exception . ODataJPAModelException e ) { org . ... | org . junit . Assert . assertNotNull ( com . sap . core . odata . processor . core . jpa . model . JPAEdmReferentialConstraintRoleTest . objJPAEdmReferentialConstraintRole . getEdmReferentialConstraintRole ( ) ) |
testBuildModelView ( ) { org . eurekastreams . server . search . modelview . PersonModelView modelView = new org . eurekastreams . server . search . factories . PersonModelViewFactory ( ) . buildModelView ( ) ; "<AssertPlaceHolder>" ; } buildModelView ( ) { return new org . eurekastreams . commons . hibernate . ModelVi... | org . junit . Assert . assertNotNull ( modelView ) |
shouldReadEmptyJsonResponse ( ) { final com . fasterxml . jackson . databind . ObjectMapper mapper = new com . fasterxml . jackson . databind . ObjectMapper ( ) ; final org . apache . http . message . BasicHttpResponse httpResponse = buildResponse ( ) ; httpResponse . setEntity ( new org . apache . http . entity . Stri... | org . junit . Assert . assertNull ( value ) |
testSendRecordsCorruptTimestamp ( ) { final java . lang . Long timestamp = - 3L ; createWorkerTask ( ) ; java . util . List < org . apache . kafka . connect . source . SourceRecord > records = java . util . Collections . singletonList ( new org . apache . kafka . connect . source . SourceRecord ( org . apache . kafka .... | org . junit . Assert . assertEquals ( null , sent . getValue ( ) . timestamp ( ) ) |
edgeCasesCase004 ( ) { processedUsages = usageRollupProcessor . processRecords ( allUsageRecordsInOrder , hourToRollup , lbsActiveDuringHour ) ; "<AssertPlaceHolder>" ; org . openstack . atlas . service . domain . entities . Usage actualUsage = processedUsages . get ( 0 ) ; org . openstack . atlas . usagerefactor . jun... | org . junit . Assert . assertEquals ( 2 , processedUsages . size ( ) ) |
bepalingVoorVolledigBericht ( ) { final nl . bzk . brp . service . maakbericht . algemeen . MaakBerichtParameters maakBerichtParameters = new nl . bzk . brp . service . maakbericht . algemeen . MaakBerichtParameters ( ) ; final nl . bzk . brp . service . maakbericht . algemeen . Berichtgegevens berichtgegevens = new nl... | org . junit . Assert . assertTrue ( berichtgegevens . isLeegBericht ( ) ) |
testGlobStatusFilterWithEmptyPathResults ( ) { org . apache . hadoop . fs . Path [ ] testDirs = new org . apache . hadoop . fs . Path [ ] { getTestRootPath ( org . apache . hadoop . fs . FileContextMainOperationsBaseTest . fc , org . apache . hadoop . fs . FileContextMainOperationsBaseTest . TEST_DIR_AAA ) , getTestRoo... | org . junit . Assert . assertEquals ( 0 , filteredPaths . length ) |
testFailTaskDataSource ( ) { context . register ( org . springframework . cloud . task . jdbchdfs . common . support . JdbcHdfsDataSourceConfiguration . class ) ; org . springframework . cloud . task . jdbchdfs . common . support . JdbcHdfsDataSourceConfiguration config = context . getBean ( org . springframework . clo... | org . junit . Assert . assertNotNull ( dataSource ) |
testGetInt ( ) { org . gradoop . common . model . impl . properties . PropertyValue p = org . gradoop . common . model . impl . properties . PropertyValue . create ( org . gradoop . common . model . impl . properties . INT_VAL_2 ) ; "<AssertPlaceHolder>" ; } getInt ( ) { return get ( java . lang . Integer . class ) ; } | org . junit . Assert . assertEquals ( org . gradoop . common . model . impl . properties . INT_VAL_2 , p . getInt ( ) ) |
coercedEitherThrowsOnAccessingMissingRight ( ) { java . lang . reflect . Type type = com . facebook . buck . rules . coercer . TypeCoercerTest . TestFields . class . getField ( "eitherStringSetOrStringToStringMap" ) . getGenericType ( ) ; com . facebook . buck . rules . coercer . TypeCoercer < ? > coercer = typeCoercer... | org . junit . Assert . assertEquals ( inputSet , either . getLeft ( ) ) |
testFloat32Array ( ) { com . eclipsesource . v8 . V8Value result = ( ( com . eclipsesource . v8 . V8Value ) ( v8 . executeScript ( "var<sp>floats<sp>=<sp>new<sp>Float32Array();<sp>floats" ) ) ) ; "<AssertPlaceHolder>" ; result . close ( ) ; } executeScript ( java . lang . String ) { return executeScript ( script , null... | org . junit . Assert . assertNotNull ( result ) |
testAddBooleanReplaceValue ( ) { v8 . add ( "foo" , true ) ; v8 . add ( "foo" , false ) ; boolean result = v8 . executeBooleanScript ( "foo" ) ; "<AssertPlaceHolder>" ; } executeBooleanScript ( java . lang . String ) { return executeBooleanScript ( script , null , 0 ) ; } | org . junit . Assert . assertFalse ( result ) |
testConditionDag ( ) { java . util . Set < io . cdap . cdap . etl . proto . Connection > connections = com . google . common . collect . ImmutableSet . of ( new io . cdap . cdap . etl . proto . Connection ( "csv" 0 , "csv" ) , new io . cdap . cdap . etl . proto . Connection ( "csv" , "c1" ) , new io . cdap . cdap . etl... | org . junit . Assert . assertEquals ( actual , expected ) |
testBasicComponentScanning ( ) { org . springframework . ide . eclipse . beans . core . internal . model . BeansConfig config = new org . springframework . ide . eclipse . beans . core . internal . model . BeansConfig ( beansProject , "basic-component-scanning.xml" , IBeansConfig . Type . MANUAL ) ; org . springframewo... | org . junit . Assert . assertEquals ( "simpleScannedBean" , bean . getElementName ( ) ) |
testSubAnd ( ) { net . sf . ntru . polynomial . IntegerPolynomial i1 = new net . sf . ntru . polynomial . IntegerPolynomial ( new int [ ] { 1368 , 2047 , 672 , 871 , 1662 , 1352 , 1099 , 1608 } ) ; net . sf . ntru . polynomial . IntegerPolynomial i2 = new net . sf . ntru . polynomial . IntegerPolynomial ( new int [ ] {... | org . junit . Assert . assertArrayEquals ( a . toIntegerPolynomial ( ) . coeffs , i1 . coeffs ) |
testRemap ( ) { org . apache . accumulo . core . data . TableId tableId = org . apache . accumulo . core . data . TableId . of ( "3" ) ; java . util . SortedMap < org . apache . accumulo . core . dataImpl . KeyExtent , org . apache . accumulo . core . clientImpl . bulk . Bulk . Files > mapping = generateMapping ( table... | org . junit . Assert . assertEquals ( newNameMapping , actual ) |
testAbstractDatalinkEdit ( ) { org . apache . taverna . workflowmodel . impl . AbstractDatalinkEdit edit = new org . apache . taverna . workflowmodel . impl . AbstractDatalinkEdit ( datalink ) { @ org . apache . taverna . workflowmodel . impl . Override protected void doEditAction ( org . apache . taverna . workflowmod... | org . junit . Assert . assertEquals ( datalink , edit . getSubject ( ) ) |
testAddsTransitionListenerReturnsUIConfiguration ( ) { com . eclipsesource . tabris . ui . UIConfiguration configuration = new com . eclipsesource . tabris . ui . UIConfiguration ( ) ; com . eclipsesource . tabris . ui . TransitionListener listener = mock ( com . eclipsesource . tabris . ui . TransitionListener . class... | org . junit . Assert . assertSame ( configuration , actualConfiguration ) |
testTruncateWhenItIsNotTruncated ( ) { final java . lang . String actualTruncate = dmnCard . truncate ( "12345" , 5 ) ; final java . lang . String expectedTruncate = "12345" ; "<AssertPlaceHolder>" ; } truncate ( java . lang . String , int ) { if ( ( value . length ( ) ) > limit ) { return "..." + ( value . substring (... | org . junit . Assert . assertEquals ( expectedTruncate , actualTruncate ) |
testCRLPathValidationWithFakeCerts ( ) { java . security . Security . addProvider ( new org . bouncycastle . jce . provider . BouncyCastleProvider ( ) ) ; org . apache . synapse . transport . utils . sslcert . Utils utils = new org . apache . synapse . transport . utils . sslcert . Utils ( ) ; java . security . cert . ... | org . junit . Assert . assertNotNull ( throwable ) |
emptyFrameAtHeadIsWritten ( ) { initState ( io . netty . handler . codec . http2 . UniformStreamByteDistributorTest . STREAM_A , 10 , true ) ; initState ( io . netty . handler . codec . http2 . UniformStreamByteDistributorTest . STREAM_B , 0 , true ) ; initState ( io . netty . handler . codec . http2 . UniformStreamByt... | org . junit . Assert . assertTrue ( write ( 10 ) ) |
testRegexSerialization ( ) { io . symcpe . wraith . conditions . Condition regexCondition = new io . symcpe . wraith . conditions . relational . JavaRegexCondition ( "host" , ".*check_rtsock_rc.*" ) ; io . symcpe . wraith . rules . SimpleRule rule = new io . symcpe . wraith . rules . SimpleRule ( ( ( short ) ( 1 ) ) , ... | org . junit . Assert . assertTrue ( rule . getCondition ( ) . matches ( event ) ) |
extractIndexerName ( ) { org . searchisko . api . rest . IndexerRestService tested = getTested ( ) ; java . util . Map < java . lang . String , java . lang . Object > ic = new java . util . HashMap ( ) ; try { tested . extractIndexerName ( ic , "type" ) ; org . junit . Assert . fail ( "ObjectNotFoundException<sp>expect... | org . junit . Assert . assertEquals ( "myName" , tested . extractIndexerName ( ic , "type" ) ) |
testToFullyQualifiedPathClass ( ) { final java . lang . String expected = "org/apache/commons/lang3/Test.properties" ; final java . lang . String actual = org . apache . commons . lang3 . ClassPathUtils . toFullyQualifiedPath ( org . apache . commons . lang3 . ClassPathUtils . class , "Test.properties" ) ; "<AssertPlac... | org . junit . Assert . assertEquals ( expected , actual ) |
testGetOutputStreamWithDirs ( ) { try { out = locationManager . getOutputStream ( "test.properties" , "test" ) ; "<AssertPlaceHolder>" ; } catch ( org . hisp . dhis . external . location . LocationManagerException ex ) { org . hisp . dhis . external . location . LocationManagerTest . log . debug ( "External<sp>director... | org . junit . Assert . assertNotNull ( out ) |
singleletters ( ) { java . util . LinkedList < lv . semti . morphology . Testi . Word > tokens ; tokens = lv . semti . morphology . Testi . Splitting . tokenize ( lv . semti . morphology . Testi . TokenizeTest . loctjs , "bv<sp>q<sp>i" , false ) ; "<AssertPlaceHolder>" ; } size ( ) { return attributes . entrySet ( ) . ... | org . junit . Assert . assertEquals ( 3 , tokens . size ( ) ) |
testBuildWithPaametersWithOrderBy ( ) { java . lang . String abbrName = "AN" ; java . lang . String name = "fdsfds" ; org . lnu . is . domain . employee . status . EmployeeStatus context = new org . lnu . is . domain . employee . status . EmployeeStatus ( ) ; context . setAbbrName ( abbrName ) ; context . setName ( nam... | org . junit . Assert . assertEquals ( expectedQuery , actualQuery ) |
testValidateSubscriptionWithExternalPriceMdel_nullSubscription ( ) { org . oscm . internal . vo . VOSubscriptionDetails subscription = null ; org . oscm . internal . vo . VOSubscriptionDetails result = bean . validateSubscription ( subscription ) ; "<AssertPlaceHolder>" ; } validateSubscription ( org . oscm . internal ... | org . junit . Assert . assertTrue ( ( result == null ) ) |
forThreadLocalRandom ( ) { net . moznion . random . string . RandomStringGenerator generator = new net . moznion . random . string . RandomStringGenerator ( java . util . concurrent . ThreadLocalRandom . current ( ) ) ; java . lang . String randomString = generator . generateByRegex ( "\\w+\\d*\\W\\D{0,3}a\\{0,3}.\\s\\... | org . junit . Assert . assertTrue ( patternToProve . matcher ( randomString ) . find ( ) ) |
testModifyAddSameSpecificArea ( ) { org . apache . directory . api . ldap . model . entry . Entry caArea = new org . apache . directory . api . ldap . model . entry . DefaultEntry ( "ou=caArea,<sp>ou=system" , "ObjectClass:<sp>top" , "ObjectClass:<sp>organizationalUnit" , "ou:<sp>caArea" , "administrativeRole:<sp>colle... | org . junit . Assert . assertTrue ( true ) |
testVar ( ) { org . nd4j . linalg . api . ndarray . INDArray data = org . nd4j . linalg . factory . Nd4j . create ( new double [ ] { 4.0 , 4.0 , 4.0 , 4.0 , 8.0 , 8.0 , 8.0 , 8.0 , 4.0 , 4.0 , 4.0 , 4.0 , 8.0 , 8.0 , 8.0 , 8.0 , 4.0 , 4.0 , 4.0 , 4.0 , 8.0 , 8.0 , 8.0 , 8.0 , 4.0 , 4.0 , 4.0 , 4.0 , 8.0 , 8.0 , 8.0 , 8... | org . junit . Assert . assertEquals ( getFailureMessage ( ) , expectedResult , actualResult ) |
testSetGetMetadataAggregatorName ( ) { final java . lang . String aggregatorName = "Willi" ; org . esa . beam . binning . operator . BinningConfigTest . config . setMetadataAggregatorName ( aggregatorName ) ; "<AssertPlaceHolder>" ; } getMetadataAggregatorName ( ) { return metadataAggregatorName ; } | org . junit . Assert . assertEquals ( aggregatorName , org . esa . beam . binning . operator . BinningConfigTest . config . getMetadataAggregatorName ( ) ) |
exludedByArrayTest ( ) { java . lang . Object instanceOne = org . jsonschema2pojo . integration . ExcludedFromEqualsAndHashCodeIT . clazz . newInstance ( ) ; java . lang . Object instanceTwo = org . jsonschema2pojo . integration . ExcludedFromEqualsAndHashCodeIT . clazz . newInstance ( ) ; org . jsonschema2pojo . integ... | org . junit . Assert . assertThat ( instanceOne . equals ( instanceTwo ) , org . hamcrest . core . Is . is ( true ) ) |
whenAddUserDuplicateWithNameThatTheyDontAdd ( ) { ru . szhernovoy . model . User vasja = new ru . szhernovoy . model . User ( "Vasja" , 25 ) ; ru . szhernovoy . model . User kolja = new ru . szhernovoy . model . User ( "Vasja" , 27 ) ; ru . szhernovoy . control . Validate [ ] valid = new ru . szhernovoy . control . Val... | org . junit . Assert . assertThat ( control , org . hamcrest . core . Is . is ( result ) ) |
testGetSecurityManager ( ) { org . apache . shiro . mgt . SecurityManager securityManager = createMock ( org . apache . shiro . mgt . SecurityManager . class ) ; org . apache . shiro . guice . GuiceEnvironment underTest = new org . apache . shiro . guice . GuiceEnvironment ( securityManager ) ; "<AssertPlaceHolder>" ; ... | org . junit . Assert . assertSame ( securityManager , underTest . getSecurityManager ( ) ) |
getPrivateProxyIPa ( ) { java . lang . String proxyIP = "10.254.28.1" ; java . lang . String resultProxyIP = org . ebayopensource . turmeric . runtime . spf . impl . transport . http . HTTPServerUtils . getFirstPublicProxyIP ( proxyIP ) ; "<AssertPlaceHolder>" ; } getFirstPublicProxyIP ( java . lang . String ) { if ( (... | org . junit . Assert . assertEquals ( "" , resultProxyIP ) |
testGetRuntimeMXBean ( ) { java . lang . management . RuntimeMXBean runtimeMxBean = java . lang . management . ManagementFactory . getRuntimeMXBean ( ) ; "<AssertPlaceHolder>" ; System . out . println ( ( "runtimeMxBean<sp>=<sp>" + runtimeMxBean ) ) ; System . out . println ( ( "runtimeMxBean.getName()<sp>=<sp>" + ( ru... | org . junit . Assert . assertNotNull ( runtimeMxBean ) |
updateUser ( ) { com . xkcoding . orm . beetlsql . entity . User user = userService . getUser ( 2L ) ; user . setName ( "beetlSql<sp>" ) ; com . xkcoding . orm . beetlsql . entity . User update = userService . updateUser ( user ) ; "<AssertPlaceHolder>" ; log . debug ( "update=<sp>{}" , update ) ; } getName ( ) { retur... | org . junit . Assert . assertEquals ( "beetlSql<sp>" , update . getName ( ) ) |
testStartFollowedByUnit ( ) { java . lang . String outcome = opennlp . tools . namefind . BilouNameFinderSequenceValidatorTest . UNIT_A ; java . lang . String [ ] inputSequence = new java . lang . String [ ] { "TypeA" , "AnyType" , "something" } ; java . lang . String [ ] outcomesSequence = new java . lang . String [ ]... | org . junit . Assert . assertFalse ( opennlp . tools . namefind . BilouNameFinderSequenceValidatorTest . validator . validSequence ( 1 , inputSequence , outcomesSequence , outcome ) ) |
reversesTypeRingWalk ( ) { com . jnape . palatable . lambda . lens . Iso < java . util . List < java . lang . String > , java . util . Set < java . lang . Integer > , java . lang . String , java . lang . Integer > iso = com . jnape . palatable . lambda . lens . Iso . iso ( ( xs ) -> xs . get ( 0 ) , Collections :: sing... | org . junit . Assert . assertEquals ( "1" , com . jnape . palatable . lambda . lens . functions . Under . under ( iso , ( set ) -> singletonList ( set . iterator ( ) . next ( ) . toString ( ) ) , 1 ) ) |
returns_files_by_partition ( ) { java . util . Map < java . lang . Integer , java . util . List < org . apache . hadoop . fs . Path > > filesByPartition = org . apache . metron . pcap . utils . FileFilterUtil . getFilesByPartition ( filesIn ) ; java . util . Map < java . lang . Integer , java . util . List < org . apac... | org . junit . Assert . assertThat ( filesByPartition , org . hamcrest . CoreMatchers . equalTo ( expectedFilesPartitioned ) ) |
testGetLongWithStringWithDefaultWithInvalidProperty ( ) { final edu . illinois . library . cantaloupe . config . Configuration instance = getInstance ( ) ; instance . setProperty ( "test1" , "cats" ) ; "<AssertPlaceHolder>" ; } getLong ( java . lang . String , long ) { try { return getLong ( key ) ; } catch ( java . ut... | org . junit . Assert . assertEquals ( 5 , instance . getLong ( "test1" , 5 ) ) |
testCreateReader ( ) { org . talend . components . marklogic . tmarklogicinput . MarkLogicInputProperties inputProperties = new org . talend . components . marklogic . tmarklogicinput . MarkLogicInputProperties ( "inputProps" ) ; inputProperties . init ( ) ; source . initialize ( null , inputProperties ) ; org . talend... | org . junit . Assert . assertNotNull ( reader ) |
testAfterStop ( ) { client . setSleepBeforeReturn ( true ) ; try { client . putEntities ( org . apache . hadoop . yarn . client . api . impl . TestTimelineClientV2Impl . generateEntity ( "1" ) ) ; for ( int i = 2 ; i < 20 ; i ++ ) { client . putEntitiesAsync ( org . apache . hadoop . yarn . client . api . impl . TestTi... | org . junit . Assert . assertEquals ( "" , "19" , timelineEntity . getId ( ) ) |
shouldLogInDescendingOrder ( ) { com . couchbase . client . core . tracing . ThresholdLogReporterTest . TestReporter reporter = null ; try { reporter = new com . couchbase . client . core . tracing . ThresholdLogReporterTest . TestReporter ( new com . couchbase . client . core . tracing . ThresholdLogReporter . Builder... | org . junit . Assert . assertEquals ( sortedDescending , totalDurations ) |
testToString ( ) { System . out . println ( "toString" ) ; for ( org . netbeans . modules . search . matcher . BufferedCharSequenceTest . TypeOfStream stype : org . netbeans . modules . search . matcher . BufferedCharSequenceTest . TypeOfStream . values ( ) ) { java . io . InputStream stream = getInputStream ( stype , ... | org . junit . Assert . assertEquals ( expResult , result ) |
createWithException ( ) { org . syncope . client . to . PasswordPolicyTO policy = new org . syncope . client . to . PasswordPolicyTO ( true ) ; policy . setSpecification ( new org . syncope . types . PasswordPolicySpec ( ) ) ; policy . setDescription ( "global<sp>password<sp>policy" ) ; java . lang . Throwable t = null... | org . junit . Assert . assertNotNull ( t ) |
testReachableViaLdcLoad ( ) { com . spotify . missinglink . datamodel . DeclaredClass remote = com . spotify . missinglink . Simple . newClass ( "other/Unknown" ) . build ( ) ; com . spotify . missinglink . datamodel . DeclaredClass root = com . spotify . missinglink . Simple . newClass ( "my/Root" ) . loadedClasses ( ... | org . junit . Assert . assertEquals ( com . google . common . collect . ImmutableSet . of ( root . className ( ) , remote . className ( ) ) , reachable ) |
startProcess ( ) { org . activiti . engine . RepositoryService repositoryService = activitiRule . getRepositoryService ( ) ; repositoryService . createDeployment ( ) . addInputStream ( "MultiInstanceBug.bpmn20.xml" , new java . io . FileInputStream ( filename ) ) . deploy ( ) ; org . activiti . engine . RuntimeService ... | org . junit . Assert . assertNotNull ( processInstance . getId ( ) ) |
testDoesNotSendAMessageToTheMessageBusIfAlreadyEnabled ( ) { java . util . Map < java . lang . String , java . lang . String > properties = new java . util . HashMap ( ) ; properties . put ( "max-height" , "100" ) ; properties . put ( "max-width" , "100" ) ; _amImageConfigurationHelper . addAMImageConfigurationEntry ( ... | org . junit . Assert . assertEquals ( messages . toString ( ) , 0 , messages . size ( ) ) |
testFlowLogging ( ) { com . gargoylesoftware . htmlunit . html . HtmlPage page = webClient . getPage ( webUrl ) ; com . gargoylesoftware . htmlunit . html . HtmlSubmitInput enterFlow = ( ( com . gargoylesoftware . htmlunit . html . HtmlSubmitInput ) ( page . getElementById ( "enterFlow" ) ) ) ; page = enterFlow . click... | org . junit . Assert . assertTrue ( ( flowInitTime < flowDestroyTime ) ) |
testBatchSaveAsListFromArray ( ) { java . util . List < com . amazonaws . mobileconnectors . dynamodbv2 . dynamodbmapper . NumberSetAttributeClass > objs = new java . util . ArrayList < com . amazonaws . mobileconnectors . dynamodbv2 . dynamodbmapper . NumberSetAttributeClass > ( ) ; for ( int i = 0 ; i < 40 ; i ++ ) {... | org . junit . Assert . assertEquals ( obj , loaded ) |
keyRecovery ( ) { com . matthewmitchell . peercoinj . core . ECKey key = new com . matthewmitchell . peercoinj . core . ECKey ( ) ; java . lang . String message = "Hello<sp>World!" ; com . matthewmitchell . peercoinj . core . Sha256Hash hash = com . matthewmitchell . peercoinj . core . Sha256Hash . create ( message . g... | org . junit . Assert . assertTrue ( found ) |
shouldDelete ( ) { importDao . delete ( net . rrm . ehour . domain . User . class ) ; net . rrm . ehour . domain . User user = importDao . find ( 3 , net . rrm . ehour . domain . User . class ) ; "<AssertPlaceHolder>" ; } find ( java . lang . Class , java . lang . String ) { java . lang . String propertyName = path . s... | org . junit . Assert . assertNull ( user ) |
of_Period0 ( ) { org . javamoney . calc . common . FutureValueGrowingAnnuity val = org . javamoney . calc . common . FutureValueGrowingAnnuity . of ( org . javamoney . calc . common . Rate . of ( 0.07 ) , org . javamoney . calc . common . Rate . of ( 0.08 ) , 0 ) ; "<AssertPlaceHolder>" ; } of ( java . math . BigDecima... | org . junit . Assert . assertNotNull ( val ) |
getZipkinData_WhenZipkinDataHasBeenBuilt_ShouldReturnBuiltData ( ) { java . lang . String spanName = "Span<sp>Name" ; when ( zipkinDataBuilder . spanName ( spanName ) ) . thenReturn ( zipkinDataBuilder ) ; when ( zipkinDataBuilder . build ( ) ) . thenReturn ( zipkinData ) ; victim = new com . betfair . cougar . modules... | org . junit . Assert . assertEquals ( victim . getZipkinData ( ) , zipkinData ) |
testOrderByWithLimit ( ) { java . util . List < java . lang . String > expected = rawInput . subList ( 0 , java . lang . Math . min ( limit , rawInput . size ( ) ) ) ; java . util . List < java . lang . String > inputs = com . google . common . collect . Lists . newArrayList ( rawInput ) ; java . util . Collections . s... | org . junit . Assert . assertEquals ( expected , result . toList ( ) ) |
accept ( ) { java . lang . String targetFileName = java . lang . String . format ( "adsWriteFailure_%s.log.%d" , "000" , 1234567890123L ) ; "<AssertPlaceHolder>" ; } checkAcceptResult ( java . lang . String ) { java . io . File file = new java . io . File ( targetFileName ) ; file . deleteOnExit ( ) ; try { file . crea... | org . junit . Assert . assertTrue ( checkAcceptResult ( targetFileName ) ) |
shouldApplyKeyOnVertexProperty ( ) { final org . apache . tinkerpop . gremlin . structure . VertexProperty e = mock ( org . apache . tinkerpop . gremlin . structure . VertexProperty . class ) ; when ( e . key ( ) ) . thenReturn ( "keyName" ) ; "<AssertPlaceHolder>" ; } apply ( org . apache . tinkerpop . gremlin . proce... | org . junit . Assert . assertEquals ( "keyName" , T . key . apply ( e ) ) |
testBlankPropertyName ( ) { java . lang . Object result = cn . jimmyshi . beanquery . DefaultNullValuePropertyValueGetter . getProperty ( new cn . jimmyshi . beanquery . example . Book ( ) , "<sp>" ) ; "<AssertPlaceHolder>" ; } getProperty ( java . lang . Object , java . lang . String ) { if ( ( null == from ) || ( org... | org . junit . Assert . assertNull ( result ) |
entry_hashCodeForNullKeyAndValue ( ) { org . eclipse . collections . api . map . MutableMap < java . lang . Integer , java . lang . String > map = this . newMapWithKeyValue ( null , null ) ; Map . Entry < java . lang . Integer , java . lang . String > entry = org . eclipse . collections . impl . utility . Iterate . get... | org . junit . Assert . assertEquals ( 0 , entry . hashCode ( ) ) |
givenNewThreadScheduler_whenCalled_shouldExecuteTheHook ( ) { io . reactivex . plugins . RxJavaPlugins . setInitNewThreadSchedulerHandler ( ( scheduler ) -> { initHookCalled = true ; return scheduler . call ( ) ; } ) ; io . reactivex . plugins . RxJavaPlugins . setNewThreadSchedulerHandler ( ( scheduler ) -> { hookCall... | org . junit . Assert . assertTrue ( ( ( hookCalled ) && ( initHookCalled ) ) ) |
getMetaData ( ) { "<AssertPlaceHolder>" ; } getMetaData ( ) { return this . metaData ; } | org . junit . Assert . assertSame ( this . metaData , this . session . getMetaData ( ) ) |
testNoMetadataRepo ( ) { "<AssertPlaceHolder>" ; } getMetadataRepositories ( ) { return java . util . Collections . unmodifiableList ( metadataRepos ) ; } | org . junit . Assert . assertEquals ( 0 , subject . getMetadataRepositories ( ) . size ( ) ) |
testKeyedCEPOperatorNFAUpdateWithRocksDB ( ) { java . lang . String rocksDbPath = tempFolder . newFolder ( ) . getAbsolutePath ( ) ; org . apache . flink . contrib . streaming . state . RocksDBStateBackend rocksDBStateBackend = new org . apache . flink . contrib . streaming . state . RocksDBStateBackend ( new org . apa... | org . junit . Assert . assertEquals ( 1 , result . size ( ) ) |
testCompleted ( ) { System . out . println ( "completed" ) ; com . sonymobile . tools . gerrit . gerritevents . dto . events . PatchsetCreated event = com . sonyericsson . hudson . plugins . gerrit . trigger . mock . Setup . createPatchsetCreated ( ) ; com . sonyericsson . hudson . plugins . gerrit . trigger . gerritno... | org . junit . Assert . assertTrue ( instance . isAllBuildsCompleted ( event ) ) |
testSetCalendarDate ( ) { int [ ] result = calendarDate1 . getCalendarDate ( ) ; int [ ] caldate = new int [ ] { 1995 , 5 , 5 } ; ( ( org . geotoolkit . temporal . object . DefaultCalendarDate ) ( calendarDate1 ) ) . setCalendarDate ( caldate ) ; "<AssertPlaceHolder>" ; } getCalendarDate ( ) { return calendarDate ; } | org . junit . Assert . assertFalse ( calendarDate1 . getCalendarDate ( ) . equals ( result ) ) |
testPLFM_1754UpdateNull ( ) { org . sagebionetworks . repo . model . FileEntity file = new org . sagebionetworks . repo . model . FileEntity ( ) ; file . setParentId ( project . getId ( ) ) ; file . setDataFileHandleId ( fileHandle1 . getId ( ) ) ; file = entityService . createEntity ( adminUserId , file , null , mockR... | org . junit . Assert . assertNotNull ( file ) |
testGetOrientation_RTL ( ) { org . eclipse . swt . widgets . Menu menu = new org . eclipse . swt . widgets . Menu ( shell , ( ( org . eclipse . swt . SWT . POP_UP ) | ( org . eclipse . swt . SWT . RIGHT_TO_LEFT ) ) ) ; "<AssertPlaceHolder>" ; } getOrientation ( ) { if ( ( ( getCurSide ( ) ) == ( org . eclipse . swt . S... | org . junit . Assert . assertEquals ( SWT . RIGHT_TO_LEFT , menu . getOrientation ( ) ) |
whenCheckedMultiplyTwoIntegerValues_shouldMultiplyThemAndReturnTheResultIfNotOverflow ( ) { int result = com . google . common . math . IntMath . checkedMultiply ( 1 , 2 ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertEquals ( 2 , result ) |
testNonStrictJsonParsing ( ) { java . lang . String raw = "{<sp>foo:<sp>'bar'<sp>}" ; com . jayway . jsonpath . DocumentContext dc = com . intuit . karate . JsonUtils . toJsonDoc ( raw ) ; com . intuit . karate . JsonUtilsTest . logger . debug ( "parsed<sp>json:<sp>{}" , dc . jsonString ( ) ) ; java . lang . String val... | org . junit . Assert . assertEquals ( "bar" , value ) |
testConjunctionOfTwoNR ( ) { java . lang . String queryString = "FOO<sp>!~<sp>BAR<sp>&&<sp>BAR<sp>!~<sp>FOO" ; java . lang . String expectedQuery = "!(FOO<sp>=~<sp>BAR)<sp>&&<sp>!(BAR<sp>=~<sp>FOO)" ; org . apache . commons . jexl2 . parser . ASTJexlScript script = datawave . query . jexl . JexlASTHelper . parseJexlQue... | org . junit . Assert . assertEquals ( expectedQuery , negatedQuery ) |
testRefreshNodes ( ) { org . apache . hadoop . yarn . client . TestResourceManagerAdministrationProtocolPBClientImpl . resourceManager . getClientRMService ( ) ; org . apache . hadoop . yarn . server . api . protocolrecords . RefreshNodesRequest request = org . apache . hadoop . yarn . server . api . protocolrecords . ... | org . junit . Assert . assertNotNull ( response ) |
testGetC ( ) { org . openscience . cdk . interfaces . ICrystal crystal = ( ( org . openscience . cdk . interfaces . ICrystal ) ( newChemObject ( ) ) ) ; crystal . setC ( new javax . vecmath . Vector3d ( 1.0 , 2.0 , 3.0 ) ) ; javax . vecmath . Vector3d a = crystal . getC ( ) ; "<AssertPlaceHolder>" ; } getC ( ) { return... | org . junit . Assert . assertNotNull ( a ) |
testSubtract ( ) { java . util . List < java . lang . Integer > minuend = java . util . Arrays . asList ( new java . lang . Integer [ ] { 2 , 2 , 2 } ) ; java . util . List < java . lang . Integer > subtrahend = java . util . Arrays . asList ( new java . lang . Integer [ ] { 0 , 1 , 2 } ) ; java . util . List < java . ... | org . junit . Assert . assertEquals ( difference , result ) |
test_convert_withSubclassedConverterInstance ( ) { com . github . dozermapper . core . Mapper mapper = com . github . dozermapper . core . DozerBeanMapperBuilder . create ( ) . withMappingFiles ( "mappings/customConverterMapperAware.xml" ) . withCustomConverter ( new com . github . dozermapper . core . functional_tests... | org . junit . Assert . assertEquals ( "bar" , result . get ( "foo" ) ) |
testSerialization ( ) { org . jfree . chart . renderer . xy . DeviationRenderer r1 = new org . jfree . chart . renderer . xy . DeviationRenderer ( ) ; org . jfree . chart . renderer . xy . DeviationRenderer r2 = ( ( org . jfree . chart . renderer . xy . DeviationRenderer ) ( org . jfree . chart . TestUtilities . serial... | org . junit . Assert . assertEquals ( r1 , r2 ) |
testSerialization ( ) { final org . apache . logging . log4j . core . impl . JdkMapAdapterStringMap original = new org . apache . logging . log4j . core . impl . JdkMapAdapterStringMap ( ) ; original . putValue ( "a" , "avalue" ) ; original . putValue ( "B" , "Bvalue" ) ; original . putValue ( "3" , "3value" ) ; final ... | org . junit . Assert . assertEquals ( original , copy ) |
shouldNotFailWhenRemovingAndAddingLabelsInOneBatch ( ) { java . lang . String jsonString = new org . neo4j . server . rest . PrettyJSON ( ) . array ( ) . object ( ) . key ( "chef" 3 ) . value ( "POST" ) . key ( "to" ) . value ( "node" ) . key ( "chef" 1 ) . value ( 0 ) . key ( "chef" 2 ) . object ( ) . key ( "key" ) . ... | org . junit . Assert . assertEquals ( 200 , response . getStatus ( ) ) |
testManyConnectionsBlocking ( ) { pool . setMaxTotal ( 10 ) ; pool . setBlockWhenExhausted ( true ) ; java . util . concurrent . CountDownLatch counter = new java . util . concurrent . CountDownLatch ( 10000 ) ; for ( int i = 0 ; i < 100 ; i ++ ) { org . apache . directory . shared . client . api . LdapConnectionPoolTe... | org . junit . Assert . assertTrue ( result ) |
testGetTitle_1 ( ) { org . jinstagram . entity . oembed . OembedInformation fixture = new org . jinstagram . entity . oembed . OembedInformation ( ) ; fixture . setVersion ( "" ) ; fixture . setTitle ( "" ) ; fixture . setProviderUrl ( "" ) ; fixture . setUrl ( "" ) ; fixture . setAuthorName ( "" ) ; fixture . setHeigh... | org . junit . Assert . assertEquals ( "" , result ) |
testNormalizedStringColumnSizeTooBig ( ) { original . setName ( "name" ) ; original . setColumnType ( ColumnType . STRING ) ; original . setEnumValues ( null ) ; original . setDefaultValue ( "123" ) ; original . setMaximumSize ( ( ( org . sagebionetworks . table . cluster . utils . ColumnConstants . MAX_ALLOWED_STRING_... | org . junit . Assert . assertTrue ( e . getMessage ( ) . contains ( ColumnConstants . MAX_ALLOWED_STRING_SIZE . toString ( ) ) ) |
testSourcePatternNoMatch ( ) { com . box . l10n . mojito . cli . filefinder . file . POFileType potFileType = new com . box . l10n . mojito . cli . filefinder . file . POFileType ( ) ; com . box . l10n . mojito . cli . filefinder . FilePattern sourceFilePattern = potFileType . getSourceFilePattern ( ) ; java . util . r... | org . junit . Assert . assertFalse ( matcher . matches ( ) ) |
totalValueShouldBeEqualToSumOfAllFundsValues ( ) { expect ( fundA . getRegisterX ( ) ) . andStubReturn ( regAX ) ; expect ( fundA . getRegisterY ( ) ) . andStubReturn ( regAY ) ; expect ( fundB . getRegisterX ( ) ) . andStubReturn ( regBX ) ; expect ( fundB . getRegisterY ( ) ) . andStubReturn ( regBY ) ; expect ( regA... | org . junit . Assert . assertEquals ( java . math . BigDecimal . valueOf ( ( ( ( 5 + 1 ) * 3 ) + ( ( 4 + 1 ) * 2 ) ) ) , client . getValueOfAllFunds ( ) ) |
gettingAResourceByANonAuthenticatedUser ( ) { try { com . sun . jersey . multipart . FormDataMultiPart form = new com . sun . jersey . multipart . FormDataMultiPart ( ) ; form . field ( "fileName" , "/Shared/marketing/my_test_document.txt" ) ; form . field ( "This<sp>test<sp>is<sp>trying<sp>to<sp>simulate<sp>the<sp>upd... | org . junit . Assert . assertThat ( receivedStatus , org . hamcrest . Matchers . is ( unauthorized ) ) |
testLimitedQueue_EmptyQueue ( ) { codeine . utils . LimitedQueue < java . lang . String > q = new codeine . utils . LimitedQueue < java . lang . String > ( 1 ) ; "<AssertPlaceHolder>" ; } isEmpty ( ) { return ( original . size ( ) ) == 0 ; } | org . junit . Assert . assertTrue ( q . isEmpty ( ) ) |
testSerialization ( ) { org . jfree . data . xy . VectorSeries s1 = new org . jfree . data . xy . VectorSeries ( "Series" ) ; s1 . add ( 1.0 , 1.1 , 1.2 , 1.3 ) ; org . jfree . data . xy . VectorSeriesCollection c1 = new org . jfree . data . xy . VectorSeriesCollection ( ) ; c1 . addSeries ( s1 ) ; org . jfree . data .... | org . junit . Assert . assertEquals ( c1 , c2 ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.