input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
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 ( layoutPageTemplateStructureRels . isEmpty ( ) ) |
testGetTableCellRendererComponent ( ) { System . out . println ( "getTableCellRendererComponent" ) ; javax . swing . JTable table = new kg . apc . jmeter . graphs . ChartRowsTable ( null ) ; java . lang . Object value = new java . lang . String ( ) ; boolean isSelected = false ; boolean hasFocus = false ; int row = 0 ;... | org . junit . Assert . assertTrue ( ( result instanceof kg . apc . jmeter . graphs . HeaderAsTextRenderer ) ) |
populatedStreamMetadataBuilderShouldBeMutable ( ) { com . github . msemys . esjc . StreamMetadata streamMetadata = com . github . msemys . esjc . StreamMetadata . newBuilder ( ) . maxCount ( 19L ) . maxAge ( java . time . Duration . ofSeconds ( 82 ) ) . truncateBefore ( 8L ) . cacheControl ( java . time . Duration . of... | org . junit . Assert . assertEquals ( expectedStreamMetadata . toJson ( ) , result . toJson ( ) ) |
testHornerForm1 ( ) { org . apache . commons . math3 . random . RandomGenerator rnd = getRandom ( ) ; org . apache . commons . math3 . random . RandomDataGenerator rndd = getRandomData ( ) ; cc . redberry . rings . IntegersZp64 ring = cc . redberry . rings . Rings . Zp64 ( cc . redberry . rings . primes . SmallPrimes .... | org . junit . Assert . assertEquals ( plain , horner ) |
getAttributePrefix ( ) { java . lang . String expected = "expected" ; int index = 10 ; when ( this . reader . getAttributePrefix ( index ) ) . thenReturn ( expected ) ; java . lang . String result = this . filter . getAttributePrefix ( index ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertSame ( expected , result ) |
entryByLicenseId ( ) { java . io . File repoFile = null ; try { sernet . verinice . model . licensemanagement . LicenseManagementEntry entry = getSingleCryptedEntry ( ) ; repoFile = addLicenseToRepository ( entry ) ; sernet . verinice . model . licensemanagement . LicenseManagementEntry entryFromRepo = licenseManagemen... | org . junit . Assert . assertTrue ( entry . equals ( entryFromRepo ) ) |
testExceptionThrow ( ) { context . checking ( new org . jmock . Expectations ( ) { { oneOf ( securityContext ) . getAuthentication ( ) ; will ( throwException ( new java . lang . Exception ( ) ) ) ; } } ) ; "<AssertPlaceHolder>" ; } runTest ( boolean ) { org . springframework . security . context . SecurityContext orig... | org . junit . Assert . assertNull ( runTest ( true ) ) |
uniquify ( ) { int [ ] ints = new int [ ] { 1 , 4 , 4 , 2 , 7 , 3 , 8 , 0 , 0 , 3 } ; int [ ] actual = biweekly . util . com . google . ical . iter . Util . uniquify ( ints ) ; int [ ] expected = new int [ ] { 0 , 1 , 2 , 3 , 4 , 7 , 8 } ; "<AssertPlaceHolder>" ; } uniquify ( int [ ] ) { biweekly . util . com . google ... | org . junit . Assert . assertTrue ( java . util . Arrays . equals ( expected , actual ) ) |
testNotifiesAboutEachFileVersionDeletion ( ) { _withMaximumNumberOfVersionsConfigured ( 2 , ( ) -> { com . liferay . portal . kernel . service . ServiceContext serviceContext = com . liferay . portal . kernel . test . util . ServiceContextTestUtil . getServiceContext ( _group . getGroupId ( ) ) ; com . liferay . portal... | org . junit . Assert . assertEquals ( deletedFileVersions . toString ( ) , 9 , deletedFileVersions . size ( ) ) |
getIotHubStatusCodeMapsHubOrDeviceNotFoundCorrectly ( ) { final int httpsStatus = 404 ; com . microsoft . azure . sdk . iot . device . IotHubStatusCode testStatus = com . microsoft . azure . sdk . iot . device . IotHubStatusCode . getIotHubStatusCode ( httpsStatus ) ; final com . microsoft . azure . sdk . iot . device ... | org . junit . Assert . assertThat ( testStatus , org . hamcrest . CoreMatchers . is ( expectedStatus ) ) |
testTaobao ( ) { io . github . bonigarcia . wdm . WebDriverManager . chromedriver ( ) . config ( ) . setAvoidAutoVersion ( true ) . setChromeDriverMirrorUrl ( new java . net . URL ( "http://npm.taobao.org/mirrors/chromedriver/" ) ) ; io . github . bonigarcia . wdm . WebDriverManager . chromedriver ( ) . useMirror ( ) .... | org . junit . Assert . assertTrue ( binary . exists ( ) ) |
testSourceEntity ( ) { org . apache . cayenne . map . Relationship rel = new org . apache . cayenne . map . MockRelationship ( ) ; org . apache . cayenne . map . Entity tstEntity = new org . apache . cayenne . map . MockEntity ( ) ; rel . setSourceEntity ( tstEntity ) ; "<AssertPlaceHolder>" ; } getSourceEntity ( ) { r... | org . junit . Assert . assertSame ( tstEntity , rel . getSourceEntity ( ) ) |
testDynamicQueryByPrimaryKeyMissing ( ) { com . liferay . portal . kernel . dao . orm . DynamicQuery dynamicQuery = com . liferay . portal . kernel . dao . orm . DynamicQueryFactoryUtil . forClass ( com . liferay . dynamic . data . mapping . model . DDMFormInstanceVersion . class , _dynamicQueryClassLoader ) ; dynamicQ... | org . junit . Assert . assertEquals ( 0 , result . size ( ) ) |
removeWorks ( ) { for ( java . util . Map < java . lang . Integer , java . lang . Integer > any : net . java . quickcheck . generator . CombinedGeneratorsIterables . someMaps ( net . java . quickcheck . generator . PrimitiveGenerators . integers ( ) , net . java . quickcheck . generator . PrimitiveGenerators . integers... | org . junit . Assert . assertEquals ( 0 , map . size ( ) ) |
shouldBeIterable ( ) { com . qcadoo . commons . functional . LazyStream < java . lang . Integer > stream = com . qcadoo . commons . functional . LazyStream . create ( 1 , com . qcadoo . commons . functional . LazyStreamTest . INCREMENT_BY_ONE ) ; java . util . List < java . lang . Integer > iterableValues = com . googl... | org . junit . Assert . assertEquals ( com . google . common . collect . Lists . newArrayList ( 1 , 2 , 3 , 4 , 5 ) , iterableValues ) |
testGetMissingRomFilesForSoftwareClone ( ) { org . tibennetwork . iarcade . mame . FakeMameRuntime mame = new org . tibennetwork . iarcade . mame . FakeMameRuntime ( ) ; java . util . List < java . io . InputStream > inputStreams = new java . util . ArrayList ( ) ; inputStreams . add ( new java . io . FileInputStream (... | org . junit . Assert . assertThat ( s . getMissingRomFiles ( romPaths ) , org . hamcrest . CoreMatchers . equalTo ( expectedMissingRomFiles ) ) |
testDoGet ( ) { uk . gov . dstl . baleen . testing . servlets . ServletCaller caller = new uk . gov . dstl . baleen . testing . servlets . ServletCaller ( ) ; javax . servlet . http . HttpServletResponse response = caller . doGet ( servlet ) ; "<AssertPlaceHolder>" ; verify ( servlet ) . service ( caller . getRequest (... | org . junit . Assert . assertNotNull ( response ) |
testRetainOverflow ( ) { io . netty . buffer . AbstractReferenceCountedByteBuf referenceCounted = io . netty . buffer . AbstractReferenceCountedByteBufTest . newReferenceCounted ( ) ; referenceCounted . setRefCnt ( Integer . MAX_VALUE ) ; "<AssertPlaceHolder>" ; referenceCounted . retain ( ) ; } refCnt ( ) { return buf... | org . junit . Assert . assertEquals ( Integer . MAX_VALUE , referenceCounted . refCnt ( ) ) |
data_should_be_compared_between_expected_and_current_data ( ) { com . lordofthejars . nosqlunit . mongodb . MongoOperation mongoOperation = new com . lordofthejars . nosqlunit . mongodb . MongoOperation ( com . lordofthejars . nosqlunit . mongodb . InMemoryMongoDbConfigurationBuilder . inMemoryMongoDb ( ) . databaseNam... | org . junit . Assert . assertThat ( result , org . hamcrest . CoreMatchers . is ( true ) ) |
testGetReferencedComponentId ( ) { java . lang . String expectedStringValue = "SomeStringValue" ; java . lang . String referencedComponentId ; closeProperties . referencedComponent . componentInstanceId . setValue ( expectedStringValue ) ; referencedComponentId = closeProperties . getReferencedComponentId ( ) ; "<Asser... | org . junit . Assert . assertEquals ( referencedComponentId , expectedStringValue ) |
testGetInstance ( ) { org . junit . Assume . assumeTrue ( ( ( org . apache . hadoop . crypto . OpensslCipher . getLoadingFailureReason ( ) ) == null ) ) ; org . apache . hadoop . crypto . OpensslCipher cipher = org . apache . hadoop . crypto . OpensslCipher . getInstance ( "AES/CTR/NoPadding" ) ; "<AssertPlaceHolder>" ... | org . junit . Assert . assertTrue ( ( cipher != null ) ) |
readData_InvalidLocationEvent ( ) { org . mockito . Mockito . when ( filereader . fileExist ( org . mockito . Mockito . anyString ( ) ) ) . thenReturn ( true ) ; org . mockito . Mockito . when ( filereader . readAllLine ( org . mockito . Mockito . anyString ( ) ) ) . thenReturn ( new java . lang . String [ ] { "1.48703... | org . junit . Assert . assertEquals ( 1.0 , listLocationEvent . size ( ) , 0 ) |
shouldReturnFalseIfFileIsNotJarFile ( ) { com . openpojo . reflection . PojoClass pojoClass = com . openpojo . reflection . impl . PojoClassFactory . getPojoClass ( this . getClass ( ) ) ; java . lang . String sourcePath = new java . net . URL ( pojoClass . getSourcePath ( ) ) . getPath ( ) ; com . openpojo . reflectio... | org . junit . Assert . assertFalse ( jarFileReader . isValid ( ) ) |
completedAndSelectedByDateCriteriaShouldBeDeleted ( ) { newJobStatus ( ) . startTime ( new java . util . Date ( ) ) . finishTime ( org . candlepin . util . Util . tomorrow ( ) ) . create ( ) ; this . curator . cleanUpOldCompletedJobs ( org . candlepin . util . Util . addDaysToDt ( 2 ) ) ; "<AssertPlaceHolder>" ; } list... | org . junit . Assert . assertEquals ( 0 , this . curator . listAll ( ) . list ( ) . size ( ) ) |
testCreateManagerUrlForDefaultHostAndPort ( ) { final java . net . URL actualManagerUrl = commonTomcatConfiguration . createManagerUrl ( ) ; final java . lang . String actualManagerUrlString = actualManagerUrl . toString ( ) ; final java . lang . String expectedManagerUrlString = "http://localhost:8080/manager" ; "<Ass... | org . junit . Assert . assertEquals ( expectedManagerUrlString , actualManagerUrlString ) |
testTriggerScanStarting ( ) { com . sonyericsson . hudson . plugins . gerrit . trigger . hudsontrigger . actions . manual . TriggerMonitor monitor = new com . sonyericsson . hudson . plugins . gerrit . trigger . hudsontrigger . actions . manual . TriggerMonitor ( ) ; com . sonyericsson . hudson . plugins . gerrit . tri... | org . junit . Assert . assertTrue ( state . isTriggerScanStarted ( ) ) |
testAsyncCreateInstance_noControllerSet ( ) { final org . oscm . provisioning . data . InstanceRequest rq = new org . oscm . provisioning . data . InstanceRequest ( ) ; rq . setOrganizationId ( "org123" ) ; rq . setOrganizationName ( "Fujitsu" ) ; rq . setSubscriptionId ( "sub123" ) ; rq . setDefaultLocale ( "de" ) ; r... | org . junit . Assert . assertFalse ( ( ( result . getRc ( ) ) == 0 ) ) |
testGetAttributeValueList ( ) { org . finra . herd . model . api . xml . AttributeValueListKey attributeValueListKey = new org . finra . herd . model . api . xml . AttributeValueListKey ( ATTRIBUTE_VALUE_LIST_NAMESPACE , ATTRIBUTE_VALUE_LIST_NAME ) ; org . finra . herd . model . api . xml . AttributeValueList attribute... | org . junit . Assert . assertEquals ( attributeValueList , result ) |
testSetsForegroundWithRGB ( ) { com . eclipsesource . tabris . ui . UIConfiguration configuration = new com . eclipsesource . tabris . ui . UIConfiguration ( ) ; configuration . setForeground ( 233 , 233 , 233 ) ; org . eclipse . swt . graphics . RGB actualForeground = configuration . getForeground ( ) ; "<AssertPlaceH... | org . junit . Assert . assertEquals ( new org . eclipse . swt . graphics . RGB ( 233 , 233 , 233 ) , actualForeground ) |
parallelStream_whenWorks_thenCorrect ( ) { com . baeldung . java8 . Stream < com . baeldung . stream . Product > streamOfCollection = productList . parallelStream ( ) ; boolean isParallel = streamOfCollection . isParallel ( ) ; boolean haveBigPrice = streamOfCollection . map ( ( product ) -> ( product . getPrice ( ) ) ... | org . junit . Assert . assertTrue ( ( isParallel && haveBigPrice ) ) |
openResource ( ) { org . apache . lucene . analysis . util . ClasspathResourceLoader parent = new org . apache . lucene . analysis . util . ClasspathResourceLoader ( getClass ( ) . getClassLoader ( ) ) ; com . s24 . search . solr . analysis . jdbc . JdbcReader reader = new com . s24 . search . solr . analysis . jdbc . ... | org . junit . Assert . assertEquals ( "test=>test1,test2" , writer . toString ( ) ) |
test_getAllAddressTags ( ) { "<AssertPlaceHolder>" ; } getAllAddressTags ( ) { return io . github . data4all . model . data . Tags . ADDRESS_TAG_LIST ; } | org . junit . Assert . assertEquals ( 5 , io . github . data4all . model . data . Tags . getAllAddressTags ( ) . size ( ) ) |
testAll ( ) { append ( "[groups]" , globalPolicyFile ) ; append ( "group<sp>=<sp>malicious_role" , globalPolicyFile ) ; append ( "[roles]" , globalPolicyFile ) ; append ( "malicious_role<sp>=<sp>*" , globalPolicyFile ) ; org . apache . sentry . policy . common . PolicyEngine policy = org . apache . sentry . policy . hi... | org . junit . Assert . assertTrue ( permissions . toString ( ) , permissions . isEmpty ( ) ) |
testConfigure ( ) { System . out . println ( "Testing<sp>RoundRobinChannelSelector.configure" ) ; channelSelector . configure ( context ) ; "<AssertPlaceHolder>" ; } configure ( org . apache . flume . Context ) { consumerKey = context . getString ( "maxBatchSize" 6 ) ; consumerSecret = context . getString ( "consumerSe... | org . junit . Assert . assertTrue ( true ) |
testQuery_ATTENDEE ( ) { try { com . github . caldav4j . util . GenerateQueryTest . log . info ( "VEVENT<sp>+<sp>ATTENDEE:" ) ; java . util . List < java . lang . String > a = new java . util . ArrayList ( ) ; a . add ( "ATTENDEE==mailto:lisa@example.com" ) ; com . github . caldav4j . util . GenerateQuery gq = new com ... | org . junit . Assert . assertTrue ( false ) |
contentsEqual ( ) { java . util . ArrayList < parser . Terminal > t1 = new java . util . ArrayList < parser . Terminal > ( ) ; java . util . ArrayList < parser . Terminal > t2 = new java . util . ArrayList < parser . Terminal > ( ) ; parser . Terminal t = new parser . Terminal ( "test" , null ) ; t1 . add ( t ) ; t2 . ... | org . junit . Assert . assertTrue ( t1 . equals ( t2 ) ) |
testConsistency ( ) { final com . yoghurt . crypto . transactions . shared . domain . Transaction tx = com . yoghurt . crypto . transactions . client . util . transaction . TransactionParseUtil . parseTransactionBytes ( com . googlecode . gwt . crypto . bouncycastle . util . encoders . Hex . decode ( com . yoghurt . cr... | org . junit . Assert . assertEquals ( com . yoghurt . crypto . transactions . client . util . transaction . TransactionEncodeUtilTest . TEST_TX , new java . lang . String ( encode ) ) |
testReadRangeFromFileWithSplitsFromStart ( ) { org . apache . beam . sdk . options . PipelineOptions options = org . apache . beam . sdk . options . PipelineOptionsFactory . create ( ) ; java . lang . String header = "<h>" ; java . util . List < java . lang . String > data = new java . util . ArrayList ( ) ; for ( int ... | org . junit . Assert . assertThat ( expectedResults , org . hamcrest . Matchers . containsInAnyOrder ( results . toArray ( ) ) ) |
testSerde ( ) { org . apache . druid . discovery . DruidService expected = new org . apache . druid . discovery . WorkerNodeService ( "1.1.1.1" , 100 , "v1" ) ; com . fasterxml . jackson . databind . ObjectMapper mapper = org . apache . druid . segment . TestHelper . makeJsonMapper ( ) ; org . apache . druid . discover... | org . junit . Assert . assertEquals ( expected , actual ) |
testSeekEventLoc_null ( ) { org . eclipse . tracecompass . tmf . ctf . core . context . CtfLocation loc = null ; fixture . seekEvent ( loc ) ; "<AssertPlaceHolder>" ; } seekEvent ( double ) { if ( ( fFile ) == null ) { return new org . eclipse . tracecompass . tmf . core . trace . TmfContext ( org . eclipse . tracecomp... | org . junit . Assert . assertNotNull ( fixture ) |
getBillingRunStartTimeInMs_eod ( ) { long expectedStartTime = ( org . oscm . configurationservice . bean . BillingOffsetTest . DAY_IN_MS ) - 1 ; long billingOffset = ( 4 * ( org . oscm . configurationservice . bean . BillingOffsetTest . DAY_IN_MS ) ) + expectedStartTime ; doReturn ( java . lang . Long . valueOf ( billi... | org . junit . Assert . assertEquals ( expectedStartTime , result ) |
testSpdyRstStreamFrame ( ) { short type = 3 ; byte flags = 0 ; int length = 8 ; int streamId = ( ( io . netty . handler . codec . spdy . SpdyFrameDecoderTest . RANDOM . nextInt ( ) ) & 2147483647 ) | 1 ; int statusCode = ( io . netty . handler . codec . spdy . SpdyFrameDecoderTest . RANDOM . nextInt ( ) ) | 1 ; io . ne... | org . junit . Assert . assertFalse ( buf . isReadable ( ) ) |
checkGetFirstDiagramNodeWithEmptyGraph ( ) { final org . kie . workbench . common . stunner . core . graph . Graph graph = new org . kie . workbench . common . stunner . core . graph . impl . GraphImpl ( "uuid" , new org . kie . workbench . common . stunner . core . graph . store . GraphNodeStoreImpl ( ) ) ; final org ... | org . junit . Assert . assertNull ( fNode ) |
simpleBlockingPoll ( ) { org . ebayopensource . turmeric . runtime . sif . impl . transport . http . HTTPSyncAsyncClientTransportPoller completionQueue = new org . ebayopensource . turmeric . runtime . sif . impl . transport . http . HTTPSyncAsyncClientTransportPoller ( ) ; com . ebay . kernel . service . invocation . ... | org . junit . Assert . assertTrue ( ( ( futures . size ( ) ) == 1 ) ) |
shouldReturnAbsentIfValueIsAbsent ( ) { when ( valueProvider . getAnnotationValue ( dataFactory ) ) . thenReturn ( java . util . Optional . < org . semanticweb . owlapi . model . OWLAnnotationValue > empty ( ) ) ; "<AssertPlaceHolder>" ; } getAnnotation ( org . protege . editor . owl . OWLEditorKit ) { return java . ut... | org . junit . Assert . assertThat ( provider . getAnnotation ( dataFactory ) , org . hamcrest . core . Is . is ( java . util . Optional . empty ( ) ) ) |
testReadWriteObjectGenerative ( ) { com . liveramp . generative . Generative . runTests ( 10 , ( testNum , gen ) -> { List < java . lang . String > path = gen . namedVar ( "path" ) . listOfLength ( gen . anyStringOfLengthUpTo ( 1000 ) , gen . anyBoundedInteger ( 0 , 20 ) ) . get ( ) ; HashMap < java . lang . String , j... | org . junit . Assert . assertEquals ( map , result ) |
asInt ( ) { "<AssertPlaceHolder>" ; } asInt ( ) { org . junit . Assert . assertEquals ( 23 , new org . eclipse . rap . json . JsonNumber ( "23" ) . asInt ( ) ) ; } | org . junit . Assert . assertEquals ( 23 , new org . eclipse . rap . json . JsonNumber ( "23" ) . asInt ( ) ) |
testValidNamesTag ( ) { final java . lang . String tagSrc = "<cfcomponent>\r\n" + ( ( ( ( "<cffunction<sp>name=\"test\">\r\n" + "\t<cfargument<sp>name=\"first_name\">\r\n" ) + "\t<cfargument<sp>name=\"firstname\">\r\n" ) + "</cffunction>\r\n" ) + "</cfcomponent>" ) ; com . cflint . api . CFLintResult lintresult = cfBug... | org . junit . Assert . assertEquals ( 0 , result . size ( ) ) |
test_Negativity_In_Equality_For_IOU ( ) { com . ripple . core . coretypes . Amount a = com . ripple . core . AmountTest . amt ( "1/USD/rNDKeo9RrCiRdfsMG8AdoZvNZxHASGzbZL" ) ; com . ripple . core . coretypes . Amount b = com . ripple . core . AmountTest . amt ( "-1/USD/rNDKeo9RrCiRdfsMG8AdoZvNZxHASGzbZL" ) ; "<AssertPla... | org . junit . Assert . assertFalse ( a . equals ( b ) ) |
testIsValidNameNull ( ) { "<AssertPlaceHolder>" ; } isValidName ( java . lang . String ) { return com . liferay . document . library . kernel . util . DLValidatorUtil . _dlValidator . isValidName ( name ) ; } | org . junit . Assert . assertFalse ( com . liferay . document . library . kernel . util . DLValidatorUtil . isValidName ( null ) ) |
testResetUserPassword ( ) { usersPage . getOtherUser ( 1L ) ; usersPage . sendPasswordReset ( ) ; "<AssertPlaceHolder>" ; } checkSuccessNotification ( ) { return pageUtilities . checkSuccessNotification ( ) ; } | org . junit . Assert . assertTrue ( usersPage . checkSuccessNotification ( ) ) |
nameFirstUpdateIsAnyUpdate ( ) { final org . libdohj . script . NameScript ns = getNameFirstUpdateNameScript ( ) ; "<AssertPlaceHolder>" ; } isAnyUpdate ( ) { switch ( op ) { case org . libdohj . script . NameScript . OP_NAME_NEW : return false ; case org . libdohj . script . NameScript . OP_NAME_FIRSTUPDATE : case org... | org . junit . Assert . assertTrue ( ns . isAnyUpdate ( ) ) |
getCounterManage_test ( ) { scouter . server . CounterManager counterManager = scouter . server . CounterManager . getInstance ( ) ; "<AssertPlaceHolder>" ; } getInstance ( ) { if ( ( scouter . server . CounterManager . instance ) == null ) { synchronized ( scouter . server . CounterManager . class ) { if ( ( scouter .... | org . junit . Assert . assertNotNull ( counterManager ) |
decodeExtended ( ) { final java . io . ByteArrayInputStream stream = new java . io . ByteArrayInputStream ( extended ) ; final com . flagstone . transform . coder . SWFDecoder decoder = new com . flagstone . transform . coder . SWFDecoder ( stream ) ; fixture = new com . flagstone . transform . video . DefineVideo ( de... | org . junit . Assert . assertNotNull ( fixture ) |
stream_of_strings_to_ints_array ( ) { java . lang . Integer [ ] stringArray = java . util . stream . Stream . of ( 1 , 2 , 3 ) . toArray ( java . lang . Integer [ ] :: new ) ; com . levelup . java . util . stream . ConvertStreamToArray . logger . info ( java . util . Arrays . toString ( stringArray ) ) ; "<AssertPlaceH... | org . junit . Assert . assertTrue ( ( ( stringArray . length ) == 3 ) ) |
testReadProjectWithWorkspaceThatDoesNotExist ( ) { org . eclipse . orion . server . core . metastore . IMetaStore metaStore = org . eclipse . orion . server . core . OrionConfiguration . getMetaStore ( ) ; org . eclipse . orion . server . core . metastore . UserInfo userInfo = new org . eclipse . orion . server . core ... | org . junit . Assert . assertNull ( readProjectInfo ) |
testGetResultForNode ( ) { result = new ch . puzzle . itc . mobiliar . presentation . generator . ComparedGenerationResult ( originalResult ) ; ch . puzzle . itc . mobiliar . business . generator . control . NodeGenerationResult newResult = result . getResultForNode ( nodeResult . getNode ( ) , originalResult ) ; "<Ass... | org . junit . Assert . assertTrue ( ( newResult == ( this . nodeResult ) ) ) |
testGetParameters ( ) { java . lang . String name = "Extract<sp>Me<sp>All" ; java . lang . String abbrName = "EML" ; org . lnu . is . domain . reason . Reason entity = new org . lnu . is . domain . reason . Reason ( ) ; entity . setName ( name ) ; entity . setAbbrName ( abbrName ) ; java . util . Map < java . lang . St... | org . junit . Assert . assertEquals ( expected , actual ) |
testExpression70 ( ) { net . objecthunter . exp4j . Expression e = new net . objecthunter . exp4j . ExpressionBuilder ( "2xx" ) . variables ( "x" ) . build ( ) . setVariable ( "x" , Math . E ) ; "<AssertPlaceHolder>" ; } evaluate ( ) { final net . objecthunter . exp4j . ArrayStack output = new net . objecthunter . exp4... | org . junit . Assert . assertEquals ( ( ( 2 * ( java . lang . Math . Math . E ) ) * ( java . lang . Math . Math . E ) ) , e . evaluate ( ) , 0.0 ) |
dropWhile_A$Function1_Nil ( ) { com . m3 . scalaflavor4j . Seq < java . lang . Integer > seq = com . m3 . scalaflavor4j . Seq . apply ( ) ; com . m3 . scalaflavor4j . Seq < java . lang . Integer > actual = seq . dropWhile ( new com . m3 . scalaflavor4j . F1 < java . lang . Integer , java . lang . Boolean > ( ) { public... | org . junit . Assert . assertThat ( actual . size ( ) , org . hamcrest . CoreMatchers . is ( org . hamcrest . CoreMatchers . equalTo ( 0 ) ) ) |
testShouldBeEqual ( ) { com . eclipsesource . tabris . ui . PageData pageData1 = new com . eclipsesource . tabris . ui . PageData ( ) ; pageData1 . set ( "a" , "1" ) ; com . eclipsesource . tabris . ui . PageData pageData2 = new com . eclipsesource . tabris . ui . PageData ( ) ; pageData2 . set ( "a" , "1" ) ; boolean ... | org . junit . Assert . assertTrue ( equal ) |
testUserExists ( ) { boolean b = dao . exists ( ( - 1L ) ) ; "<AssertPlaceHolder>" ; } exists ( PK extends java . io . Serializable ) { T entity = ( ( T ) ( super . getHibernateTemplate ( ) . get ( this . persistentClass , id ) ) ) ; return entity != null ; } | org . junit . Assert . assertTrue ( b ) |
testGetUpnpMimeType ( ) { org . seamless . util . MimeType mimeType = net . holmes . core . business . streaming . upnp . UpnpUtils . getUpnpMimeType ( net . holmes . core . business . mimetype . model . MimeType . valueOf ( "image/png" ) ) ; "<AssertPlaceHolder>" ; } valueOf ( java . lang . String ) { return mimeType ... | org . junit . Assert . assertNotNull ( mimeType ) |
applyTest ( ) { java . lang . String [ ] [ ] tests = new java . lang . String [ ] [ ] { new java . lang . String [ ] { "{{<sp>'foo+bar'<sp>|<sp>url_decode<sp>}}" , "foo<sp>bar" } , new java . lang . String [ ] { "{{<sp>'foo%20bar'<sp>|<sp>url_decode<sp>}}" , "foo<sp>bar" } , new java . lang . String [ ] { "{{<sp>'foo%2... | org . junit . Assert . assertThat ( rendered , org . hamcrest . CoreMatchers . is ( test [ 1 ] ) ) |
testStripSequenceNumberBlank ( ) { "<AssertPlaceHolder>" ; } stripSequenceNumber ( java . lang . String ) { if ( ( isBlank ( name ) ) || ( ! ( java . lang . Character . isDigit ( name . charAt ( ( ( name . length ( ) ) - 1 ) ) ) ) ) ) { return name ; } return au . gov . ga . worldwind . animator . util . FileUtil . str... | org . junit . Assert . assertEquals ( "<sp>" , au . gov . ga . worldwind . animator . util . FileUtil . stripSequenceNumber ( "<sp>" ) ) |
testRouterServicePathLookUp ( ) { java . lang . String path = "/v3/namespaces/default//apps/ResponseCodeAnalytics/services/LogAnalyticsService/status" ; io . netty . handler . codec . http . HttpRequest httpRequest = new io . netty . handler . codec . http . DefaultHttpRequest ( io . cdap . cdap . gateway . router . Ro... | org . junit . Assert . assertEquals ( RouterPathLookup . APP_FABRIC_HTTP , result ) |
genericWithReflection ( ) { org . apache . avro . generic . GenericRecord savedRecord = new org . apache . avro . generic . GenericData . Record ( org . apache . crunch . test . Person . SCHEMA$ ) ; savedRecord . put ( "name" , "John<sp>Doe" ) ; savedRecord . put ( "age" , 42 ) ; savedRecord . put ( "siblingnames" , co... | org . junit . Assert . assertEquals ( 1 , ret . size ( ) ) |
testPass ( ) { "<AssertPlaceHolder>" ; } | org . junit . Assert . assertEquals ( 1 , 1 ) |
compareListContentsFullOverlap ( ) { java . util . List < java . lang . String > names1 = new java . util . ArrayList ( ) ; java . util . List < java . lang . String > names2 = new java . util . ArrayList ( ) ; names1 . add ( "bob" ) ; names1 . add ( "alice" ) ; names2 . add ( "bob" ) ; names2 . add ( "alice" ) ; "<Ass... | org . junit . Assert . assertTrue ( checkContainsSame ( names1 , names2 ) ) |
testPolling ( ) { java . io . File tmpDir = tempDir . newFolder ( ) ; org . deeplearning4j . perf . listener . SystemPolling systemPolling = new org . deeplearning4j . perf . listener . SystemPolling . Builder ( ) . outputDirectory ( tmpDir ) . pollEveryMillis ( 1000 ) . build ( ) ; systemPolling . run ( ) ; java . lan... | org . junit . Assert . assertTrue ( ( ( files != null ) && ( ( files . length ) > 0 ) ) ) |
testRandomByteArrayTransfer2 ( ) { byte [ ] value = new byte [ ( org . apache . flink . runtime . io . network . buffer . AbstractByteBufTest . BLOCK_SIZE ) * 2 ] ; for ( int i = 0 ; i < ( ( ( buffer . capacity ( ) ) - ( org . apache . flink . runtime . io . network . buffer . AbstractByteBufTest . BLOCK_SIZE ) ) + 1 )... | org . junit . Assert . assertEquals ( expectedValue . getByte ( j ) , value [ j ] ) |
testGetPropertyInstanceNoTargetType ( ) { org . finra . herd . model . dto . ConfigurationValue configurationValue = org . finra . herd . model . dto . ConfigurationValue . HERD_ENVIRONMENT ; java . lang . String value = configurationHelper . getProperty ( configurationValue ) ; "<AssertPlaceHolder>" ; } getDefaultValu... | org . junit . Assert . assertEquals ( "value" , configurationValue . getDefaultValue ( ) , value ) |
testBadCast ( ) { org . eurekastreams . commons . test . EasyMatcher < java . lang . String > sut = new org . eurekastreams . commons . test . EasyMatcher < java . lang . String > ( ) { @ org . eurekastreams . commons . test . Override protected boolean isMatch ( final java . lang . String inTestObject ) { java . lang ... | org . junit . Assert . assertFalse ( sut . matches ( null ) ) |
testGetParent ( ) { org . eclipse . xtext . nodemodel . impl . AbstractNode node = createNode ( ) ; org . eclipse . xtext . nodemodel . ICompositeNode parent = builder . newRootNode ( "input" ) ; builder . addChild ( parent , node ) ; "<AssertPlaceHolder>" ; } getParent ( ) { if ( ( grammarElementIdx ) == 1 ) return de... | org . junit . Assert . assertSame ( parent , node . getParent ( ) ) |
split_string_colon_guava ( ) { java . util . List < java . lang . String > elementsInString = com . google . common . base . Splitter . on ( ":" ) . splitToList ( "This:is:a:sentence:by:colon" ) ; com . levelup . java . string . SplitStringByColon . logger . info ( elementsInString ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertEquals ( 6 , elementsInString . size ( ) ) |
testOpslaan ( ) { nl . bzk . brp . preview . model . Bericht bericht = new nl . bzk . brp . preview . model . Bericht ( ) ; bericht . setPartij ( "<sp>and<sp>indprevalidatie<sp>=<sp>true" 0 ) ; bericht . setBericht ( "qwe" ) ; bericht . setBerichtDetails ( "asd" ) ; bericht . setAantalMeldingen ( 2 ) ; java . util . Ca... | org . junit . Assert . assertEquals ( 1 , count ) |
testLocalAddress ( ) { java . net . InetSocketAddress localAddress = new java . net . InetSocketAddress ( "localhost" , 60000 ) ; final org . glassfish . grizzly . connectionpool . MultiEndpointPool < java . net . SocketAddress > pool = org . glassfish . grizzly . connectionpool . MultiEndpointPool . builder ( java . n... | org . junit . Assert . assertEquals ( localAddress , c1 . getLocalAddress ( ) ) |
metadata_xmlComplexPropertyNullablefalse ( ) { final java . lang . String entryName = "bar/90_contents/odatacol1/00_$metadata.xml" ; final java . lang . String filename = "/00_$metadata_compprop_nullable_empty.xml" ; java . net . URL fileUrl = java . lang . ClassLoader . getSystemResource ( ( ( com . fujitsu . dc . tes... | org . junit . Assert . assertFalse ( res ) |
testListDataRecordPaginatedStartingAtMinusTwo ( ) { com . liferay . data . engine . model . DEDataRecordCollection deDataRecordCollection = com . liferay . data . engine . service . test . DEDataEngineTestUtil . insertDEDataRecordCollection ( _adminUser , _group , _deDataDefinitionService , _deDataRecordCollectionServi... | org . junit . Assert . assertEquals ( deDataRecords . toString ( ) , 5 , deDataRecords . size ( ) ) |
testGetV8ResultNull ( ) { java . lang . Object result = com . eclipsesource . v8 . utils . V8ObjectUtils . getV8Result ( v8 , null ) ; "<AssertPlaceHolder>" ; } getV8Result ( com . eclipsesource . v8 . V8 , java . lang . Object ) { if ( value == null ) { return null ; } java . util . Map < java . lang . Object , com . ... | org . junit . Assert . assertNull ( result ) |
testProcessData ( ) { java . lang . Object expectedObject = new java . lang . Object ( ) ; org . talend . codegen . flowvariables . runtime . MainDataProcessor mainDataProcessor = new org . talend . codegen . flowvariables . runtime . MainDataProcessor ( ) ; java . lang . Object actualObject = mainDataProcessor . proce... | org . junit . Assert . assertEquals ( expectedObject , actualObject ) |
testCreateFamilyMedicalHistorySectionBuilder ( ) { org . openhealthtools . mdht . uml . cda . builder . SectionBuilder < org . openhealthtools . mdht . uml . cda . ihe . FamilyMedicalHistorySection > sectionBuilder = org . openhealthtools . mdht . uml . cda . ihe . builder . IHEBuilderFactory . createFamilyMedicalHisto... | org . junit . Assert . assertNotNull ( section ) |
testImplementingRepositoryInterfaceThroughOtherInterface ( ) { org . eclipse . jdt . core . IType type = javaProject . findType ( "org.ClassImplementingRepositoryInterfaceThroughOtherInterface" ) ; "<AssertPlaceHolder>" ; } isSpringDataRepository ( org . eclipse . jdt . core . IType ) { if ( type == null ) { return fal... | org . junit . Assert . assertTrue ( org . springframework . ide . eclipse . data . jdt . core . RepositoryInformation . isSpringDataRepository ( type ) ) |
testCreateCacheIdAbsoluteURLWithPort ( ) { java . lang . String cacheId = com . hannikkala . poc . util . CacheIdUtil . createCacheId ( "http://localhost:3000/" , "http://localhost:3000/font-awesome@4.3.0/css/font-awesome.min.css" , "http://localhost:3000" ) ; "<AssertPlaceHolder>" ; } createCacheId ( java . lang . Str... | org . junit . Assert . assertEquals ( "http://localhost:3000/font-awesome@4.3.0/css/font-awesome.min.css" , cacheId ) |
findBetweenTwoDates ( ) { java . util . Calendar d = java . util . Calendar . getInstance ( ) ; d . add ( Calendar . DATE , ( - 1 ) ) ; topDomain = domainRepository . findById ( LoadingServiceTestDatas . sqlDomain ) ; rootDomain = domainRepository . findById ( LoadingServiceTestDatas . sqlRootDomain ) ; advancedStatist... | org . junit . Assert . assertEquals ( 2 , mimeTypeStatistics . size ( ) ) |
returnsInstanceGivenInCreationOfObjectFactory ( ) { java . lang . Object instance = new java . lang . Object ( ) ; org . everrest . core . ObjectModel objectModel = mock ( org . everrest . core . ObjectModel . class ) ; org . everrest . core . SingletonObjectFactory singletonObjectFactory = new org . everrest . core . ... | org . junit . Assert . assertSame ( instance , result ) |
testGetTreePermission ( ) { org . apache . jackrabbit . oak . spi . security . authorization . permission . PermissionProvider pp = createPermissionProvider ( ) ; org . apache . jackrabbit . oak . api . Tree t = root . getTree ( PermissionConstants . PERMISSIONS_STORE_PATH ) ; "<AssertPlaceHolder>" ; } getTreePermissio... | org . junit . Assert . assertSame ( TreePermission . EMPTY , pp . getTreePermission ( t , TreePermission . EMPTY ) ) |
testUpdate ( ) { org . smartdata . model . ClusterInfo clusterInfo = new org . smartdata . model . ClusterInfo ( ) ; clusterInfo . setCid ( 1 ) ; clusterInfo . setType ( "test" ) ; clusterInfo . setState ( "test" ) ; clusterInfo . setConfPath ( "test" ) ; clusterInfo . setUrl ( "test" ) ; clusterInfo . setName ( "test"... | org . junit . Assert . assertTrue ( clusterInfoDao . getById ( 1 ) . equals ( clusterInfo ) ) |
compareDefaultSortOrderFileToString ( ) { java . lang . String expected = org . apache . commons . io . IOUtils . toString ( new java . io . FileInputStream ( "src/test/resources/sortOrderFiles/with_newline_tagsToString.txt" ) , sortpom . wrapper . CustomSortOrderFileTest . UTF_8 ) ; "<AssertPlaceHolder>" ; } getToStri... | org . junit . Assert . assertEquals ( expected , getToStringOnCustomSortOrderFile ( ) ) |
isValidProfileHashNullRequestNullTest ( ) { org . kaaproject . kaa . server . sync . ClientSyncMetaData clientSyncMetaData = mock ( org . kaaproject . kaa . server . sync . ClientSyncMetaData . class ) ; when ( clientSyncMetaData . getProfileHash ( ) ) . thenReturn ( null ) ; org . kaaproject . kaa . server . sync . Cl... | org . junit . Assert . assertEquals ( clientSync . isValid ( ) , false ) |
testCurrentMappingXML ( ) { com . github . dozermapper . core . builder . xml . JAXBModelParser < com . github . dozermapper . core . builder . model . jaxb . MappingsDefinition > factory = new com . github . dozermapper . core . builder . xml . DefaultJAXBModelParser ( new com . github . dozermapper . core . config . ... | org . junit . Assert . assertNotNull ( mapping ) |
testIsRightArrowWhenItIsRightArrow ( ) { final elemental2 . dom . Element element = mock ( elemental2 . dom . Element . class ) ; final elemental2 . dom . DOMTokenList classList = mock ( elemental2 . dom . DOMTokenList . class ) ; element . classList = classList ; when ( classList . contains ( org . kie . workbench . c... | org . junit . Assert . assertTrue ( org . kie . workbench . common . dmn . client . editors . types . listview . common . ListItemViewCssHelper . isRightArrow ( element ) ) |
testConvertToKettleValueRecordStringValue ( ) { avroField . m_kettleType = "String" ; avroField . m_fieldPath = "key" ; avroField . init ( 0 ) ; avroField . reset ( variableSpace ) ; java . lang . String testString = "testString" ; org . apache . avro . Schema schema = mock ( org . apache . avro . Schema . class ) ; or... | org . junit . Assert . assertEquals ( testString , avroField . convertToKettleValue ( record , schema , mock ( org . apache . avro . Schema . class ) , false ) ) |
testResolveLocale ( ) { org . apache . tiles . request . Request request = createMock ( org . apache . tiles . request . Request . class ) ; java . util . Map < java . lang . String , java . lang . Object > sessionScope = createMock ( java . util . Map . class ) ; java . util . Locale locale = java . util . Locale . IT... | org . junit . Assert . assertSame ( locale , resolver . resolveLocale ( request ) ) |
testReadPoints ( ) { java . lang . String namedCurve = "secp192r1" ; java . util . List < de . rub . nds . tlsattacker . attacks . ec . ICEPoint > result = de . rub . nds . tlsattacker . attacks . ec . ICEPointReader . readPoints ( namedCurve ) ; "<AssertPlaceHolder>" ; } getOrder ( ) { return order ; } | org . junit . Assert . assertEquals ( 5 , result . get ( 0 ) . getOrder ( ) ) |
testCoerceToType02 ( ) { java . lang . Object result = javax . el . ELManager . getExpressionFactory ( ) . coerceToType ( null , int . class ) ; "<AssertPlaceHolder>" ; } coerceToType ( java . lang . Class , java . lang . String ) { if ( type . equals ( java . lang . String . class ) ) { return value ; } else if ( ( ty... | org . junit . Assert . assertEquals ( java . lang . Integer . valueOf ( 0 ) , result ) |
testSetCommand ( ) { org . opencastproject . dictionary . hunspell . DictionaryServiceImpl service = new org . opencastproject . dictionary . hunspell . DictionaryServiceImpl ( ) ; java . lang . String command = "123" ; service . setCommand ( command ) ; "<AssertPlaceHolder>" ; } getCommand ( ) { return command ; } | org . junit . Assert . assertEquals ( command , service . getCommand ( ) ) |
testJiraAwareFailureRegex ( ) { JiraAwareFailureUtils . regexJiraMatches . put ( "TEST.*UNIQUE.*TEST" , "KULRICE-TEST" ) ; org . kuali . rice . testtools . common . JiraAwareFailureUtils . failOnMatchedJira ( "TEST<sp>UNIQUE<sp>data<sp>for<sp>TEST" , this ) ; "<AssertPlaceHolder>" ; } contains ( java . lang . Class ) {... | org . junit . Assert . assertTrue ( message . contains ( "KULRICE-TEST" ) ) |
testTokenGeneratorWithStandardUsername ( ) { axiom . delauth . token . TokenGenerator generator = new axiom . delauth . token . TokenGenerator ( ) ; final java . lang . String USERNAME = "testUsername" ; final java . lang . String TOKEN = generator . generateToken ( USERNAME ) ; "<AssertPlaceHolder>" ; } generateToken ... | org . junit . Assert . assertNotNull ( TOKEN ) |
testDoDestroy ( ) { control . bind ( session ) ; control . doDestroy ( ) ; "<AssertPlaceHolder>" ; } getGridPanel ( ) { return ( ( org . kie . workbench . common . dmn . client . widgets . panel . DMNGridPanelControl ) ( getSession ( ) . getCanvasControl ( org . kie . workbench . common . dmn . client . widgets . panel... | org . junit . Assert . assertNull ( control . getGridPanel ( ) ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.