input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
testCassandraBatchRowFormat ( ) { org . apache . flink . api . common . io . OutputFormat < org . apache . flink . types . Row > sink = new org . apache . flink . batch . connectors . cassandra . CassandraRowOutputFormat ( injectTableName ( org . apache . flink . streaming . connectors . cassandra . CassandraConnectorI... | org . junit . Assert . assertEquals ( org . apache . flink . streaming . connectors . cassandra . CassandraConnectorITCase . rowCollection . size ( ) , rows . size ( ) ) |
isAbsoluteFalse ( ) { final java . nio . file . Path path = fileSystem . getPath ( "relative" ) ; "<AssertPlaceHolder>" ; } isAbsolute ( ) { return false ; } | org . junit . Assert . assertFalse ( path . isAbsolute ( ) ) |
assertMonthsDaysWeakInvariant_T2_Minus_T1UntilT2_Eq_T1 ( ) { if ( ( this . start . getDayOfMonth ( ) ) <= 28 ) { net . time4j . Duration < net . time4j . CalendarUnit > period = this . start . until ( this . end , net . time4j . Duration . in ( net . time4j . CalendarUnit . MONTHS , net . time4j . CalendarUnit . DAYS )... | org . junit . Assert . assertThat ( this . end . minus ( period ) , org . hamcrest . CoreMatchers . is ( this . start ) ) |
testGlobStatusFilterWithEmptyPathResults ( ) { org . apache . hadoop . fs . Path [ ] testDirs = new org . apache . hadoop . fs . Path [ ] { getTestRootPath ( org . apache . hadoop . fs . FSMainOperationsBaseTest . fSys , org . apache . hadoop . fs . FSMainOperationsBaseTest . TEST_DIR_AAA ) , getTestRootPath ( org . ap... | org . junit . Assert . assertEquals ( 0 , filteredPaths . length ) |
testHasNext ( ) { java . sql . ResultSet resultSet = com . exigeninsurance . x4j . analytic . util . MockResultSet . create ( cols ( "A" , "B" , "C" , "D" ) , data ( row ( 1 , 2 , 3 , 4 ) , row ( 1 , 2 , 3 , 4 ) ) ) ; com . exigeninsurance . x4j . analytic . xlsx . core . node . GroupAdapter adapter = new com . exigeni... | org . junit . Assert . assertTrue ( hasNext ) |
testSomeMethod4 ( ) { java . util . List < com . wcs . netbeans . liquiface . model . Table > allTables = createTestTables ( ) ; com . wcs . netbeans . liquiface . model . Table centerTable = table1 ; int distance = 0 ; com . wcs . netbeans . liquiface . logic . TableNeighborFilter logika = new com . wcs . netbeans . l... | org . junit . Assert . assertEquals ( 1 , filteredTables . size ( ) ) |
test1 ( ) { java_programs . Node station1 = new java_programs . Node ( "Westminster" ) ; java_programs . Node station2 = new java_programs . Node ( "Waterloo" , new java . util . ArrayList < java_programs . Node > ( java . util . Arrays . asList ( station1 ) ) ) ; java_programs . Node station3 = new java_programs . Nod... | org . junit . Assert . assertEquals ( "Path<sp>found!" , resultStr ) |
isCurrentUserAuthenticatedShouldNotBeAuthenticatedWhenUserIsNotLoggedIn ( ) { org . springframework . security . core . context . SecurityContextHolder . getContext ( ) . setAuthentication ( null ) ; boolean result = springSecurityAuthenticationService . isCurrentUserAuthenticated ( ) ; "<AssertPlaceHolder>" ; } isCurr... | org . junit . Assert . assertFalse ( result ) |
getRedenVerliesNlTestOK ( ) { final java . lang . String rvnCode = "034" ; final nl . bzk . algemeenbrp . dal . domein . brp . entity . RedenVerliesNLNationaliteit expectedRvn = new nl . bzk . algemeenbrp . dal . domein . brp . entity . RedenVerliesNLNationaliteit ( rvnCode , "034" ) ; final java . lang . String rvnCod... | org . junit . Assert . assertEquals ( expected , resultRvn ) |
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 ) ; final com . flagstone . transform . coder . Context context = new co... | org . junit . Assert . assertNotNull ( fixture ) |
testExclude2 ( ) { java . lang . String sdp = "v=0\n" + ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( "a=rtpmap:100<sp>AMR-WB/16000/1\n" 3 + "s=-\n" ) + "b=AS:80\n" 1 ) + "a=rtpmap:100<sp>AMR-WB/16000/1\n" 5 ) + "m=audio<sp>42412<sp>RTP/AVP<sp>0<sp>8<sp>4<sp>18<sp>97<sp>99<sp>101<sp>100\n" ) + "b=AS:80\n" 1 ) + "a=rtpmap:100... | org . junit . Assert . assertEquals ( ( - 1 ) , s . indexOf ( "pcma" ) ) |
testHandlingOfConnectionLoss ( ) { org . I0Itec . zkclient . ContentWatcherTest . LOG . info ( "---<sp>testHandlingOfConnectionLoss" ) ; final org . I0Itec . zkclient . Gateway gateway = new org . I0Itec . zkclient . Gateway ( 4712 , 4711 ) ; gateway . start ( ) ; final org . I0Itec . zkclient . ZkClient zkClient = org... | org . junit . Assert . assertEquals ( "b" , watcher . getContent ( ) ) |
testTimestampOrdering ( ) { long smallerTimestamp = this . agentLifeCycleAsyncTaskService . createEventIdentifier ( 0 , Integer . MAX_VALUE ) ; long largerTimestamp = this . agentLifeCycleAsyncTaskService . createEventIdentifier ( 1 , 0 ) ; "<AssertPlaceHolder>" ; } createEventIdentifier ( int , int ) { if ( socketId <... | org . junit . Assert . assertTrue ( ( smallerTimestamp < largerTimestamp ) ) |
getDurationReportByMonthNoAuthenticatedTenants ( ) { testRule . deployForTenant ( org . camunda . bpm . engine . test . api . multitenancy . tenantcheck . MultiTenancyHistoricProcessInstanceReportCmdTenantCheckTest . TENANT_ONE , org . camunda . bpm . engine . test . api . multitenancy . tenantcheck . MultiTenancyHisto... | org . junit . Assert . assertThat ( result . size ( ) , org . hamcrest . CoreMatchers . is ( 0 ) ) |
mementoEverydayTest ( ) { com . designpatternsaga . memento . Customer customer = new com . designpatternsaga . memento . Customer ( "Rafael" , "31,<sp>Fairview<sp>Close" , "777-555-7777" ) ; com . designpatternsaga . memento . SerializableMementoDemo . serialize ( customer ) ; com . designpatternsaga . memento . Custo... | org . junit . Assert . assertEquals ( customer , newCustomer ) |
deveObterCodigoEventoComoFoiSetado ( ) { final com . fincatto . documentofiscal . nfe310 . classes . evento . manifestacaodestinatario . NFInfoEventoManifestacaoDestinatario infoEventoManifestacaoDestinatario = new com . fincatto . documentofiscal . nfe310 . classes . evento . manifestacaodestinatario . NFInfoEventoMan... | org . junit . Assert . assertEquals ( codigoEvento , infoEventoManifestacaoDestinatario . getCodigoEvento ( ) ) |
cancel ( ) { final java . lang . String TEST_PROCESS_NAME = "Test<sp>structured<sp>process" ; popup ( ) ; driver . findElement ( org . apromore . portal . uitest . By . xpath ( ( ( IBPSTRUCT_SETUP_DIALOG_XPATH ) + "//button[text()='<sp>Cancel']" ) ) ) . click ( ) ; delay ( ) ; "<AssertPlaceHolder>" ; } isElementPresent... | org . junit . Assert . assertFalse ( isElementPresent ( org . apromore . portal . uitest . By . xpath ( IBPSTRUCT_SETUP_DIALOG_XPATH ) ) ) |
testNormalizerStandardizeFitLabels ( ) { org . nd4j . linalg . dataset . NormalizerStandardize original = new org . nd4j . linalg . dataset . NormalizerStandardize ( org . nd4j . linalg . factory . Nd4j . create ( new double [ ] { 0.5 , 1.5 } ) , org . nd4j . linalg . factory . Nd4j . create ( new double [ ] { 2.5 , 3.... | org . junit . Assert . assertEquals ( original , restored ) |
testChannelSizeLimit ( ) { for ( int i = 0 ; i < ( channelSize ) ; i ++ ) { connector . connect ( "127.0.0.1" , io . craft . atom . nio . TestNioTcpAcceptorChannelSizeLimit . PORT ) ; } try { java . lang . Thread . sleep ( 100 ) ; java . util . concurrent . Future < io . craft . atom . io . Channel < byte [ ] > > futur... | org . junit . Assert . assertFalse ( channel . isOpen ( ) ) |
testCookiesShouldAllowHttpOnlyToBeSet ( ) { org . openqa . selenium . Cookie cookie = new org . openqa . selenium . Cookie ( "name" , "value" , "" , "/" , new java . util . Date ( ) , false , true ) ; "<AssertPlaceHolder>" ; } isHttpOnly ( ) { return isHttpOnly ; } | org . junit . Assert . assertTrue ( cookie . isHttpOnly ( ) ) |
testEndMS ( ) { com . bixly . pastevid . models . VideoFileItemTest . log ( "VideoFileItem.endMS" ) ; com . bixly . pastevid . models . VideoFileItem instance = new com . bixly . pastevid . models . VideoFileItem ( ) ; long expResult = java . lang . System . currentTimeMillis ( ) ; instance . setEndMS ( expResult ) ; l... | org . junit . Assert . assertEquals ( expResult , result ) |
testValueAsObject ( ) { final com . allanbank . mongodb . bson . element . UuidElement element = new com . allanbank . mongodb . bson . element . UuidElement ( "f" , com . allanbank . mongodb . bson . element . UuidElementTest . TEST_UUID ) ; "<AssertPlaceHolder>" ; } getValueAsObject ( ) { return myUuid ; } | org . junit . Assert . assertEquals ( com . allanbank . mongodb . bson . element . UuidElementTest . TEST_UUID , element . getValueAsObject ( ) ) |
testPowerLevelStaticInvalidAccess ( ) { "<AssertPlaceHolder>" ; } get ( int ) { com . digi . xbee . api . models . PowerLevel powerLevel = com . digi . xbee . api . models . PowerLevel . lookupTable . get ( value ) ; if ( powerLevel != null ) return powerLevel ; return com . digi . xbee . api . models . PowerLevel . LE... | org . junit . Assert . assertEquals ( PowerLevel . LEVEL_UNKNOWN , com . digi . xbee . api . models . PowerLevel . get ( 10 ) ) |
testAvoidEmptyObjectCreation ( ) { ma . glasnost . orika . MapperFactory factory = ma . glasnost . orika . test . MappingUtil . getMapperFactory ( ) ; factory . registerClassMap ( ma . glasnost . orika . metadata . ClassMapBuilder . map ( ma . glasnost . orika . test . community . Issue38TestCase . A . class , ma . gla... | org . junit . Assert . assertNull ( result . b ) |
OpenWriter ( ) { com . mysema . codegen . MemSourceFileObject obj = new com . mysema . codegen . MemSourceFileObject ( "Test" ) ; obj . openWriter ( ) . write ( "Hello<sp>World" ) ; "<AssertPlaceHolder>" ; } getCharContent ( boolean ) { return contents ; } | org . junit . Assert . assertEquals ( "Hello<sp>World" , obj . getCharContent ( true ) . toString ( ) ) |
testMapThenParallelMap ( ) { org . stringtemplate . v4 . STGroup group = new org . stringtemplate . v4 . STGroup ( ) ; group . defineTemplate ( "bold" , "x" , "[<x>]" ) ; group . defineTemplate ( "test" , "names,phones" , "hi<sp><[names:bold()],phones:{n,p<sp>|<sp><n>:<p>;}>" ) ; org . stringtemplate . v4 . ST st = gro... | org . junit . Assert . assertEquals ( expected , result ) |
testCache ( ) { org . talend . repository . model . StableRepositoryNode container = new org . talend . repository . model . StableRepositoryNode ( null , "SAP" , org . talend . commons . ui . runtime . image . ECoreImage . FOLDER_CLOSE_ICON ) ; container . setChildrenObjectType ( ERepositoryObjectType . METADATA_CON_T... | org . junit . Assert . assertTrue ( ( child == ( rnc . removeChildFolderCache ( child ) ) ) ) |
testMixedRangesAndElements ( ) { org . antlr . v4 . runtime . misc . IntervalSet s = new org . antlr . v4 . runtime . misc . IntervalSet ( ) ; s . add ( 1 ) ; s . add ( 'a' , 'z' ) ; s . add ( '0' , '9' ) ; java . lang . String expecting = "{1,<sp>48..57,<sp>97..122}" ; "<AssertPlaceHolder>" ; } toString ( ) { return (... | org . junit . Assert . assertEquals ( s . toString ( ) , expecting ) |
testEnums ( ) { ser . Basics obj = new ser . Basics ( 123 ) ; out . writeObject ( obj ) ; in . resetForReuseUseArray ( out . getCopyOfWrittenBuffer ( ) ) ; out . flush ( ) ; ser . Basics res = ( ( ser . Basics ) ( in . readObject ( ) ) ) ; java . lang . Object [ ] exceptions1 = res . exceptions ; java . lang . Object [... | org . junit . Assert . assertTrue ( ( ( exceptions1 [ i ] . getClass ( ) ) == ( exceptions2 [ i ] . getClass ( ) ) ) ) |
testGetPersoonElementen ( ) { final nl . bzk . brp . bijhouding . bericht . model . RelatieElement relatieElement = builder . maakHuwelijkElement ( "CI_huwelijk" , builder . maakRelatieGroepElement ( "CI_relatie" , "1" , new nl . bzk . brp . bijhouding . bericht . model . ElementBuilder . RelatieGroepParameters ( ) ) ,... | org . junit . Assert . assertTrue ( actieElement . getPersoonElementen ( ) . isEmpty ( ) ) |
shouldNotPerformAnalysisWhenDependencyDistanceIsLessThan0 ( ) { when ( this . extractor . getMaxDistance ( ) ) . thenReturn ( ( - 1 ) ) ; final java . util . List < org . pitest . testapi . TestUnit > actual = this . testee . filterTestsByDependencyAnalysis ( this . tus ) ; "<AssertPlaceHolder>" ; verify ( this . extra... | org . junit . Assert . assertSame ( this . tus , actual ) |
testMapSingleValue ( ) { org . stringtemplate . v4 . STGroup group = new org . stringtemplate . v4 . STGroup ( ) ; group . defineTemplate ( "a" , "x" , "[<x>]" ) ; group . defineTemplate ( "test" , "name" , "hi<sp><name:a()>!" ) ; org . stringtemplate . v4 . ST st = group . getInstanceOf ( "test" ) ; st . add ( "name" ... | org . junit . Assert . assertEquals ( expected , result ) |
testGetPriority ( ) { "<AssertPlaceHolder>" ; } getPriority ( ) { return 3 ; } | org . junit . Assert . assertEquals ( 7 , provider . getPriority ( ) ) |
equalsFail ( ) { org . apache . hadoop . fs . shell . find . Result one = org . apache . hadoop . fs . shell . find . Result . FAIL ; org . apache . hadoop . fs . shell . find . Result two = Result . FAIL . combine ( Result . FAIL ) ; "<AssertPlaceHolder>" ; } combine ( org . apache . hadoop . fs . shell . find . Resul... | org . junit . Assert . assertEquals ( one , two ) |
whenGetObjectAtSecondPosition_thenReturnExpectedBean ( ) { org . robobinding . itempresentationmodel . BeanCursorTest . Bean bean2 = beanCursor . getObjectAtPosition ( 1 ) ; "<AssertPlaceHolder>" ; } get ( java . lang . Object ) { return getReferenceObject ( map . get ( key ) ) ; } | org . junit . Assert . assertEquals ( beans . get ( 1 ) , bean2 ) |
testSetId ( ) { target . setId ( "abc" ) ; "<AssertPlaceHolder>" ; } getId ( ) { return id ; } | org . junit . Assert . assertThat ( target . getId ( ) , org . hamcrest . CoreMatchers . is ( "abc" ) ) |
readData_badData ( ) { 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.413badtime5177E9<s... | org . junit . Assert . assertTrue ( ( ( info . size ( ) ) == 1 ) ) |
testLongName ( ) { try { javax . jcr . Session s = getAdminSession ( ) ; java . lang . StringBuilder buff = new java . lang . StringBuilder ( ) ; for ( int i = 0 ; i < 100 ; i ++ ) { buff . append ( "0123456789" ) ; } java . lang . String longName = "n" + ( buff . toString ( ) ) ; javax . jcr . Node n = s . getRootNode... | org . junit . Assert . assertEquals ( n . getPath ( ) , n2 . getPath ( ) ) |
testCountByG_U_R_F_M_StatusInTrash_EmptyRepositories ( ) { com . liferay . portal . kernel . dao . orm . QueryDefinition < com . liferay . document . library . kernel . model . DLFileEntry > queryDefinition = new com . liferay . portal . kernel . dao . orm . QueryDefinition ( ) ; queryDefinition . setStatus ( WorkflowC... | org . junit . Assert . assertEquals ( 4 , doCountBy_G_U_R_F_M_EmptyRepositories ( 0 , null , queryDefinition ) ) |
testFindRolesInsertedByLiquibase ( ) { try ( final java . sql . Connection connection = embeddedDatabaseRule . getConnection ( ) ) { final java . util . List < java . lang . String > rolesForUser = new org . zapodot . junit . db . plugin . dao . RoleDao ( connection ) . rolesForUser ( "Ada" ) ; "<AssertPlaceHolder>" ; ... | org . junit . Assert . assertEquals ( 0 , rolesForUser . size ( ) ) |
testResultUndefinedForNoReturnInIntFunction ( ) { v8 . executeIntegerScript ( "function<sp>foo()<sp>{};<sp>42" ) ; int result = v8 . executeIntegerFunction ( "foo" , null ) ; "<AssertPlaceHolder>" ; } executeIntegerFunction ( java . lang . String , com . eclipsesource . v8 . V8Array ) { throw new java . lang . Unsuppor... | org . junit . Assert . assertEquals ( 3 , result ) |
testEofHandlingByteArray ( ) { nom . tam . util . BufferedDataInputStream create8ByteInput = create8ByteInput ( ) ; java . io . EOFException expectedEof = null ; try { create8ByteInput . read ( new byte [ 0 ] , 0 , 0 ) ; } catch ( java . io . EOFException eof ) { expectedEof = eof ; } "<AssertPlaceHolder>" ; } read ( b... | org . junit . Assert . assertNull ( expectedEof ) |
testSetFromNeuron ( ) { org . neuroph . core . Connection instance = new org . neuroph . core . Connection ( fromNeuron , toNeuron ) ; "<AssertPlaceHolder>" ; } getFromNeuron ( ) { return fromNeuron ; } | org . junit . Assert . assertEquals ( fromNeuron , instance . getFromNeuron ( ) ) |
testZoekGeboorteDatumHuisnummer ( ) { final java . util . Set < nl . bzk . brp . domain . algemeen . ZoekCriterium > zoekCriteria = new java . util . HashSet ( ) ; nl . bzk . brp . domain . algemeen . ZoekCriterium zoekCriteria1 = new nl . bzk . brp . domain . algemeen . ZoekCriterium ( getAttribuutElement ( Element . ... | org . junit . Assert . assertEquals ( 1 , ids . size ( ) ) |
shouldExpandStringsComposedByTildeSlash ( ) { java . lang . String result = expander . expand ( "~/" ) ; java . lang . String expected = ( java . lang . System . getProperty ( "user.home" ) ) + "/" ; "<AssertPlaceHolder>" ; } getProperty ( java . lang . String ) { readLock . lock ( ) ; try { return properties . getProp... | org . junit . Assert . assertEquals ( expected , result ) |
testBug934819 ( ) { org . openscience . cdk . interfaces . IAtomContainer superStructure = org . openscience . cdk . fingerprint . AbstractFixedLengthFingerprinterTest . bug934819_2 ( ) ; org . openscience . cdk . interfaces . IAtomContainer subStructure = org . openscience . cdk . fingerprint . AbstractFixedLengthFing... | org . junit . Assert . assertThat ( org . openscience . cdk . fingerprint . AbstractFixedLengthFingerprinterTest . and ( superBS , subBS ) , org . hamcrest . CoreMatchers . is ( subBS ) ) |
testRemoveDouble ( ) { java . lang . Double [ ] inputArray1 = new java . lang . Double [ ] { 0.1 , 3.1 , 5.1 } ; java . lang . Double [ ] outputArray = org . openl . rules . helpers . RulesUtilsTest . instance . testDoubleRemove ( inputArray1 , 1 ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertTrue ( org . openl . rules . helpers . Arrays . equals ( new java . lang . Double [ ] { 0.1 , 5.1 } , outputArray ) ) |
createWithRiskDataParams ( ) { com . braintreegateway . integrationtest . CustomerRequest request = new com . braintreegateway . integrationtest . CustomerRequest ( ) . creditCard ( ) . number ( "4111111111111111" ) . expirationDate ( "05/12" ) . done ( ) . riskData ( ) . customerBrowser ( "IE6" ) . customerIP ( "192.1... | org . junit . Assert . assertTrue ( result . isSuccess ( ) ) |
testMultiLayerIdInex ( ) { de . vandermeer . svg2vector . applications . is . Svg2Vector_IS app = new de . vandermeer . svg2vector . applications . is . Svg2Vector_IS ( ) ; java . lang . String [ ] args = org . apache . commons . lang3 . ArrayUtils . addAll ( de . vandermeer . svg2vector . applications . is . Test_Svg2... | org . junit . Assert . assertEquals ( 0 , app . executeApplication ( args ) ) |
testSave ( ) { java . util . List < software . amazon . awssdk . services . dynamodb . pojos . StringSetAttributeClass > objs = new java . util . ArrayList < software . amazon . awssdk . services . dynamodb . pojos . StringSetAttributeClass > ( ) ; for ( int i = 0 ; i < 5 ; i ++ ) { software . amazon . awssdk . service... | org . junit . Assert . assertEquals ( obj , loaded ) |
testAddition ( ) { org . apache . commons . math3 . analysis . polynomials . PolynomialFunction p1 = new org . apache . commons . math3 . analysis . polynomials . PolynomialFunction ( new double [ ] { - 2 , 1 } ) ; org . apache . commons . math3 . analysis . polynomials . PolynomialFunction p2 = new org . apache . comm... | org . junit . Assert . assertEquals ( 1 , p1 . degree ( ) ) |
testNoHarborProperty ( ) { com . vmware . xenon . common . test . TestContext t = new com . vmware . xenon . common . test . TestContext ( 1 , java . time . Duration . ofSeconds ( 15 ) ) ; harborInitRegistryService . handleStart ( com . vmware . xenon . common . Operation . createGet ( null ) . setCompletion ( t . getC... | org . junit . Assert . assertNull ( harborRegistry ) |
getGroupDisplayNameWithGroupPrimaryRealm ( ) { java . lang . String group = "vmmgrp1" ; com . ibm . websphere . simplicity . log . Log . info ( com . ibm . ws . security . wim . adapter . ldap . fat . URAPIs_Federation_2LDAPs_2RealmsTest . c , "getGroupDisplayNameWithGroupPrimaryRealm" , "Checking<sp>with<sp>a<sp>valid... | org . junit . Assert . assertEquals ( "vmmgrp1" , com . ibm . ws . security . wim . adapter . ldap . fat . URAPIs_Federation_2LDAPs_2RealmsTest . servlet . getGroupDisplayName ( group ) ) |
add347 ( ) { tdd . Calculator sut = new tdd . Calculator ( ) ; "<AssertPlaceHolder>" ; } add ( java . lang . String , int ) { int oldSize = size ( item ) ; int newSize = oldSize + num ; list . put ( item , newSize ) ; } | org . junit . Assert . assertThat ( sut . add ( 3 , 4 ) , org . hamcrest . CoreMatchers . is ( 7 ) ) |
testBuild ( ) { org . lnu . is . domain . education . form . type . EducationFormType context = new org . lnu . is . domain . education . form . type . EducationFormType ( ) ; java . lang . String expectedQuery = "SELECT<sp>e<sp>FROM<sp>EducationFormType<sp>e<sp>WHERE<sp>e.status=:status<sp>AND<sp>e.crtUserGroup<sp>IN<... | org . junit . Assert . assertEquals ( expectedQuery , actualQuery ) |
testToUnsignedByteArrayInt_LeadingBytesZero ( ) { byte [ ] actual = de . persosim . simulator . utils . Utils . toUnsignedByteArray ( ( ( int ) ( 1122867 ) ) ) ; byte [ ] expected = new byte [ ] { ( ( byte ) ( 0 ) ) , ( ( byte ) ( 17 ) ) , ( ( byte ) ( 34 ) ) , ( ( byte ) ( 51 ) ) } ; "<AssertPlaceHolder>" ; } toUnsign... | org . junit . Assert . assertArrayEquals ( expected , actual ) |
neverWritableColumnsShouldNotBeInValueMap_shouldReturnFalse ( ) { com . vaadin . v7 . data . util . sqlcontainer . ColumnProperty property = new com . vaadin . v7 . data . util . sqlcontainer . ColumnProperty ( "NAME" , true , false , true , false , "Ville" , java . lang . String . class ) ; "<AssertPlaceHolder>" ; } i... | org . junit . Assert . assertFalse ( property . isPersistent ( ) ) |
testSetWrongWidgetProperty3 ( ) { clientPair . appClient . send ( "loadProfileGzipped" ) ; cc . blynk . server . core . model . Profile profile = clientPair . appClient . parseProfile ( 1 ) ; cc . blynk . server . core . model . widgets . Widget widget = profile . dashBoards [ 0 ] . findWidgetByPin ( 0 , ( ( short ) ( ... | org . junit . Assert . assertEquals ( widget . x , 1 ) |
mapOrderDoesNotChangeHash ( ) { java . util . Map < ? , ? > map1 = com . google . common . collect . ImmutableMap . of ( "firstKey" , 24 , "secondKey" , new java . lang . Float ( 13.5 ) ) ; java . util . Map < ? , ? > map2 = com . google . common . collect . ImmutableMap . of ( "secondKey" , new java . lang . Float ( 1... | org . junit . Assert . assertEquals ( hasher1 . hash ( ) . toString ( ) , hasher2 . hash ( ) . toString ( ) ) |
testCanGetLargerTree ( ) { java . util . List < uk . gov . dstl . baleen . types . language . WordToken > tokens = java . util . Arrays . asList ( wt0 , wt7 ) ; uk . gov . dstl . baleen . uima . grammar . DependencyTree actual = graph . minimalTree ( tokens ) ; uk . gov . dstl . baleen . uima . grammar . DependencyTree... | org . junit . Assert . assertTrue ( expected . matches ( actual ) ) |
testWeekOfMonth ( ) { java . lang . Object result = run ( "WEEK_OF_MONTH(epoch)" ) ; "<AssertPlaceHolder>" ; } run ( org . apache . commons . cli . CommandLine ) { try ( org . apache . curator . framework . CuratorFramework client = org . apache . metron . common . configuration . ConfigurationsUtils . getClient ( org ... | org . junit . Assert . assertEquals ( 4 , result ) |
testOfferLast ( ) { com . sun . sgs . test . app . util . TestScalableDeque . txnScheduler . runTask ( new com . sun . sgs . test . util . TestAbstractKernelRunnable ( ) { public void run ( ) throws com . sun . sgs . test . app . util . Exception { com . sun . sgs . app . util . ScalableDeque < java . lang . Integer > ... | org . junit . Assert . assertEquals ( 1 , ( ( int ) ( d . getLast ( ) ) ) ) |
getUUIDSuccessfullyRetrievesCachedEntry ( ) { configuration . linkingMethod = "uuid" ; when ( player . getUniqueId ( ) ) . thenReturn ( uuid ) ; when ( player . getName ( ) ) . thenReturn ( org . communitybridge . linker . UserPlayerLinkerTest . PLAYER_NAME ) ; when ( userIDDao . getUserID ( org . communitybridge . lin... | org . junit . Assert . assertEquals ( uuid . toString ( ) , userPlayerLinker . getUUID ( org . communitybridge . linker . UserPlayerLinkerTest . UUID_USER_ID ) ) |
testWordMissingOOXMLBeans ( ) { java . lang . String [ ] fileNames = new java . lang . String [ ] { "testWORD_missing_ooxml_bean1.docx" } ; java . io . PrintStream origErr = System . err ; for ( java . lang . String fileName : fileNames ) { java . io . ByteArrayOutputStream errContent = new java . io . ByteArrayOutputS... | org . junit . Assert . assertTrue ( ( ( err . length ( ) ) == 0 ) ) |
testDoNothingOneElementConfig ( ) { org . dcache . gplazma . strategies . AuthenticationStrategy strategy = strategyFactory . newAuthenticationStrategy ( ) ; "<AssertPlaceHolder>" ; strategy . setPlugins ( oneDoNothingPlugins ) ; java . util . Set < java . lang . Object > publicCredential = com . google . common . coll... | org . junit . Assert . assertNotNull ( strategy ) |
testCheckReconnectSocketFailure ( ) { final java . util . concurrent . atomic . AtomicBoolean interrupt = new java . util . concurrent . atomic . AtomicBoolean ( ) ; final ch . cyberduck . core . pool . StatelessSessionPool pool = new ch . cyberduck . core . pool . StatelessSessionPool ( new ch . cyberduck . core . Tes... | org . junit . Assert . assertTrue ( interrupt . get ( ) ) |
testBasicDiscoveryRR ( ) { com . flipkart . ranger . finder . sharded . SimpleShardedServiceFinder < com . flipkart . ranger . model . ServiceNoProviderTest . TestShardInfo > serviceFinder = com . flipkart . ranger . ServiceFinderBuilders . < com . flipkart . ranger . model . ServiceNoProviderTest . TestShardInfo > sha... | org . junit . Assert . assertNull ( node ) |
testToMap_allowValuelessKeys ( ) { java . lang . String [ ] values = new java . lang . String [ ] { "key1:value1" , "key2:value2" , "key3:value3" } ; java . lang . String separator = ":" ; java . util . Map < java . lang . String , java . lang . String > expResult = new java . util . HashMap < java . lang . String , ja... | org . junit . Assert . assertEquals ( expResult , result ) |
testIsSubProject4 ( ) { java . io . File build = root . newFile ( "build.gradle" ) ; java . io . File settings = root . newFile ( "settings.gradle" ) ; java . io . File module = root . newFolder ( "subprojects" , "module" ) ; java . nio . file . Files . write ( settings . toPath ( ) , java . util . Arrays . asList ( "i... | org . junit . Assert . assertTrue ( gf . isSubProject ( ) ) |
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 ( mbDiscussions . isEmpty ( ) ) |
hasInternetConnection ( ) { mockStatic ( java . net . InetAddress . class ) ; when ( java . net . InetAddress . getByName ( anyString ( ) ) ) . thenReturn ( null ) ; "<AssertPlaceHolder>" ; } hasConnection ( fi . helsinki . cs . tmc . cli . core . CliContext ) { try { java . net . InetAddress . getByName ( "www.mooc.fi... | org . junit . Assert . assertTrue ( fi . helsinki . cs . tmc . cli . backend . TmcUtil . hasConnection ( ctx ) ) |
updateUser_usesDAO_001 ( ) { when ( userRepository . save ( userA ) ) . thenReturn ( userA ) ; when ( securityContext . getAuthentication ( ) ) . thenReturn ( authentication ) ; when ( authentication . getPrincipal ( ) ) . thenReturn ( userA ) ; edu . zipcloud . cloudstreetmarket . core . entities . User user = communi... | org . junit . Assert . assertEquals ( userA , user ) |
getAboutResponse_OobAvailable ( ) { org . springframework . http . ResponseEntity responseEntityMock = mock ( org . springframework . http . ResponseEntity . class ) ; com . vmware . vrack . hms . rest . factory . HmsOobAgentRestTemplate restTemplateMock = mock ( com . vmware . vrack . hms . rest . factory . HmsOobAgen... | org . junit . Assert . assertNotNull ( response ) |
testGenerateClassWithInheritance ( ) { org . eclipse . emf . common . util . EList < org . eclipse . uml2 . uml . Generalization > generalizations = new org . eclipse . emf . common . util . UniqueEList < org . eclipse . uml2 . uml . Generalization > ( ) ; org . eclipse . uml2 . uml . Generalization generalization = mo... | org . junit . Assert . assertEquals ( typeDeclaration . toString ( ) , td . toString ( ) ) |
canAddMapOfRuleKeyAppendable ( ) { com . google . common . collect . ImmutableMap < java . lang . String , com . facebook . buck . core . rulekey . RuleKeyTest . TestRuleKeyAppendable > map = com . google . common . collect . ImmutableMap . of ( "foo" , new com . facebook . buck . core . rulekey . RuleKeyTest . TestRul... | org . junit . Assert . assertNotNull ( key ) |
testAddingTheSameIsNoOp ( ) { ru . r2cloud . DefaultScheduleEntry entry = ru . r2cloud . satellite . ScheduleTest . create ( ) ; schedule . add ( entry ) ; schedule . add ( entry ) ; "<AssertPlaceHolder>" ; } isCancelled ( ) { return cancelled ; } | org . junit . Assert . assertFalse ( entry . isCancelled ( ) ) |
testCreationTimestamp ( ) { org . candlepin . model . Product newProduct = this . createProduct ( owner ) ; org . candlepin . model . Pool pool = createPool ( owner , newProduct , 1L , org . candlepin . test . TestUtil . createDate ( 2011 , 3 , 30 ) , org . candlepin . test . TestUtil . createDate ( 2022 , 11 , 29 ) ) ... | org . junit . Assert . assertNotNull ( pool . getCreated ( ) ) |
testOnNeg_Long ( ) { this . codeGenerator . onConstant ( new com . googlecode . aviator . lexer . token . NumberToken ( 3L , "3" ) ) ; this . codeGenerator . onNeg ( null ) ; java . lang . Object result = this . eval ( new java . util . HashMap < java . lang . String , java . lang . Object > ( ) ) ; "<AssertPlaceHolder... | org . junit . Assert . assertEquals ( ( - 3L ) , result ) |
testCheckHdfsNameEmpty ( ) { java . lang . String testHost = "" ; namedCluster . setHdfsHost ( ( ( "<sp>" + testHost ) + "<sp>" ) ) ; "<AssertPlaceHolder>" ; } isHdfsHostEmpty ( org . pentaho . di . core . variables . VariableSpace ) { java . lang . String hostNameParsed = getHostNameParsed ( variableSpace ) ; return (... | org . junit . Assert . assertEquals ( true , namedCluster . isHdfsHostEmpty ( null ) ) |
testConstructor ( ) { org . openhealthtools . mdht . uml . cda . hitsp . operations . SocialHistorySectionOperations obj = new org . openhealthtools . mdht . uml . cda . hitsp . operations . SocialHistorySectionOperations ( ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertTrue ( true ) |
testGetMethodParamsString ( ) { org . uberfire . client . callbacks . Callback < java . util . List < java . lang . String > > callback = spy ( new org . uberfire . client . callbacks . Callback < java . util . List < java . lang . String > > ( ) { @ org . kie . workbench . common . widgets . client . datamodel . Overr... | org . junit . Assert . assertEquals ( 1 , result . size ( ) ) |
testParseIonic_StatisticalUnit ( ) { final java . lang . String [ ] properties = new java . lang . String [ ] { "unitId" , "typeAbbreviation" , "instanceName" , "geometry" } ; final javax . xml . namespace . QName featureName = org . geotools . data . wfs . WFSTestData . IONIC_STATISTICAL_UNIT . TYPENAME ; final java .... | org . junit . Assert . assertEquals ( ( - 1 ) , nof ) |
testCollectionLiteralExp04 ( ) { testpackage . Class1 class1 ; class1 = new testpackage . Class1 ( ) ; java . util . List < java . lang . Integer > expectedResult = new java . util . ArrayList < java . lang . Integer > ( ) ; expectedResult . add ( 0 ) ; expectedResult . add ( 1 ) ; expectedResult . add ( 2 ) ; "<Assert... | org . junit . Assert . assertEquals ( expectedResult , class1 . testCollectionLiteralExp04 ( ) ) |
test_isValidForSqlQuery_String_ok ( ) { ch . puzzle . itc . mobiliar . business . deploy . entity . CustomFilter c = ch . puzzle . itc . mobiliar . business . deploy . entity . CustomFilter . builder ( stringType ) . filterDisplayName ( "filter<sp>DisplayName" ) . deploymentTableColumnName ( "deploymentTableColumnName"... | org . junit . Assert . assertTrue ( c . isValidForSqlQuery ( ) ) |
testEquals_differentHigh ( ) { com . sumzerotrading . data . BarData [ ] bars = getEqualBars ( ) ; bars [ 0 ] . setHigh ( BigDecimal . ZERO ) ; "<AssertPlaceHolder>" ; } getEqualBars ( ) { java . time . LocalDateTime cal = java . time . LocalDateTime . now ( ) ; java . math . BigDecimal open = new java . math . BigDeci... | org . junit . Assert . assertFalse ( bars [ 0 ] . equals ( bars [ 1 ] ) ) |
setScript ( ) { System . out . println ( "<sp>set<sp>and<sp>get<sp>the<sp>script" ) ; java . lang . String script = "dest<sp>=<sp>42;" ; jiffle . setScript ( script ) ; java . lang . String result = jiffle . getScript ( ) ; "<AssertPlaceHolder>" ; } contains ( java . awt . geom . Rectangle2D ) { return contains ( rect ... | org . junit . Assert . assertTrue ( result . contains ( script ) ) |
isExtensionAllowedAllowAll ( ) { com . tinkerpop . rexster . extension . ExtensionAllowed configuration = new com . tinkerpop . rexster . extension . ExtensionAllowed ( "*:*" ) ; com . tinkerpop . rexster . extension . ExtensionSegmentSet extensionSegmentSet = new com . tinkerpop . rexster . extension . ExtensionSegmen... | org . junit . Assert . assertTrue ( configuration . isExtensionAllowed ( extensionSegmentSet ) ) |
toStringValues ( ) { biweekly . util . UtcOffset offset = new biweekly . util . UtcOffset ( true , 1 , 0 ) ; biweekly . util . ICalDate start = new biweekly . util . ICalDate ( date ( "2016-01-17" ) ) ; biweekly . util . ICalDate end = new biweekly . util . ICalDate ( date ( "2016-01-18" ) ) ; biweekly . property . Day... | org . junit . Assert . assertFalse ( property . toStringValues ( ) . isEmpty ( ) ) |
limitL11 ( ) { java . lang . String sqlite = "SELECT<sp>*<sp>FROM<sp>users<sp>order<sp>by<sp>created<sp>desc<sp>LIMIT<sp>11" ; java . lang . String api = null ; int limit = 11 ; org . apache . usergrid . query . validator . QueryRequest request = new org . apache . usergrid . query . validator . QueryRequest ( ) ; requ... | org . junit . Assert . assertTrue ( response . toString ( ) , response . result ( ) ) |
infeasibleAtoms ( ) { org . openscience . cdk . isomorphism . AtomMatcher mock = mock ( org . openscience . cdk . isomorphism . AtomMatcher . class ) ; when ( mock . matches ( any ( org . openscience . cdk . interfaces . IAtom . class ) , any ( org . openscience . cdk . interfaces . IAtom . class ) ) ) . thenReturn ( f... | org . junit . Assert . assertFalse ( state . feasible ( i , j ) ) |
testGetPlayers ( ) { world . bentobox . bentobox . api . addons . AddonTest . TestClass test = new world . bentobox . bentobox . api . addons . AddonTest . TestClass ( ) ; world . bentobox . bentobox . managers . PlayersManager pm = mock ( world . bentobox . bentobox . managers . PlayersManager . class ) ; when ( world... | org . junit . Assert . assertEquals ( pm , test . getPlayers ( ) ) |
coercesValidLogLevel ( ) { java . util . logging . Level expected = java . util . logging . Level . WARNING ; java . util . logging . Level actual = coercer . coerce ( createCellRoots ( filesystem ) , filesystem , pathFromRoot , EmptyTargetConfiguration . INSTANCE , "WARNING" ) ; "<AssertPlaceHolder>" ; } createCellRoo... | org . junit . Assert . assertEquals ( expected , actual ) |
testCreateXMLFileByMap ( ) { org . xmlbeam . types . CloseableMap < java . lang . String > map = new org . xmlbeam . XBProjector ( ) . io ( ) . file ( "example.xml" ) . bindXPath ( "/rootpath" ) . asMapOf ( java . lang . String . class ) ; map . put ( "foo" , "bar" ) ; map . close ( ) ; "<AssertPlaceHolder>" ; } close ... | org . junit . Assert . assertTrue ( new java . io . File ( "example.xml" ) . delete ( ) ) |
newMessage ( ) { org . eclipse . kapua . message . device . data . KapuaDataMessage message = kapuaDataMessageFactory . newKapuaDataMessage ( ) ; "<AssertPlaceHolder>" ; } newKapuaDataMessage ( ) { return org . eclipse . kapua . message . device . data . xml . DataMessageXmlRegistry . KAPUA_DATA_MESSAGE_FACTORY . newKa... | org . junit . Assert . assertNotNull ( message ) |
testCombinedInsertCheckForData ( ) { int res ; java . util . List < com . ctrip . platform . dal . dao . unitbase . ClientTestModel > modelList = null ; try { res = dao . combinedInsert ( new com . ctrip . platform . dal . dao . unittests . DalHints ( ) , null , modelList ) ; org . junit . Assert . fail ( ) ; } catch (... | org . junit . Assert . assertEquals ( 0 , res ) |
testConvertWithEmptyFields ( ) { org . lnu . is . domain . person . pension . PersonPension source = new org . lnu . is . domain . person . pension . PersonPension ( ) ; org . lnu . is . resource . person . pension . PersonPensionResource expected = new org . lnu . is . resource . person . pension . PersonPensionResour... | org . junit . Assert . assertEquals ( expected , actual ) |
testMoveLocalizable ( ) { final long [ ] initial = new long [ ] { 532 , 632 , 987421 } ; final long [ ] displacement = new long [ ] { 85 , 8643 , - 973 } ; final net . imglib2 . Point p = new net . imglib2 . Point ( initial ) ; final net . imglib2 . Point d = new net . imglib2 . Point ( displacement ) ; p . move ( d ) ... | org . junit . Assert . assertEquals ( p . getLongPosition ( i ) , ( ( initial [ i ] ) + ( displacement [ i ] ) ) ) |
testCompressionPolicyBuilder ( ) { java . util . Collection < org . apache . neethi . Assertion > c = new java . util . ArrayList < org . apache . neethi . Assertion > ( ) ; org . apache . cxf . ws . policy . AssertionInfoMap aim = new org . apache . cxf . ws . policy . AssertionInfoMap ( c ) ; org . apache . cxf . mes... | org . junit . Assert . assertNull ( org . talend . esb . policy . compression . impl . CompressionPolicyBuilder . getAssertion ( m ) ) |
REG_EXPAND_SZ_getData ( ) { final byte [ ] data = new byte [ ] { '?' , 0 , 0 , 0 } ; final com . rapid7 . client . dcerpc . msrrp . dto . RegistryValue value = new com . rapid7 . client . dcerpc . msrrp . dto . RegistryValue ( "test" , com . rapid7 . client . dcerpc . msrrp . dto . RegistryValueType . REG_EXPAND_SZ , d... | org . junit . Assert . assertArrayEquals ( data , value . getData ( ) ) |
testJacksonUnableToDeserializeInvalidJson ( ) { com . xebia . jacksonlombok . JacksonLombokAnnotationIntrospectorTest . ImmutablePojo output = mapperWithExtention . readValue ( com . xebia . jacksonlombok . JacksonLombokAnnotationIntrospectorTest . INVALID_JSON , com . xebia . jacksonlombok . JacksonLombokAnnotationInt... | org . junit . Assert . assertThat ( output , org . hamcrest . core . Is . is ( instance ) ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.