input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
saleVisaReceivesNetworkTransactionIdentifier ( ) { com . braintreegateway . integrationtest . TransactionRequest request = new com . braintreegateway . integrationtest . TransactionRequest ( ) . amount ( new java . math . BigDecimal ( "10.00" ) ) . creditCard ( ) . number ( CreditCardNumber . VISA . number ) . expirati... | org . junit . Assert . assertTrue ( ( ( transaction . getNetworkTransactionId ( ) . length ( ) ) > 0 ) ) |
fillOpacitySetWithNoneFillRGBA ( ) { com . itextpdf . svg . renderers . impl . AbstractSvgNodeRenderer renderer = new com . itextpdf . svg . renderers . impl . CircleSvgNodeRenderer ( ) ; renderer . setAttribute ( SvgConstants . Attributes . FILL_OPACITY , "0.75" ) ; renderer . setAttribute ( SvgConstants . Attributes ... | org . junit . Assert . assertTrue ( resources . getResourceNames ( ) . isEmpty ( ) ) |
testDefaultTemplate ( ) { org . revapi . reporter . text . TextReporter reporter = new org . revapi . reporter . text . TextReporter ( ) ; org . revapi . Revapi r = new org . revapi . Revapi ( org . revapi . PipelineConfiguration . builder ( ) . withReporters ( org . revapi . reporter . text . TextReporter . class ) . ... | org . junit . Assert . assertEquals ( expected , out . toString ( ) ) |
testListResourcesCostCategoryAssignments ( ) { int previous = resourcesCostCategoryAssignmentDAO . list ( org . libreplan . business . costcategories . entities . ResourcesCostCategoryAssignment . class ) . size ( ) ; org . libreplan . business . costcategories . entities . ResourcesCostCategoryAssignment assignment = ... | org . junit . Assert . assertEquals ( ( previous + 1 ) , list . size ( ) ) |
getMountTable ( ) { java . util . Map < java . lang . String , alluxio . master . file . meta . options . MountInfo > mountTable = new java . util . HashMap ( 2 ) ; mountTable . put ( "/mnt/foo" , new alluxio . master . file . meta . options . MountInfo ( new alluxio . AlluxioURI ( "/mnt/foo" ) , new alluxio . AlluxioU... | org . junit . Assert . assertEquals ( mountTable , mMountTable . getMountTable ( ) ) |
testMetaOp4 ( ) { org . nd4j . linalg . api . ndarray . INDArray array1 = org . nd4j . linalg . factory . Nd4j . create ( new float [ ] { 1.0F , 1.0F , 1.0F , 1.0F , 1.0F , 1.0F , 1.0F } ) ; org . nd4j . linalg . api . ndarray . INDArray exp = org . nd4j . linalg . factory . Nd4j . create ( new float [ ] { 2.0F , 2.0F ... | org . junit . Assert . assertEquals ( exp , res ) |
emptyInputShouldNotPass ( ) { eu . inmite . android . lib . validations . FormsValidatorWithConditionTest . ModelWithPassingConditionValidation model = new eu . inmite . android . lib . validations . FormsValidatorWithConditionTest . ModelWithPassingConditionValidation ( org . robolectric . Robolectric . application ) ... | org . junit . Assert . assertFalse ( result ) |
test_ancestor_count ( ) { java . util . Map < org . openrdf . model . URI , java . lang . Integer > nbAncestors = engine . getAllNbAncestorsInc ( ) ; for ( org . openrdf . model . URI v : graph . getV ( ) ) { java . util . Set < org . openrdf . model . URI > ancestorsURIsExpected = ancestors . get ( v ) ; System . out ... | org . junit . Assert . assertTrue ( ( ( ancestorsURIsExpected . size ( ) ) == ( nbAncestors . get ( v ) ) ) ) |
testShouldCallAConstructorTakingACapabilitiesArgInPreferenceToANoArgOne ( ) { org . openqa . selenium . Capabilities caps = new org . openqa . selenium . ImmutableCapabilities ( org . openqa . selenium . remote . CapabilityType . BROWSER_NAME , "example" ) ; factory . registerDriverProvider ( new org . openqa . seleniu... | org . junit . Assert . assertEquals ( caps , driver . getCapabilities ( ) ) |
getJoinedFolderFileAndDeeperRightFolder ( ) { java . io . File folder = org . apache . maven . shared . project . utils . ProjectUtilsTest . ROOT_FOLDER ; java . io . File lhsFolder = new java . io . File ( folder , "pom.xml" ) ; java . io . File rhsFolder = new java . io . File ( folder , "src" ) ; "<AssertPlaceHolder... | org . junit . Assert . assertEquals ( folder , org . apache . maven . shared . project . utils . ProjectUtils . getJoinedFolder ( lhsFolder , rhsFolder ) ) |
exhaustive ( ) { int size = 8 ; java . util . List < au . edu . wehi . idsv . graph . RectangleGraphNode > nodes = new java . util . ArrayList < au . edu . wehi . idsv . graph . RectangleGraphNode > ( ) ; for ( int startx = 0 ; startx < size ; startx ++ ) { for ( int endx = startx ; endx < size ; endx ++ ) { for ( int ... | org . junit . Assert . assertEquals ( ( size * size ) , cliques . length ) |
serialize_shouldReturnTheUuidOfTheObject ( ) { org . openmrs . OpenmrsObject location = new org . openmrs . Location ( ) ; java . lang . String expectedUuid = "some<sp>uuid" ; location . setUuid ( expectedUuid ) ; org . openmrs . customdatatype . datatype . BaseOpenmrsDatatype datatype = new org . openmrs . customdatat... | org . junit . Assert . assertEquals ( expectedUuid , datatype . serialize ( location ) ) |
isJMockitMockableType_A$String_true ( ) { org . junithelper . core . meta . ClassMeta classMeta = new org . junithelper . core . meta . ClassMeta ( ) ; classMeta . importedList . add ( "java.io.InputStream" ) ; org . junithelper . core . extractor . AvailableTypeDetector target = new org . junithelper . core . extracto... | org . junit . Assert . assertEquals ( expected , actual ) |
testHashBaseForItemAnswersIncludesAnswerOptionsRichTextInsteadOfAnswerOptionLabelsForExtendedMatchingItems ( ) { final org . sakaiproject . tool . assessment . data . dao . assessment . ItemData item = newExtendedMatchingItem ( ) ; item . setAnswerOptionsSimpleOrRich ( ItemDataIfc . ANSWER_OPTIONS_RICH ) ; expectServer... | org . junit . Assert . assertThat ( actualHashBase . toString ( ) , org . hamcrest . CoreMatchers . equalTo ( expectedHashBase . toString ( ) ) ) |
testNullCacheGetCacheReult ( ) { com . ewcms . common . query . Resultable result = query . setRow ( 20 ) . setPage ( 3 ) . queryCacheResult ( "testCacheKey" ) ; "<AssertPlaceHolder>" ; } getResultList ( ) { return resultList ; } | org . junit . Assert . assertEquals ( 20 , result . getResultList ( ) . size ( ) ) |
testGetInfo ( ) { final edu . illinois . library . cantaloupe . image . Identifier identifier = new edu . illinois . library . cantaloupe . image . Identifier ( "jpg" ) ; java . util . Optional < edu . illinois . library . cantaloupe . image . Info > expected = edu . illinois . library . cantaloupe . cache . InfoServic... | org . junit . Assert . assertEquals ( expected , actual ) |
testIsIncludePlaceGroups ( ) { System . out . println ( "isIncludePlaceGroups" ) ; mudmap2 . backend . legend . Legend instance = new mudmap2 . backend . legend . Legend ( layer , Legend . Orientation . HORIZONTAL , 500 ) ; "<AssertPlaceHolder>" ; } isIncludePlaceGroups ( ) { return includePlaceGroups ; } | org . junit . Assert . assertFalse ( instance . isIncludePlaceGroups ( ) ) |
testGenerateAnyFromDynAny ( ) { java . lang . String msg ; org . omg . CORBA . Any any = null ; org . omg . CORBA . TypeCode tc = null ; org . omg . DynamicAny . DynSequence dynAny = null ; org . omg . DynamicAny . DynSequence dynAny2 = null ; tc = org . jacorb . test . BoundedDataHelper . type ( ) ; dynAny = createDyn... | org . junit . Assert . assertTrue ( msg , dynAny . equal ( dynAny2 ) ) |
generateTrajectory_CorrectNumberOfSteps ( ) { double [ ] size = new double [ ] { 512 , 512 } ; de . biomedical_imaging . traJ . simulation . AnomalousDiffusionScene scene = new de . biomedical_imaging . traJ . simulation . AnomalousDiffusionScene ( size , 2 ) ; double diffusioncoefficient = 1 ; double timelag = 1 ; int... | org . junit . Assert . assertEquals ( numberOfSteps , ( ( t . size ( ) ) - 1 ) ) |
trimsAccessTokenWhenSettingIt ( ) { java . lang . String accessTokenWithoutWhitespace = "wuryew2347234987" ; profile . setAccessToken ( ( ( "\t" + accessTokenWithoutWhitespace ) + "<sp>\n" ) ) ; "<AssertPlaceHolder>" ; } getAccessToken ( ) { return configuration . getAccessToken ( ) ; } | org . junit . Assert . assertThat ( profile . getAccessToken ( ) , org . hamcrest . core . Is . is ( accessTokenWithoutWhitespace ) ) |
testBuild ( ) { org . lnu . is . domain . department . name . DepartmentName context = new org . lnu . is . domain . department . name . DepartmentName ( ) ; java . lang . String expectedQuery = "SELECT<sp>e<sp>FROM<sp>DepartmentName<sp>e<sp>WHERE<sp>e.status=:status<sp>AND<sp>e.crtUserGroup<sp>IN<sp>(:userGroups)<sp>"... | org . junit . Assert . assertEquals ( expectedQuery , actualQuery ) |
testDeletePipelineConfirmYesAndFailed ( ) { preparePipelineDelete ( ) ; org . guvnor . ala . ui . model . PipelineExecutionTraceKey currentKey = trace . getKey ( ) ; doThrow ( new java . lang . RuntimeException ( org . guvnor . ala . ui . client . provider . status . runtime . RuntimePresenterActionsTest . ERROR_MESSAG... | org . junit . Assert . assertEquals ( org . guvnor . ala . ui . client . provider . status . runtime . RuntimePresenterActionsTest . ERROR_MESSAGE , exceptionCaptor . getValue ( ) . getMessage ( ) ) |
testFunctionWithDefaultAndRestMetadata ( ) { java . lang . String script = "remote<sp>User<sp>function<sp>getUser(numeric<sp>userid=\"default\"<sp>restargsource=\"Path\")<sp>httpmethod=\"GET\"<sp>restpath=\"{userid}\"<sp>{}" ; cfml . CFSCRIPTParser . ScriptBlockContext scriptStatement = parseScript ( script ) ; if ( ( ... | org . junit . Assert . assertNotNull ( scriptStatement ) |
dereference_completed ( ) { final java . util . concurrent . CompletionStage < java . lang . String > future = completedFuture ( "hello" ) ; final java . util . concurrent . CompletionStage < java . lang . String > dereferenced = com . spotify . futures . CompletableFutures . dereference ( completedFuture ( future ) ) ... | org . junit . Assert . assertThat ( dereferenced , com . spotify . futures . CompletableFuturesTest . completesTo ( "hello" ) ) |
testLambdaAsFunction05 ( ) { javax . el . ELProcessor processor = new javax . el . ELProcessor ( ) ; java . lang . Object result = processor . getValue ( "v<sp>=<sp>(()->y->()->x->x-y);<sp>v()(1)()(2)" , org . apache . el . parser . Integer . class ) ; "<AssertPlaceHolder>" ; } valueOf ( int ) { return org . apache . t... | org . junit . Assert . assertEquals ( java . lang . Integer . valueOf ( 1 ) , result ) |
testHeaderAcceptLanguage ( ) { request . setHeaderAcceptLanguage ( "language" ) ; "<AssertPlaceHolder>" ; } getHeaderAcceptLanguage ( ) { return ( ( java . lang . String ) ( getParameter ( org . piwik . java . tracking . PiwikRequest . HEADER_ACCEPT_LANGUAGE ) ) ) ; } | org . junit . Assert . assertEquals ( "language" , request . getHeaderAcceptLanguage ( ) ) |
testGeenWijzigingen ( ) { nl . bzk . brp . levering . lo3 . conversie . mutatie . MutatieCategorie01IntegratieTest . LOG . info ( "testGeenWijzigingen" ) ; final nl . bzk . brp . domain . leveringmodel . MetaObject persoonMetaObject = maakBasisPersoon ( 5001 ) ; final nl . bzk . brp . domain . leveringmodel . Administr... | org . junit . Assert . assertEquals ( 0 , resultaat . size ( ) ) |
testVertexIterator ( ) { org . apache . tinkerpop . gremlin . structure . Vertex a = this . sqlgGraph . addVertex ( ) ; org . apache . tinkerpop . gremlin . structure . Vertex b = this . sqlgGraph . addVertex ( ) ; org . apache . tinkerpop . gremlin . structure . Vertex c = this . sqlgGraph . addVertex ( ) ; org . apac... | org . junit . Assert . assertEquals ( 8 , vertexes . size ( ) ) |
flatMap_A$Function1 ( ) { com . m3 . scalaflavor4j . None < java . lang . String > target = new com . m3 . scalaflavor4j . None < java . lang . String > ( ) ; com . m3 . scalaflavor4j . F1 < java . lang . String , com . m3 . scalaflavor4j . Option < java . lang . Integer > > f = new com . m3 . scalaflavor4j . F1 < java... | org . junit . Assert . assertNull ( actual . getOrNull ( ) ) |
hasStreamInherited ( ) { org . apache . olingo . commons . api . edm . provider . CsdlEdmProvider provider = mock ( org . apache . olingo . commons . api . edm . provider . CsdlEdmProvider . class ) ; org . apache . olingo . commons . core . edm . EdmProviderImpl edm = new org . apache . olingo . commons . core . edm .... | org . junit . Assert . assertTrue ( typeWithBaseTypeWithStream . hasStream ( ) ) |
testMonitoringSourceRestore ( ) { java . io . File testFolder = org . apache . flink . hdfstests . ContinuousFileProcessingMigrationTest . tempFolder . newFolder ( ) ; org . apache . flink . api . java . io . TextInputFormat format = new org . apache . flink . api . java . io . TextInputFormat ( new org . apache . flin... | org . junit . Assert . assertEquals ( ( ( long ) ( expectedModTime ) ) , monitoringFunction . getGlobalModificationTime ( ) ) |
getLongRunningTasksWrappedFutureTest ( ) { final org . threadly . concurrent . statistics . NoThreadSchedulerStatisticTracker scheduler = new org . threadly . concurrent . statistics . NoThreadSchedulerStatisticTracker ( ) ; scheduler . submit ( new org . threadly . concurrent . statistics . ClockUpdateRunnable ( ) { @... | org . junit . Assert . assertTrue ( ( ( scheduler . getLongRunningTasks ( ( - 1 ) ) . get ( 0 ) . getLeft ( ) ) == ( this ) ) ) |
testCreateFieldByType ( ) { final org . kie . workbench . common . dmn . client . property . dmn . QNameFieldDefinition definition1 = provider . createFieldByType ( typeInfo ) ; final org . kie . workbench . common . dmn . client . property . dmn . QNameFieldDefinition definition2 = provider . createFieldByType ( typeI... | org . junit . Assert . assertFalse ( definition1 . equals ( definition2 ) ) |
complementIfPastWindow ( ) { net . time4j . range . IntervalCollection < net . time4j . PlainDate > coll = net . time4j . range . IntervalCollection . onDateAxis ( ) . plus ( net . time4j . range . DateInterval . parseISO ( "2011-01-01/2013-12-31" ) ) . plus ( net . time4j . range . DateInterval . parseISO ( "2014-06-3... | org . junit . Assert . assertThat ( coll . withComplement ( window ) , org . hamcrest . CoreMatchers . is ( expected ) ) |
testUndirected ( ) { org . gradoop . flink . util . FlinkAsciiGraphLoader loader = new org . gradoop . flink . util . FlinkAsciiGraphLoader ( getConfig ( ) ) ; loader . initDatabaseFromFile ( getFilePath ( "/data/gdl/cam_test.gdl" ) ) ; org . gradoop . flink . model . impl . epgm . GraphCollection g = loader . getGraph... | org . junit . Assert . assertEquals ( expectation , result ) |
testParentColumnNames ( ) { try { java . lang . String [ ] columnNames = getAllColumnNames ( com . ctrip . platform . dal . dao . helper . EntityManagerTest . Entity . Inheritance . Parent . class ) ; java . util . List < java . lang . String > actualColumnNames = java . util . Arrays . asList ( columnNames ) ; java . ... | org . junit . Assert . assertEquals ( actualColumnNames , expectedColumnNames ) |
testAromatizeMolecule ( ) { java . lang . String rawMolSmiles = "C1=CC2=C(C=C1)C=CC=C2" ; org . openscience . cdk . smiles . SmilesParser sp = new org . openscience . cdk . smiles . SmilesParser ( org . openscience . cdk . DefaultChemObjectBuilder . getInstance ( ) ) ; org . openscience . cdk . interfaces . IAtomContai... | org . junit . Assert . assertEquals ( 5 , count ) |
testGetColumnName ( ) { java . util . List positions = mockPositions ( org . pentaho . platform . plugin . services . connections . mondrian . MDXMetaDataTest . COLUMN_SIZE , org . pentaho . platform . plugin . services . connections . mondrian . MDXMetaDataTest . ROW_SIZE ) ; mondrian . olap . Axis axColumn = mockAxis... | org . junit . Assert . assertEquals ( metadata . getRowHeaderNames ( ) [ 0 ] , columnName ) |
testIndicatieStaatLoosAlAanwezigMaarDagErvoor ( ) { final nl . bzk . brp . bijhouding . bericht . model . RegistratieNationaliteitActieElement actieElement = getRegistratieNationaliteitActieElement ( 19900101 , null , true ) ; final java . util . List < nl . bzk . brp . bijhouding . bericht . model . MeldingElement > m... | org . junit . Assert . assertEquals ( 0 , meldingElements . size ( ) ) |
kapuaUnmatchedChannelGetterSetters ( ) { org . eclipse . kapua . message . device . lifecycle . KapuaUnmatchedChannel kapuaUnmatchedChannel = new org . eclipse . kapua . message . internal . device . lifecycle . KapuaUnmatchedChannelImpl ( ) ; kapuaUnmatchedChannel . setClientId ( "clientId-1" ) ; "<AssertPlaceHolder>"... | org . junit . Assert . assertEquals ( "clientId-1" , kapuaUnmatchedChannel . getClientId ( ) ) |
testFloatCollectSet ( ) { io . cdap . cdap . api . data . schema . Schema schema = io . cdap . cdap . api . data . schema . Schema . recordOf ( "test" , Schema . Field . of ( "x" , io . cdap . cdap . api . data . schema . Schema . of ( Schema . Type . FLOAT ) ) ) ; io . cdap . plugin . batch . aggregator . function . C... | org . junit . Assert . assertEquals ( expectedSet , set ) |
certV1Creation ( ) { java . security . KeyPair keyPair = org . ebayopensource . fido . uaf . crypto . KeyCodec . generate ( ) ; java . security . cert . X509Certificate x509Certificate = org . ebayopensource . fido . uaf . crypto . X509 . generateV1Cert ( keyPair ) ; "<AssertPlaceHolder>" ; logger . info ( ( "V1<sp>:<s... | org . junit . Assert . assertNotNull ( x509Certificate ) |
testPerson_When_ReadLimitedToken_EmptyElement ( ) { org . orcid . core . utils . SecurityContextTestUtils . setUpSecurityContext ( org . orcid . core . manager . ORCID_1 , org . orcid . core . manager . CLIENT_1 , ScopePathType . PERSON_READ_LIMITED ) ; org . orcid . jaxb . model . record_v2 . Person p = new org . orci... | org . junit . Assert . assertNotNull ( p ) |
loadStreamConfNullOverrides ( ) { org . apache . distributedlog . DistributedLogConfiguration conf = new org . apache . distributedlog . DistributedLogConfiguration ( ) ; org . apache . distributedlog . DistributedLogConfiguration confClone = new org . apache . distributedlog . DistributedLogConfiguration ( ) ; com . g... | org . junit . Assert . assertTrue ( comp . compare ( conf , confClone ) ) |
testARinheritance3HomozygousOnly ( ) { java . util . ArrayList < jannovar . exome . Variant > lst = new java . util . ArrayList < jannovar . exome . Variant > ( ) ; jannovar . exome . Variant mg1 = constructGenotypeCall ( Genotype . HETEROZYGOUS , Genotype . HETEROZYGOUS , Genotype . HETEROZYGOUS , Genotype . HETEROZYG... | org . junit . Assert . assertEquals ( true , b ) |
generateNewTeradataQuery ( ) { connection = ConnectionFactory . eINSTANCE . createConnection ( ) ; node = org . mockito . Mockito . mock ( org . talend . core . model . process . INode . class ) ; connection . setContextMode ( true ) ; org . talend . cwm . relational . TdTable table = RelationalFactory . eINSTANCE . cr... | org . junit . Assert . assertEquals ( expectedQuery , queryString ) |
createEventBusMonitor ( ) { org . axonframework . monitoring . MessageMonitor < ? super org . axonframework . eventhandling . EventMessage < ? > > monitor = subject . registerEventBus ( "eventBus" ) ; monitor . onMessageIngested ( asEventMessage ( "test" ) ) . reportSuccess ( ) ; java . io . ByteArrayOutputStream out =... | org . junit . Assert . assertTrue ( output . contains ( "eventBus" ) ) |
testRemoveBindingNotFoundReadNext ( ) { com . sun . sgs . test . impl . service . data . store . BasicTxnIsolationTest . store . setBinding ( txn , "b" , 200 ) ; newTransaction ( ) ; com . sun . sgs . test . impl . service . data . store . BasicTxnIsolationTest . store . getBinding ( txn , "b" ) ; com . sun . sgs . tes... | org . junit . Assert . assertFalse ( ( ( java . lang . Boolean ) ( runner . getResult ( ) ) ) ) |
testListbyNameNone ( ) { java . util . List < uk . ac . bbsrc . tgac . miso . core . data . InstrumentModel > platforms = dao . listByPlatformType ( "Futurism" ) ; "<AssertPlaceHolder>" ; } size ( ) { return map . size ( ) ; } | org . junit . Assert . assertEquals ( 0 , platforms . size ( ) ) |
testUpdateConfigsWithModifyOperation ( ) { expect ( mockK8sApiConfigAdminService . apiConfig ( anyString ( ) ) ) . andReturn ( k8sApiConfig ) . once ( ) ; mockK8sApiConfigAdminService . updateApiConfig ( anyObject ( ) ) ; replay ( mockK8sApiConfigAdminService ) ; final javax . ws . rs . client . WebTarget wt = target (... | org . junit . Assert . assertThat ( status , org . hamcrest . Matchers . is ( 200 ) ) |
testValidateAssignmentWithFunctionOnParameter_InServer ( ) { java . lang . String sql = "EXEC<sp>pm1.vsp36(5)" ; org . teiid . query . metadata . QueryMetadataInterface metadata = org . teiid . query . unittest . RealMetadataFactory . example1Cached ( ) ; org . teiid . query . sql . lang . Command command = new org . t... | org . junit . Assert . assertEquals ( 0 , report . getItems ( ) . size ( ) ) |
get_NotExisting ( ) { java . lang . Long existingKey = java . lang . System . currentTimeMillis ( ) ; java . lang . String existingValue = "value" + existingKey ; cache . put ( existingKey , existingValue ) ; java . lang . Long key1 = existingKey + 1 ; "<AssertPlaceHolder>" ; } get ( K ) { return writtenKeys . get ( ke... | org . junit . Assert . assertNull ( cache . get ( key1 ) ) |
AccessClassVariableConstant ( ) { java . lang . String fromClass = "Domain.Direct.Violating.AccessClassVariableConstant" ; java . lang . String toClass = "Technology.Direct.Dao.UserDAO" ; java . util . ArrayList < java . lang . String > typesToFind = new java . util . ArrayList < java . lang . String > ( ) ; typesToFin... | org . junit . Assert . assertTrue ( areDependencyTypesDetected ( fromClass , toClass , typesToFind , false ) ) |
testDateRangeQuery1 ( ) { lemongrenade . core . database . mongo . Calendar calStart = lemongrenade . core . database . mongo . GregorianCalendar . getInstance ( ) ; calStart . add ( Calendar . DAY_OF_YEAR , ( - 26 ) ) ; lemongrenade . core . database . mongo . Calendar calEnd = lemongrenade . core . database . mongo .... | org . junit . Assert . assertFalse ( lookInList ( jobs1 , j . getJobId ( ) ) ) |
testIncludedDataEnabledTroughSettings ( ) { converter . disableSerializationOption ( SerializationFeature . INCLUDE_RELATIONSHIP_ATTRIBUTES ) ; com . github . jasminb . jsonapi . JSONAPIDocument < com . github . jasminb . jsonapi . models . User > document = createDocument ( createUser ( ) ) ; com . github . jasminb . ... | org . junit . Assert . assertNotNull ( status . getContent ( ) ) |
shouldConcatNoneAndNoneToNone ( ) { "<AssertPlaceHolder>" ; } none ( ) { return org . dcache . pool . assumption . Assumptions . UNRESTRICTED ; } | org . junit . Assert . assertThat ( org . dcache . pool . assumption . Assumptions . none ( ) . and ( org . dcache . pool . assumption . Assumptions . none ( ) ) , org . hamcrest . CoreMatchers . is ( org . dcache . pool . assumption . Assumptions . none ( ) ) ) |
testDynamicQueryByProjectionMissing ( ) { com . liferay . portal . kernel . dao . orm . DynamicQuery dynamicQuery = com . liferay . portal . kernel . dao . orm . DynamicQueryFactoryUtil . forClass ( com . liferay . wiki . model . WikiPage . class , _dynamicQueryClassLoader ) ; dynamicQuery . setProjection ( com . lifer... | org . junit . Assert . assertEquals ( 0 , result . size ( ) ) |
testCheckDirString ( ) { java . lang . String ret = datawave . common . io . Files . checkDir ( "file" ) ; "<AssertPlaceHolder>" ; } checkDir ( java . lang . String ) { return datawave . common . io . Files . checkDir ( dir , false ) ; } | org . junit . Assert . assertNull ( ret ) |
testComp_VEVENT ( ) { try { com . github . caldav4j . util . GenerateQueryTest . log . info ( "Comp:<sp>VEVENT" ) ; com . github . caldav4j . util . GenerateQuery gq = new com . github . caldav4j . util . GenerateQuery ( ) ; gq . setComponent ( Component . VEVENT ) ; com . github . caldav4j . util . GenerateQueryTest .... | org . junit . Assert . assertTrue ( false ) |
findOldestUserAssignmentForPeriod_NoAssignment ( ) { java . util . List < org . oscm . billingservice . business . calculation . revenue . model . UserAssignment > userAssignments = new java . util . ArrayList < org . oscm . billingservice . business . calculation . revenue . model . UserAssignment > ( ) ; org . oscm .... | org . junit . Assert . assertNull ( result ) |
writesStreamingOutputToOutputStream ( ) { javax . ws . rs . core . StreamingOutput streamingOutput = mock ( javax . ws . rs . core . StreamingOutput . class ) ; java . io . ByteArrayOutputStream out = new java . io . ByteArrayOutputStream ( ) ; byte [ ] streamingOutputContent = "streaming<sp>output" . getBytes ( ) ; do... | org . junit . Assert . assertArrayEquals ( streamingOutputContent , out . toByteArray ( ) ) |
shouldAddTermsFromRedisOnZrevrangebyscoreCommandWithCustomRange ( ) { when ( localParamsMock . get ( "command" ) ) . thenReturn ( "command" 0 ) ; when ( localParamsMock . get ( "key" ) ) . thenReturn ( "simpleKey" ) ; when ( localParamsMock . get ( "min" ) ) . thenReturn ( "1" ) ; when ( localParamsMock . get ( "max" )... | org . junit . Assert . assertEquals ( 2 , terms . size ( ) ) |
testFileResourceGetChildReturnsNull ( ) { java . io . File file = java . io . File . createTempFile ( "fileresourcetest" , ".tmp" ) ; file . deleteOnExit ( ) ; org . jboss . forge . addon . resource . FileResource < ? > fileResource = resourceFactory . create ( org . jboss . forge . addon . resource . FileResource . cl... | org . junit . Assert . assertNull ( fileResource . getChild ( "foo" ) ) |
properlyBuildsCommand ( ) { util . CommandBuilder cb = new util . CommandBuilder ( ) ; cb . setCommand ( "wow" ) . addParam ( "--foo" , "v1" ) . addParam ( "--bar" ) . addParam ( "--baz" , 123 ) ; java . lang . String [ ] expectedParams = new java . lang . String [ ] { "wow" , "--foo" , "v1" , "--bar" , "--baz" , "123"... | org . junit . Assert . assertArrayEquals ( expectedParams , cb . build ( ) ) |
testNotEmptyCollectionWithParameterNull ( ) { com . twelvemonkeys . lang . Set < java . lang . Byte > collection = com . twelvemonkeys . lang . Collections . singleton ( ( ( byte ) ( 1 ) ) ) ; "<AssertPlaceHolder>" ; } notEmpty ( T extends com . twelvemonkeys . lang . CharSequence , java . lang . String ) { if ( ( ( pP... | org . junit . Assert . assertSame ( collection , com . twelvemonkeys . lang . Validate . notEmpty ( collection , null ) ) |
testBitwiseOrIntegerLong ( ) { long expected = 7L ; long actual = cFunction . bitwiseOr ( 5 , 3L ) ; "<AssertPlaceHolder>" ; } bitwiseOr ( java . lang . Integer , java . lang . Long ) { return l1 | l2 ; } | org . junit . Assert . assertEquals ( expected , actual ) |
test12 ( ) { java . lang . String usuario = "Teste1" ; java . lang . String operacao = "Teste2" ; java . lang . String recurso = "Teste3" ; java . lang . String expResult = "O<sp>usurio<sp>no<sp>possui<sp>permisso<sp>para<sp>executar<sp>a<sp>ao<sp>Teste1<sp>no<sp>recurso<sp>Teste2" ; java . lang . String result = insta... | org . junit . Assert . assertEquals ( expResult , result ) |
testGetParametersWithDefaultEntityAndDisabledDefaults ( ) { unit . setActive ( false ) ; unit . setSecurity ( false ) ; org . lnu . is . domain . street . type . StreetType entity = new org . lnu . is . domain . street . type . StreetType ( ) ; java . util . Map < java . lang . String , java . lang . Object > expected ... | org . junit . Assert . assertEquals ( expected , actual ) |
testIsGuidedDecisionTableEditableWhenDecisionTableIsNotEditable ( ) { final org . drools . workbench . screens . guided . dtable . client . widget . table . GuidedDecisionTableView . Presenter dtPresenter = mock ( GuidedDecisionTableView . Presenter . class ) ; final org . drools . workbench . screens . guided . dtable... | org . junit . Assert . assertFalse ( isGuidedDecisionTableEditable ) |
shouldFindNextCharacterAfterOpenBracket ( ) { int position = edu . stanford . bmir . protege . web . shared . entity . EntityNameUtils . indexOfWord ( "xx(x" , 1 ) ; "<AssertPlaceHolder>" ; } indexOfWord ( java . lang . String , int ) { checkNotNull ( entityName , "Input<sp>string<sp>must<sp>not<sp>be<sp>null" ) ; int ... | org . junit . Assert . assertEquals ( 3 , position ) |
shouldDefaultToSingletonGraph ( ) { final uk . gov . gchq . gaffer . rest . factory . DefaultGraphFactory factory = new uk . gov . gchq . gaffer . rest . factory . DefaultGraphFactory ( ) ; final boolean isSingleton = factory . isSingletonGraph ( ) ; "<AssertPlaceHolder>" ; } isSingletonGraph ( ) { return singletonGrap... | org . junit . Assert . assertTrue ( isSingleton ) |
getSetLastModified ( ) { java . util . Date expected = new java . util . Date ( ) ; com . microsoft . windowsazure . services . media . models . AccessPolicyInfo policy = new com . microsoft . windowsazure . services . media . models . AccessPolicyInfo ( null , new com . microsoft . windowsazure . services . media . im... | org . junit . Assert . assertEquals ( expected , actual ) |
shouldParseIsoDateWithZuluTimeZone ( ) { java . util . Date date = now ( ) ; value = JsonReader . DATE_VALUE_MATCHER . parseValue ( org . modeshape . schematic . document . Bson . getDateFormatter ( ) . format ( date ) ) ; "<AssertPlaceHolder>" ; } getDateFormatter ( ) { java . lang . ref . SoftReference < java . text ... | org . junit . Assert . assertTrue ( ( ( value ) instanceof java . util . Date ) ) |
testSerialization ( ) { org . jfree . chart . renderer . xy . StandardXYItemRenderer r1 = new org . jfree . chart . renderer . xy . StandardXYItemRenderer ( ) ; org . jfree . chart . renderer . xy . StandardXYItemRenderer r2 = ( ( org . jfree . chart . renderer . xy . StandardXYItemRenderer ) ( org . jfree . chart . Te... | org . junit . Assert . assertEquals ( r1 , r2 ) |
areSame_sameInstance ( ) { final java . net . URI uri = java . net . URI . create ( "http://one.example.com" ) ; "<AssertPlaceHolder>" ; } areSame ( java . net . URI , java . net . URI ) { if ( a == null ) { return b == null ; } if ( b == null ) { return false ; } if ( ! ( hudson . plugins . tfs . util . StringHelper .... | org . junit . Assert . assertTrue ( hudson . plugins . tfs . util . UriHelper . areSame ( uri , uri ) ) |
shouldReturnFalseIfIsReasonNeededWhenChangingStateToInterrupted ( ) { com . qcadoo . model . api . Entity parameter = mock ( com . qcadoo . model . api . Entity . class ) ; given ( parameterService . getParameter ( ) ) . willReturn ( parameter ) ; given ( parameter . getBooleanField ( com . qcadoo . mes . orders . REAS... | org . junit . Assert . assertFalse ( result ) |
extractSysType ( ) { java . util . Map < java . lang . String , java . lang . Object > typeDef = new java . util . HashMap < java . lang . String , java . lang . Object > ( ) ; try { org . searchisko . api . service . ProviderService . extractSysType ( typeDef , org . searchisko . api . service . ProviderServiceTest . ... | org . junit . Assert . assertEquals ( typeDef . get ( ProviderService . SYS_TYPE ) , org . searchisko . api . service . ProviderService . extractSysType ( typeDef , org . searchisko . api . service . ProviderServiceTest . TEST_TYPE_NAME ) ) |
testDataPointsRecoveryPTR ( ) { long ts = java . lang . System . currentTimeMillis ( ) ; java . util . List < com . srotya . sidewinder . core . rpc . Tag > tags = java . util . Arrays . asList ( com . srotya . sidewinder . core . rpc . Tag . newBuilder ( ) . setTagKey ( "test" ) . setTagValue ( "1" ) . build ( ) , com... | org . junit . Assert . assertEquals ( LIMIT , resultMap . size ( ) ) |
testDefaultFormatVector3D ( ) { java . util . Locale defaultLocal = java . util . Locale . getDefault ( ) ; java . util . Locale . setDefault ( getLocale ( ) ) ; org . apache . commons . math4 . geometry . euclidean . threed . Cartesian3D c = new org . apache . commons . math4 . geometry . euclidean . threed . Cartesia... | org . junit . Assert . assertEquals ( expected , actual ) |
allMatch ( ) { org . mule . runtime . api . message . ErrorType mockErrorType = mock ( org . mule . runtime . api . message . ErrorType . class ) ; when ( mockErrorType . getParentErrorType ( ) ) . thenReturn ( transformationErrorType ) ; org . mule . runtime . core . api . exception . ErrorTypeMatcher matcherWithTwoTr... | org . junit . Assert . assertThat ( matcherWithTwoTransformation . match ( mockErrorType ) , org . hamcrest . Matchers . is ( true ) ) |
shouldChangeStartTime ( ) { java . time . LocalTime time = entry . getStartTime ( ) . plusHours ( 1 ) ; entry . changeStartTime ( time ) ; "<AssertPlaceHolder>" ; } getStartTime ( ) { return ( startTime ) == null ? _startTime : startTime . get ( ) ; } | org . junit . Assert . assertThat ( entry . getStartTime ( ) , org . hamcrest . Matchers . is ( org . hamcrest . Matchers . equalTo ( time ) ) ) |
testCopyWithoutTargetDirectory ( ) { final org . uberfire . backend . vfs . Path expectedPath = mock ( org . uberfire . backend . vfs . Path . class ) ; doReturn ( expectedPath ) . when ( copyService ) . copy ( path , newFileName , comment ) ; final org . uberfire . backend . vfs . Path actualPath = htmlEditorService .... | org . junit . Assert . assertEquals ( expectedPath , actualPath ) |
testWindowDefnEquivalent ( ) { java . lang . String sqlText = java . lang . String . format ( ( "DENSE_RANK()<sp>OVER<sp>(ORDER<sp>BY<sp>SUM(amount)<sp>DESC)<sp>AS<sp>dense_rank\n" 2 + ( ( ( ( ( ( "prd_type_id,<sp>SUM(amount),\n" + "RANK()<sp>OVER<sp>(ORDER<sp>BY<sp>SUM(amount)<sp>DESC)<sp>AS<sp>rank,\n" ) + "DENSE_RAN... | org . junit . Assert . assertEquals ( ( ( "DENSE_RANK()<sp>OVER<sp>(ORDER<sp>BY<sp>SUM(amount)<sp>DESC)<sp>AS<sp>dense_rank\n" 0 + sqlText ) + "DENSE_RANK()<sp>OVER<sp>(ORDER<sp>BY<sp>SUM(amount)<sp>DESC)<sp>AS<sp>dense_rank\n" 0 ) , expected , TestUtils . FormattedResult . ResultFactory . toStringUnsorted ( rs ) ) |
testFooBar1 ( ) { java . lang . String className = com . examples . with . different . packagename . staticusage . FooBar1 . class . getName ( ) ; org . evosuite . setup . PutStaticMethodCollector collector = new org . evosuite . setup . PutStaticMethodCollector ( className ) ; org . evosuite . setup . PutStaticMethodC... | org . junit . Assert . assertEquals ( expected_methods , methods ) |
testPatternMatching1 ( ) { java . lang . String text = "blabla<sp>d<sp>is<sp>the<sp>word" ; java . lang . String pattern = "d" ; byte [ ] b2 = org . apache . james . mime4j . util . ContentUtil . toAsciiByteArray ( pattern ) ; org . apache . james . mime4j . io . BufferedLineReaderInputStream inbuffer = org . apache . ... | org . junit . Assert . assertEquals ( 7 , i ) |
equalsStop ( ) { org . apache . hadoop . fs . shell . find . Result one = org . apache . hadoop . fs . shell . find . Result . STOP ; org . apache . hadoop . fs . shell . find . Result two = Result . STOP . combine ( Result . STOP ) ; "<AssertPlaceHolder>" ; } combine ( org . apache . hadoop . fs . shell . find . Resul... | org . junit . Assert . assertEquals ( one , two ) |
testCoordinateDimensionPolygonLite3D ( ) { org . locationtech . jts . geom . Geometry geom = org . geotools . geometry . jts . coordinatesequence . CoordinateSequencesTest . liteGF . createPolygon ( org . geotools . geometry . jts . coordinatesequence . CoordinateSequencesTest . liteGF . createLinearRing ( org . geotoo... | org . junit . Assert . assertEquals ( 3 , org . geotools . geometry . jts . coordinatesequence . CoordinateSequences . coordinateDimension ( geom ) ) |
testMyExtension ( ) { try ( org . neo4j . harness . ServerControls server = getServerBuilder ( ) . withExtension ( "/myExtension" , org . neo4j . harness . doc . ExtensionTestingDocIT . MyUnmanagedExtension . class ) . newServer ( ) ) { org . neo4j . doc . server . HTTP . Response response = org . neo4j . doc . server ... | org . junit . Assert . assertEquals ( 200 , response . status ( ) ) |
getProcessDeploymentInfosWithActorOnlyForRole ( ) { final org . bonitasoft . engine . persistence . QueryOptions options = new org . bonitasoft . engine . persistence . QueryOptions ( 0 , 10 ) ; final java . util . List < org . bonitasoft . engine . core . process . definition . model . SProcessDefinitionDeployInfo > s... | org . junit . Assert . assertEquals ( sProcessDefinitionDeployInfos , processDeploymentInfos ) |
testCalendarCutoffWithStartedEvent ( ) { long currentTime = java . lang . System . currentTimeMillis ( ) ; java . util . Date startDate = new java . util . Date ( ( currentTime - ( 10 * 1000 ) ) ) ; java . util . Date endDate = new java . util . Date ( ( currentTime + ( ( 60 * 60 ) * 1000 ) ) ) ; org . opencastproject ... | org . junit . Assert . assertEquals ( 1 , events . size ( ) ) |
simple_updates ( ) { final java . lang . String rulebase = "rules/reloaded/test019.prova" ; java . util . concurrent . atomic . AtomicInteger count = new java . util . concurrent . atomic . AtomicInteger ( ) ; java . util . Map < java . lang . String , java . lang . Object > globals = new java . util . HashMap < java .... | org . junit . Assert . assertEquals ( 3 , count . get ( ) ) |
testDefaultFalse ( ) { com . hp . hpl . jena . rdf . model . Model config = getModelA ( "false" ) ; com . epimorphics . lda . metadata . MetaConfig mc = parseMetaConfig ( config ) ; "<AssertPlaceHolder>" ; } disableDefaultMetadata ( ) { return disableDefaultMetadata ; } | org . junit . Assert . assertEquals ( false , mc . disableDefaultMetadata ( ) ) |
name_equality ( ) { com . groupon . lex . metrics . timeseries . Alert alert1 = new com . groupon . lex . metrics . timeseries . Alert ( com . groupon . lex . metrics . timeseries . AlertTest . t_past , com . groupon . lex . metrics . timeseries . AlertTest . alert_name , ( ) -> "foo" , java . util . Optional . of ( tr... | org . junit . Assert . assertEquals ( alert1 , alert2 ) |
getPaths ( ) { java . util . List < java . net . URL > trackerPaths = java . util . Collections . singletonList ( new java . net . URL ( "http://www.last.fm/1/2" ) ) ; when ( mockTracker . getPaths ( fm . last . moji . impl . MojiFileImplTest . KEY , fm . last . moji . impl . MojiFileImplTest . DOMAIN ) ) . thenReturn ... | org . junit . Assert . assertThat ( paths , org . hamcrest . CoreMatchers . is ( trackerPaths ) ) |
testItShouldCountTwoMapsForTolueneOntoToluene ( ) { org . openscience . cdk . smsd . algorithm . vflib . interfaces . IMapper mapper = new org . openscience . cdk . smsd . algorithm . vflib . map . VFMapper ( toluene , true ) ; "<AssertPlaceHolder>" ; } countMaps ( org . openscience . cdk . smsd . algorithm . vflib . b... | org . junit . Assert . assertEquals ( 2 , mapper . countMaps ( toluene ) ) |
testGetObject ( ) { org . apache . rocketmq . jms . domain . message . JmsObjectMessage jmsObjectMessage = new org . apache . rocketmq . jms . domain . message . JmsObjectMessage ( new org . apache . rocketmq . jms . domain . message . JmsObjectMessageTest . User ( "jack" , 20 ) ) ; try { "<AssertPlaceHolder>" ; } catc... | org . junit . Assert . assertEquals ( jmsObjectMessage . getObject ( ) , new org . apache . rocketmq . jms . domain . message . JmsObjectMessageTest . User ( "jack" , 20 ) ) |
testGetFullPathSimpleField ( ) { com . redhat . lightblue . util . Path fullPath = getMD1 ( ) . resolve ( new com . redhat . lightblue . util . Path ( "obj1.nestedSimpleInteger" ) ) . getFullPath ( ) ; "<AssertPlaceHolder>" ; } getFullPath ( ) { return com . redhat . lightblue . util . Path . EMPTY ; } | org . junit . Assert . assertEquals ( new com . redhat . lightblue . util . Path ( "obj1.nestedSimpleInteger" ) , fullPath ) |
shouldInstrumentES6GeneratorDirect ( ) { java . lang . String source = "<sp>}\n" 3 + ( ( ( ( "<sp>while<sp>(start<sp><<sp>end)<sp>{\n" + "<sp>}\n" 4 ) + "<sp>start<sp>+=<sp>step;\n" ) + "<sp>}\n" 1 ) + "<sp>}\n" 0 ) ; java . lang . String instrumentedSource = sourceProcessor . instrumentSource ( source ) ; java . lang ... | org . junit . Assert . assertEquals ( expectedSource , instrumentedSource ) |
testMissingName ( ) { if ( ! ( org . postgresql . test . TestUtil . haveMinimumServerVersion ( con , ServerVersion . v9_0 ) ) ) { return ; } con . setClientInfo ( "ApplicationName" , "my<sp>app" ) ; con . setClientInfo ( new java . util . Properties ( ) ) ; java . lang . String applicationName = con . getClientInfo ( "... | org . junit . Assert . assertTrue ( ( ( "" . equals ( applicationName ) ) || ( applicationName == null ) ) ) |
manyClientsMemoryTest ( ) { java . util . ArrayList < org . threadly . concurrent . future . ListenableFuture < ? > > lfl = new java . util . ArrayList < org . threadly . concurrent . future . ListenableFuture < ? > > ( ) ; for ( int i = 0 ; i < 100 ; i ++ ) { org . threadly . litesockets . TCPClient tc = SE . createTC... | org . junit . Assert . assertEquals ( 200 , SE . getClientCount ( ) ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.