input
stringlengths
28
18.7k
output
stringlengths
39
1.69k
hasAnyBranchPermission ( ) { when ( permissionEvaluator . hasAnyBranchPermission ( authentication , "project" , Permission . EDIT_PAGE ) ) . thenReturn ( true ) ; "<AssertPlaceHolder>" ; } hasAnyBranchPermission ( java . lang . String , de . blizzy . documentr . access . Permission ) { return permissionEvaluator . hasA...
org . junit . Assert . assertTrue ( root . hasAnyBranchPermission ( "project" , Permission . EDIT_PAGE ) )
testApiMisuse4_3 ( ) { "<AssertPlaceHolder>" ; } format ( org . ocpsoft . prettytime . Duration ) { return ( duration . getQuantityRounded ( 50 ) ) + "<sp>minut" ; }
org . junit . Assert . assertEquals ( t . format ( new java . util . Date ( ) ) , t . format ( ( ( java . util . List < org . ocpsoft . prettytime . Duration > ) ( null ) ) ) )
testColumnManagementGroupTitleWorkItemSetFieldEmpty ( ) { final org . drools . workbench . models . guided . dtable . shared . model . ActionWorkItemSetFieldCol52 column = mock ( org . drools . workbench . models . guided . dtable . shared . model . ActionWorkItemSetFieldCol52 . class ) ; doReturn ( org . drools . work...
org . junit . Assert . assertEquals ( org . drools . workbench . screens . guided . dtable . client . wizard . column . pages . common . DecisionTableColumnViewUtilsTest . COLUMN_HEADER , org . drools . workbench . screens . guided . dtable . client . wizard . column . pages . common . DecisionTableColumnViewUtils . ge...
testFormatLogMessage_code_and_message_is_notnull ( ) { java . lang . String code = "code" ; java . lang . String message = "message" ; java . lang . String actualLogMessage = testTarget . formatLogMessage ( code , message ) ; java . lang . String expectedLogMessage = ( ( "[" + code ) + "]<sp>" ) + message ; "<AssertPla...
org . junit . Assert . assertThat ( actualLogMessage , org . hamcrest . CoreMatchers . is ( expectedLogMessage ) )
getRealm ( ) { com . ibm . websphere . simplicity . log . Log . info ( com . ibm . ws . security . wim . adapter . ldap . fat . URAPIs_ADWildCardTest . c , "getRealm" , "Checking<sp>expected<sp>realm" ) ; "<AssertPlaceHolder>" ; } getRealm ( ) { com . ibm . websphere . simplicity . log . Log . info ( com . ibm . ws . s...
org . junit . Assert . assertEquals ( "SampleLdapADRealm" , com . ibm . ws . security . wim . adapter . ldap . fat . URAPIs_ADWildCardTest . servlet . getRealm ( ) )
testWithTimeAllowed ( ) { org . springframework . data . solr . core . SimpleQuery query = new org . springframework . data . solr . core . SimpleQuery ( new org . springframework . data . solr . core . SimpleStringCriteria ( "field_1:value_1" ) ) ; query . setTimeAllowed ( 100 ) ; org . apache . solr . client . solrj ...
org . junit . Assert . assertEquals ( new java . lang . Integer ( 100 ) , solrQuery . getTimeAllowed ( ) )
testReplaceIpForVNCInDesc ( ) { final java . lang . String xmlDesc = "transformation<sp>does<sp>not<sp>live<sp>up<sp>to<sp>expectation:\n" 0 + ( ( ( ( ( "<sp><devices>" + "<sp><graphics<sp>type='vnc'<sp>port='5900'<sp>autoport='yes'<sp>listen='10.10.10.1'>" ) + "<sp><listen<sp>type='address'<sp>address='10.10.10.1'/>" ...
org . junit . Assert . assertTrue ( ( "transformation<sp>does<sp>not<sp>live<sp>up<sp>to<sp>expectation:\n" + result ) , expectedXmlDesc . equals ( result ) )
collectPromises ( ) { io . trane . future . Promise < java . lang . Integer > p1 = io . trane . future . Promise . apply ( ) ; io . trane . future . Promise < java . lang . Integer > p2 = io . trane . future . Promise . apply ( ) ; io . trane . future . Promise < java . lang . Integer > p3 = io . trane . future . Promi...
org . junit . Assert . assertArrayEquals ( expected , result )
testAddPhaseListener_twice ( ) { org . eclipse . rap . rwt . internal . lifecycle . PhaseListener phaseListener = new org . eclipse . rap . rwt . internal . lifecycle . PhaseListenerManager_Test . EmptyPhaseListener ( ) ; phaseListenerManager . addPhaseListener ( phaseListener ) ; phaseListenerManager . addPhaseListene...
org . junit . Assert . assertEquals ( asList ( phaseListener ) , getPhaseListeners ( ) )
testSerialization ( ) { org . jfree . chart . renderer . xy . XYAreaRenderer r1 = new org . jfree . chart . renderer . xy . XYAreaRenderer ( ) ; java . io . ByteArrayOutputStream buffer = new java . io . ByteArrayOutputStream ( ) ; java . io . ObjectOutput out = new java . io . ObjectOutputStream ( buffer ) ; out . wri...
org . junit . Assert . assertEquals ( r1 , r2 )
testResolveModuleWithRootPath ( ) { final javax . enterprise . inject . spi . Bean moduleServiceBean = ( ( javax . enterprise . inject . spi . Bean ) ( beanManager . getBeans ( org . kie . workbench . common . services . shared . project . KieModuleService . class ) . iterator ( ) . next ( ) ) ) ; final javax . enterpr...
org . junit . Assert . assertNull ( result )
equalsAndHashCodeTest ( ) { org . apache . apex . malhar . lib . dimensions . DimensionsDescriptor ddA = new org . apache . apex . malhar . lib . dimensions . DimensionsDescriptor ( new org . apache . apex . malhar . lib . appdata . schemas . CustomTimeBucket ( org . apache . apex . malhar . lib . appdata . schemas . T...
org . junit . Assert . assertTrue ( ddB . equals ( ddA ) )
testNoMatch ( ) { org . jacoco . core . internal . analysis . ClassCoverageImpl node = new org . jacoco . core . internal . analysis . ClassCoverageImpl ( "Sample" , 12345 , true ) ; "<AssertPlaceHolder>" ; } isNoMatch ( ) { return noMatch ; }
org . junit . Assert . assertTrue ( node . isNoMatch ( ) )
testClusterFromKafka ( ) { io . strimzi . operator . user . model . acl . SimpleAclRuleResource strimzi = new io . strimzi . operator . user . model . acl . SimpleAclRuleResource ( "kafka-cluster" , SimpleAclRuleResourceType . CLUSTER , io . strimzi . api . kafka . model . AclResourcePatternType . LITERAL ) ; kafka . s...
org . junit . Assert . assertEquals ( strimzi , io . strimzi . operator . user . model . acl . SimpleAclRuleResource . fromKafkaResource ( kafka ) )
testDefaultFormatVector3D ( ) { java . util . Locale defaultLocal = java . util . Locale . getDefault ( ) ; java . util . Locale . setDefault ( getLocale ( ) ) ; org . apache . commons . math3 . geometry . euclidean . threed . Vector3D c = new org . apache . commons . math3 . geometry . euclidean . threed . Vector3D ( ...
org . junit . Assert . assertEquals ( expected , actual )
testIsSatisfied ( ) { org . apache . commons . math4 . genetics . FixedGenerationCount fgc = new org . apache . commons . math4 . genetics . FixedGenerationCount ( 20 ) ; int cnt = 0 ; org . apache . commons . math4 . genetics . Population pop = new org . apache . commons . math4 . genetics . Population ( ) { @ org . a...
org . junit . Assert . assertEquals ( 20 , cnt )
testBlasGemm5 ( ) { if ( org . nd4j . linalg . factory . Nd4j . getExecutioner ( ) . getClass ( ) . getSimpleName ( ) . toLowerCase ( ) . contains ( "cuda" ) ) return ; lombok . val A = org . nd4j . linalg . factory . Nd4j . linspace ( 1 , 12 , 12 ) . reshape ( 'c' , 4 , 3 ) . dup ( 'f' ) ; lombok . val B = org . nd4j ...
org . junit . Assert . assertEquals ( exp , res )
testFindExact ( ) { for ( net . ripe . db . whois . common . ip . Ipv4Resource n : all ) { "<AssertPlaceHolder>" ; } } findExact ( net . ripe . db . whois . common . ip . IpInterval ) { if ( ipInterval instanceof net . ripe . db . whois . common . ip . Ipv4Resource ) { return ipv4Tree . findExact ( ( ( net . ripe . db ...
org . junit . Assert . assertThat ( subject . findExact ( n ) , contains ( n ) )
testLetExp01 ( ) { testpackage . Class1 class1 ; class1 = new testpackage . Class1 ( ) ; "<AssertPlaceHolder>" ; } testLetExp01 ( ) { testpackage . Class1 class1 ; class1 = new testpackage . Class1 ( ) ; org . junit . Assert . assertEquals ( new java . lang . Integer ( 42 ) , class1 . testLetExp01 ( ) ) ; }
org . junit . Assert . assertEquals ( new java . lang . Integer ( 42 ) , class1 . testLetExp01 ( ) )
testValue ( ) { mmarquee . automation . AutomationElement element = org . mockito . Mockito . mock ( mmarquee . automation . AutomationElement . class ) ; mmarquee . automation . pattern . Value value = org . mockito . Mockito . mock ( mmarquee . automation . pattern . Value . class ) ; when ( value . isAvailable ( ) )...
org . junit . Assert . assertTrue ( val . equals ( "VALUE" ) )
heterogeneousTest ( ) { org . organicdesign . fp . collections . RrbTree < java . lang . Object > rrb = org . organicdesign . fp . StaticImports . < java . lang . Object > rrb ( 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 1 , 2 ) . concat ( ...
org . junit . Assert . assertEquals ( list . get ( i ) , elem )
addWordHorizontalSuccesTest ( ) { this . crossword . addWord ( new de . unima . dws . semanta . crossword . model . HAWord ( new de . unima . dws . semanta . model . HAEntity ( null , "germany" , null , null , null ) ) , 0 , 0 , 6 , 0 ) ; "<AssertPlaceHolder>" ; } size ( ) { return words . size ( ) ; }
org . junit . Assert . assertEquals ( 1 , this . crossword . size ( ) )
testAddDropBasicColumnFamilyDefinition ( ) { me . prettyprint . cassandra . model . BasicColumnFamilyDefinition cfDef = new me . prettyprint . cassandra . model . BasicColumnFamilyDefinition ( ) ; cfDef . setName ( "DynCf" ) ; cfDef . setKeyspaceName ( "Keyspace1" ) ; cassandraCluster . addColumnFamily ( cfDef ) ; java...
org . junit . Assert . assertNotNull ( cfid2 )
testSQLDateMath ( ) { com . googlecode . cqengine . query . parser . sql . support . DateMathParser dateMathParser = new com . googlecode . cqengine . query . parser . sql . support . DateMathParser ( ) ; java . util . Date parsedDate = dateMathParser . validatedParse ( java . util . Date . class , "'+0DAY'" ) ; "<Asse...
org . junit . Assert . assertNotNull ( parsedDate )
incrementExistingSuffixWithTemporary ( ) { final java . util . Properties props = new java . util . Properties ( ) ; props . setProperty ( VersioningState . INCREMENT_SERIAL_SUFFIX_SYSPROP . getCurrent ( ) , "temporary-redhat" ) ; props . setProperty ( VersioningState . INCREMENT_SERIAL_SUFFIX_PADDING_SYSPROP . getCurr...
org . junit . Assert . assertThat ( result , org . hamcrest . CoreMatchers . equalTo ( v ) )
testKeyBuildingFromRowFamilyVisibilityBytes ( ) { org . apache . accumulo . core . data . Key keyBuilt = org . apache . accumulo . core . data . Key . builder ( ) . row ( rowBytes ) . family ( familyBytes ) . visibility ( visibilityBytes ) . build ( ) ; org . apache . accumulo . core . data . Key keyExpected = new org ...
org . junit . Assert . assertEquals ( keyExpected , keyBuilt )
testShaUpdateWithByteArray ( ) { final java . lang . String d1 = "C'est<sp>un<sp>homme<sp>qui<sp>rentre<sp>dans<sp>un<sp>caf,<sp>et<sp>plouf" ; final java . lang . String d2 = "C'est<sp>un<sp>homme,<sp>c'est<sp>qu'une<sp>tte,<sp>on<sp>lui<sp>offre<sp>un<sp>cadeau:<sp>'oh...<sp>encore<sp>un<sp>chapeau!'" ; java . securi...
org . junit . Assert . assertEquals ( expectedResult , actualResult )
getOperatorRevenueShare_MandatoryForTemplates ( ) { org . oscm . domobjects . Product product = givenProduct ( 101L ) ; doReturn ( product ) . when ( partnerBean . dm ) . getReference ( eq ( org . oscm . domobjects . Product . class ) , eq ( 101L ) ) ; doNothing ( ) . when ( partnerBean ) . verifyOwningPermission ( eq ...
org . junit . Assert . assertTrue ( e . getMessage ( ) . contains ( "Template<sp>without<sp>operator<sp>revenue<sp>share" ) )
testFluentInterfaceWithPassword ( ) { System . out . println ( "testFluentInterfaceWithPassword" ) ; team . bus . model . bean . DataBaseInfo instance = new team . bus . model . bean . DataBaseInfo ( ) ; java . lang . String expResult = "123456" ; instance . withPassword ( expResult ) ; java . lang . String result = in...
org . junit . Assert . assertEquals ( expResult , result )
testCalendar_CreateDate20121215_NotNull ( ) { int year = 2012 ; int month = 12 ; int day = 15 ; java . util . Date actual = info . michaelkohler . helpertools . date . CalendarHelper . date ( year , month , day ) ; "<AssertPlaceHolder>" ; } date ( int , int , int ) { info . michaelkohler . helpertools . tools . DateTim...
org . junit . Assert . assertNotNull ( actual )
testBasic2 ( ) { com . laytonsmith . core . constructs . CByteArray ba = new com . laytonsmith . core . constructs . CByteArray ( Target . UNKNOWN , 0 ) ; ba . putByte ( ( ( byte ) ( 1 ) ) , null ) ; ba . putByte ( ( ( byte ) ( 1 ) ) , null ) ; ba . putByte ( ( ( byte ) ( 1 ) ) , null ) ; "<AssertPlaceHolder>" ; } asBy...
org . junit . Assert . assertEquals ( 3 , ba . asByteArrayCopy ( ) . length )
Duplicate_Scalar_Values_Allowed ( ) { org . javersion . object . MapTest . Mab mab = new org . javersion . object . MapTest . Mab ( ) ; java . lang . Integer integer = 123 ; mab . primitives . put ( "eka" , integer ) ; mab . primitives . put ( "toka" , integer ) ; java . util . Map < org . javersion . path . PropertyPa...
org . junit . Assert . assertThat ( mab . primitives , org . hamcrest . Matchers . equalTo ( org . javersion . object . MapTest . map ( "eka" , integer , "toka" , integer ) ) )
testTimerStop ( ) { try { com . igumnov . common . Benchmark . timerStop ( ) ; } catch ( java . lang . Exception e ) { "<AssertPlaceHolder>" ; } } timerStop ( ) { return com . igumnov . common . Benchmark . timerStop ( com . igumnov . common . Benchmark . timerDefaultName ) ; }
org . junit . Assert . assertTrue ( true )
testNone ( ) { barrysw19 . calculon . engine . CompoundIterator < java . lang . String > iter = new barrysw19 . calculon . engine . CompoundIterator ( ) ; "<AssertPlaceHolder>" ; } hasNext ( ) { return ( ( iterators . length ) > 0 ) && ( ( iterators [ index ] . hasNext ( ) ) || ( ( ( ++ ( index ) ) < ( iterators . leng...
org . junit . Assert . assertFalse ( iter . hasNext ( ) )
testMaxFunctionQuantityTypeIncompatibleUnits ( ) { items . add ( createNumberItem ( "TestItem1" , javax . measure . quantity . Temperature . class , new org . eclipse . smarthome . core . library . types . QuantityType < javax . measure . quantity . Temperature > ( "23.54<sp>C" ) ) ) ; items . add ( createNumberItem ( ...
org . junit . Assert . assertEquals ( new org . eclipse . smarthome . core . library . types . QuantityType < javax . measure . quantity . Temperature > ( "23.54<sp>C" ) , state )
random_id ( ) { service = ( ( com . alibaba . citrus . service . requestcontext . impl . RequestContextChainingServiceImpl ) ( factory . getBean ( "rc2" ) ) ) ; com . alibaba . citrus . service . requestcontext . session . impl . SessionRequestContextFactoryImpl f = getFactory ( service , com . alibaba . citrus . servi...
org . junit . Assert . assertEquals ( 16 , rid . getLength ( ) )
instantiation ( ) { com . github . seratch . taskun . scheduler . crond . Crontab crontab = new com . github . seratch . taskun . scheduler . crond . Crontab ( ) ; "<AssertPlaceHolder>" ; }
org . junit . Assert . assertNotNull ( crontab )
testSimpleWithDecimalsTrunc ( ) { org . apache . commons . math . complex . Complex c = new org . apache . commons . math . complex . Complex ( 1.2323 , 1.4343 ) ; java . lang . String expected = ( ( ( "1" + ( getDecimalCharacter ( ) ) ) + "23<sp>+<sp>1" ) + ( getDecimalCharacter ( ) ) ) + "43i" ; java . lang . String ...
org . junit . Assert . assertEquals ( expected , actual )
testDocumentToIndexCollectionValueEmptyOne ( ) { final com . orientechnologies . orient . core . record . impl . ODocument document = new com . orientechnologies . orient . core . record . impl . ODocument ( ) ; document . field ( "fOne" , 12 ) ; document . field ( "fTwo" , com . orientechnologies . orient . core . ind...
org . junit . Assert . assertNull ( result )
testObserverIsAlwaysCheapForNullValues ( ) { org . apache . beam . sdk . coders . NullableCoder < java . util . List < java . lang . String > > coder = org . apache . beam . sdk . coders . NullableCoder . of ( org . apache . beam . sdk . coders . ListCoder . of ( org . apache . beam . sdk . coders . StringUtf8Coder . o...
org . junit . Assert . assertTrue ( coder . isRegisterByteSizeObserverCheap ( null ) )
testNoFailure ( ) { "<AssertPlaceHolder>" ; } failed ( ) { return ( ruleFailedException ) != null ; }
org . junit . Assert . assertFalse ( result . failed ( ) )
testStandalone ( ) { org . apache . camel . impl . JndiRegistry jndi = new org . apache . camel . impl . JndiRegistry ( true ) ; jndi . bind ( "bar" , "Hello<sp>bar" ) ; "<AssertPlaceHolder>" ; } lookupByName ( java . lang . String ) { try { return unwrap ( getContext ( ) . lookup ( name ) ) ; } catch ( javax . naming ...
org . junit . Assert . assertEquals ( "Hello<sp>bar" , jndi . lookupByName ( "bar" ) )
testDeclareExtendsMissingJavaParent ( ) { java . lang . String drl = "package<sp>org.drools.test;<sp>\n" + ( ( "import<sp>org.drools.compiler.integrationtests.ExtendsTest.Y;<sp>\n" + "declare<sp>Student<sp>extends<sp>Y<sp>end<sp>\n" ) + "" ) ; org . kie . internal . builder . KnowledgeBuilder kBuilder = org . kie . int...
org . junit . Assert . assertTrue ( kBuilder . hasErrors ( ) )
cloneAsVersionTest ( ) { final org . opendaylight . controller . cluster . access . commands . TransactionAbortRequest clone = org . opendaylight . controller . cluster . access . commands . TransactionAbortRequestTest . OBJECT . cloneAsVersion ( ABIVersion . BORON ) ; "<AssertPlaceHolder>" ; } cloneAsVersion ( org . o...
org . junit . Assert . assertEquals ( org . opendaylight . controller . cluster . access . commands . TransactionAbortRequestTest . OBJECT , clone )
testBuildWithDisabledStatusConstraintWithOrderBy ( ) { unit . setActive ( false ) ; org . lnu . is . domain . education . type . EducationType context = new org . lnu . is . domain . education . type . EducationType ( ) ; org . lnu . is . pagination . OrderBy orderBy1 = new org . lnu . is . pagination . OrderBy ( "abbr...
org . junit . Assert . assertEquals ( expected , actualQuery )
shouldCallNewMethodWhenDatabaseInterfaceIsOfANewType ( ) { org . pentaho . di . core . database . DatabaseInterfaceExtended databaseInterfaceNew = mock ( org . pentaho . di . core . database . DatabaseInterfaceExtended . class ) ; databaseMeta . setDatabaseInterface ( databaseInterfaceNew ) ; when ( databaseInterfaceNe...
org . junit . Assert . assertEquals ( org . pentaho . di . core . database . DatabaseMetaTest . DROP_STATEMENT , statement )
testFindNoType ( ) { java . util . Collection < org . eclipse . emf . ecore . EObject > others = org . eclipse . emf . edit . provider . ItemPropertyDescriptor . getReachableObjectsOfType ( otherItemObject , poClass ) ; "<AssertPlaceHolder>" ; } size ( ) { return ( primarySelection ) instanceof org . eclipse . jface . ...
org . junit . Assert . assertEquals ( others . size ( ) , 0 )
testGetParameters ( ) { org . lnu . is . multysearch . person . PersonList entity = new org . lnu . is . multysearch . person . PersonList ( ) ; java . util . Map < java . lang . String , java . lang . Object > expected = new java . util . HashMap ( ) ; expected . put ( "status" , RowStatus . ACTIVE ) ; expected . put ...
org . junit . Assert . assertEquals ( expected , actual )
testReadWithoutSource ( ) { "<AssertPlaceHolder>" ; } readHDU ( ) { if ( ( ( this . dataStr ) == null ) || ( this . atEOF ) ) { if ( ( this . dataStr ) == null ) { nom . tam . fits . Fits . LOG . warning ( "trying<sp>to<sp>read<sp>a<sp>hdu,<sp>without<sp>an<sp>input<sp>source!" ) ; } return null ; } if ( ( ( this . dat...
org . junit . Assert . assertNull ( new nom . tam . fits . Fits ( ) . readHDU ( ) )
testPutActual ( ) { java . lang . Object o = new java . lang . Object ( ) ; sut . put ( org . eurekastreams . server . domain . PropertyHashMapTest . KEY , o ) ; org . eurekastreams . server . domain . Property < java . lang . Object > result = sut . get ( org . eurekastreams . server . domain . PropertyHashMapTest . K...
org . junit . Assert . assertEquals ( o , result . getValue ( ) )
testGetLeadsChangesPagination ( ) { iprops . afterInputOperation ( ) ; iprops . batchSize . setValue ( 300 ) ; iprops . sinceDateTime . setValue ( org . talend . components . marketo . runtime . client . DATE_OLDEST_CREATE ) ; iprops . fieldList . setValue ( "id,email,firstName,lastName,company" ) ; org . talend . comp...
org . junit . Assert . assertTrue ( ( ( iprops . batchSize . getValue ( ) ) < counted ) )
testDeleteJobWithDisabledTenantCheck ( ) { java . lang . String timerJobId = managementService . createJobQuery ( ) . processInstanceId ( processInstance . getId ( ) ) . singleResult ( ) . getId ( ) ; identityService . setAuthentication ( "aUserId" , null ) ; engineRule . getProcessEngineConfiguration ( ) . setTenantCh...
org . junit . Assert . assertEquals ( 0 , managementService . createJobQuery ( ) . processInstanceId ( processInstance . getId ( ) ) . count ( ) )
test_Short ( ) { com . alibaba . dubbo . common . serialize . ObjectOutput objectOutput = serialization . serialize ( url , byteArrayOutputStream ) ; objectOutput . writeShort ( ( ( short ) ( 123 ) ) ) ; objectOutput . flushBuffer ( ) ; java . io . ByteArrayInputStream byteArrayInputStream = new java . io . ByteArrayIn...
org . junit . Assert . assertEquals ( ( ( short ) ( 123 ) ) , deserialize . readShort ( ) )
theLargest2 ( ) { int [ ] input = new int [ ] { 4 , 2 , 3 } ; chapter3 . selectionsort . JaegyuSelectionSort selection = new chapter3 . selectionsort . JaegyuSelectionSort ( ) ; "<AssertPlaceHolder>" ; } returnMaxIndex ( int [ ] , int ) { int maxIndex = 0 ; for ( int i = 1 ; i <= last ; i ++ ) { if ( ( input [ i ] ) > ...
org . junit . Assert . assertEquals ( 0 , selection . returnMaxIndex ( input , 2 ) )
getLastCommittedTransactionShouldFailWhenStoreIsClosed ( ) { org . neo4j . kernel . impl . store . MetaDataStore metaDataStore = newMetaDataStore ( ) ; metaDataStore . close ( ) ; try { metaDataStore . getLastCommittedTransaction ( ) ; org . junit . Assert . fail ( "Expected<sp>exception<sp>reading<sp>from<sp>MetaDataS...
org . junit . Assert . assertThat ( e , org . hamcrest . Matchers . instanceOf ( org . neo4j . kernel . impl . store . IllegalStateException . class ) )
testExecutionTimeUrnsBuildMonitoringInfos ( ) { java . lang . String testPTransformId = "pTransformId" ; java . util . HashMap < java . lang . String , java . lang . String > labelsMetadata = new java . util . HashMap < java . lang . String , java . lang . String > ( ) ; labelsMetadata . put ( MonitoringInfoConstants ....
org . junit . Assert . assertThat ( testOutput , org . hamcrest . Matchers . hasItem ( matcher ) )
testGetStructures ( ) { addStructure ( com . liferay . dynamic . data . mapping . service . test . DDMStructureServiceTest . _classNameId , com . liferay . portal . kernel . util . StringUtil . randomString ( ) ) ; addStructure ( com . liferay . dynamic . data . mapping . service . test . DDMStructureServiceTest . _cla...
org . junit . Assert . assertEquals ( structures . toString ( ) , 3 , structures . size ( ) )
testBasicWithMap ( ) { com . cloudera . science . avro . common . JsonConverter jc = new com . cloudera . science . avro . common . JsonConverter ( com . cloudera . science . avro . common . JsonConverterTest . sr ( f1 , f2 , f3Map ) ) ; java . lang . String json = "{\"field1\":<sp>1729,<sp>\"field2\":<sp>[true,<sp>tru...
org . junit . Assert . assertEquals ( json , r . toString ( ) )
testEnsureValidMask ( ) { final org . esa . beam . framework . datamodel . Product product = new org . esa . beam . framework . datamodel . Product ( "n" , "t" , 18 , 2 ) ; final org . esa . beam . framework . datamodel . Band flagsBand = product . addBand ( "flags" , ProductData . TYPE_INT8 ) ; final org . esa . beam ...
org . junit . Assert . assertEquals ( ( ( elems [ i ] ) == 1 ) , validMask . isSet ( i ) )
validate_shouldPassValidationIfFieldLengthsAreCorrect ( ) { org . openmrs . LocationAttributeType type = new org . openmrs . LocationAttributeType ( ) ; type . setName ( "name" ) ; type . setDatatypeClassname ( "org.openmrs.customdatatype.datatype.FreeTextDatatype" ) ; type . setDescription ( "description" ) ; type . s...
org . junit . Assert . assertFalse ( errors . hasErrors ( ) )
normalizesAbsolutePathWithJustDotsTest ( ) { com . beijunyi . parallelgit . filesystem . GitPath path = gfs . getPath ( "/./." ) ; com . beijunyi . parallelgit . filesystem . GitPath result = path . normalize ( ) ; "<AssertPlaceHolder>" ; } toString ( ) { if ( ( stringValue ) == null ) stringValue = decode ( com . beij...
org . junit . Assert . assertEquals ( "/" , result . toString ( ) )
testSoftmax ( ) { org . nd4j . linalg . api . ndarray . INDArray vec = org . nd4j . linalg . factory . Nd4j . linspace ( 1 , 6 , 6 , DataType . DOUBLE ) ; org . nd4j . linalg . api . ndarray . INDArray matrix = vec . dup ( ) . reshape ( 'f' , 2 , 3 ) ; org . nd4j . linalg . factory . Nd4j . getExecutioner ( ) . exec ( ...
org . junit . Assert . assertEquals ( matrixAssertion , matrix )
testConstants1 ( ) { java . lang . Object o = checkConstantExpression ( "null" ) ; "<AssertPlaceHolder>" ; } checkConstantExpression ( java . lang . String ) { org . eclipse . birt . data . engine . expression . CompiledExpression expr = m_compiler . compile ( exprStr , m_registry , context ) ; org . junit . Assert . a...
org . junit . Assert . assertNull ( o )
testAddFileEntryTypeWithEmptyDDMForm ( ) { int fileEntryTypesCount = com . liferay . document . library . kernel . service . DLFileEntryTypeServiceUtil . getFileEntryTypesCount ( new long [ ] { _group . getGroupId ( ) } ) ; com . liferay . portal . kernel . service . ServiceContext serviceContext = com . liferay . port...
org . junit . Assert . assertEquals ( ( fileEntryTypesCount + 1 ) , com . liferay . document . library . kernel . service . DLFileEntryTypeServiceUtil . getFileEntryTypesCount ( new long [ ] { _group . getGroupId ( ) } ) )
testIsRunByJunit ( ) { boolean isRunByJunit = cn . xiaowenjie . myrestutil . StackTraceHelper . isRunByJunit ( cn . xiaowenjie . myrestutil . StackTraceHelper . getMainThreadStackTraceElements ( ) ) ; "<AssertPlaceHolder>" ; } getMainThreadStackTraceElements ( ) { java . util . Map < java . lang . Thread , java . lang ...
org . junit . Assert . assertEquals ( true , isRunByJunit )
testFetchByPrimaryKeyExisting ( ) { com . liferay . segments . model . SegmentsEntryRel newSegmentsEntryRel = addSegmentsEntryRel ( ) ; com . liferay . segments . model . SegmentsEntryRel existingSegmentsEntryRel = _persistence . fetchByPrimaryKey ( newSegmentsEntryRel . getPrimaryKey ( ) ) ; "<AssertPlaceHolder>" ; } ...
org . junit . Assert . assertEquals ( existingSegmentsEntryRel , newSegmentsEntryRel )
testPhysicalIgnoresPastConsumed ( ) { pool . getProduct ( ) . setAttribute ( Pool . Attributes . MULTI_ENTITLEMENT , "yes" ) ; pool . getProduct ( ) . setAttribute ( Product . Attributes . STACKING_ID , "1" ) ; pool . getProduct ( ) . setAttribute ( org . candlepin . policy . js . quantity . QuantityRulesTest . SOCKET_...
org . junit . Assert . assertEquals ( new java . lang . Long ( 4 ) , suggested . getSuggested ( ) )
testRequestWithInvalidAuthorization ( ) { javax . servlet . http . HttpServletRequest request = org . mockito . Mockito . mock ( javax . servlet . http . HttpServletRequest . class ) ; javax . servlet . http . HttpServletResponse response = org . mockito . Mockito . mock ( javax . servlet . http . HttpServletResponse ....
org . junit . Assert . assertNull ( handler . authenticate ( request , response ) )
getAccessInfo_USER_fromSubscription ( ) { technicalProduct . setAccessType ( ServiceAccessType . USER ) ; subscription . setAccessInfo ( "<p><p>URL</p></p>" ) ; java . lang . String info = bean . getAccessInfo ( subscription , user ) ; "<AssertPlaceHolder>" ; verify ( bean , times ( 0 ) ) . getSubscriptionUrl ( eq ( su...
org . junit . Assert . assertEquals ( "<p><p>URL</p></p>" , info )
whenExtractMultipleParametersThenTheParsedParametersAreReturned ( ) { when ( parameterParser . parse ( com . thoughtworks . gauge . execution . parameters . ANY_TYPE , com . thoughtworks . gauge . execution . ParameterTestHelpers . aParameter ( ) ) ) . thenReturn ( com . thoughtworks . gauge . execution . parameters . ...
org . junit . Assert . assertThat ( stream ( extract ) . filter ( ( v ) -> ( v == com . thoughtworks . gauge . execution . parameters . SPECIFIC_VALUE ) || ( v == ( com . thoughtworks . gauge . execution . parameters . ParametersExtractorTest . ANOTHER_SPECIFIC_VALUE ) ) ) . count ( ) , org . hamcrest . CoreMatchers . ...
constructorSuccess ( ) { java . lang . String body = "This<sp>is<sp>a<sp>valid<sp>body" ; com . microsoft . azure . sdk . iot . device . transport . IotHubTransportMessage iotHubTransportMessage = new com . microsoft . azure . sdk . iot . device . transport . IotHubTransportMessage ( body ) ; "<AssertPlaceHolder>" ; } ...
org . junit . Assert . assertEquals ( body , new java . lang . String ( iotHubTransportMessage . getBytes ( ) ) )
testByteStringConstructorValueCopy ( ) { byte [ ] changing = new byte [ ] { 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 } ; byte [ ] original = new byte [ ] { 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 } ; org . opcfoundation . ua . builtintypes . ByteString bs1 = org . opcfoundation . ua . builtintypes . ByteString . valueOf ( changing ...
org . junit . Assert . assertEquals ( bs1 , bs2 )
testConverterFile ( ) { org . spf4j . jmx . JMXBeanMapping m = conv . get ( java . io . File . class ) ; java . io . File expected = new java . io . File ( "bla" ) ; java . lang . Object toOpenValue = m . toOpenValue ( expected ) ; java . lang . Object f = m . fromOpenValue ( toOpenValue ) ; "<AssertPlaceHolder>" ; } f...
org . junit . Assert . assertEquals ( expected , f )
matchXPathAttributeStartsWith ( ) { java . lang . String xmlString = "<xml><doc<sp>id='US123456789'></doc></xml>" ; gov . uspto . bulkdata . find . PatternXPath pattern = new gov . uspto . bulkdata . find . PatternXPath ( "//doc/@id[starts-with(.,'US1234')]" ) ; gov . uspto . bulkdata . find . PatternMatcher matcher = ...
org . junit . Assert . assertTrue ( matcher . match ( xmlString ) )
compareToNull ( ) { final int actual = this . dbObjectComparator . compare ( null , null ) ; "<AssertPlaceHolder>" ; } compare ( com . mongodb . DBObject , com . mongodb . DBObject ) { final int obj1Count = getCount ( obj1 ) ; final int obj2Count = getCount ( obj2 ) ; return obj2Count - obj1Count ; }
org . junit . Assert . assertEquals ( 0 , actual )
testBuildTimerRollOverValue ( ) { final org . opendaylight . protocol . bgp . rib . spi . state . BGPTimersState timerState = mock ( org . opendaylight . protocol . bgp . rib . spi . state . BGPTimersState . class ) ; doReturn ( 90L ) . when ( timerState ) . getNegotiatedHoldTime ( ) ; doReturn ( 42949673015L ) . when ...
org . junit . Assert . assertEquals ( expectedTimers , org . opendaylight . protocol . bgp . state . NeighborUtil . buildTimer ( timerState ) )
testGetAllChunks ( ) { org . apache . jackrabbit . core . data . DataIdentifier d10 = new org . apache . jackrabbit . core . data . DataIdentifier ( "d-10" ) ; org . apache . jackrabbit . core . data . DataIdentifier d20 = new org . apache . jackrabbit . core . data . DataIdentifier ( "d-20" ) ; org . apache . jackrabb...
org . junit . Assert . assertEquals ( expected , com . google . common . collect . Sets . newHashSet ( chunks ) )
testTreePermissionIsGrantedOR ( ) { org . apache . jackrabbit . oak . spi . security . authorization . permission . TreePermission parentPermission = org . apache . jackrabbit . oak . spi . security . authorization . permission . TreePermission . EMPTY ; for ( java . lang . String path : TP_PATHS ) { org . apache . jac...
org . junit . Assert . assertTrue ( tp . isGranted ( toTest ) )
testCompareArtists ( ) { org . bff . javampd . album . MPDAlbum album1 = new org . bff . javampd . album . MPDAlbum ( "Album1" , "Artist1" ) ; org . bff . javampd . album . MPDAlbum album2 = new org . bff . javampd . album . MPDAlbum ( "Album2" , "Artist1" ) ; "<AssertPlaceHolder>" ; } getArtistName ( ) { return artist...
org . junit . Assert . assertEquals ( album1 . getArtistName ( ) , album2 . getArtistName ( ) )
testExists_False ( ) { initializeExpectedJob ( 1 ) ; com . google . cloud . bigquery . BigQuery [ ] expectedOptions = new BigQuery . JobOption [ ] { BigQuery . JobOption . fields ( ) } ; expect ( bigquery . getOptions ( ) ) . andReturn ( mockOptions ) ; expect ( bigquery . getJob ( com . google . cloud . bigquery . Job...
org . junit . Assert . assertFalse ( job . exists ( ) )
testGetXWhenShapeIsNull ( ) { when ( canvas . getShape ( uuid ) ) . thenReturn ( null ) ; "<AssertPlaceHolder>" ; } getX ( ) { return x ; }
org . junit . Assert . assertEquals ( 0 , event . getX ( ) )
testConstructorWithBasicAwsCredentialsAndClientConfiguration ( ) { creds = new com . amazonaws . auth . BasicAWSCredentials ( "accessKey" , "secretKey" ) ; s3 = new com . amazonaws . services . s3 . AmazonS3Client ( creds , new com . amazonaws . ClientConfiguration ( ) ) ; "<AssertPlaceHolder>" ; }
org . junit . Assert . assertNotNull ( s3 )
testGetElementType ( ) { final javax . xml . namespace . QName qName = pluginForMongo . getElementType ( "test" , false ) ; "<AssertPlaceHolder>" ; } getLocalPart ( ) { return name . getLocalPart ( ) ; }
org . junit . Assert . assertEquals ( "test" , qName . getLocalPart ( ) )
testThatDoesntNormalizeIfStartsWithHttps ( ) { java . lang . String url = new net . vidageek . crawler . component . DefaultLinkNormalizer ( "http://test.com/foo" ) . normalize ( "https://other.com/bar" ) ; "<AssertPlaceHolder>" ; } normalize ( java . lang . String ) { java . lang . String normalizedUrl = delegate . no...
org . junit . Assert . assertEquals ( "https://other.com/bar" , url )
testPendingMemberShouldLeaveGroup ( ) { final java . lang . String consumerId = "consumer-id" ; subscriptions . subscribe ( singleton ( topic1 ) , rebalanceListener ) ; client . prepareResponse ( groupCoordinatorResponse ( node , Errors . NONE ) ) ; coordinator . ensureCoordinatorReady ( time . timer ( Long . MAX_VALUE...
org . junit . Assert . assertTrue ( received . get ( ) )
testGetWhenDoesNotExist ( ) { final byte [ ] flow1v1 = fileSystemFlowProvider . getFlowContent ( "bucket1" , "flow1" , 1 ) ; "<AssertPlaceHolder>" ; } getFlowContent ( java . lang . String , java . lang . String , int ) { final org . apache . nifi . registry . provider . flow . git . Bucket bucket = getBucketOrFail ( b...
org . junit . Assert . assertNull ( flow1v1 )
GetArrayOffset ( ) { java . lang . String st = "HTTP/1.1<sp>101<sp>Switching<sp>Protocols\r\nAccept:<sp>*/*\r\nSec-WebSocket-Accept:<sp>W5bRv0dwYtd1GPxLJnXACYizcbU=\r\nUser-Agent:<sp>litesockets\r\n\r\n" ; org . threadly . litesockets . buffers . MergedByteBuffers mbb = new org . threadly . litesockets . buffers . Reus...
org . junit . Assert . assertEquals ( st , new java . lang . String ( ba ) )
testCreateSchemaCharSet ( ) { java . util . List < com . zendesk . maxwell . schema . ddl . SchemaChange > changes = parse ( "CREATE<sp>SCHEMA<sp>IF<sp>NOT<sp>EXISTS<sp>`tblname`<sp>CHARACTER<sp>SET<sp>=<sp>default" ) ; "<AssertPlaceHolder>" ; } size ( ) { return columns . size ( ) ; }
org . junit . Assert . assertThat ( changes . size ( ) , org . hamcrest . CoreMatchers . is ( 1 ) )
assignedOrgChanged_negative ( ) { org . oscm . ui . model . Marketplace m = new org . oscm . ui . model . Marketplace ( ) ; m . setOwningOrganizationId ( "owningOrganizationId" ) ; m . setOriginalOrgId ( m . getOwningOrganizationId ( ) ) ; "<AssertPlaceHolder>" ; } assignedOrgChanged ( ) { org . oscm . ui . model . Mar...
org . junit . Assert . assertFalse ( m . assignedOrgChanged ( ) )
noClassCastExceptionInGetAction ( ) { org . sejda . sambox . pdmodel . interactive . documentnavigation . outline . PDOutlineItem victim = new org . sejda . sambox . pdmodel . interactive . documentnavigation . outline . PDOutlineItem ( ) ; victim . getCOSObject ( ) . setItem ( COSName . A , new org . sejda . sambox . ...
org . junit . Assert . assertNull ( victim . getAction ( ) )
testList ( ) { final ch . cyberduck . core . AttributedList < ch . cyberduck . core . Path > list = new ch . cyberduck . core . b2 . B2BucketListService ( session ) . list ( new ch . cyberduck . core . Path ( java . lang . String . valueOf ( Path . DELIMITER ) , java . util . EnumSet . of ( Path . Type . volume , Path ...
org . junit . Assert . assertFalse ( list . isEmpty ( ) )
testMismatchedFunctionUnequivalent ( ) { final org . openbel . framework . common . model . Namespace hgnc = new org . openbel . framework . common . model . Namespace ( "HGNC" , "http://resource.belframework.org/belframework/1.0/namespace/hgnc-approved-symbols.belns" ) ; org . openbel . framework . core . equivalence ...
org . junit . Assert . assertThat ( term1 . equals ( term2 ) , org . hamcrest . CoreMatchers . is ( false ) )
testSetLiteralWithOneEntryBlock ( ) { org . apache . commons . jexl3 . JexlScript e = org . apache . commons . jexl3 . JEXL . createScript ( "{<sp>{<sp>'foo'<sp>};<sp>}" ) ; org . apache . commons . jexl3 . JexlContext jc = new org . apache . commons . jexl3 . MapContext ( ) ; java . lang . Object o = e . execute ( jc ...
org . junit . Assert . assertTrue ( check . equals ( o ) )
testSingleFault ( ) { if ( ! ( runningInDistributedMode ( ) ) ) { System . out . println ( "testSingleFault:<sp>Ignore<sp>this<sp>test<sp>in<sp>local<sp>mode." ) ; return ; } org . apache . hadoop . fs . Path outputPath = getTempPath ( getCallingMethodName ( ) ) ; org . apache . giraph . conf . GiraphConfiguration conf...
org . junit . Assert . assertTrue ( job . run ( true ) )
mustNotIdentifyAsParentOrEqual ( ) { com . offbynull . actors . address . Address other = com . offbynull . actors . address . Address . of ( "one" , "two" , "three" ) ; com . offbynull . actors . address . Address fixture = com . offbynull . actors . address . Address . of ( "one" , "xxx" , "three" ) ; "<AssertPlaceHo...
org . junit . Assert . assertFalse ( other . isPrefixOf ( fixture ) )
testDynamicQueryByProjectionMissing ( ) { com . liferay . portal . kernel . dao . orm . DynamicQuery dynamicQuery = com . liferay . portal . kernel . dao . orm . DynamicQueryFactoryUtil . forClass ( com . liferay . message . boards . model . MBMailingList . class , _dynamicQueryClassLoader ) ; dynamicQuery . setProject...
org . junit . Assert . assertEquals ( 0 , result . size ( ) )
testSendAnalytics ( ) { java . lang . String name = com . liferay . portal . kernel . security . auth . PrincipalThreadLocal . getName ( ) ; try { com . liferay . portal . kernel . security . auth . PrincipalThreadLocal . setName ( com . liferay . portal . kernel . test . util . TestPropsValues . getUserId ( ) ) ; com ...
org . junit . Assert . assertNull ( response )
updateShouldChangeUsername ( ) { final net . jforum . entities . User current = new net . jforum . entities . User ( ) ; current . setUsername ( "old" ) ; when ( repository . get ( 1 ) ) . thenReturn ( current ) ; net . jforum . entities . User newUser = new net . jforum . entities . User ( ) ; newUser . setId ( 1 ) ; ...
org . junit . Assert . assertEquals ( newUser . getUsername ( ) , current . getUsername ( ) )
applyTest ( ) { java . lang . String [ ] [ ] tests = new java . lang . String [ ] [ ] { new java . lang . String [ ] { "{{<sp>8<sp>|<sp>modulo:<sp>2<sp>}}" , "0" } , new java . lang . String [ ] { "{{<sp>8<sp>|<sp>modulo:<sp>3<sp>}}" , "2" } , new java . lang . String [ ] { "{{<sp>\"8\"<sp>|<sp>modulo:<sp>3.<sp>}}" , "...
org . junit . Assert . assertThat ( rendered , org . hamcrest . CoreMatchers . is ( test [ 1 ] ) )
shouldAllowBypassForPresentPermission ( ) { org . bukkit . command . CommandSender sender = mock ( org . bukkit . command . CommandSender . class ) ; java . lang . String email = "mail-address@example.com" ; given ( permissionsManager . hasPermission ( sender , PlayerStatePermission . ALLOW_MULTIPLE_ACCOUNTS ) ) . will...
org . junit . Assert . assertThat ( result , org . hamcrest . Matchers . equalTo ( true ) )