input stringlengths 28 18.7k | output stringlengths 39 1.69k |
|---|---|
testGetActionsParent ( ) { com . eclipsesource . tabris . internal . ui . RemoteUI remoteUI = new com . eclipsesource . tabris . internal . ui . RemoteUI ( shell ) ; org . eclipse . swt . widgets . Composite uiParent = remoteUI . getActionsParent ( ) ; "<AssertPlaceHolder>" ; } getActionsParent ( ) { return actionsBar ... | org . junit . Assert . assertSame ( shell , uiParent ) |
testGetJobs ( ) { java . util . List < org . gitlab4j . api . models . Job > jobs = org . gitlab4j . api . TestJobApi . gitLabApi . getJobApi ( ) . getJobs ( org . gitlab4j . api . TestJobApi . testProjectId . intValue ( ) ) ; "<AssertPlaceHolder>" ; } getJobs ( java . lang . Integer ) { return getJobs ( runnerId , nul... | org . junit . Assert . assertNotNull ( jobs ) |
testSetBindingIndex_returnsCell ( ) { org . eclipse . rap . rwt . template . Cell < ? > cell = new org . eclipse . rap . rwt . template . TestCell ( template , "foo" ) ; org . eclipse . rap . rwt . template . Cell < ? > actualCell = cell . setBindingIndex ( 1 ) ; "<AssertPlaceHolder>" ; } setBindingIndex ( int ) { bind... | org . junit . Assert . assertSame ( cell , actualCell ) |
testProcessSongBadLine ( ) { java . lang . String testDisc = "testDisc" ; org . bff . javampd . processor . DiscTagProcessor discTagProcessor = new org . bff . javampd . processor . DiscTagProcessor ( ) ; org . bff . javampd . song . MPDSong song = new org . bff . javampd . song . MPDSong ( "testFile" , "testName" ) ; ... | org . junit . Assert . assertNull ( song . getDiscNumber ( ) ) |
testDeleteAplicacionByCodigo ( ) { int count = getAplicacionManager ( ) . count ( ) ; getAplicacionManager ( ) . deleteAplicacionByCodigo ( es . ieci . tecdoc . fwktd . csv . api . manager . impl . AplicacionManagerImplTest . CODIGO_APLICACION_BORRAR ) ; "<AssertPlaceHolder>" ; } getAplicacionManager ( ) { return fwktd... | org . junit . Assert . assertEquals ( getAplicacionManager ( ) . count ( ) , ( count - 1 ) ) |
fullUrlCanHaveUncommonDomainPostfixInfo ( ) { shortUrl . setFullUrl ( "http://repasky.info" ) ; constraintViolations = com . repaskys . domain . ShortUrlTest . validator . validate ( shortUrl ) ; "<AssertPlaceHolder>" ; } setFullUrl ( java . lang . String ) { this . fullUrl = fullUrl ; } | org . junit . Assert . assertEquals ( 0 , constraintViolations . size ( ) ) |
matchesInputZeroOutputFalse3 ( ) { final com . freedomotic . plugins . CronSchedule . SingleTimeValue objectUnderTest = new com . freedomotic . plugins . CronSchedule . SingleTimeValue ( 1 ) ; final int timeValue = 0 ; final boolean retval = objectUnderTest . matches ( timeValue ) ; "<AssertPlaceHolder>" ; } matches ( ... | org . junit . Assert . assertEquals ( false , retval ) |
testProvider ( ) { startServer ( com . sun . jersey . osgi . tests . jetty . GrizzlyWebProviderLifecycleTest . FileReferenceWriter . class , com . sun . jersey . osgi . tests . jetty . GrizzlyWebProviderLifecycleTest . FileTypeResource . class ) ; com . sun . jersey . api . client . WebResource r = com . sun . jersey .... | org . junit . Assert . assertTrue ( f . exists ( ) ) |
check ( ) { final org . apache . openejb . assembler . classic . ReloadableEntityManagerFactory remf = ( ( org . apache . openejb . assembler . classic . ReloadableEntityManagerFactory ) ( emf ) ) ; "<AssertPlaceHolder>" ; } getManagedClasses ( ) { return managedClasses ; } | org . junit . Assert . assertEquals ( 0 , remf . getManagedClasses ( ) . size ( ) ) |
testWelAdresgevendGeenBrpMoeder ( ) { final java . util . List < nl . bzk . brp . model . basis . BerichtEntiteit > overtreders = brby0103 . voerRegelUit ( null , maakNieuweSituatie ( nl . bzk . brp . bijhouding . business . regels . impl . bijhouding . afstamming . acties . geboorte . BRBY0103Test . MOEDER_IS_ADRESGEV... | org . junit . Assert . assertEquals ( 0 , overtreders . size ( ) ) |
testWithOOPathOnSingleItem ( ) { final java . lang . String drl = ( ( ( ( ( ( ( ( ( ( "package<sp>org.drools.compiler.integrationtests\n" + "unit<sp>" ) + ( getCanonicalSimpleName ( org . drools . compiler . integrationtests . RuleUnitTest . AdultUnitWithSingleItem . class ) ) ) + "\n" ) + "import<sp>" ) + ( org . droo... | org . junit . Assert . assertEquals ( 1 , executor . run ( adultUnit ) ) |
testGetBoundingBoxZoom ( ) { final int tileSize = 256 ; final int screenWidth = tileSize * 2 ; final int screenHeight = screenWidth * 2 ; org . osmdroid . util . TileSystem . setTileSize ( tileSize ) ; final int iterations = 2000 ; for ( int i = 0 ; i < iterations ; i ++ ) { final double north = getRandomLatitude ( ) ;... | org . junit . Assert . assertTrue ( ( ( north <= south ) || ( east == west ) ) ) |
shouldHaveSingletonOK ( ) { com . spotify . apollo . Response < java . lang . Object > ok1 = com . spotify . apollo . Response . ok ( ) ; com . spotify . apollo . Response < java . lang . Object > ok2 = com . spotify . apollo . Response . forStatus ( Status . OK ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertSame ( ok1 , ok2 ) |
should_call_correct_direction ( ) { java . util . List < au . edu . wehi . idsv . VariantContextDirectedEvidence > calls = com . google . common . collect . Lists . newArrayList ( new au . edu . wehi . idsv . BreakendMaximalEvidenceCliqueIterator ( getContext ( ) , com . google . common . collect . ImmutableList . < au... | org . junit . Assert . assertEquals ( 0 , calls . size ( ) ) |
shouldCloseReclaimWindowOnComplete ( ) { givenServer ( ) ; clientRecoveryStore . reclaimComplete ( ) ; "<AssertPlaceHolder>" ; } waitingForReclaim ( ) { return false ; } | org . junit . Assert . assertFalse ( clientRecoveryStore . waitingForReclaim ( ) ) |
v6Attributes ( ) { org . everit . json . schema . NumberSchema expected = org . everit . json . schema . NumberSchema . builder ( ) . minimum ( 5 ) . maximum ( 10 ) . multipleOf ( 2 ) . exclusiveMinimum ( 5 ) . exclusiveMaximum ( 10 ) . build ( ) ; org . everit . json . schema . NumberSchema actual = ( ( org . everit .... | org . junit . Assert . assertEquals ( expected , actual ) |
testCeilDoubleInWhere ( ) { java . sql . Connection conn = java . sql . DriverManager . getConnection ( getUrl ( ) ) ; java . sql . ResultSet rs = conn . createStatement ( ) . executeQuery ( ( ( "SELECT<sp>*<sp>FROM<sp>" + ( tableName ) ) + "<sp>WHERE<sp>CEIL(doub,<sp>2)<sp>=<sp>1.27" ) ) ; "<AssertPlaceHolder>" ; } ne... | org . junit . Assert . assertTrue ( rs . next ( ) ) |
testDotDiv ( ) { "<AssertPlaceHolder>" ; } dotDiv ( java . lang . Object , java . lang . Object ) { return null ; } | org . junit . Assert . assertNull ( e . dotDiv ( o ( 0 ) , o ( 0 ) ) ) |
getAParameterFromABadPath ( ) { org . silverpeas . core . util . XmlSettingBundle bundle = org . silverpeas . core . util . ResourceLocator . getXmlSettingBundle ( org . silverpeas . core . util . XmlSettingBundleTest . XML_SETTING_BUNDLE ) ; "<AssertPlaceHolder>" ; bundle . getString ( "BD_Silverpeas-configuration.Dri... | org . junit . Assert . assertThat ( bundle . exists ( ) , is ( true ) ) |
testDisplayname ( ) { com . github . sardine . DavResource folder = new com . github . sardine . DavResourceTest . Builder ( "/test/path/" ) . withDisplayName ( "My<sp>path" ) . build ( ) ; "<AssertPlaceHolder>" ; } getDisplayName ( ) { return displayName ; } | org . junit . Assert . assertEquals ( "My<sp>path" , folder . getDisplayName ( ) ) |
when_setAllDatasets_then_stationaryFilterActive ( ) { org . n52 . io . request . IoParameters parameters = org . n52 . io . request . IoParameters . createDefaults ( ) ; org . n52 . io . request . FilterResolver resolver = createResolver ( parameters ) ; "<AssertPlaceHolder>" ; } hasMobileFilter ( ) { return ( paramete... | org . junit . Assert . assertFalse ( resolver . hasMobileFilter ( ) ) |
orderOfEnvVarsIsIrrelevant ( ) { com . facebook . buck . rules . args . StringArg arg = com . facebook . buck . rules . args . StringArg . of ( "arbitrary" ) ; com . facebook . buck . core . toolchain . tool . impl . CommandTool one = com . facebook . buck . core . toolchain . tool . impl . CommandToolRuleKeyTest . com... | org . junit . Assert . assertThat ( ruleKey ( one ) , org . hamcrest . Matchers . equalTo ( ruleKey ( two ) ) ) |
testTrueCount ( ) { int [ ] expected = new int [ ] { 4 , 3 , 2 , 1 , 0 } ; int [ ] [ ] dense = new int [ ] [ ] { new int [ ] { 0 , 1 , 1 , 1 , 1 } , new int [ ] { 0 , 0 , 1 , 1 , 1 } , new int [ ] { 0 , 0 , 0 , 1 , 1 } , new int [ ] { 0 , 0 , 0 , 0 , 1 } , new int [ ] { 0 , 0 , 0 , 0 , 0 } } ; org . numenta . nupic . u... | org . junit . Assert . assertArrayEquals ( expected , sp . getTrueCounts ( ) ) |
testGetAttribute ( ) { expect ( servletContext . getAttribute ( "whatever" ) ) . andReturn ( "value" ) ; replay ( servletContext , config ) ; org . apache . tiles . web . util . ServletContextAdapter adapter = new org . apache . tiles . web . util . ServletContextAdapter ( config ) ; "<AssertPlaceHolder>" ; } getAttrib... | org . junit . Assert . assertEquals ( "value" , adapter . getAttribute ( "whatever" ) ) |
testNoFunctionImport ( ) { com . sap . core . odata . processor . core . jpa . model . JPAEdmFunctionImportTest . VARIANT = 99 ; build ( ) ; java . util . List < com . sap . core . odata . api . edm . provider . FunctionImport > functionImportList = jpaEdmfunctionImport . getConsistentFunctionImportList ( ) ; "<AssertP... | org . junit . Assert . assertEquals ( functionImportList . size ( ) , 0 ) |
testGetFinalResponse ( ) { System . out . println ( "getFinalResponse" ) ; gov . hhs . fha . nhinc . gateway . executorservice . NhinTaskExecutor < gov . hhs . fha . nhinc . orchestration . OutboundOrchestratableMessage , gov . hhs . fha . nhinc . orchestration . OutboundOrchestratableMessage > instance = new gov . hhs... | org . junit . Assert . assertEquals ( expResult , result ) |
isPlatformOperator_False ( ) { java . util . Set < org . oscm . internal . types . enumtypes . OrganizationRoleType > orgRoles = new java . util . HashSet < org . oscm . internal . types . enumtypes . OrganizationRoleType > ( ) ; org . oscm . internal . vo . VOUserDetails userDetails = new org . oscm . internal . vo . ... | org . junit . Assert . assertFalse ( isPlatformOperator ) |
should_Match_By_Field_But_Not_By_Regex_Path ( ) { underTest = new org . sonatype . nexus . repository . npm . internal . NpmFieldMatcher ( org . sonatype . nexus . repository . npm . internal . NpmFieldMatcherTest . FIELD_NAME , "/b(.*)b" , fieldDeserializer ) ; "<AssertPlaceHolder>" ; } matches ( java . lang . Object ... | org . junit . Assert . assertFalse ( underTest . matches ( parser ) ) |
canHaveEntriesWithDefaultTextAndSomeModificationToAnExistingFile2 ( ) { java . lang . String authorName = "Test<sp>Author" ; java . lang . String email = "/ChangeLog" 2 ; final java . lang . String dateLine = gnuFormatter . formatDateLine ( authorName , email ) ; java . lang . String changelogPath = ( "/ChangeLog" 1 + ... | org . junit . Assert . assertEquals ( expectedResult , actualMergeResult ) |
testStripPrefixNullPrefix ( ) { java . lang . String value = "prefixed.option" ; java . lang . String result = org . apache . qpid . jms . util . PropertyUtil . stripPrefix ( value , null ) ; "<AssertPlaceHolder>" ; } stripPrefix ( java . lang . String , java . lang . String ) { if ( ( ( value != null ) && ( prefix != ... | org . junit . Assert . assertSame ( value , result ) |
testGetExternalReport ( ) { org . oscm . reportingservice . business . model . externalservices . RDOExternal report = reporting . getExternalServicesReport ( org . oscm . reportingservice . bean . ReportingServiceBeanTest . VALID_SESSION_ID ) ; "<AssertPlaceHolder>" ; } getExternalServicesReport ( java . lang . String... | org . junit . Assert . assertNotNull ( report ) |
testGetSummaryNs ( ) { com . jmethods . catatumbo . stats . StatTotalNs stat = com . jmethods . catatumbo . DatastoreStatsTest . stats . getSummaryNs ( ) ; com . google . cloud . datastore . Key key = com . jmethods . catatumbo . DatastoreStatsTest . datastore . newKeyFactory ( ) . setKind ( StatConstants . STAT_TOTAL_... | org . junit . Assert . assertTrue ( com . jmethods . catatumbo . DatastoreStatsTest . equals ( stat , nativeEntity ) ) |
testCreate ( ) { org . oscarehr . billing . CA . BC . model . BillingHistory entity = new org . oscarehr . billing . CA . BC . model . BillingHistory ( ) ; org . oscarehr . common . dao . utils . EntityDataGenerator . generateTestDataForModelClass ( entity ) ; dao . persist ( entity ) ; "<AssertPlaceHolder>" ; } getId ... | org . junit . Assert . assertNotNull ( entity . getId ( ) ) |
datasetShouldNotBeDeaccessionedWithArchivedAndReleasedVersions ( ) { java . util . List < edu . harvard . iq . dataverse . DatasetVersion > versionList = new java . util . ArrayList < edu . harvard . iq . dataverse . DatasetVersion > ( ) ; versionList . add ( this . archivedVersion ) ; versionList . add ( this . releas... | org . junit . Assert . assertFalse ( dataset . isDeaccessioned ( ) ) |
findExactFilePath ( ) { final java . nio . file . Path path = com . hartwig . hmftools . common . io . path . PathRegexFinder . build ( ) . findPath ( com . hartwig . hmftools . common . io . path . PathRegexFinderTest . BASE_DIRECTORY , com . hartwig . hmftools . common . io . path . PathRegexFinderTest . EXISTING_FIL... | org . junit . Assert . assertNotNull ( path ) |
testFileBlockReplicationAffectingMaintenance ( ) { int defaultReplication = getConf ( ) . getInt ( DFSConfigKeys . DFS_REPLICATION_KEY , DFSConfigKeys . DFS_REPLICATION_DEFAULT ) ; int defaultMaintenanceMinRepl = getConf ( ) . getInt ( DFSConfigKeys . DFS_NAMENODE_MAINTENANCE_REPLICATION_MIN_KEY , DFSConfigKeys . DFS_N... | org . junit . Assert . assertTrue ( ( maintenanceMinRepl <= defaultReplication ) ) |
sum_n_values_java ( ) { int sumNValues = 0 ; for ( int x = 0 ; x < 5 ; x ++ ) { sumNValues += numbers . get ( x ) ; } "<AssertPlaceHolder>" ; } | org . junit . Assert . assertEquals ( 15 , sumNValues ) |
testFacilitiesName ( ) { org . matsim . api . core . v01 . Scenario scenario = org . matsim . core . scenario . ScenarioUtils . createScenario ( org . matsim . core . config . ConfigUtils . createConfig ( ) ) ; org . matsim . facilities . ActivityFacilities facilities = scenario . getActivityFacilities ( ) ; org . mats... | org . junit . Assert . assertEquals ( desc , desc2 ) |
testEmpty ( ) { try ( org . apache . jackrabbit . oak . segment . file . JournalReader journalReader = createJournalReader ( "" ) ) { "<AssertPlaceHolder>" ; } } hasNext ( ) { return ( current . next ) != null ; } | org . junit . Assert . assertFalse ( journalReader . hasNext ( ) ) |
instantiation ( ) { org . junithelper . core . filter . impl . TrimQuotationFilter target = new org . junithelper . core . filter . impl . TrimQuotationFilter ( ) ; "<AssertPlaceHolder>" ; } | org . junit . Assert . assertNotNull ( target ) |
testGetExplanationChunkBuilderData1 ( ) { int type = ExplanationChunkBuilderFactory . DATA ; org . goodoldai . jeff . explanation . builder . ExplanationChunkBuilder result = instance . getExplanationChunkBuilder ( type ) ; "<AssertPlaceHolder>" ; } getExplanationChunkBuilder ( int ) { if ( ( i18nManager ) == null ) th... | org . junit . Assert . assertTrue ( ( result instanceof org . goodoldai . jeff . explanation . builder . DefaultDataExplanationChunkBuilder ) ) |
handleEvent_PercentType0invertPercentFalse_returnPercentType0 ( ) { org . openhab . binding . zwave . internal . converter . ZWaveMultiLevelSwitchConverter sut = new org . openhab . binding . zwave . internal . converter . ZWaveMultiLevelSwitchConverter ( controller ) ; java . util . Map < java . lang . String , java .... | org . junit . Assert . assertEquals ( new org . eclipse . smarthome . core . library . types . PercentType ( 0 ) , state ) |
mergeTest ( ) { boolean result = org . opendaylight . aaa . cert . utils . MdsalUtils . merge ( org . opendaylight . aaa . cert . test . MdsalUtilsTest . dataBroker , LogicalDatastoreType . CONFIGURATION , org . opendaylight . aaa . cert . test . MdsalUtilsTest . instanceIdentifier , org . opendaylight . aaa . cert . t... | org . junit . Assert . assertTrue ( result ) |
testListPropertyInitNotDirty ( ) { org . nuxeo . ecm . core . api . model . impl . ListProperty property = getListProperty ( ) ; "<AssertPlaceHolder>" ; } isDirty ( ) { return ( ( listDiff ) != null ) && ( listDiff . isDirty ( ) ) ; } | org . junit . Assert . assertFalse ( property . isDirty ( ) ) |
testCheckAttributeValueElixirNamespace ( ) { System . out . println ( "testCheckAttributeValue()" ) ; cz . metacentrum . perun . core . api . Attribute attribute = new cz . metacentrum . perun . core . api . Attribute ( ) ; attribute . setFriendlyName ( "login-namespace:elixir-persistent" ) ; attribute . setValue ( "28... | org . junit . Assert . assertEquals ( attribute . getValue ( ) . toString ( ) , "28c5353b8bb34984a8bd4169ba94c606@elixir-europe.org" ) |
testRegions ( ) { com . runabove . api . RunAboveManager runAboveApi = login ( ) ; java . lang . String [ ] regions = runAboveApi . getRegions ( ) ; "<AssertPlaceHolder>" ; for ( java . lang . String string : regions ) { com . runabove . ApiTest . LOG . info ( ( "Regions<sp>" + string ) ) ; } } login ( ) { return new c... | org . junit . Assert . assertNotNull ( regions ) |
copyToLocalWildcardNotDir ( ) { java . lang . String testDir = alluxio . client . cli . fs . FileSystemShellUtilsTest . resetFileHierarchy ( mFileSystem ) ; new java . io . File ( ( ( mLocalAlluxioCluster . getAlluxioHome ( ) ) + "/testDir" ) ) . mkdir ( ) ; new java . io . File ( ( ( mLocalAlluxioCluster . getAlluxioH... | org . junit . Assert . assertEquals ( ( - 1 ) , ret ) |
testGetPartId ( ) { JWBF . cache = com . google . common . collect . ImmutableMap . < java . lang . String , java . lang . String > builder ( ) . put ( "jwbf-generic-mediawiki" , "anyVersion" ) . build ( ) ; java . lang . String partId = net . sourceforge . jwbf . JWBF . getPartId ( net . sourceforge . jwbf . mediawiki... | org . junit . Assert . assertEquals ( "jwbf-generic-mediawiki" , partId ) |
setMergedFalse ( ) { reset ( gridLayer ) ; dtPresenter . setMerged ( false ) ; "<AssertPlaceHolder>" ; verify ( gridLayer , times ( 1 ) ) . draw ( ) ; } isMerged ( ) { return uiModel . isMerged ( ) ; } | org . junit . Assert . assertFalse ( dtPresenter . isMerged ( ) ) |
getActionsWhenHostNotSet ( ) { org . codice . ddf . catalog . actions . AbstractMetacardActionProviderTest . MetacardActionProvider actionProvider = createMetacardActionProvider ( ) ; when ( actionProvider . canHandleMetacard ( metacard ) ) . thenReturn ( true ) ; when ( actionProvider . createMetacardAction ( eq ( org... | org . junit . Assert . assertThat ( action , org . hamcrest . Matchers . is ( this . action ) ) |
parse ( ) { java . lang . String rac = "jdbc:oracle:thin:@(DESCRIPTION=(LOAD_BALANCE=on)" + ( ( "(ADDRESS=(PROTOCOL=TCP)(HOST=1.2.3.4)<sp>(PORT=1521))" + "(ADDRESS=(PROTOCOL=TCP)(HOST=1.2.3.5)<sp>(PORT=1522))" ) + "(CONNECT_DATA=(SERVICE_NAME=service)))" ) ; com . navercorp . pinpoint . plugin . jdbc . oracle . parser ... | org . junit . Assert . assertEquals ( description , value ) |
encodeBase64WithMultipleOf4CharactersSuccess ( ) { java . lang . String textToEncode = "This<sp>is<sp>a<sp>valid<sp>test>>>>????(aBcDeFgHiJKLmnoPqRstuVWXyz)0123456789" ; java . lang . String expectedBase64Result = "VGhpcyBpcyBhIHZhbGlkIHRlc3Q+Pj4+Pz8/PyhhQmNEZUZnSGlKS0xtbm9QcVJzdHVWV1h5eikwMTIzNDU2Nzg5" ; byte [ ] resu... | org . junit . Assert . assertEquals ( expectedBase64Result , new java . lang . String ( result ) ) |
testLexerNotSetWithRange2 ( ) { org . antlr . v4 . tool . LexerGrammar lg = new org . antlr . v4 . tool . LexerGrammar ( ( "mode<sp>0:0\n" 4 + "ID<sp>:<sp>~(\'a\'|\'b\')<sp>~(\'e\'|\'p\'..\'t\')\n<sp>;" ) ) ; java . lang . String expecting = "max<sp>type<sp>1\n" + ( ( ( ( ( ( ( ( ( ( ( ( ( ( ( "mode<sp>0:0\n" 5 + "1:RU... | org . junit . Assert . assertEquals ( expecting , result ) |
shouldGenerateXmlReportFile ( ) { final java . io . File reportFile = ro . isdc . wro . util . WroUtil . createTempFile ( ) ; try { ( ( ro . isdc . wro . maven . plugin . JsHintMojo ) ( getMojo ( ) ) ) . setReportFile ( reportFile ) ; getMojo ( ) . setOptions ( "undef,<sp>browser" ) ; getMojo ( ) . setTargetGroups ( nu... | org . junit . Assert . assertTrue ( ( ( reportFile . length ( ) ) > 1000 ) ) |
listWithOneItemShouldHaveOneItem ( ) { "<AssertPlaceHolder>" ; } count ( java . lang . Iterable ) { if ( iterable instanceof java . util . Collection ) { return ( ( java . util . Collection ) ( iterable ) ) . size ( ) ; } return org . neo4j . helpers . collection . Iterables . count ( iterable ) ; } | org . junit . Assert . assertEquals ( 1 , count ( asList ( "test" ) ) ) |
testRPCWithResult ( ) { java . lang . String result = "result" ; java . util . concurrent . Future < java . lang . String > future = com . liferay . portal . fabric . netty . rpc . RPCUtil . execute ( _embeddedChannel , new com . liferay . portal . fabric . netty . rpc . RPCUtilTest . ResultRPCCallable ( result ) ) ; _... | org . junit . Assert . assertEquals ( result , future . get ( ) ) |
testRondConverteerReisdocument ( ) { final nl . bzk . migratiebrp . conversie . model . lo3 . Lo3PersoonslijstBuilder builder = maakLo3PersoonslijstBuilder ( ) ; voegReisdocumentToe ( builder ) ; final nl . bzk . migratiebrp . conversie . model . lo3 . Lo3Persoonslijst lo3Persoonslijst = builder . build ( ) ; final nl ... | org . junit . Assert . assertEquals ( lo3Persoonslijst . getReisdocumentStapels ( ) , lo3Terug . getReisdocumentStapels ( ) ) |
whenPostRequestToEmployeeServlet_thenEmployeeReturnedAsJson ( ) { int id = 1 ; java . lang . String name = "Karan<sp>Khanna" ; java . lang . String department = "IT" ; long salary = 5000 ; employee = new com . baeldung . model . Employee ( id , name , department , salary ) ; java . io . StringWriter sw = new java . io ... | org . junit . Assert . assertEquals ( fetchedEmployee , employee ) |
testGetPages ( ) { doReturn ( GuidedDecisionTable52 . TableFormat . EXTENDED_ENTRY ) . when ( plugin ) . tableFormat ( ) ; final java . util . List < org . uberfire . ext . widgets . core . client . wizards . WizardPage > pages = plugin . getPages ( ) ; "<AssertPlaceHolder>" ; } size ( ) { return patternsByColumnNumber... | org . junit . Assert . assertEquals ( 4 , pages . size ( ) ) |
testGetJobsWhenNamespaceSpecifiedButDoesNotExistAssertResultEmpty ( ) { java . lang . String namespace = "namespace" ; java . lang . String jobName = "jobName" ; org . finra . herd . model . api . xml . JobStatusEnum jobStatus = org . finra . herd . model . api . xml . JobStatusEnum . COMPLETED ; java . util . Set < ja... | org . junit . Assert . assertEquals ( 0 , jobSummaries . size ( ) ) |
givenCSVFile_whenOpencsv_thenContentsAsExpected ( ) { java . util . List < java . util . List < java . lang . String > > records = new java . util . ArrayList < java . util . List < java . lang . String > > ( ) ; try ( com . opencsv . CSVReader csvReader = new com . opencsv . CSVReader ( new java . io . FileReader ( co... | org . junit . Assert . assertArrayEquals ( com . baeldung . csv . ReadCSVInArrayUnitTest . EXPECTED_ARRAY . get ( i ) . toArray ( ) , records . get ( i ) . toArray ( ) ) |
testPopulateReleases_setEmrReleaseToFirstElementFromEmrReleasesList ( ) { java . lang . String expectedEmrRelease = "emr-5.11.0" ; org . pentaho . amazon . hive . job . AmazonHiveJobExecutor jobEntry = spy ( new org . pentaho . amazon . hive . job . AmazonHiveJobExecutor ( ) ) ; org . pentaho . amazon . hive . ui . Ama... | org . junit . Assert . assertEquals ( expectedEmrRelease , jobEntry . getEmrRelease ( ) ) |
testGetEstimatedDurationWithOneRun ( ) { final java . util . SortedMap < java . lang . Integer , hudson . model . SimpleJobTest . TestBuild > runs = new java . util . TreeMap < java . lang . Integer , hudson . model . SimpleJobTest . TestBuild > ( ) ; hudson . model . Job project = createMockProject ( runs ) ; hudson .... | org . junit . Assert . assertEquals ( 42 , project . getEstimatedDuration ( ) ) |
testRemove ( ) { com . liferay . asset . kernel . model . AssetCategory newAssetCategory = addAssetCategory ( ) ; _persistence . remove ( newAssetCategory ) ; com . liferay . asset . kernel . model . AssetCategory existingAssetCategory = _persistence . fetchByPrimaryKey ( newAssetCategory . getPrimaryKey ( ) ) ; "<Asse... | org . junit . Assert . assertNull ( existingAssetCategory ) |
testShouldBeAbleToPassAWebElementAsArgument ( ) { driver . get ( pages . javascriptPage ) ; org . openqa . selenium . WebElement button = driver . findElement ( org . openqa . selenium . By . id ( "plainButton" ) ) ; java . lang . String value = ( ( java . lang . String ) ( executeScript ( "arguments[0]['flibble']<sp>=... | org . junit . Assert . assertEquals ( "plainButton" , value ) |
testSetSubIdNullRemoval ( ) { pool . getSourceSubscription ( ) . setSubscriptionSubKey ( null ) ; pool . setSubscriptionId ( null ) ; "<AssertPlaceHolder>" ; } getSourceSubscription ( ) { return sourceSubscription ; } | org . junit . Assert . assertNull ( pool . getSourceSubscription ( ) ) |
testSetAllMinReadBufferSize ( ) { org . kaazing . mina . netty . socket . nio . DefaultNioSocketChannelIoSessionConfig config = new org . kaazing . mina . netty . socket . nio . DefaultNioSocketChannelIoSessionConfig ( ) ; config . init ( new org . kaazing . mina . netty . socket . nio . NioSocketChannelIoAcceptor ( co... | org . junit . Assert . assertEquals ( config . getMinReadBufferSize ( ) , acceptedConfig . getMinReadBufferSize ( ) ) |
testParametersOkDstu2 ( ) { ca . uhn . fhir . model . dstu2 . resource . Patient patient = new ca . uhn . fhir . model . dstu2 . resource . Patient ( ) ; patient . addName ( ) . addGiven ( "James" ) ; patient . setBirthDate ( new ca . uhn . fhir . model . primitive . DateDt ( "2011-02-02" ) ) ; ca . uhn . fhir . model ... | org . junit . Assert . assertTrue ( result . isSuccessful ( ) ) |
resetBranchHeadTest ( ) { org . eclipse . jgit . lib . AnyObjectId firstCommit = initRepository ( ) ; writeToCache ( "a.txt" ) ; java . lang . String branchName = "second" ; org . eclipse . jgit . lib . AnyObjectId branchCommit = commitToBranch ( branchName , firstCommit ) ; com . beijunyi . parallelgit . utils . Branc... | org . junit . Assert . assertEquals ( branchCommit , com . beijunyi . parallelgit . utils . BranchUtils . getHeadCommit ( Constants . MASTER , repo ) ) |
testOverridingStateDisabled ( ) { descriptor . setState ( FeatureState . DISABLED ) ; com . tacitknowledge . flip . model . FeatureState state = descriptor . process ( contextManager ) ; "<AssertPlaceHolder>" ; } process ( com . tacitknowledge . flip . context . ContextManager ) { if ( ( conditions ) != null ) { for ( ... | org . junit . Assert . assertEquals ( FeatureState . DISABLED , state ) |
shouldNotBeValidWithNotEnoughCustomLength ( ) { when ( parameterService . findAll ( Key . API_QUALITY_METRICS_DESCRIPTION_MIN_LENGTH ) ) . thenReturn ( java . util . Arrays . asList ( "3" ) ) ; io . gravitee . management . model . api . ApiEntity api = mock ( io . gravitee . management . model . api . ApiEntity . class... | org . junit . Assert . assertFalse ( valid ) |
getReadyTimeout ( ) { configSettings . put ( PropertyHandler . READY_TIMEOUT , new org . oscm . app . v2_0 . data . Setting ( PropertyHandler . READY_TIMEOUT , "300000" ) ) ; propertyHandler = new org . oscm . app . openstack . controller . PropertyHandler ( settings ) ; long time = propertyHandler . getReadyTimeout ( ... | org . junit . Assert . assertEquals ( 300000 , time ) |
testGetByte ( ) { byte [ ] data = new byte [ ] { 100 } ; "<AssertPlaceHolder>" ; } getByte ( byte [ ] ) { if ( ( ( data . length ) * ( NetUtils . NUM_BITS_IN_A_BYTE ) ) > ( Byte . SIZE ) ) { org . opendaylight . l2switch . packethandler . decoders . utils . BitBufferHelper . LOG . error ( "getByte" , new org . opendayl... | org . junit . Assert . assertTrue ( ( ( org . opendaylight . l2switch . packethandler . decoders . utils . BitBufferHelper . getByte ( data ) ) == 100 ) ) |
testFetchRequestMaxBytesOldVersions ( ) { final short version = 1 ; org . apache . kafka . common . requests . FetchRequest fr = createFetchRequest ( version ) ; org . apache . kafka . common . requests . FetchRequest fr2 = new org . apache . kafka . common . requests . FetchRequest ( fr . toStruct ( ) , version ) ; "<... | org . junit . Assert . assertEquals ( fr2 . maxBytes ( ) , fr . maxBytes ( ) ) |
testConvert ( ) { java . lang . String name = "first<sp>blood" ; java . lang . String abbrName = "fb" ; java . lang . Long id = 1L ; java . lang . Long timePeriodId = 2L ; org . lnu . is . domain . timeperiod . TimePeriod timePeriod = new org . lnu . is . domain . timeperiod . TimePeriod ( ) ; timePeriod . setId ( time... | org . junit . Assert . assertEquals ( expected , actual ) |
testKind ( ) { org . antlr . runtime . tree . CommonTree sink = com . cloudera . flume . conf . FlumeBuilder . parseSink ( com . cloudera . flume . conf . TestPatternMatch . simple ) ; com . cloudera . flume . conf . PatternMatch pp = com . cloudera . flume . conf . PatternMatch . kind ( "DECO" ) ; java . util . Map < ... | org . junit . Assert . assertNotNull ( m ) |
testSomeEmptyOffsetsAdjacency ( ) { java . lang . String query = buildFunction ( ContentFunctions . CONTENT_ADJACENT_FUNCTION_NAME , "BODY" , Constants . TERM_OFFSET_MAP_JEXL_VARIABLE_NAME , "'foo'" , "'bar'" , "'car'" ) ; org . apache . commons . jexl2 . Expression expr = datawave . query . jexl . functions . ContentF... | org . junit . Assert . assertTrue ( datawave . query . jexl . functions . ContentFunctionsTest . expect ( o , false ) ) |
setBaseUrlExplicitly ( ) { fixture . baseUrl ( "http://localhost:1234" ) ; "<AssertPlaceHolder>" ; } getBaseUrl ( ) { return restFixture . getBaseUrl ( ) ; } | org . junit . Assert . assertThat ( fixture . getBaseUrl ( ) . toString ( ) , org . hamcrest . CoreMatchers . is ( "http://localhost:1234" ) ) |
testDesignNoElementOnPhysicalNetwork ( ) { final com . cloud . network . dao . PhysicalNetworkVO physnet = mock ( com . cloud . network . dao . PhysicalNetworkVO . class ) ; when ( physnetdao . findById ( ( ( java . lang . Long ) ( any ( ) ) ) ) ) . thenReturn ( physnet ) ; when ( physnet . getIsolationMethods ( ) ) . ... | org . junit . Assert . assertTrue ( ( designednetwork == null ) ) |
testGetAndSetJMSReplyTo ( ) { org . apache . qpid . jms . message . JmsMessage msg = factory . createMessage ( ) ; msg . setJMSReplyTo ( this . jmsReplyTo ) ; "<AssertPlaceHolder>" ; } getJMSReplyTo ( ) { return replyTo ; } | org . junit . Assert . assertTrue ( msg . getJMSReplyTo ( ) . equals ( this . jmsReplyTo ) ) |
testIntegration ( ) { org . apache . poi . xwpf . usermodel . XWPFDocument doc1 = new org . apache . poi . xwpf . usermodel . XWPFDocument ( ) ; org . apache . poi . xwpf . usermodel . XWPFParagraph p1 = doc1 . createParagraph ( ) ; org . apache . poi . xwpf . usermodel . XWPFRun r1 = p1 . createRun ( ) ; r1 . setText ... | org . junit . Assert . assertTrue ( doc2 . isEnforcedCommentsProtection ( ) ) |
testParseCatalogXML2 ( ) { owltools . io . LocalMirrorIRIMapper m = new owltools . io . LocalMirrorIRIMapper ( "src/test/resources/owl-mirror.txt" ) ; org . semanticweb . owlapi . model . IRI iri = m . getDocumentIRI ( org . semanticweb . owlapi . model . IRI . create ( "http://purl.obolibrary.org/obo/go.owl" ) ) ; "<A... | org . junit . Assert . assertNotNull ( iri ) |
testGroupMembershipByMemberQueries ( ) { org . picketlink . idm . IdentityManager identityManager = getIdentityManager ( ) ; org . picketlink . idm . query . IdentityQuery < org . picketlink . idm . model . basic . User > query = identityManager . createIdentityQuery ( org . picketlink . idm . model . basic . User . cl... | org . junit . Assert . assertFalse ( relationshipQuery . getResultList ( ) . isEmpty ( ) ) |
dividedBy6 ( ) { java . time . Duration duration1 = org . diirt . util . time . TimeDuration . TimeDuration . ofSeconds ( 10.4 ) ; java . time . Duration duration2 = org . diirt . util . time . TimeDuration . TimeDuration . ofSeconds ( 2.5 ) ; "<AssertPlaceHolder>" ; } dividedBy ( java . time . Duration , java . time .... | org . junit . Assert . assertThat ( org . diirt . util . time . TimeDuration . TimeDuration . dividedBy ( duration1 , duration2 ) , equalTo ( 4 ) ) |
testConsumeFromDurableQueue ( ) { org . apache . activemq . artemis . api . core . SimpleString queue = org . apache . activemq . artemis . utils . RandomUtil . randomSimpleString ( ) ; org . apache . activemq . artemis . api . core . SimpleString address = org . apache . activemq . artemis . utils . RandomUtil . rando... | org . junit . Assert . assertNotNull ( message ) |
toStringer ( ) { org . kitteh . irc . client . library . command . KickCommand command = new org . kitteh . irc . client . library . command . KickCommand ( this . client , org . kitteh . irc . client . library . command . KickCommandTest . CHANNEL ) ; "<AssertPlaceHolder>" ; } toString ( ) { return new org . kitteh . ... | org . junit . Assert . assertTrue ( command . toString ( ) . contains ( org . kitteh . irc . client . library . command . KickCommandTest . CHANNEL ) ) |
entrySetToArray ( ) { com . gs . collections . api . map . sorted . MutableSortedMap < java . lang . Integer , java . lang . String > map = this . newMapWithKeyValue ( 1 , "One" ) . asUnmodifiable ( ) ; java . lang . Object [ ] entries = map . entrySet ( ) . toArray ( ) ; "<AssertPlaceHolder>" ; } of ( T1 , T2 ) { retu... | org . junit . Assert . assertEquals ( com . gs . collections . impl . tuple . ImmutableEntry . of ( 1 , "One" ) , entries [ 0 ] ) |
testLongRndEven ( ) { try ( com . questdb . cairo . VirtualMemory mem = new com . questdb . cairo . VirtualMemory ( 11 ) ) { int n = 999 ; long o = 0 ; for ( int i = n ; i > 0 ; i -- ) { mem . putLong ( o , i ) ; o += 8 ; } o = 0 ; for ( int i = n ; i > 0 ; i -- ) { "<AssertPlaceHolder>" ; o += 8 ; } } } getLong ( int ... | org . junit . Assert . assertEquals ( i , mem . getLong ( o ) ) |
testSerialization ( ) { org . jfree . chart . block . BlockContainer c1 = new org . jfree . chart . block . BlockContainer ( ) ; c1 . add ( new org . jfree . chart . block . EmptyBlock ( 1.2 , 3.4 ) ) ; java . io . ByteArrayOutputStream buffer = new java . io . ByteArrayOutputStream ( ) ; java . io . ObjectOutput out =... | org . junit . Assert . assertEquals ( c1 , c2 ) |
findByIdReturnsTheVertexWithId ( ) { java . util . UUID id1 = java . util . UUID . randomUUID ( ) ; nl . knaw . huygens . timbuctoo . server . TinkerPopGraphManager tinkerPopGraphManager = newGraph ( ) . withVertex ( ( v ) -> v . withTimId ( id1 . toString ( ) ) . withProperty ( "keyword_type" , "keywordType" ) . withP... | org . junit . Assert . assertThat ( result . get ( ) . value ( "tim_id" ) , org . hamcrest . Matchers . is ( id1 . toString ( ) ) ) |
testQueryRow20RowTable ( ) { java . lang . String query = java . lang . String . format ( "select<sp>*<sp>from<sp>%s.%s<sp>where<sp>%s.%s.transaction_header_key<sp>=<sp>18" , com . splicemachine . derby . utils . test . DecoderIT . SCHEMA_NAME , com . splicemachine . derby . utils . test . DecoderIT . TransactionHeader... | org . junit . Assert . assertEquals ( 1 , fr . size ( ) ) |
shouldInvalidateAlreadyAcceptedInactiveTechnology ( ) { given ( technology . getId ( ) ) . willReturn ( 101L ) ; given ( techDataDefinition . get ( 101L ) ) . willReturn ( existingTechnology ) ; given ( technology . getStringField ( TechnologyFields . STATE ) ) . willReturn ( TechnologyState . ACCEPTED . getStringValue... | org . junit . Assert . assertFalse ( isValid ) |
testGetDrillDownProfile ( ) { org . pentaho . reporting . designer . extensions . pentaho . drilldown . PentahoPathModel model = new org . pentaho . reporting . designer . extensions . pentaho . drilldown . PentahoPathModel ( reportDesignerContext ) ; "<AssertPlaceHolder>" ; model . setLocalPath ( "MySolution/path/to/m... | org . junit . Assert . assertNotNull ( model ) |
testOverloadIsNotOverride ( ) { java . lang . reflect . Method m1 = org . apache . camel . component . bean . MyOtherFooBean . class . getMethod ( "toString" , java . lang . Object . class ) ; java . lang . reflect . Method m2 = org . apache . camel . component . bean . MyOtherFooBean . class . getMethod ( "toString" ,... | org . junit . Assert . assertFalse ( org . apache . camel . support . org . apache . camel . util . ObjectHelper . isOverridingMethod ( m2 , m1 , false ) ) |
testSendNotificationWithAppKeyWithSpecialCharacter21 ( ) { int erroCode = ErrorCodeEnum . NOERROR . value ( ) ; java . lang . String msgTitle = "jpush" ; java . lang . String msgContent = "jpush{}" ; cn . jpush . api . MessageResult result = jpush . sendNotificationWithAppKey ( sendNo , msgTitle , msgContent ) ; "<Asse... | org . junit . Assert . assertEquals ( erroCode , result . getErrcode ( ) ) |
testShouldEmit0 ( com . boozallen . cognition . ingest . storm . vo . LogRecord ) { bolt . field = "field" ; new mockit . Expectations ( ) { { record . getValue ( bolt . field ) ; result = "asdf" ; } } ; "<AssertPlaceHolder>" ; } shouldEmit ( com . boozallen . cognition . ingest . storm . vo . LogRecord ) { java . lang... | org . junit . Assert . assertThat ( bolt . shouldEmit ( record ) , org . hamcrest . core . Is . is ( true ) ) |
whenAddFoodInStorageCountFoodInStorageUp ( ) { ru . szhernovoy . ControlQuality control = new ru . szhernovoy . ControlQuality ( ) ; ru . szhernovoy . Food [ ] food = new ru . szhernovoy . Food [ 1 ] ; java . util . GregorianCalendar today = new java . util . GregorianCalendar ( 2016 , java . util . GregorianCalendar .... | org . junit . Assert . assertThat ( check , org . hamcrest . core . Is . is ( contain ) ) |
putTaskState ( ) { org . apache . kafka . connect . util . KafkaBasedLog < java . lang . String , byte [ ] > kafkaBasedLog = mock ( org . apache . kafka . connect . util . KafkaBasedLog . class ) ; org . apache . kafka . connect . storage . Converter converter = mock ( org . apache . kafka . connect . storage . Convert... | org . junit . Assert . assertEquals ( null , store . get ( org . apache . kafka . connect . storage . KafkaStatusBackingStoreTest . TASK ) ) |
canAdjustLastTransactionThatIsAWithdrawal ( ) { savingsProduct = new org . mifos . domain . builders . SavingsProductBuilder ( ) . mandatory ( ) . withMandatoryAmount ( "33.0" ) . withMaxWithdrawalAmount ( org . mifos . framework . TestUtils . createMoney ( "50" ) ) . appliesToClientsOnly ( ) . buildForUnitTests ( ) ; ... | org . junit . Assert . assertTrue ( result ) |
testConfigureStaticNatRulesOnLogicalRouter ( ) { resource . configure ( "NiciraNvpResource" , parameters ) ; final com . cloud . agent . api . ConfigureStaticNatRulesOnLogicalRouterCommand cmd = mock ( com . cloud . agent . api . ConfigureStaticNatRulesOnLogicalRouterCommand . class ) ; final com . cloud . agent . api ... | org . junit . Assert . assertTrue ( a . getResult ( ) ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.