input
stringlengths
28
18.7k
output
stringlengths
39
1.69k
testScriptDereferencing ( ) { java . util . Map < java . lang . String , java . lang . Object > johndoe = new java . util . HashMap ( ) ; johndoe . put ( "fullName" , "John<sp>Doe" ) ; com . effektif . workflow . api . workflow . ExecutableWorkflow workflow = new com . effektif . workflow . api . workflow . ExecutableWorkflow ( ) . variable ( "user" , new com . effektif . workflow . impl . data . types . ObjectType ( ) ) . variable ( "name" , new com . effektif . workflow . api . types . TextType ( ) ) . activity ( "s" , new com . effektif . script . ScriptTask ( ) . script ( "name<sp>=<sp>user.fullName;" ) ) ; deploy ( workflow ) ; com . effektif . workflow . api . workflowinstance . WorkflowInstance workflowInstance = workflowEngine . start ( new com . effektif . workflow . api . model . TriggerInstance ( ) . workflowId ( workflow . getId ( ) ) . data ( "user" , johndoe ) ) ; "<AssertPlaceHolder>" ; } getVariableValue ( java . lang . String ) { if ( variableId == null ) { return null ; } if ( ( variableInstances ) != null ) { for ( com . effektif . workflow . api . workflowinstance . VariableInstance variableInstance : variableInstances ) { if ( variableId . equals ( variableInstance . getVariableId ( ) ) ) { return ( ( T ) ( variableInstance . getValue ( ) ) ) ; } } } return null ; }
org . junit . Assert . assertEquals ( "John<sp>Doe" , workflowInstance . getVariableValue ( "name" ) )
testSerializable ( ) { @ com . vaadin . flow . internal . SuppressWarnings ( "unchecked" ) java . lang . Class < ? extends com . vaadin . flow . internal . nodefeature . NodeFeature > [ ] features = new java . lang . Class [ ] { com . vaadin . flow . internal . nodefeature . ElementChildrenList . class , com . vaadin . flow . internal . nodefeature . ElementData . class , com . vaadin . flow . internal . nodefeature . ElementAttributeMap . class , com . vaadin . flow . internal . nodefeature . ElementPropertyMap . class } ; com . vaadin . flow . internal . StateTree tree = new com . vaadin . flow . internal . StateTree ( new com . vaadin . flow . component . UI ( ) . getInternals ( ) , features ) ; com . vaadin . flow . internal . StateNode root = tree . getRootNode ( ) ; root . getFeature ( com . vaadin . flow . internal . nodefeature . ElementData . class ) . setTag ( "body" ) ; com . vaadin . flow . internal . StateNode child = new com . vaadin . flow . internal . StateNode ( features ) ; root . getFeature ( com . vaadin . flow . internal . nodefeature . ElementChildrenList . class ) . add ( 0 , child ) ; child . getFeature ( com . vaadin . flow . internal . nodefeature . ElementData . class ) . setTag ( Tag . DIV ) ; byte [ ] serialized = org . apache . commons . lang3 . SerializationUtils . serialize ( tree ) ; com . vaadin . flow . internal . StateTree d1 = ( ( com . vaadin . flow . internal . StateTree ) ( org . apache . commons . lang3 . SerializationUtils . deserialize ( serialized ) ) ) ; "<AssertPlaceHolder>" ; } setTag ( java . lang . String ) { this . tag = tag ; }
org . junit . Assert . assertNotNull ( d1 )
testRegistrationWithoutHealthCheck ( ) { final com . spotify . helios . agent . TaskConfig taskConfig = com . spotify . helios . agent . TaskConfig . builder ( ) . namespace ( "test" ) . host ( com . spotify . helios . agent . TaskConfigTest . HOST ) . job ( com . spotify . helios . agent . TaskConfigTest . JOB ) . build ( ) ; final com . spotify . helios . serviceregistration . ServiceRegistration . Endpoint endpoint = taskConfig . registration ( ) . getEndpoints ( ) . get ( 0 ) ; "<AssertPlaceHolder>" ; } getHealthCheck ( ) { return healthCheck ; }
org . junit . Assert . assertNull ( endpoint . getHealthCheck ( ) )
testGetFragmentSize ( ) { org . openscience . cdk . smiles . SmilesParser sp = new org . openscience . cdk . smiles . SmilesParser ( org . openscience . cdk . DefaultChemObjectBuilder . getInstance ( ) ) ; org . openscience . cdk . interfaces . IAtomContainer target = sp . parseSmiles ( "C\\C=C/Nc1cccc(c1)N(O)\\C=C\\C\\C=C\\C=C/C" ) ; org . openscience . cdk . interfaces . IAtomContainer query = sp . parseSmiles ( "Nc1ccccc1" ) ; org . openscience . smsd . Isomorphism smsd1 = new org . openscience . smsd . Isomorphism ( query , target , org . openscience . smsd . interfaces . Algorithm . DEFAULT , true , false , true ) ; smsd1 . setChemFilters ( false , true , false ) ; java . lang . Integer score = 2 ; "<AssertPlaceHolder>" ; } getFragmentSize ( int ) { return ( ( fragmentSizeList ) != null ) && ( ! ( fragmentSizeList . isEmpty ( ) ) ) ? fragmentSizeList . get ( Key ) : null ; }
org . junit . Assert . assertEquals ( score , smsd1 . getFragmentSize ( 0 ) )
testMultipleStmtEPL ( ) { java . lang . String EPL1 = "<sp>select<sp>*<sp>from<sp>TestEvent;<sp>" + ( "<sp>Select<sp>timemillis<sp>from<sp>TestEvent;<sp>" + "<sp>@OutputTo(\"omc\")<sp>select<sp>*<sp>from<sp>TestEvent;<sp>" ) ; com . ebay . jetstream . event . processor . esper . EPL epl = new com . ebay . jetstream . event . processor . esper . EPL ( ) ; epl . setStatementBlock ( EPL1 ) ; com . ebay . jetstream . event . processor . esper . EsperProcessor proc = new com . ebay . jetstream . event . processor . esper . EsperProcessor ( ) ; com . ebay . jetstream . event . processor . esper . EsperConfiguration config = new com . ebay . jetstream . event . processor . esper . EsperConfiguration ( ) ; config . addEventType ( "TestEvent" , com . ebay . jetstream . epl . EPLCompileTest . TestEvents . class ) ; config . addImport ( com . ebay . jetstream . event . processor . esper . annotation . OutputTo . class ) ; proc . setConfiguration ( config ) ; "<AssertPlaceHolder>" ; } compileEPL ( com . ebay . jetstream . event . processor . esper . EPL ) { com . ebay . jetstream . event . processor . esper . EsperProcessor . EsperInternals esperInternals = null ; try { if ( epl != null ) { esperInternals = new com . ebay . jetstream . event . processor . esper . EsperProcessor . EsperInternals ( "compileEngine" , epl ) ; esperInternals . compile ( false ) ; return true ; } return false ; } finally { if ( esperInternals != null ) { esperInternals . getEsperService ( ) . destroy ( ) ; esperInternals . clear ( ) ; } } }
org . junit . Assert . assertTrue ( proc . compileEPL ( epl ) )
testBuildNumber ( ) { com . exigeninsurance . x4j . analytic . model . Attribute a = new com . exigeninsurance . x4j . analytic . model . Attribute ( ) ; a . setName ( ReportMetadata . VERSION ) ; a . setValue ( "1" ) ; java . util . List < com . exigeninsurance . x4j . analytic . model . Attribute > list = new java . util . ArrayList < com . exigeninsurance . x4j . analytic . model . Attribute > ( ) ; list . add ( a ) ; metadata . setAttribute ( list ) ; "<AssertPlaceHolder>" ; } getBuildNumber ( ) { for ( com . exigeninsurance . x4j . analytic . model . Attribute attr : getAttributes ( ) ) { if ( com . exigeninsurance . x4j . analytic . model . ReportMetadata . VERSION . equals ( attr . getName ( ) ) ) { return attr . getValue ( ) ; } } return null ; }
org . junit . Assert . assertEquals ( "1" , metadata . getBuildNumber ( ) )
testeableConnectionProvider ( ) { org . mule . runtime . api . meta . model . connection . ConnectionProviderModel connectionProviderModel = veganExtension . getConfigurationModel ( org . mule . runtime . module . extension . internal . loader . BANANA ) . map ( ( c ) -> c . getConnectionProviders ( ) . get ( 0 ) ) . get ( ) ; "<AssertPlaceHolder>" ; } supportsConnectivityTesting ( ) { return ! ( ( super . getDeclaringClass ( ) . isPresent ( ) ) && ( org . mule . runtime . extension . api . connectivity . NoConnectivityTest . class . isAssignableFrom ( super . getDeclaringClass ( ) . get ( ) ) ) ) ; }
org . junit . Assert . assertThat ( connectionProviderModel . supportsConnectivityTesting ( ) , org . hamcrest . CoreMatchers . is ( true ) )
testResolvedItems_300PreloadedItems ( ) { tree = new org . eclipse . swt . widgets . Tree ( shell , org . eclipse . swt . SWT . VIRTUAL ) ; tree . setData ( RWT . PRELOADED_ITEMS , java . lang . Integer . valueOf ( 300 ) ) ; tree . setSize ( 100 , 100 ) ; tree . setItemCount ( 200 ) ; org . eclipse . swt . widgets . Tree_Test . getTreeAdapter ( tree ) . setTopItemIndex ( 100 ) ; org . eclipse . swt . widgets . Tree_Test . redrawTree ( tree ) ; "<AssertPlaceHolder>" ; } countResolvedItems ( org . eclipse . swt . widgets . Tree ) { return org . eclipse . swt . widgets . Tree_Test . countResolvedItems ( org . eclipse . swt . widgets . Tree_Test . getTreeAdapter ( tree ) , tree . getItems ( ) ) ; }
org . junit . Assert . assertEquals ( 200 , org . eclipse . swt . widgets . Tree_Test . countResolvedItems ( tree ) )
getOrCreateCache_Same ( ) { java . lang . String name = "c1" ; javax . cache . CacheManager cacheManager = getCacheManager ( ) ; cacheManager . createCache ( name , new javax . cache . configuration . MutableConfiguration ( ) ) ; javax . cache . Cache cache = cacheManager . getCache ( name ) ; "<AssertPlaceHolder>" ; } getCacheManager ( ) { javax . cache . spi . CachingProvider provider = javax . cache . Caching . getCachingProvider ( ) ; java . net . URI uri = provider . getDefaultURI ( ) ; return javax . cache . Caching . getCachingProvider ( ) . getCacheManager ( uri , provider . getDefaultClassLoader ( ) ) ; }
org . junit . Assert . assertSame ( cache , cacheManager . getCache ( name ) )
whenMultipleValues_sort ( ) { java . util . List < java . lang . String > values = java . util . Arrays . asList ( "v3beta1" 0 , "foo1" , "v3beta2" , "v2" , "v1" , "v3beta1" , "v11alpha2" , "v10beta3" , "v10" , "foo10" , "v12alpha1" ) ; java . util . List < oracle . kubernetes . operator . helpers . ResourceVersion > rvs = values . stream ( ) . map ( ( e ) -> new oracle . kubernetes . operator . helpers . ResourceVersion ( e ) ) . collect ( java . util . stream . Collectors . toList ( ) ) ; java . util . Collections . sort ( rvs ) ; java . util . List < java . lang . String > actual = rvs . stream ( ) . map ( ( e ) -> e . toString ( ) ) . collect ( java . util . stream . Collectors . toList ( ) ) ; java . util . List < java . lang . String > expected = java . util . Arrays . asList ( "foo10" , "foo1" , "v11alpha2" , "v12alpha1" , "v3beta1" , "v3beta2" , "v10beta3" , "v3beta1" 0 , "v1" , "v2" , "v10" ) ; "<AssertPlaceHolder>" ; } toString ( ) { return new org . apache . commons . lang3 . builder . ToStringBuilder ( this ) . append ( "lastProbeTime" , lastProbeTime ) . append ( "lastTransitionTime" , lastTransitionTime ) . append ( "message" , message ) . append ( "reason" , reason ) . append ( "status" , status ) . append ( "type" , type ) . toString ( ) ; }
org . junit . Assert . assertEquals ( expected , actual )
test_zh_CN_from_file ( ) { java . io . Reader reader = org . nutz . lang . Streams . fileInr ( "org/nutz/json/zh_CN.txt" ) ; java . util . Map < java . lang . String , java . lang . String > map = ( ( java . util . Map < java . lang . String , java . lang . String > ) ( org . nutz . json . Json . fromJson ( reader ) ) ) ; "<AssertPlaceHolder>" ; } get ( org . nutz . ioc . IocMaking ) { java . lang . Object [ ] re = new java . lang . Object [ values . length ] ; for ( int i = 0 ; i < ( values . length ) ; i ++ ) re [ i ] = values [ i ] . get ( ing ) ; return re ; }
org . junit . Assert . assertEquals ( "" , map . get ( "name" ) )
testGetLabelResource ( ) { System . out . println ( "getLabelResource" ) ; kg . apc . jmeter . modifiers . FifoPutPostProcessorGui instance = new kg . apc . jmeter . modifiers . FifoPutPostProcessorGui ( ) ; java . lang . String result = instance . getLabelResource ( ) ; "<AssertPlaceHolder>" ; } getLabelResource ( ) { return this . getClass ( ) . getSimpleName ( ) ; }
org . junit . Assert . assertNotNull ( result )
testWildcardFilter ( ) { thredds . server . catalog . ConfigCatalog cat = thredds . server . catalog . TestConfigCatalogBuilder . getFromResource ( "thredds/server/catalog/TestDatasetScan.xml" ) ; thredds . client . catalog . Dataset ds = cat . findDatasetByID ( "testGridScan" ) ; assert ds != null ; assert ds instanceof thredds . server . catalog . DatasetScan ; thredds . server . catalog . DatasetScan dss = ( ( thredds . server . catalog . DatasetScan ) ( ds ) ) ; java . lang . String serviceName = dss . getServiceNameDefault ( ) ; assert serviceName . equals ( "all" ) ; thredds . server . catalog . DatasetScanConfig config = dss . getConfig ( ) ; System . out . printf ( "%s%n" , config ) ; thredds . client . catalog . Catalog scanCat = dss . makeCatalogForDirectory ( "testGridScan" , cat . getBaseURI ( ) ) . makeCatalog ( ) ; assert scanCat != null ; thredds . client . catalog . tools . CatalogXmlWriter writer = new thredds . client . catalog . tools . CatalogXmlWriter ( ) ; System . out . printf ( "%n%s%n" , writer . writeXML ( scanCat ) ) ; assert ( scanCat . getDatasets ( ) . size ( ) ) == 1 ; thredds . client . catalog . Dataset root = scanCat . getDatasets ( ) . get ( 0 ) ; assert ( root . getDatasets ( ) . size ( ) ) == 1 ; scanCat = dss . makeCatalogForDirectory ( "testGridScan/testDatafilesInDateTimeNestedDirs/profiles" , cat . getBaseURI ( ) ) . makeCatalog ( ) ; System . out . printf ( "%n%s%n" , writer . writeXML ( scanCat ) ) ; assert ( scanCat . getDatasets ( ) . size ( ) ) == 1 ; root = scanCat . getDatasets ( ) . get ( 0 ) ; assert ( root . getDatasets ( ) . size ( ) ) == 2 ; scanCat = dss . makeCatalogForDirectory ( "testGridScan/testDatafilesInDateTimeNestedDirs/profiles/20131106" , cat . getBaseURI ( ) ) . makeCatalog ( ) ; System . out . printf ( "%n%s%n" , writer . writeXML ( scanCat ) ) ; assert ( scanCat . getDatasets ( ) . size ( ) ) == 1 ; root = scanCat . getDatasets ( ) . get ( 0 ) ; "<AssertPlaceHolder>" ; scanCat = dss . makeCatalogForDirectory ( "testGridScan/testDatafilesInDateTimeNestedDirs/profiles/20131107" , cat . getBaseURI ( ) ) . makeCatalog ( ) ; System . out . printf ( "%n%s%n" , writer . writeXML ( scanCat ) ) ; assert ( scanCat . getDatasets ( ) . size ( ) ) == 1 ; root = scanCat . getDatasets ( ) . get ( 0 ) ; assert ( root . getDatasets ( ) . size ( ) ) == 4 ; } getDatasets ( ) { return datasets ; }
org . junit . Assert . assertEquals ( 3 , root . getDatasets ( ) . size ( ) )
convertFromString ( ) { org . xwiki . instance . InstanceId id = this . mocker . getComponentUnderTest ( ) . convertToType ( org . xwiki . instance . InstanceId . class , "b6ad6165-daaf-41a1-8a3f-9aa81451c402" ) ; "<AssertPlaceHolder>" ; } getInstanceId ( ) { return instanceIdManager . getInstanceId ( ) ; }
org . junit . Assert . assertEquals ( "b6ad6165-daaf-41a1-8a3f-9aa81451c402" , id . getInstanceId ( ) )
testMapStringIntegerValueWithoutListMarshallers ( ) { net . openhft . chronicle . map . ChronicleMapBuilder < java . lang . String , net . openhft . chronicle . map . Map < java . lang . String , java . lang . Integer > > builder = net . openhft . chronicle . map . ChronicleMapBuilder . of ( java . lang . String . class , ( ( java . lang . Class < net . openhft . chronicle . map . Map < java . lang . String , java . lang . Integer > > ) ( ( java . lang . Class ) ( net . openhft . chronicle . map . Map . class ) ) ) ) . averageKey ( "2" ) . averageValue ( net . openhft . chronicle . map . CHMUseCasesTest . mapOf ( "two" , 2 ) ) . entries ( 2 ) ; try ( net . openhft . chronicle . map . ChronicleMap < java . lang . String , net . openhft . chronicle . map . Map < java . lang . String , java . lang . Integer > > map = newInstance ( builder ) ) { map . put ( "1" , net . openhft . chronicle . map . Collections . emptyMap ( ) ) ; map . put ( "2" , net . openhft . chronicle . map . CHMUseCasesTest . mapOf ( "two" , 2 ) ) ; "<AssertPlaceHolder>" ; mapChecks ( ) ; } } get ( java . lang . Object ) { return check ( new net . openhft . chronicle . map . ReplicationCheckingMap . Call < K , V > ( ) { @ net . openhft . chronicle . map . Override public java . lang . Object method ( java . util . concurrent . ConcurrentMap < K , V > map ) { return map . get ( key ) ; } } ) ; }
org . junit . Assert . assertEquals ( net . openhft . chronicle . map . CHMUseCasesTest . mapOf ( "two" , 2 ) , map . get ( "2" ) )
testGetTreeWithParentElements ( ) { java . lang . String relPath = ( org . apache . jackrabbit . oak . commons . PathUtils . relativize ( PathUtils . ROOT_PATH , child . getPath ( ) ) ) + "/.." ; org . apache . jackrabbit . oak . api . Tree t = org . apache . jackrabbit . oak . plugins . tree . TreeUtil . getTree ( rootTree , relPath ) ; "<AssertPlaceHolder>" ; } getParent ( ) { return parent ; }
org . junit . Assert . assertEquals ( child . getParent ( ) . getPath ( ) , t . getPath ( ) )
testConcentric ( ) { double h = ( org . apache . commons . math . util . FastMath . sqrt ( 3.0 ) ) / 2.0 ; org . apache . commons . math . geometry . euclidean . twod . Vector2D [ ] [ ] vertices1 = new org . apache . commons . math . geometry . euclidean . twod . Vector2D [ ] [ ] { new org . apache . commons . math . geometry . euclidean . twod . Vector2D [ ] { new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( 0.0 , ( 0.1 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( 0.05 , ( 0.1 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( 0.1 , ( 0.2 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( 0.05 , ( 0.3 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( ( - 0.05 ) , ( 0.3 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( ( - 0.1 ) , ( 0.2 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( ( - 0.05 ) , ( 0.1 * h ) ) } } ; org . apache . commons . math . geometry . euclidean . twod . PolygonsSet set1 = buildSet ( vertices1 ) ; org . apache . commons . math . geometry . euclidean . twod . Vector2D [ ] [ ] vertices2 = new org . apache . commons . math . geometry . euclidean . twod . Vector2D [ ] [ ] { new org . apache . commons . math . geometry . euclidean . twod . Vector2D [ ] { new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( 0.0 , ( 0.0 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( 0.1 , ( 0.0 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( 0.2 , ( 0.2 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( 0.1 , ( 0.4 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( ( - 0.1 ) , ( 0.4 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( ( - 0.2 ) , ( 0.2 * h ) ) , new org . apache . commons . math . geometry . euclidean . twod . Vector2D ( ( - 0.1 ) , ( 0.0 * h ) ) } } ; org . apache . commons . math . geometry . euclidean . twod . PolygonsSet set2 = buildSet ( vertices2 ) ; "<AssertPlaceHolder>" ; } contains ( java . lang . Object ) { if ( cache . contains ( o . toString ( ) ) ) return true ; return super . contains ( o ) ; }
org . junit . Assert . assertTrue ( set2 . contains ( set1 ) )
test_Servlet7 ( ) { java . lang . String expected = "a" ; java . lang . String actual ; org . osgi . framework . Bundle bundle = installBundle ( org . eclipse . equinox . http . servlet . tests . TEST_BUNDLE_1 ) ; try { bundle . start ( ) ; actual = requestAdvisor . request ( "TestServlet7/a" ) ; } finally { uninstallBundle ( bundle ) ; } "<AssertPlaceHolder>" ; } uninstallBundle ( org . osgi . framework . Bundle ) { org . eclipse . equinox . internal . security . tests . storage . WaitingRegistryListener listener = new org . eclipse . equinox . internal . security . tests . storage . WaitingRegistryListener ( ) ; listener . register ( "org.eclipse.equinox.security.secureStorage" ) ; try { bundle . uninstall ( ) ; bundle = null ; org . junit . Assert . assertTrue ( ( ( listener . waitFor ( 1 , ( 10 * ( org . eclipse . equinox . internal . security . tests . storage . DynamicPreferencesTest . MAX_TIME_PER_BUNDLE ) ) ) ) == 1 ) ) ; return true ; } finally { listener . unregister ( ) ; if ( bundle != null ) bundle . uninstall ( ) ; } }
org . junit . Assert . assertEquals ( expected , actual )
testHasTitle ( ) { com . eclipsesource . tabris . ui . ActionConfiguration configuration = new com . eclipsesource . tabris . ui . ActionConfiguration ( "foo" , com . eclipsesource . tabris . internal . ui . TestAction . class ) . setTitle ( "bar" ) ; java . lang . String title = configuration . getTitle ( ) ; "<AssertPlaceHolder>" ; } getTitle ( ) { return title ; }
org . junit . Assert . assertEquals ( "bar" , title )
testFindMetric ( ) { org . ebayopensource . turmeric . monitoring . model . MetricDef metricDef = new org . ebayopensource . turmeric . monitoring . model . MetricDef ( "metric1" , org . ebayopensource . turmeric . monitoring . model . MetricCategory . TIMING , org . ebayopensource . turmeric . monitoring . model . MonitoringLevel . NORMAL ) ; metricDef . addMetricComponentDef ( new org . ebayopensource . turmeric . monitoring . model . MetricComponentDef ( "count" , "long" ) ) ; metricsDAO . persistMetricDef ( metricDef ) ; org . ebayopensource . turmeric . monitoring . model . Metric metric = new org . ebayopensource . turmeric . monitoring . model . Metric ( "service1" , "operation1" , metricDef ) ; metricsDAO . persistMetric ( metric ) ; org . ebayopensource . turmeric . monitoring . model . Metric savedMetric = metricsDAO . findMetric ( metricDef . getName ( ) , metric . getServiceAdminName ( ) , metric . getOperationName ( ) ) ; "<AssertPlaceHolder>" ; } getOperationName ( ) { return operationName ; }
org . junit . Assert . assertNotNull ( savedMetric )
testAnnotationWithNoMetadataContainer ( ) { org . obeonetwork . graal . System system = loadRoot ( "AnnotationWithNoMetadataContainer.graal" , org . obeonetwork . graal . System . class ) ; org . obeonetwork . graal . DomainClass domainClass = query ( ( ) -> { return ( ( org . obeonetwork . graal . DomainClass ) ( system . getOwnedNamespaces ( ) . get ( 0 ) . getTypes ( ) . get ( 0 ) ) ) ; } ) ; "<AssertPlaceHolder>" ; } getPhysicalSize ( org . obeonetwork . dsl . environment . ObeoDSMObject ) { return fr . gouv . mindef . safran . database . transfo . util . AnnotationHelper . getNonEmptyAnnotationBody ( dsmObject , fr . gouv . mindef . safran . database . transfo . util . AnnotationHelper . PHYSICAL_SIZE_KEY ) ; }
org . junit . Assert . assertEquals ( "" , getPhysicalSize ( domainClass ) )
testGetEncryptionKeyProviderUri ( ) { java . lang . String keyProvider = "kms://http@localhost:16000/kms" ; org . apache . ambari . view . cluster . Cluster cluster = createNiceMock ( org . apache . ambari . view . cluster . Cluster . class ) ; expect ( cluster . getConfigurationValue ( "hdfs-site" , "dfs.encryption.key.provider.uri" ) ) . andReturn ( keyProvider ) ; replay ( cluster ) ; org . apache . ambari . view . ViewContext viewContext = createNiceMock ( org . apache . ambari . view . ViewContext . class ) ; expect ( viewContext . getCluster ( ) ) . andReturn ( cluster ) . anyTimes ( ) ; java . util . Map < java . lang . String , java . lang . String > instanceProperties = new java . util . HashMap ( ) ; expect ( viewContext . getProperties ( ) ) . andReturn ( instanceProperties ) . anyTimes ( ) ; replay ( viewContext ) ; org . apache . ambari . view . utils . hdfs . ConfigurationBuilder configurationBuilder = new org . apache . ambari . view . utils . hdfs . ConfigurationBuilder ( viewContext ) ; java . lang . String encryptionKeyProviderUri = configurationBuilder . getEncryptionKeyProviderUri ( ) ; "<AssertPlaceHolder>" ; } getEncryptionKeyProviderUri ( ) { java . lang . String encryptionKeyProviderUri = getProperty ( "hdfs-site" , "dfs.encryption.key.provider.uri" ) ; return encryptionKeyProviderUri ; }
org . junit . Assert . assertEquals ( encryptionKeyProviderUri , keyProvider )
testFast ( ) { "<AssertPlaceHolder>" ; }
org . junit . Assert . assertTrue ( true )
voidObs_shouldSetVoidedBitOnGivenObs ( ) { org . openmrs . api . ObsService obsService = org . openmrs . api . context . Context . getObsService ( ) ; org . openmrs . Obs obs = obsService . getObs ( 7 ) ; obsService . voidObs ( obs , "testing<sp>void<sp>function" ) ; "<AssertPlaceHolder>" ; } getVoided ( ) { return voided ; }
org . junit . Assert . assertTrue ( obs . getVoided ( ) )
testHasField ( ) { java . lang . String name = "" ; boolean result = fixture . hasField ( name ) ; "<AssertPlaceHolder>" ; } hasField ( java . lang . String ) { return fFields . containsKey ( fieldTag ) ; }
org . junit . Assert . assertEquals ( false , result )
testCallWithNewReadTransactionAndCloseReadSuccessfully ( ) { org . opendaylight . yang . gen . v1 . urn . opendaylight . params . xml . ns . yang . mdsal . test . binding . rev140701 . two . level . list . TopLevelList data = newTestDataObject ( ) ; managedNewTransactionRunner . callWithNewWriteOnlyTransactionAndSubmit ( org . opendaylight . mdsal . binding . util . Datastore . OPERATIONAL , ( tx ) -> tx . put ( org . opendaylight . mdsal . binding . util . ManagedNewTransactionRunnerImplTest . TEST_PATH , data ) ) . get ( ) ; "<AssertPlaceHolder>" ; } applyWithNewReadOnlyTransactionAndClose ( java . lang . Class , org . opendaylight . mdsal . binding . util . CheckedFunction ) { return applyWithNewReadOnlyTransactionAndClose ( datastoreType , txFunction , maxRetries ) ; }
org . junit . Assert . assertEquals ( data , managedNewTransactionRunner . applyWithNewReadOnlyTransactionAndClose ( org . opendaylight . mdsal . binding . util . Datastore . OPERATIONAL , ( tx ) -> tx . read ( org . opendaylight . mdsal . binding . util . ManagedNewTransactionRunnerImplTest . TEST_PATH ) ) . get ( ) . get ( ) )
testGet2 ( ) { int breakInterval = 3 ; com . google . common . base . Supplier < java . lang . Integer > supplier = new com . rhythm . louie . cache . LoadingSupplierTest . FaultTestSupplier2 ( new com . rhythm . louie . cache . LoadingSupplierTest . FaultySupplier ( breakInterval ) ) ; for ( int i = 1 ; i <= 10 ; i ++ ) { java . lang . Integer value = supplier . get ( ) ; System . out . println ( ( ( i + ":<sp>" ) + value ) ) ; int testValue = i ; if ( ( i % breakInterval ) == 0 ) { testValue -- ; } "<AssertPlaceHolder>" ; } } get ( ) { return list ; }
org . junit . Assert . assertEquals ( value , java . lang . Integer . valueOf ( testValue ) )
deadLetterQueueTTLPromptExpiry ( ) { com . rabbitmq . client . test . functional . Map < java . lang . String , java . lang . Object > args = new com . rabbitmq . client . test . functional . HashMap ( ) ; args . put ( "x-message-ttl" , com . rabbitmq . client . test . functional . DeadLetterExchange . TTL ) ; declareQueue ( com . rabbitmq . client . test . functional . DeadLetterExchange . TEST_QUEUE_NAME , com . rabbitmq . client . test . functional . DeadLetterExchange . DLX , null , args ) ; channel . queueBind ( com . rabbitmq . client . test . functional . DeadLetterExchange . TEST_QUEUE_NAME , "amq.direct" , "test" ) ; channel . queueBind ( com . rabbitmq . client . test . functional . DeadLetterExchange . DLQ , com . rabbitmq . client . test . functional . DeadLetterExchange . DLX , "test" ) ; com . rabbitmq . client . test . functional . DeadLetterExchange . AccumulatingMessageConsumer c = new com . rabbitmq . client . test . functional . DeadLetterExchange . AccumulatingMessageConsumer ( channel ) ; java . lang . String cTag = channel . basicConsume ( com . rabbitmq . client . test . functional . DeadLetterExchange . TEST_QUEUE_NAME , true , c ) ; long start = java . lang . System . currentTimeMillis ( ) ; publish ( null , "test" ) ; byte [ ] body = c . nextDelivery ( com . rabbitmq . client . test . functional . DeadLetterExchange . TTL ) ; long stop = java . lang . System . currentTimeMillis ( ) ; "<AssertPlaceHolder>" ; channel . basicCancel ( cTag ) ; long latency = stop - start ; channel . basicConsume ( com . rabbitmq . client . test . functional . DeadLetterExchange . DLQ , true , c ) ; int count = 0 ; start = java . lang . System . currentTimeMillis ( ) ; stop = start + ( ( ( com . rabbitmq . client . test . functional . DeadLetterExchange . TTL ) * 3 ) / 4 ) ; long now = start ; while ( now < stop ) { publish ( null , java . lang . Long . toString ( now ) ) ; count ++ ; java . lang . Thread . sleep ( ( ( com . rabbitmq . client . test . functional . DeadLetterExchange . TTL ) / 100 ) ) ; now = java . lang . System . currentTimeMillis ( ) ; } checkPromptArrival ( c , count , latency ) ; start = java . lang . System . currentTimeMillis ( ) ; publishAt ( start ) ; basicGet ( com . rabbitmq . client . test . functional . DeadLetterExchange . TEST_QUEUE_NAME ) ; publishAt ( ( start + ( ( com . rabbitmq . client . test . functional . DeadLetterExchange . TTL ) / 2 ) ) ) ; com . rabbitmq . client . test . functional . GetResponse r = channel . basicGet ( com . rabbitmq . client . test . functional . DeadLetterExchange . TEST_QUEUE_NAME , false ) ; publishAt ( ( start + ( ( ( com . rabbitmq . client . test . functional . DeadLetterExchange . TTL ) * 3 ) / 4 ) ) ) ; waitUntil ( ( start + ( ( ( com . rabbitmq . client . test . functional . DeadLetterExchange . TTL ) * 5 ) / 4 ) ) ) ; channel . basicReject ( r . getEnvelope ( ) . getDeliveryTag ( ) , true ) ; checkPromptArrival ( c , 2 , latency ) ; } nextDelivery ( long ) { return messages . poll ( timeoutInMs , TimeUnit . MILLISECONDS ) ; }
org . junit . Assert . assertNotNull ( body )
testGetPasswordEncoder_ClassNotFound ( ) { config = new org . pentaho . platform . config . SpringSecurityHibernateConfig ( document ) ; org . dom4j . Node node = mock ( org . dom4j . Node . class ) ; when ( node . getText ( ) ) . thenReturn ( "org.pentaho.ClassNotFoundEncoder" ) ; when ( document . selectSingleNode ( anyString ( ) ) ) . thenReturn ( node ) ; org . springframework . security . authentication . encoding . PasswordEncoder passwordEncoder = config . getPasswordEncoder ( ) ; "<AssertPlaceHolder>" ; } getPasswordEncoder ( ) { try { java . lang . String pentahoEncoderClassName = document . selectSingleNode ( org . pentaho . platform . config . SpringSecurityHibernateConfig . PASSWORD_ENCODER_CLASS_XPATH ) . getText ( ) ; java . lang . Class passwordEncoderClass = java . lang . Class . forName ( pentahoEncoderClassName ) ; return ( ( org . springframework . security . authentication . encoding . PasswordEncoder ) ( passwordEncoderClass . newInstance ( ) ) ) ; } catch ( java . lang . ClassNotFoundException e ) { return null ; } catch ( java . lang . InstantiationException e ) { return null ; } catch ( java . lang . IllegalAccessException e ) { return null ; } }
org . junit . Assert . assertNull ( passwordEncoder )
testRemoveGenomeAssemblyFromSampleSuccess ( ) { ca . corefacility . bioinformatics . irida . model . sample . Sample s = sampleService . read ( 1L ) ; "<AssertPlaceHolder>" ; sampleService . removeGenomeAssemblyFromSample ( s , 1L ) ; try { sampleService . getGenomeAssemblyForSample ( s , 1L ) ; } catch ( ca . corefacility . bioinformatics . irida . exceptions . EntityNotFoundException e ) { return ; } org . junit . Assert . fail ( ( "Did<sp>not<sp>catch<sp>" + ( ca . corefacility . bioinformatics . irida . exceptions . EntityNotFoundException . class ) ) ) ; } getGenomeAssemblyForSample ( ca . corefacility . bioinformatics . irida . model . sample . Sample , java . lang . Long ) { ca . corefacility . bioinformatics . irida . model . joins . impl . SampleGenomeAssemblyJoin join = sampleGenomeAssemblyJoinRepository . findBySampleAndAssemblyId ( sample . getId ( ) , genomeAssemblyId ) ; if ( join == null ) { throw new ca . corefacility . bioinformatics . irida . exceptions . EntityNotFoundException ( ( ( ( ( "No<sp>join<sp>found<sp>between<sp>sample<sp>[" + ( sample . getId ( ) ) ) + "]<sp>and<sp>genome<sp>assembly<sp>[" ) + genomeAssemblyId ) + "]" ) ) ; } return join . getObject ( ) ; }
org . junit . Assert . assertNotNull ( sampleService . getGenomeAssemblyForSample ( s , 1L ) )
testListMatchingCategoryQueries ( ) { System . out . println ( "listMatchingCategoryQueries" ) ; org . netbeans . modules . profiler . oql . repository . api . OQLQueryCategory category = instance . listCategories ( ) . get ( 0 ) ; java . util . List result = instance . listQueries ( category , ".+?allocated.*" ) ; "<AssertPlaceHolder>" ; } size ( ) { synchronized ( dataLock ) { return curSize ; } }
org . junit . Assert . assertEquals ( 2 , result . size ( ) )
testReverseInsertNoNormalizationNecessaryOneBaseFirst ( ) { de . charite . compbio . jannovar . reference . TranscriptPosition txPos = new de . charite . compbio . jannovar . reference . TranscriptPosition ( infoReverse , 0 , PositionType . ZERO_BASED ) ; de . charite . compbio . jannovar . reference . GenomePosition gPos = projectorReverse . transcriptToGenomePos ( txPos ) . withStrand ( Strand . FWD ) ; de . charite . compbio . jannovar . reference . GenomeVariant change = new de . charite . compbio . jannovar . reference . GenomeVariant ( gPos , "" , "G" , Strand . REV ) ; de . charite . compbio . jannovar . reference . GenomeVariant updatedChange = de . charite . compbio . jannovar . reference . GenomeVariantNormalizer . normalizeInsertion ( this . infoReverse , change , txPos ) ; "<AssertPlaceHolder>" ; } normalizeInsertion ( de . charite . compbio . jannovar . reference . TranscriptModel , de . charite . compbio . jannovar . reference . GenomeVariant , de . charite . compbio . jannovar . reference . TranscriptPosition ) { assert ( change . getRef ( ) . length ( ) ) == 0 ; if ( ( change . getGenomePos ( ) . getStrand ( ) ) != ( transcript . getStrand ( ) ) ) change = change . withStrand ( transcript . getStrand ( ) ) ; int pos = txPos . getPos ( ) ; java . lang . StringBuilder builder = new java . lang . StringBuilder ( transcript . getSequence ( ) ) ; builder . insert ( pos , change . getAlt ( ) ) ; int shift = 0 ; final int LEN = change . getAlt ( ) . length ( ) ; final java . lang . String seq = builder . toString ( ) ; final int maxPos = java . lang . Math . min ( seq . length ( ) , transcript . transcriptLength ( ) ) ; while ( ( ( pos + LEN ) < maxPos ) && ( ( seq . charAt ( pos ) ) == ( seq . charAt ( ( pos + LEN ) ) ) ) ) { ++ shift ; ++ pos ; } final de . charite . compbio . jannovar . reference . TranscriptProjectionDecorator projector = new de . charite . compbio . jannovar . reference . TranscriptProjectionDecorator ( transcript ) ; final de . charite . compbio . jannovar . reference . GenomePosition shiftedPos ; try { shiftedPos = projector . transcriptToGenomePos ( txPos . shifted ( shift ) ) ; } catch ( de . charite . compbio . jannovar . reference . ProjectionException e ) { throw new java . lang . RuntimeException ( "Bug:<sp>transcript<sp>position<sp>must<sp>be<sp>valid<sp>here!" , e ) ; } if ( shift == 0 ) return change ; else return new de . charite . compbio . jannovar . reference . GenomeVariant ( shiftedPos , "" , seq . substring ( pos , ( pos + LEN ) ) ) ; }
org . junit . Assert . assertEquals ( change , updatedChange )
testSetTableName ( ) { org . pentaho . hbase . shim . api . HBaseValueMeta hbMeta = getHBaseValueMeta ( ) ; hbMeta . setTableName ( "test" ) ; "<AssertPlaceHolder>" ; } setTableName ( java . lang . String ) { m_tableName = tableName ; }
org . junit . Assert . assertEquals ( "test" , hbMeta . m_tableName )
testSolutionRightSide ( ) { org . hipparchus . analysis . UnivariateFunction f = new org . hipparchus . analysis . function . Sin ( ) ; org . hipparchus . analysis . solvers . UnivariateSolver solver = getSolver ( ) ; double left = - 1.5 ; double right = 0.05 ; for ( int i = 0 ; i < 10 ; i ++ ) { double solution = getSolution ( solver , 100 , f , left , right , AllowedSolution . RIGHT_SIDE ) ; if ( ! ( java . lang . Double . isNaN ( solution ) ) ) { "<AssertPlaceHolder>" ; } left -= 0.1 ; right += 0.3 ; } } getSolver ( ) { return new org . hipparchus . analysis . solvers . SecantSolver ( ) ; }
org . junit . Assert . assertTrue ( ( solution >= 0.0 ) )
testPlatypus ( ) { java . lang . String headerLines = PLATYPUS_HEADER ; java . lang . String vcfLine = "1\t17452\t.\tA\tG\t388\tPASS\tFR=1.0;MMLQ=27.0;TCR=7;HP=1;WE=14938;" + ( ( "Source=Platypus;WS=14920;PP=388.0;TR=17;NF=10;TCF=10;NR=7;TC=17;MGOF=29;SbPval=0.59;MQ=46.59;" + "QD=24.8688948557;SC=ACAGAATTACAAGGTGCTGGC;BRF=0.38;HapScore=2\t" ) + "GT:GL:GOF:GQ:NR:NV\t1/1:-14.5,-0.9,0.0:29.0:10:5:5\n" ) ; htsjdk . variant . variantcontext . VariantContext variant = writeAndReadVcfLine ( vcfLine , headerLines ) ; htsjdk . variant . variantcontext . Genotype gt = variant . getGenotype ( "individual" ) ; "<AssertPlaceHolder>" ; } guessFromGenotype ( htsjdk . variant . variantcontext . Genotype ) { if ( ( ( gt . hasAnyAttribute ( "NR" 1 ) ) && ( gt . hasAnyAttribute ( "DV" ) ) ) && ( gt . hasAnyAttribute ( "DPR" ) ) ) { return de . charite . compbio . jannovar . filter . impl . gt . SupportedVarCaller . BCFTOOLS ; } else if ( ( ( ( ( ( gt . hasAnyAttribute ( "GT" ) ) && ( gt . hasAnyAttribute ( "GQ" ) ) ) && ( gt . hasAnyAttribute ( "RO" ) ) ) && ( gt . hasAnyAttribute ( "NR" 2 ) ) ) && ( gt . hasAnyAttribute ( "AO" ) ) ) && ( gt . hasAnyAttribute ( "QA" ) ) ) { return de . charite . compbio . jannovar . filter . impl . gt . SupportedVarCaller . FREEBAYES ; } else if ( ( ( ( ( gt . hasAnyAttribute ( "GT" ) ) && ( gt . hasAnyAttribute ( "AD" ) ) ) && ( gt . hasAnyAttribute ( "NR" 1 ) ) ) && ( gt . hasAnyAttribute ( "GQ" ) ) ) && ( gt . hasAnyAttribute ( "PL" ) ) ) { return de . charite . compbio . jannovar . filter . impl . gt . SupportedVarCaller . GATK_CALLER ; } else if ( ( ( ( gt . hasAnyAttribute ( "GT" ) ) && ( gt . hasAnyAttribute ( "GQ" ) ) ) && ( gt . hasAnyAttribute ( "NR" ) ) ) && ( gt . hasAnyAttribute ( "NR" 0 ) ) ) { return de . charite . compbio . jannovar . filter . impl . gt . SupportedVarCaller . PLATYPUS ; } else { return de . charite . compbio . jannovar . filter . impl . gt . SupportedVarCaller . GATK_CALLER ; } }
org . junit . Assert . assertEquals ( SupportedVarCaller . PLATYPUS , de . charite . compbio . jannovar . filter . impl . gt . SupportedVarCaller . guessFromGenotype ( gt ) )
invalidIntegerGreaterOrEqualShouldCreateViolations ( ) { java . util . Set < javax . validation . ConstraintViolation < org . alien4cloud . tosca . model . definitions . PropertyDefinition > > violations = validator . validate ( createGreaterOrEqualDefinition ( ToscaTypes . INTEGER . toString ( ) , 10L , "5" ) , alien4cloud . tosca . container . validation . ToscaSequence . class ) ; "<AssertPlaceHolder>" ; } toString ( ) { return ( ( ( "name:<sp>[" + ( name ) ) + "],<sp>value:<sp>[" ) + ( value ) ) + "]" ; }
org . junit . Assert . assertEquals ( 1 , violations . size ( ) )
setStyleAttributeMultipleTimes ( ) { com . vaadin . flow . dom . Element e = com . vaadin . flow . dom . ElementFactory . createDiv ( ) ; e . setAttribute ( "style" , "width:12em" ) ; e . setAttribute ( "style" , "height:12em" ) ; "<AssertPlaceHolder>" ; } getAttribute ( java . lang . String ) { return sessionAttributes . get ( name ) ; }
org . junit . Assert . assertEquals ( "height:12em" , e . getAttribute ( "style" ) )
init_clone ( ) { V v = newValidatorFor_AbstractCompositeValidatorTests ( ) ; com . alibaba . citrus . service . form . Validator v1 = com . alibaba . citrus . service . form . impl . validation . composite . AbstractCompositeValidatorTests . createMock ( com . alibaba . citrus . service . form . Validator . class ) ; com . alibaba . citrus . service . form . Validator v2 = com . alibaba . citrus . service . form . impl . validation . composite . AbstractCompositeValidatorTests . createMock ( com . alibaba . citrus . service . form . Validator . class ) ; com . alibaba . citrus . service . form . Validator v1copy = com . alibaba . citrus . service . form . impl . validation . composite . AbstractCompositeValidatorTests . createMock ( com . alibaba . citrus . service . form . Validator . class ) ; com . alibaba . citrus . service . form . Validator v2copy = com . alibaba . citrus . service . form . impl . validation . composite . AbstractCompositeValidatorTests . createMock ( com . alibaba . citrus . service . form . Validator . class ) ; expect ( v1 . clone ( ) ) . andReturn ( v1copy ) ; expect ( v2 . clone ( ) ) . andReturn ( v2copy ) ; replay ( v1 , v2 , v1copy , v2copy ) ; v . setValidators ( createValidatorList ( v1 , v2 ) ) ; @ com . alibaba . citrus . service . form . impl . validation . composite . SuppressWarnings ( "unchecked" ) V vcopy = ( ( V ) ( v . clone ( ) ) ) ; java . util . List < com . alibaba . citrus . service . form . Validator > validatorsCopy = vcopy . getValidators ( ) ; "<AssertPlaceHolder>" ; } toArray ( ) { return com . alibaba . citrus . service . pipeline . valve . ExecutionLog . log . get ( ) . toArray ( com . alibaba . citrus . service . pipeline . valve . EMPTY_STRING_ARRAY ) ; }
org . junit . Assert . assertArrayEquals ( new java . lang . Object [ ] { v1copy , v2copy } , validatorsCopy . toArray ( ) )
giveBlackFromCache ( ) { pv . giveBlack ( nl . jqno . equalsverifier . internal . prefabvalues . PrefabValuesTest . STRING_TAG ) ; "<AssertPlaceHolder>" ; } giveBlack ( nl . jqno . equalsverifier . internal . prefabvalues . TypeTag ) { return this . < T > giveTuple ( tag ) . getBlack ( ) ; }
org . junit . Assert . assertEquals ( "b" , pv . giveBlack ( nl . jqno . equalsverifier . internal . prefabvalues . PrefabValuesTest . STRING_TAG ) )
testDelete ( ) { org . apache . ibatis . session . SqlSession tdhsSession = getTDHSSession ( ) ; int insert = tdhsSession . getMapper ( com . taobao . tdhs . jdbc . test . mybatis . mapper . OrderMapper . class ) . delete ( ) ; "<AssertPlaceHolder>" ; tdhsSession . close ( ) ; } delete ( ) { return statement . delete ( get ) ; }
org . junit . Assert . assertEquals ( 3 , insert )
shouldReturnNullIfResourceEditRelationListIsEmpty ( ) { java . util . List < ch . puzzle . itc . mobiliar . business . property . entity . ResourceEditRelation > relations = java . util . Collections . < ch . puzzle . itc . mobiliar . business . property . entity . ResourceEditRelation > emptyList ( ) ; java . lang . String actual = helper . nextFreeIdentifierForResourceEditRelations ( relations , null , StringUtils . EMPTY ) ; "<AssertPlaceHolder>" ; } nextFreeIdentifierForResourceEditRelations ( java . util . List , java . lang . Integer , java . lang . String ) { int count = 0 ; java . util . List < java . lang . String > identifiers = new java . util . ArrayList ( ) ; java . lang . String prefix = null ; for ( ch . puzzle . itc . mobiliar . business . property . entity . ResourceEditRelation relation : relations ) { if ( relation . getSlaveGroupId ( ) . equals ( slaveResourceGroupId ) ) { if ( prefix == null ) { prefix = relation . getSlaveName ( ) ; } identifiers . add ( relation . getIdentifier ( ) ) ; ++ count ; } } prefix = ( prefix == null ) ? slavePrefix : prefix ; return nextFreeIdentifier ( identifiers , prefix , count ) ; }
org . junit . Assert . assertEquals ( StringUtils . EMPTY , actual )
shouldNotRegisterAlreadyRegisteredPlayer ( ) { java . lang . String name = "jonah" ; given ( dataSource . isAuthAvailable ( name ) ) . willReturn ( true ) ; boolean result = api . registerPlayer ( name , "pass" ) ; "<AssertPlaceHolder>" ; verify ( dataSource , only ( ) ) . isAuthAvailable ( name ) ; verifyZeroInteractions ( management , passwordSecurity ) ; } registerPlayer ( java . lang . String , java . lang . String ) { java . lang . String name = playerName . toLowerCase ( ) ; if ( isRegistered ( name ) ) { return false ; } fr . xephi . authme . security . crypts . HashedPassword result = passwordSecurity . computeHash ( password , name ) ; fr . xephi . authme . data . auth . PlayerAuth auth = fr . xephi . authme . data . auth . PlayerAuth . builder ( ) . name ( name ) . password ( result ) . realName ( playerName ) . registrationDate ( java . lang . System . currentTimeMillis ( ) ) . build ( ) ; return dataSource . saveAuth ( auth ) ; }
org . junit . Assert . assertThat ( result , org . hamcrest . Matchers . equalTo ( false ) )
testPersistence ( ) { System . out . println ( "persistence" ) ; fd = new de . waldheinz . fs . util . FileDisk ( f , true ) ; final java . nio . ByteBuffer read = java . nio . ByteBuffer . allocate ( de . waldheinz . fs . util . FileDiskTest . SIZE ) ; fd . read ( 0 , read ) ; reference . rewind ( ) ; read . rewind ( ) ; "<AssertPlaceHolder>" ; } read ( de . waldheinz . fs . fat . FatDirectoryEntry , de . waldheinz . fs . fat . Fat ) { if ( ! ( entry . isDirectory ( ) ) ) throw new java . lang . IllegalArgumentException ( ( entry + "<sp>is<sp>no<sp>directory" ) ) ; final de . waldheinz . fs . fat . ClusterChain chain = new de . waldheinz . fs . fat . ClusterChain ( fat , entry . getStartCluster ( ) , entry . isReadonlyFlag ( ) ) ; final de . waldheinz . fs . fat . ClusterChainDirectory result = new de . waldheinz . fs . fat . ClusterChainDirectory ( chain , false ) ; result . read ( ) ; return result ; }
org . junit . Assert . assertEquals ( reference , read )
testMovePackageToParent ( ) { enableSilentOperation ( VcsConfiguration . StandardConfirmation . ADD ) ; final com . intellij . openapi . vfs . VirtualFile child = createDirInCommand ( myWorkingCopyDir , "child" ) ; final com . intellij . openapi . vfs . VirtualFile grandChild = createDirInCommand ( child , "grandChild" ) ; createFileInCommand ( grandChild , "a.txt" , "a" ) ; checkin ( ) ; final com . intellij . openapi . vcs . changes . ChangeListManager changeListManager = com . intellij . openapi . vcs . changes . ChangeListManager . getInstance ( myProject ) ; moveFileInCommand ( grandChild , myWorkingCopyDir ) ; com . intellij . openapi . vfs . LocalFileSystem . getInstance ( ) . refresh ( false ) ; changeListManager . ensureUpToDate ( false ) ; final java . util . List < com . intellij . openapi . vcs . changes . Change > changes = new java . util . ArrayList < com . intellij . openapi . vcs . changes . Change > ( changeListManager . getDefaultChangeList ( ) . getChanges ( ) ) ; "<AssertPlaceHolder>" ; sortChanges ( changes ) ; verifyChange ( changes . get ( 0 ) , "child\\grandChild" , "grandChild" ) ; verifyChange ( changes . get ( 1 ) , "child\\grandChild\\a.txt" , "grandChild\\a.txt" ) ; } listToString ( java . util . List ) { return ( "{" + ( com . intellij . openapi . util . text . StringUtil . join ( changes , new com . intellij . util . Function < com . intellij . openapi . vcs . changes . Change , java . lang . String > ( ) { public java . lang . String fun ( final com . intellij . openapi . vcs . changes . Change change ) { return change . toString ( ) ; } } , "," ) ) ) + "}" ; }
org . junit . Assert . assertEquals ( listToString ( changes ) , 2 , changes . size ( ) )
testBigDecimalEquality ( ) { org . teiid . query . processor . eval . CompareCriteria crit = new org . teiid . query . processor . eval . CompareCriteria ( new org . teiid . query . sql . symbol . Constant ( new java . math . BigDecimal ( "3.10" ) ) , CompareCriteria . EQ , new org . teiid . query . sql . symbol . Constant ( new java . math . BigDecimal ( "3.1" ) ) ) ; "<AssertPlaceHolder>" ; } evaluate ( org . teiid . query . eval . Criteria ) { return new org . teiid . query . eval . Evaluator ( java . util . Collections . emptyMap ( ) , null , null ) . evaluate ( criteria , java . util . Collections . emptyList ( ) ) ; }
org . junit . Assert . assertTrue ( org . teiid . query . eval . Evaluator . evaluate ( crit ) )
testLastTimeStepLayer ( ) { int nIn = 3 ; int nOut = 5 ; int tsLength = 4 ; int layerSize = 8 ; java . util . Random r = new java . util . Random ( 12345 ) ; for ( int mb : new int [ ] { 1 , 3 } ) { for ( boolean inputMask : new boolean [ ] { false , true } ) { for ( boolean simple : new boolean [ ] { false , true } ) { for ( boolean hasLayerNorm : new boolean [ ] { true , false } ) { org . nd4j . linalg . api . ndarray . INDArray in = org . nd4j . linalg . factory . Nd4j . rand ( new int [ ] { mb , nIn , tsLength } ) ; org . nd4j . linalg . api . ndarray . INDArray labels = org . nd4j . linalg . factory . Nd4j . create ( mb , nOut ) ; for ( int i = 0 ; i < mb ; i ++ ) { labels . putScalar ( i , r . nextInt ( nOut ) , 1.0 ) ; } java . lang . String maskType = ( inputMask ) ? "inputMask" : "none" ; org . nd4j . linalg . api . ndarray . INDArray inMask = null ; if ( inputMask ) { inMask = org . nd4j . linalg . factory . Nd4j . ones ( mb , tsLength ) ; for ( int i = 0 ; i < mb ; i ++ ) { int firstMaskedStep = ( tsLength - 1 ) - i ; if ( firstMaskedStep == 0 ) { firstMaskedStep = tsLength ; } for ( int j = firstMaskedStep ; j < tsLength ; j ++ ) { inMask . putScalar ( i , j , 0.0 ) ; } } } java . lang . String name = ( ( ( ( ( ( ( ( "testLastTimeStepLayer()<sp>-<sp>mb=" + mb ) + ",<sp>tsLength<sp>=<sp>" ) + tsLength ) + ",<sp>maskType=" ) + maskType ) + ",<sp>hasLayerNorm=" ) + hasLayerNorm ) + ",<sp>rnnType=" ) + ( simple ? "SimpleRnn" : "LSTM" ) ; if ( org . deeplearning4j . gradientcheck . RnnGradientChecks . PRINT_RESULTS ) { System . out . println ( ( "Starting<sp>test:<sp>" + name ) ) ; } org . deeplearning4j . nn . conf . MultiLayerConfiguration conf = new org . deeplearning4j . nn . conf . NeuralNetConfiguration . Builder ( ) . activation ( Activation . TANH ) . updater ( new org . nd4j . linalg . learning . config . NoOp ( ) ) . weightInit ( WeightInit . XAVIER ) . list ( ) . layer ( ( simple ? new org . deeplearning4j . nn . conf . layers . recurrent . SimpleRnn . Builder ( ) . nOut ( layerSize ) . hasLayerNorm ( hasLayerNorm ) . build ( ) : new org . deeplearning4j . nn . conf . layers . LSTM . Builder ( ) . nOut ( layerSize ) . build ( ) ) ) . layer ( new org . deeplearning4j . nn . conf . layers . recurrent . LastTimeStep ( ( simple ? new org . deeplearning4j . nn . conf . layers . recurrent . SimpleRnn . Builder ( ) . nOut ( layerSize ) . hasLayerNorm ( hasLayerNorm ) . build ( ) : new org . deeplearning4j . nn . conf . layers . LSTM . Builder ( ) . nOut ( layerSize ) . build ( ) ) ) ) . layer ( new org . deeplearning4j . nn . conf . layers . OutputLayer . Builder ( ) . nOut ( nOut ) . activation ( Activation . SOFTMAX ) . lossFunction ( LossFunctions . LossFunction . MCXENT ) . build ( ) ) . setInputType ( org . deeplearning4j . nn . conf . inputs . InputType . recurrent ( nIn ) ) . build ( ) ; org . deeplearning4j . nn . multilayer . MultiLayerNetwork net = new org . deeplearning4j . nn . multilayer . MultiLayerNetwork ( conf ) ; net . init ( ) ; boolean gradOK = org . deeplearning4j . gradientcheck . GradientCheckUtil . checkGradients ( net , org . deeplearning4j . gradientcheck . RnnGradientChecks . DEFAULT_EPS , org . deeplearning4j . gradientcheck . RnnGradientChecks . DEFAULT_MAX_REL_ERROR , org . deeplearning4j . gradientcheck . RnnGradientChecks . DEFAULT_MIN_ABS_ERROR , org . deeplearning4j . gradientcheck . RnnGradientChecks . PRINT_RESULTS , org . deeplearning4j . gradientcheck . RnnGradientChecks . RETURN_ON_FIRST_FAILURE , in , labels , inMask , null ) ; "<AssertPlaceHolder>" ; org . deeplearning4j . TestUtils . testModelSerialization ( net ) ; } } } } } checkGradients ( org . deeplearning4j . nn . multilayer . MultiLayerNetwork , double , double , double , boolean , boolean , org . nd4j . linalg . api . ndarray . INDArray , org . nd4j . linalg . api . ndarray . INDArray , org . nd4j . linalg . api . ndarray . INDArray , org . nd4j . linalg . api . ndarray . INDArray ) { return org . deeplearning4j . gradientcheck . GradientCheckUtil . checkGradients ( mln , epsilon , maxRelError , minAbsoluteError , print , exitOnFirstError , input , labels , inputMask , labelMask , false , ( - 1 ) ) ; }
org . junit . Assert . assertTrue ( name , gradOK )
applyMaterieelFormeelGeldigHistorieVormGeen_PeilmomentNaVerval_AfnemerInd ( ) { nl . bzk . brp . domain . leveringmodel . MetaGroep . Builder groepBuilder = new nl . bzk . brp . domain . leveringmodel . MetaGroep . Builder ( null ) ; groepBuilder . metGroepElement ( Element . PERSOON_AFNEMERINDICATIE_STANDAARD . getId ( ) ) ; final nl . bzk . brp . domain . leveringmodel . MetaGroep metaGroep = groepBuilder . build ( null ) ; final int jaarTsReg = 2014 ; final int maandTsReg = 1 ; final int dagTsReg = 1 ; final java . time . ZonedDateTime actieInhoudTsReg = maakDatumTijdAttribuut ( jaarTsReg , maandTsReg , dagTsReg ) ; final java . time . ZonedDateTime actieVervalTsReg = maakDatumTijdAttribuut ( jaarTsReg , maandTsReg , dagTsReg ) ; java . util . Calendar calendarActie = java . util . Calendar . getInstance ( ) ; calendarActie . set ( jaarTsReg , maandTsReg , dagTsReg ) ; nl . bzk . brp . domain . leveringmodel . MetaRecord . Builder recordBuilder = new nl . bzk . brp . domain . leveringmodel . MetaRecord . Builder ( groepBuilder ) ; recordBuilder . metAttribuut ( getAttribuutElement ( Element . PERSOON_AFNEMERINDICATIE_TIJDSTIPREGISTRATIE . getId ( ) ) , actieInhoudTsReg ) ; recordBuilder . metAttribuut ( getAttribuutElement ( Element . PERSOON_AFNEMERINDICATIE_TIJDSTIPVERVAL . getId ( ) ) , actieVervalTsReg ) ; final nl . bzk . brp . domain . leveringmodel . MetaRecord metaRecord = recordBuilder . build ( metaGroep ) ; final java . lang . Integer peilDatumMaterieel = maakDatumInteger ( ( jaarTsReg + 1 ) , maandTsReg , dagTsReg ) ; final java . time . ZonedDateTime peilDatumFormeel = java . time . LocalDate . parse ( peilDatumMaterieel . toString ( ) , nl . bzk . brp . service . maakbericht . filterstappen . HistoriePredikaatTest . FORMATTER ) . atStartOfDay ( DatumUtil . BRP_ZONE_ID ) ; final nl . bzk . brp . domain . leveringmodel . persoon . PeilmomentHistorievormPredicate bevragingHistoriePredikaat = new nl . bzk . brp . domain . leveringmodel . persoon . PeilmomentHistorievormPredicate ( peilDatumMaterieel , peilDatumFormeel , nl . bzk . algemeenbrp . dal . domein . brp . enums . HistorieVorm . GEEN ) ; final boolean apply = bevragingHistoriePredikaat . apply ( metaRecord ) ; "<AssertPlaceHolder>" ; } apply ( T ) { return isTrue . apply ( input ) ; }
org . junit . Assert . assertThat ( apply , org . hamcrest . core . Is . is ( false ) )
splitFolderTestAFolderEmptyFL ( ) { java . util . Set < org . talend . dataprep . qa . dto . Folder > result = folderUtil . splitFolder ( aPathF , emptyFList ) ; "<AssertPlaceHolder>" ; } isEmpty ( ) { return ( ( ( ( org . apache . commons . lang3 . StringUtils . isEmpty ( title ) ) && ( org . apache . commons . lang3 . StringUtils . isEmpty ( mail ) ) ) && ( org . apache . commons . lang3 . StringUtils . isEmpty ( severity ) ) ) && ( org . apache . commons . lang3 . StringUtils . isEmpty ( type ) ) ) && ( org . apache . commons . lang3 . StringUtils . isEmpty ( description ) ) ; }
org . junit . Assert . assertTrue ( result . isEmpty ( ) )
testIdFieldNameQuery ( ) { com . github . jmkgreen . morphia . TestQuery . PhotoWithKeywords pwk = new com . github . jmkgreen . morphia . TestQuery . PhotoWithKeywords ( "scott" , "hernandez" ) ; ds . save ( pwk ) ; com . github . jmkgreen . morphia . TestQuery . PhotoWithKeywords pwkLoaded = ds . find ( com . github . jmkgreen . morphia . TestQuery . PhotoWithKeywords . class , "id<sp>!=" , "scott" ) . get ( ) ; "<AssertPlaceHolder>" ; } get ( ) { return ds ; }
org . junit . Assert . assertNotNull ( pwkLoaded )
mapTest ( ) { com . navercorp . pinpoint . collector . mapper . thrift . stat . TFResponseTimeMapper mapper = new com . navercorp . pinpoint . collector . mapper . thrift . stat . TFResponseTimeMapper ( ) ; com . navercorp . pinpoint . common . server . bo . stat . ResponseTimeBo responseTimeBo = new com . navercorp . pinpoint . common . server . bo . stat . ResponseTimeBo ( ) ; responseTimeBo . setAvg ( 50 ) ; com . navercorp . pinpoint . thrift . dto . flink . TFResponseTime tFResponseTime = mapper . map ( responseTimeBo ) ; "<AssertPlaceHolder>" ; } getAvg ( ) { if ( ( transactionCount ) == 0 ) { return totalResponseTime ; } return ( totalResponseTime ) / ( transactionCount ) ; }
org . junit . Assert . assertEquals ( tFResponseTime . getAvg ( ) , 50 )
testAddNewContainerToGroupingRequest ( ) { java . lang . String groupLeaderContainerId = "container_1" ; java . lang . String newAffectedContainerId = "container_11" ; underTest . addOrModifyGroupingRequest ( groupLeaderContainerId , com . google . common . collect . ImmutableSet . of ( oper1 ) ) ; underTest . addNewContainerToGroupingRequest ( groupLeaderContainerId , newAffectedContainerId ) ; org . apache . apex . engine . events . grouping . GroupingRequest request = underTest . getGroupingRequest ( groupLeaderContainerId ) ; "<AssertPlaceHolder>" ; } getAffectedContainers ( ) { return affectedContainers ; }
org . junit . Assert . assertTrue ( request . getAffectedContainers ( ) . contains ( newAffectedContainerId ) )
deactivateTokenTest ( ) { final net . violet . platform . dataobjects . UserData theUser = net . violet . platform . dataobjects . UserData . getData ( getKowalskyUser ( ) ) ; theUser . generateToken ( ) ; final net . violet . platform . datamodel . Application theApplication = new net . violet . platform . datamodel . mock . ApplicationMock ( 42 , "My<sp>first<sp>application" , theUser . getReference ( ) , new java . util . Date ( ) ) ; final net . violet . platform . datamodel . ApplicationCredentials cred = new net . violet . platform . datamodel . mock . ApplicationCredentialsMock ( "6992873d28d86925325dc52d15d6feec30bb2da5" , "59e6060a53ab1be5" , theApplication ) ; final net . violet . platform . api . callers . APICaller caller = new net . violet . platform . api . callers . ApplicationAPICaller ( net . violet . platform . dataobjects . ApplicationCredentialsData . getData ( cred ) ) ; final net . violet . platform . api . actions . Action theAction = new net . violet . platform . api . actions . people . ManageToken ( ) ; final java . util . Map < java . lang . String , java . lang . Object > theParams = new java . util . HashMap < java . lang . String , java . lang . Object > ( ) ; theParams . put ( ActionParam . SESSION_PARAM_KEY , generateSession ( theUser , caller ) ) ; theParams . put ( "activate" , false ) ; final net . violet . platform . api . actions . ActionParam theActionParam = new net . violet . platform . api . actions . ActionParam ( caller , theParams ) ; final java . lang . Object theResult = theAction . processRequest ( theActionParam ) ; "<AssertPlaceHolder>" ; } put ( K , T ) { this . mMap . put ( theRef , new net . violet . db . cache . CacheReference < K , T > ( theRef , theRecord , this . mReferenceQueue ) ) ; this . mLinkedMap . put ( theRef , theRecord ) ; }
org . junit . Assert . assertNull ( theResult )
InterfaceForTemplates004 ( ) { java . lang . String code = "class<sp>A{isA<sp>T1;}<sp>interface<sp>I{}<sp>trait<sp>T<X<sp>isA<sp>I>{}<sp>trait<sp>T1{<sp>isA<sp>T<X=B>;}" ; cruise . umple . compiler . UmpleModel model = getModel ( code ) ; boolean happened = false ; try { model . run ( ) ; } catch ( java . lang . Exception e ) { happened = e . getMessage ( ) . contains ( "221" ) ; } finally { "<AssertPlaceHolder>" ; cruise . umple . util . SampleFileWriter . destroy ( "traitTest.ump" ) ; } } contains ( java . lang . Object ) { if ( ( parent ) != null ) { return ( super . contains ( obj ) ) || ( parent . contains ( obj ) ) ; } else { return super . contains ( obj ) ; } }
org . junit . Assert . assertTrue ( happened )
hashCode_equals ( ) { java . security . PrivateKey privateKey = com . google . auth . oauth2 . ServiceAccountCredentials . privateKeyFromPkcs8 ( com . google . auth . oauth2 . ServiceAccountJwtAccessCredentialsTest . SA_PRIVATE_KEY_PKCS8 ) ; com . google . auth . oauth2 . ServiceAccountJwtAccessCredentials credentials = com . google . auth . oauth2 . ServiceAccountJwtAccessCredentials . newBuilder ( ) . setClientId ( com . google . auth . oauth2 . ServiceAccountJwtAccessCredentialsTest . SA_CLIENT_ID ) . setClientEmail ( com . google . auth . oauth2 . ServiceAccountJwtAccessCredentialsTest . SA_CLIENT_EMAIL ) . setPrivateKey ( privateKey ) . setPrivateKeyId ( com . google . auth . oauth2 . ServiceAccountJwtAccessCredentialsTest . SA_PRIVATE_KEY_ID ) . setDefaultAudience ( com . google . auth . oauth2 . ServiceAccountJwtAccessCredentialsTest . CALL_URI ) . build ( ) ; com . google . auth . oauth2 . ServiceAccountJwtAccessCredentials otherCredentials = com . google . auth . oauth2 . ServiceAccountJwtAccessCredentials . newBuilder ( ) . setClientId ( com . google . auth . oauth2 . ServiceAccountJwtAccessCredentialsTest . SA_CLIENT_ID ) . setClientEmail ( com . google . auth . oauth2 . ServiceAccountJwtAccessCredentialsTest . SA_CLIENT_EMAIL ) . setPrivateKey ( privateKey ) . setPrivateKeyId ( com . google . auth . oauth2 . ServiceAccountJwtAccessCredentialsTest . SA_PRIVATE_KEY_ID ) . setDefaultAudience ( com . google . auth . oauth2 . ServiceAccountJwtAccessCredentialsTest . CALL_URI ) . build ( ) ; "<AssertPlaceHolder>" ; } hashCode ( ) { return java . util . Objects . hash ( getMessage ( ) , getCause ( ) ) ; }
org . junit . Assert . assertEquals ( credentials . hashCode ( ) , otherCredentials . hashCode ( ) )
testIfDerived_MavenPath_2 ( ) { final org . eclipse . xtext . generator . OutputConfiguration output = new org . eclipse . xtext . generator . OutputConfiguration ( "TEST" ) ; output . setOutputDirectory ( "xtend_gen" ) ; this . classNameValidator . getContext ( ) . put ( "ProjectAwareUniqueClassNameValidator.outputConfigs" , java . util . Collections . < org . eclipse . xtext . generator . OutputConfiguration > unmodifiableList ( org . eclipse . xtext . xbase . lib . CollectionLiterals . < org . eclipse . xtext . generator . OutputConfiguration > newArrayList ( output ) ) ) ; org . eclipse . core . runtime . Path _path = new org . eclipse . core . runtime . Path ( "foo/src/main/xtend_gen/org/eclipse/test/foo.bar" ) ; final org . eclipse . xtext . xbase . ui . tests . validation . MockedFile file = new org . eclipse . xtext . xbase . ui . tests . validation . MockedFile ( _path , null ) ; "<AssertPlaceHolder>" ; } isDerived ( org . eclipse . jdt . core . IType ) { return isDerived ( type . getFullyQualifiedName ( ) , type . getJavaProject ( ) ) ; }
org . junit . Assert . assertFalse ( this . classNameValidator . isDerived ( file ) )
testTake ( ) { java . nio . file . WatchKey mockKey = mock ( java . nio . file . WatchKey . class ) ; doReturn ( null ) . doReturn ( mockKey ) . when ( watchService ) . poll ( ) ; org . powermock . api . mockito . PowerMockito . spy ( com . peircean . glusterfs . Thread . class ) ; org . powermock . api . mockito . PowerMockito . doThrow ( new java . lang . InterruptedException ( ) ) . when ( com . peircean . glusterfs . Thread . class ) ; java . lang . Thread . sleep ( GlusterWatchService . PERIOD ) ; java . nio . file . WatchKey key = watchService . take ( ) ; "<AssertPlaceHolder>" ; org . mockito . Mockito . verify ( watchService , org . mockito . Mockito . times ( 2 ) ) . poll ( ) ; org . powermock . api . mockito . PowerMockito . verifyStatic ( ) ; java . lang . Thread . sleep ( GlusterWatchService . PERIOD ) ; } take ( ) { while ( running ) { java . nio . file . WatchKey key = poll ( ) ; if ( key != null ) { return key ; } try { java . lang . Thread . sleep ( com . peircean . glusterfs . GlusterWatchService . PERIOD ) ; } catch ( java . lang . InterruptedException e ) { } } throw new java . nio . file . ClosedWatchServiceException ( ) ; }
org . junit . Assert . assertEquals ( mockKey , key )
testTestClassWithoutCleaningErrorLog ( ) { org . eclipse . core . runtime . ILog log = org . eclipse . core . runtime . Platform . getLog ( org . eclipse . core . runtime . Platform . getBundle ( Activator . PLUGIN_ID ) ) ; log . log ( new org . eclipse . core . runtime . Status ( org . eclipse . core . runtime . IStatus . ERROR , "ERROR_1234" , "Error<sp>1234" , new java . lang . NullPointerException ( "NPE_1234" ) ) ) ; getRequirements ( org . eclipse . reddeer . requirements . test . cleanerrorlog . CleanErrorLogRequirementTest . TestClassWithoutCleaningErrorLog . class ) . fulfill ( ) ; new org . eclipse . reddeer . eclipse . ui . views . log . LogView ( ) . open ( ) ; "<AssertPlaceHolder>" ; } getErrorMessages ( ) { return getMessages ( org . eclipse . reddeer . eclipse . ui . views . log . LogView . Severity . ERROR ) ; }
org . junit . Assert . assertFalse ( new org . eclipse . reddeer . eclipse . ui . views . log . LogView ( ) . getErrorMessages ( ) . isEmpty ( ) )
bindEnumSetsInitialValue ( ) { final org . tessell . model . values . SetValue < org . tessell . model . dsl . Color > v = new org . tessell . model . values . SetValue < org . tessell . model . dsl . Color > ( "v" , org . tessell . model . dsl . Color . GREEN ) ; final org . tessell . tests . model . dsl . EnumProperty < org . tessell . model . dsl . Color > e = enumProperty ( v ) ; final org . tessell . tests . model . dsl . StubListBox box = new org . tessell . tests . model . dsl . StubListBox ( ) ; binder . bind ( e ) . to ( box , org . tessell . model . dsl . Color . values ( ) ) ; "<AssertPlaceHolder>" ; } getSelectedIndex ( ) { for ( int i = 0 ; i < ( items . size ( ) ) ; i ++ ) { if ( items . get ( i ) . selected ) { return i ; } } return - 1 ; }
org . junit . Assert . assertThat ( box . getSelectedIndex ( ) , org . hamcrest . CoreMatchers . is ( 0 ) )
sum_A$_Int_containsNull ( ) { com . m3 . scalaflavor4j . IndexedSeq < java . lang . Integer > seq = com . m3 . scalaflavor4j . IndexedSeq . apply ( 1 , 2 , null , 3 ) ; com . m3 . scalaflavor4j . SNum actual = seq . sum ( ) ; "<AssertPlaceHolder>" ; } toInt ( ) { return value . intValue ( ) ; }
org . junit . Assert . assertThat ( actual . toInt ( ) , org . hamcrest . CoreMatchers . is ( org . hamcrest . CoreMatchers . equalTo ( 6 ) ) )
testWithNoHeader ( ) { java . util . Properties props = new java . util . Properties ( ) ; props . put ( "commentChar" , "#" ) ; props . put ( "fileExtension" , ".txt" ) ; java . sql . Connection conn = java . sql . DriverManager . getConnection ( ( "jdbc:relique:csv:" + ( org . relique . jdbc . csv . TestCsvDriver . filePath ) ) , props ) ; java . sql . Statement stmt = conn . createStatement ( ) ; java . sql . ResultSet results = stmt . executeQuery ( "SELECT<sp>*<sp>FROM<sp>only_comments" ) ; "<AssertPlaceHolder>" ; } next ( ) { if ( this . isPlainReader ( ) ) { boolean result = rawReader . next ( ) ; lineNumber = rawReader . getLineNumber ( ) ; fieldValues = rawReader . getFieldValues ( ) ; return result ; } else { if ( ( ( joiningValues ) == null ) || ( ( ( joiningValueNo ) + ( getTransposedFieldsToSkip ( ) ) ) == ( valuesToJoin ) ) ) { java . lang . String line ; try { line = rawReader . getNextDataLine ( ) ; if ( line != null ) lineNumber = rawReader . getLineNumber ( ) ; } catch ( java . io . IOException e ) { throw new java . sql . SQLException ( e . toString ( ) ) ; } if ( line == null ) return false ; joiningValues = rawReader . parseLine ( line , false ) ; joiningValueNo = 0 ; } for ( int i = 0 ; i < ( transposedLines ) ; i ++ ) { fieldValues [ i ] = firstTable . get ( i ) [ ( ( joiningValueNo ) + ( getTransposedFieldsToSkip ( ) ) ) ] ; } for ( int i = transposedLines ; i < ( ( columnNames . length ) - 1 ) ; i ++ ) { fieldValues [ i ] = joiningValues [ ( i - ( transposedLines ) ) ] ; } fieldValues [ ( ( columnNames . length ) - 1 ) ] = joiningValues [ ( ( ( ( columnNames . length ) - ( transposedLines ) ) - 1 ) + ( joiningValueNo ) ) ] ; ( joiningValueNo ) ++ ; if ( ( columnTypes ) == null ) getColumnTypes ( ) ; return true ; } }
org . junit . Assert . assertFalse ( results . next ( ) )
testConvertUrlWithUserinfo ( ) { org . apache . hadoop . fs . Path expectedPath = new org . apache . hadoop . fs . Path ( "foo://username:password@example.com:8042" ) ; org . apache . hadoop . yarn . api . records . URL url = org . apache . hadoop . yarn . api . records . URL . fromPath ( expectedPath ) ; org . apache . hadoop . fs . Path actualPath = url . toPath ( ) ; "<AssertPlaceHolder>" ; }
org . junit . Assert . assertEquals ( expectedPath , actualPath )
testTimeout ( ) { final java . util . concurrent . Future < java . lang . Boolean > future = getFutureAsync ( ) . timeout ( ) ; "<AssertPlaceHolder>" ; org . junit . Assert . fail ( java . lang . String . valueOf ( future . get ( ) ) ) ; } timeout ( ) { java . lang . Thread . sleep ( 1000 ) ; return com . github . vbauer . caesar . bean . SimpleSync . TIMEOUT_VALUE ; }
org . junit . Assert . assertNotNull ( future )
testJaspiAuthContextThrowsAuthenticationException ( ) { com . ibm . ws . security . jaspi . JaspiServiceImplTest . TestDoubleJaspiServiceImpl jaspiService = new com . ibm . ws . security . jaspi . JaspiServiceImplTest . TestDoubleJaspiServiceImpl ( ) ; mock . checking ( new org . jmock . Expectations ( ) { { allowing ( mockWebSecurityContext ) . getJaspiAuthContext ( ) ; will ( throwException ( new com . ibm . ws . security . authentication . AuthenticationException ( "bob" ) ) ) ; } } ) ; com . ibm . ws . security . jaspi . JaspiRequest jaspiRequest = new com . ibm . ws . security . jaspi . JaspiRequest ( newWebRequest ( ) , mockWebAppConfig ) ; com . ibm . ws . webcontainer . security . JaspiService . JaspiAuthContext jac = jaspiService . getJaspiAuthContext ( jaspiRequest , mockAuthConfigProvider ) ; "<AssertPlaceHolder>" ; } getJaspiAuthContext ( com . ibm . ws . security . jaspi . JaspiRequest , javax . security . auth . message . config . AuthConfigProvider ) { com . ibm . ws . security . jaspi . JaspiAuthContext jaspiContext = null ; try { javax . security . auth . message . config . ServerAuthContext authContext = getServerAuthContext ( jaspiRequest , provider ) ; if ( authContext != null ) { jaspiContext = new com . ibm . ws . security . jaspi . JaspiServiceImpl . PostInvokeJaspiContext ( authContext , jaspiRequest . getMessageInfo ( ) ) ; } } catch ( java . lang . Exception e ) { com . ibm . ws . security . authentication . AuthenticationException ex = new com . ibm . ws . security . authentication . AuthenticationException ( "Unable<sp>to<sp>get<sp>JASPI<sp>ServerAuthContext." ) ; ex . initCause ( e ) ; throw ex ; } return jaspiContext ; }
org . junit . Assert . assertNotNull ( jac )
test_getSerialiser_for_string_successful ( ) { java . util . HashMap < java . lang . Class , com . esotericsoftware . kryo . Serializer > serialisers = new java . util . HashMap < java . lang . Class , com . esotericsoftware . kryo . Serializer > ( ) ; serialisers . put ( java . io . File . class , new org . ikasan . serialiser . service . FileKryoSerialiser ( ) ) ; java . util . HashMap < java . lang . Class , org . ikasan . spec . serialiser . Converter > converters = new java . util . HashMap < java . lang . Class , org . ikasan . spec . serialiser . Converter > ( ) ; converters . put ( javax . jms . TextMessage . class , new org . ikasan . serialiser . converter . JmsTextMessageConverter ( ) ) ; converters . put ( javax . jms . MapMessage . class , new org . ikasan . serialiser . converter . JmsMapMessageConverter ( ) ) ; org . ikasan . spec . serialiser . SerialiserFactory serialiserFactory = new org . ikasan . serialiser . service . SerialiserFactoryKryoImpl ( serialisers , converters ) ; java . lang . String str = new java . lang . String ( "test" ) ; org . ikasan . spec . serialiser . Serialiser < java . lang . String , byte [ ] > serialiser = serialiserFactory . getDefaultSerialiser ( ) ; byte [ ] bytes = serialiser . serialise ( str ) ; java . lang . String restored = serialiser . deserialise ( bytes ) ; "<AssertPlaceHolder>" ; } equals ( java . lang . Object ) { if ( ( this ) == o ) return true ; if ( ( o == null ) || ( ( org . ikasan . flow . event . FlowEventFactory . GenericFlowEvent . getClass ( ) ) != ( o . getClass ( ) ) ) ) return false ; org . ikasan . flow . event . FlowEventFactory . GenericFlowEvent that = ( ( org . ikasan . flow . event . FlowEventFactory . GenericFlowEvent ) ( o ) ) ; if ( ! ( identifier . equals ( that . identifier ) ) ) return false ; if ( ( relatedIdentifier ) != null ? ! ( relatedIdentifier . equals ( that . relatedIdentifier ) ) : ( that . relatedIdentifier ) != null ) return false ; return true ; }
org . junit . Assert . assertTrue ( restored . equals ( str ) )
testGetYesterdayDate ( ) { java . util . Calendar cal = new java . util . GregorianCalendar ( ) ; cal . roll ( Calendar . DATE , false ) ; java . util . Date expected = cal . getTime ( ) ; java . util . Date actual = info . michaelkohler . helpertools . date . DateHelper . yesterdayDate ( ) ; "<AssertPlaceHolder>" ; } compareDatesToTheMinutes ( java . util . Date , java . util . Date ) { java . util . Calendar cal1 = new java . util . GregorianCalendar ( ) ; cal1 . setTimeInMillis ( obj1 . getTime ( ) ) ; java . util . Calendar cal2 = new java . util . GregorianCalendar ( ) ; cal2 . setTimeInMillis ( obj2 . getTime ( ) ) ; return ( ( ( ( cal1 . get ( Calendar . DATE ) ) == ( cal2 . get ( Calendar . DATE ) ) ) && ( ( cal1 . get ( Calendar . HOUR ) ) == ( cal2 . get ( Calendar . HOUR ) ) ) ) && ( ( cal1 . get ( Calendar . MINUTE ) ) == ( cal2 . get ( Calendar . MINUTE ) ) ) ) && ( ( cal1 . get ( Calendar . SECOND ) ) == ( cal2 . get ( Calendar . SECOND ) ) ) ; }
org . junit . Assert . assertTrue ( compareDatesToTheMinutes ( actual , expected ) )
tagAbiPairComparisionWhenEqual ( ) { org . arquillian . droidium . container . configuration . target . TagAbiPair tagAbiPair1 = new org . arquillian . droidium . container . configuration . target . TagAbiPair ( org . arquillian . droidium . container . configuration . target . TAG . DEFAULT , org . arquillian . droidium . container . configuration . target . ABI . ARMEABI ) ; org . arquillian . droidium . container . configuration . target . TagAbiPair tagAbiPair2 = new org . arquillian . droidium . container . configuration . target . TagAbiPair ( org . arquillian . droidium . container . configuration . target . TAG . DEFAULT , org . arquillian . droidium . container . configuration . target . ABI . ARMEABI ) ; "<AssertPlaceHolder>" ; } compareTo ( org . arquillian . droidium . container . configuration . target . Target ) { if ( o == null ) { return 1 ; } return ( getId ( ) ) - ( o . getId ( ) ) ; }
org . junit . Assert . assertEquals ( 0 , tagAbiPair1 . compareTo ( tagAbiPair2 ) )
testUndoTaskAssignmentByDocumentIdAndUserId ( ) { qa . qcri . aidr . dbmanager . ejb . remote . facade . imp . TestTaskAssignmentResourceFacadeImp . entityManager . getTransaction ( ) . begin ( ) ; int result = qa . qcri . aidr . dbmanager . ejb . remote . facade . imp . TestTaskAssignmentResourceFacadeImp . taskAssignmentResourceFacadeImp . undoTaskAssignment ( qa . qcri . aidr . dbmanager . ejb . remote . facade . imp . TestTaskAssignmentResourceFacadeImp . documentDTO . getDocumentID ( ) , qa . qcri . aidr . dbmanager . ejb . remote . facade . imp . TestTaskAssignmentResourceFacadeImp . user . getUserID ( ) ) ; qa . qcri . aidr . dbmanager . ejb . remote . facade . imp . TestTaskAssignmentResourceFacadeImp . entityManager . getTransaction ( ) . commit ( ) ; "<AssertPlaceHolder>" ; qa . qcri . aidr . dbmanager . ejb . remote . facade . imp . TestTaskAssignmentResourceFacadeImp . taskAssignment = null ; } getUserID ( ) { return userID ; }
org . junit . Assert . assertEquals ( 1 , result )
testCreateBizkeeperCommand ( ) { com . netflix . hystrix . strategy . HystrixPlugins . reset ( ) ; org . apache . servicecomb . bizkeeper . ProviderBizkeeperHanlder providerBizkeeperHanlder = new org . apache . servicecomb . bizkeeper . ProviderBizkeeperHanlder ( ) ; org . apache . servicecomb . core . Invocation invocation = org . mockito . Mockito . mock ( org . apache . servicecomb . core . Invocation . class ) ; org . mockito . Mockito . when ( invocation . getOperationMeta ( ) ) . thenReturn ( org . mockito . Mockito . mock ( org . apache . servicecomb . core . definition . OperationMeta . class ) ) ; org . mockito . Mockito . when ( invocation . getOperationMeta ( ) . getMicroserviceQualifiedName ( ) ) . thenReturn ( "test1" ) ; org . apache . servicecomb . bizkeeper . CommandKey . toHystrixCommandGroupKey ( "groupname" , invocation ) ; org . apache . servicecomb . bizkeeper . CommandKey . toHystrixCommandKey ( "groupname" , invocation ) ; org . apache . servicecomb . bizkeeper . BizkeeperCommand command = providerBizkeeperHanlder . createBizkeeperCommand ( invocation ) ; "<AssertPlaceHolder>" ; } createBizkeeperCommand ( org . apache . servicecomb . core . Invocation ) { if ( Configuration . INSTANCE . isFallbackForce ( handler . groupname , invocation . getMicroserviceName ( ) , invocation . getOperationMeta ( ) . getMicroserviceQualifiedName ( ) ) ) { return forceFallbackCommand ( invocation ) ; } return handler . createBizkeeperCommand ( invocation ) ; }
org . junit . Assert . assertNotNull ( command )
validateErrorSituationOutput ( ) { nl . basjes . parse . useragent . debug . UserAgentAnalyzerTester uaa = nl . basjes . parse . useragent . debug . UserAgentAnalyzerTester . newBuilder ( ) . hideMatcherLoadStats ( ) . delayInitialization ( ) . dropTests ( ) . build ( ) ; uaa . setShowMatcherStats ( true ) ; uaa . keepTests ( ) ; uaa . loadResources ( "classpath*:**/CheckErrorOutput.yaml" ) ; "<AssertPlaceHolder>" ; } runTests ( boolean , boolean ) { return runTests ( showAll , failOnUnexpected , null , false , false ) ; }
org . junit . Assert . assertFalse ( uaa . runTests ( false , true ) )
testHasNext_NotEnoughPayload ( ) { final java . nio . ByteBuffer buf = java . nio . ByteBuffer . allocate ( MessageUtils . HEADER_LEN ) ; buf . putInt ( 20 ) ; this . it = new com . taobao . metamorphosis . consumer . MessageIterator ( "test" , buf . array ( ) ) ; "<AssertPlaceHolder>" ; } hasNext ( ) { return it . hasNext ( ) ; }
org . junit . Assert . assertFalse ( this . it . hasNext ( ) )
testDependentInstanceDestroyedDuringShutdown ( ) { Foo . DESTROYED . set ( false ) ; try ( org . jboss . weld . environment . se . WeldContainer container = new org . jboss . weld . environment . se . Weld ( ) . disableDiscovery ( ) . beanClasses ( org . jboss . weld . environment . se . test . container . instance . Foo . class ) . initialize ( ) ) { javax . enterprise . inject . spi . CDI . current ( ) . select ( org . jboss . weld . environment . se . test . container . instance . Foo . class ) . get ( ) ; } "<AssertPlaceHolder>" ; } get ( ) { return "Foo!" ; }
org . junit . Assert . assertTrue ( Foo . DESTROYED . get ( ) )
getResultSetShouldNotReturnNull ( ) { org . neo4j . jdbc . bolt . BoltNeo4jStatement statement = mock ( org . neo4j . jdbc . bolt . BoltNeo4jStatement . class ) ; when ( statement . isClosed ( ) ) . thenReturn ( false ) ; when ( statement . getResultSet ( ) ) . thenCallRealMethod ( ) ; org . powermock . reflect . Whitebox . setInternalState ( statement , "currentResultSet" , mock ( org . neo4j . jdbc . bolt . BoltNeo4jResultSet . class ) ) ; org . powermock . reflect . Whitebox . setInternalState ( statement , "currentUpdateCount" , ( - 1 ) ) ; "<AssertPlaceHolder>" ; } getResultSet ( ) { this . checkClosed ( ) ; java . sql . ResultSet rs = this . currentResultSet ; this . currentResultSet = null ; return rs ; }
org . junit . Assert . assertTrue ( ( ( statement . getResultSet ( ) ) != null ) )
testGetIntegerWithoutConversionMask ( ) { java . lang . String value = "100.56" ; org . pentaho . di . core . row . ValueMetaInterface stringValueMeta = new org . pentaho . di . core . row . value . ValueMetaString ( "test" ) ; java . lang . Long expected = 100L ; java . lang . Long result = stringValueMeta . getInteger ( value ) ; "<AssertPlaceHolder>" ; } getInteger ( java . lang . Object ) { try { return meta . getInteger ( object ) ; } catch ( org . pentaho . di . core . exception . KettleValueException kve ) { throw new com . infobright . etl . model . ValueConverterException ( kve ) ; } }
org . junit . Assert . assertEquals ( expected , result )
testParseDummyOptions ( ) { org . jboss . arquillian . drone . webdriver . factory . CapabilitiesDummyOptionsMapperTest . DummyBrowserOptions dummyBrowserOptions = new org . jboss . arquillian . drone . webdriver . factory . CapabilitiesDummyOptionsMapperTest . DummyBrowserOptions ( ) ; org . jboss . arquillian . drone . webdriver . factory . CapabilitiesDummyOptionsMapperTest . DummyBrowserOptions expectedDummyBrowserOptions = prepareDummyBrowserOptions ( ) ; org . openqa . selenium . remote . DesiredCapabilities desiredCapabilities = prepareDesiredCapabilities ( expectedDummyBrowserOptions ) ; org . jboss . arquillian . drone . webdriver . factory . CapabilitiesOptionsMapper . mapCapabilities ( dummyBrowserOptions , desiredCapabilities , "dummy" ) ; "<AssertPlaceHolder>" ; } mapCapabilities ( java . lang . Object , org . openqa . selenium . remote . DesiredCapabilities , java . lang . String ) { java . lang . reflect . Method [ ] methods = object . getClass ( ) . getMethods ( ) ; java . util . List < java . lang . String > processedMethods = new java . util . ArrayList < java . lang . String > ( ) ; for ( java . lang . reflect . Method method : methods ) { if ( org . jboss . arquillian . drone . webdriver . factory . CapabilitiesOptionsMapper . isSetter ( method ) ) { method . setAccessible ( true ) ; java . lang . String methodName = method . getName ( ) ; if ( processedMethods . contains ( methodName ) ) { continue ; } java . lang . String propertyName = browserPrefix + ( methodName . substring ( 3 ) ) ; propertyName = ( java . lang . Character . toLowerCase ( propertyName . charAt ( 0 ) ) ) + ( propertyName . substring ( 1 ) ) ; java . lang . String capability = ( ( java . lang . String ) ( capabilities . getCapability ( propertyName ) ) ) ; if ( org . jboss . arquillian . drone . webdriver . utils . Validate . nonEmpty ( capability ) ) { try { if ( ( method . getParameterTypes ( ) . length ) == 1 ) { java . lang . Object converted = org . jboss . arquillian . drone . webdriver . factory . CapabilitiesOptionsMapper . convert ( method , capability ) ; if ( converted != null ) { method . invoke ( object , converted ) ; processedMethods . add ( methodName ) ; } } else if ( org . jboss . arquillian . drone . webdriver . factory . CapabilitiesOptionsMapper . shouldContainDictionaries ( method ) ) { org . jboss . arquillian . drone . webdriver . factory . CapabilitiesOptionsMapper . handleDictionaries ( object , method , capability ) ; processedMethods . add ( methodName ) ; } } catch ( java . lang . Exception e ) { e . printStackTrace ( ) ; } } } } }
org . junit . Assert . assertEquals ( expectedDummyBrowserOptions , dummyBrowserOptions )
contraintPKAdjustedNotNullBoth ( ) { java . lang . String sql = "CREATE<sp>TABLE<sp>t1<sp>(c1<sp>int,<sp>c2<sp>varchar(32),<sp>PRIMARY<sp>KEY(c1,c2))" ; makeSeparateAIS ( ) ; com . foundationdb . sql . aisddl . TableDDLTest . dropTable = com . foundationdb . ais . model . TableName . create ( com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_SCHEMA , com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_TABLE ) ; builder . table ( com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_SCHEMA , com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_TABLE ) ; builder . column ( com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_SCHEMA , com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_TABLE , "c1" , 0 , "MCOMPAT" , "int" , false , false ) ; builder . column ( com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_SCHEMA , com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_TABLE , "c2" , 1 , "MCOMPAT" , "varchar" , 32L , 0L , false ) ; builder . pk ( com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_SCHEMA , com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_TABLE ) ; builder . indexColumn ( com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_SCHEMA , com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_TABLE , "PRIMARY" , "c1" , 0 , true , 0 ) ; builder . indexColumn ( com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_SCHEMA , com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_TABLE , "PRIMARY" , "c2" , 1 , true , 0 ) ; builder . basicSchemaIsComplete ( ) ; builder . groupingIsComplete ( ) ; com . foundationdb . sql . parser . StatementNode stmt = parser . parseStatement ( sql ) ; "<AssertPlaceHolder>" ; com . foundationdb . sql . aisddl . TableDDL . createTable ( ddlFunctions , null , com . foundationdb . sql . aisddl . TableDDLTest . DEFAULT_SCHEMA , ( ( com . foundationdb . sql . parser . CreateTableNode ) ( stmt ) ) , null ) ; } groupingIsComplete ( ) { com . foundationdb . ais . model . AISBuilder . LOG . trace ( "groupingIsComplete" ) ; for ( com . foundationdb . ais . model . Group group : ais . getGroups ( ) . values ( ) ) { setRootIfNeeded ( group ) ; finishStorageDescription ( group ) ; } for ( com . foundationdb . ais . model . Table table : ais . getTables ( ) . values ( ) ) { table . endTable ( nameGenerator ) ; com . foundationdb . ais . model . Index index = table . getPrimaryKeyIncludingInternal ( ) . getIndex ( ) ; finishStorageDescription ( index ) ; if ( ! ( table . isVirtual ( ) ) ) { com . foundationdb . ais . model . Column column = index . getKeyColumns ( ) . get ( 0 ) . getColumn ( ) ; if ( column . isAkibanPKColumn ( ) ) { com . foundationdb . ais . model . Sequence sequence = column . getIdentityGenerator ( ) ; finishStorageDescription ( sequence ) ; } } } }
org . junit . Assert . assertTrue ( ( stmt instanceof com . foundationdb . sql . parser . CreateTableNode ) )
testAddSegmentInt ( ) { org . pb . x12 . X12Simple x12 = new org . pb . x12 . X12Simple ( new org . pb . x12 . Context ( '~' , '*' , ':' ) ) ; x12 . addSegment ( "ISA*ISA01*ISA02*ISA03" ) ; x12 . addSegment ( "ST*ST01*ST02*ST03" ) ; org . pb . x12 . Segment s = x12 . addSegment ( 1 ) ; s . addElements ( "GS*GS01*GS02*GS03" ) ; "<AssertPlaceHolder>" ; } getSegment ( int ) { return segments . get ( index ) ; }
org . junit . Assert . assertEquals ( "GS*GS01*GS02*GS03" , x12 . getSegment ( 1 ) . toString ( ) )
canConvertPrimitiveInts ( ) { com . sjl . dsl4xml . support . convert . PrimitiveIntStringConverter _c = new com . sjl . dsl4xml . support . convert . PrimitiveIntStringConverter ( ) ; "<AssertPlaceHolder>" ; } canConvertTo ( java . lang . Class ) { return aClass . isAssignableFrom ( Long . TYPE ) ; }
org . junit . Assert . assertTrue ( _c . canConvertTo ( Integer . TYPE ) )
dataConversionTest ( ) { org . kaaproject . kaa . common . dto . credentials . EndpointRegistrationDto endpointRegistrationDto = new org . kaaproject . kaa . common . dto . credentials . EndpointRegistrationDto ( "1" , "2" , "3" , 42 , "test" ) ; org . kaaproject . kaa . server . common . nosql . mongo . dao . model . MongoEndpointRegistration mongoEndpointRegistration = new org . kaaproject . kaa . server . common . nosql . mongo . dao . model . MongoEndpointRegistration ( endpointRegistrationDto ) ; "<AssertPlaceHolder>" ; } toDto ( ) { java . util . List < org . kaaproject . kaa . common . dto . TopicDto > topicDtos = org . kaaproject . kaa . server . common . dao . model . sql . ModelUtils . getTopicDtos ( topicIds ) ; return new org . kaaproject . kaa . common . dto . TopicListEntryDto ( simpleHash , hash , topicDtos ) ; }
org . junit . Assert . assertEquals ( endpointRegistrationDto , mongoEndpointRegistration . toDto ( ) )
test_ ( ) { cfvbaibai . cardfantasy . test . func . SkillTestContext context = prepare ( 50 , 50 , "+" , "+" ) ; context . addToField ( 0 , 0 ) ; cfvbaibai . cardfantasy . engine . CardInfo c = context . addToField ( 1 , 1 ) ; c . setBasicHP ( 1000 ) ; context . startGame ( ) ; context . proceedOneRound ( ) ; "<AssertPlaceHolder>" ; } isDead ( ) { return ! ( isAlive ( ) ) ; }
org . junit . Assert . assertTrue ( c . isDead ( ) )
test_WithOnlyCookieNameMismatch ( ) { ctx . request ( ) . addCookie ( randomCookie ) ; extension . activate ( configWithCookie ) ; boolean actual = extension . accepts ( ctx . request ( ) , null , extension . getAllowedKeyValues ( ) ) ; "<AssertPlaceHolder>" ; } activate ( java . util . Map ) { this . listRoot = org . apache . sling . commons . osgi . PropertiesUtil . toString ( props . get ( com . adobe . acs . commons . genericlists . impl . GenericListJsonResourceProvider . PROP_LIST_ROOT ) , com . adobe . acs . commons . genericlists . impl . GenericListJsonResourceProvider . DEFAULT_LIST_ROOT ) ; }
org . junit . Assert . assertFalse ( actual )
testTypeParPlain ( ) { org . drools . decisiontable . parser . LhsBuilder builder = new org . drools . decisiontable . parser . LhsBuilder ( 9 , 1 , null ) ; builder . addTemplate ( 10 , 1 , "Type()" ) ; builder . addCellValue ( 11 , 1 , "x" ) ; "<AssertPlaceHolder>" ; } getResult ( ) { return result ; }
org . junit . Assert . assertEquals ( "Type()" , builder . getResult ( ) )
testGetLayerGroups ( ) { if ( ! ( enabled ( ) ) ) { return ; } java . util . List < java . lang . String > groups = reader . getLayerGroups ( ) . getNames ( ) ; it . geosolutions . geoserver . rest . GeoServerRESTClassTest . LOGGER . info ( ( ( "Found<sp>" + ( groups . size ( ) ) ) + "<sp>layerGroups" ) ) ; for ( java . lang . String groupName : groups ) { it . geosolutions . geoserver . rest . decoder . RESTLayerGroup group = reader . getLayerGroup ( groupName ) ; if ( groups != null ) { "<AssertPlaceHolder>" ; } } } getPublishedList ( ) { if ( ( rootElem . getChild ( "publishables" ) ) != null ) { return new it . geosolutions . geoserver . rest . decoder . RESTPublishedList ( rootElem . getChild ( "publishables" ) ) ; } else { return null ; } }
org . junit . Assert . assertNotNull ( group . getPublishedList ( ) )
testConnectionClosed ( ) { java . sql . Connection conn = createMock ( java . sql . Connection . class ) ; conn . setAutoCommit ( true ) ; expect ( conn . isClosed ( ) ) . andReturn ( true ) ; java . sql . Driver driver = createMock ( java . sql . Driver . class ) ; java . lang . String url = "jdbc:bar:baz" ; expect ( driver . acceptsURL ( url ) ) . andReturn ( true ) ; expect ( driver . connect ( isA ( java . lang . String . class ) , isA ( java . util . Properties . class ) ) ) . andReturn ( conn ) ; replay ( driver , conn ) ; java . sql . DriverManager . registerDriver ( driver ) ; try { com . j256 . ormlite . jdbc . JdbcConnectionSource sds = new com . j256 . ormlite . jdbc . JdbcConnectionSource ( url , databaseType ) ; "<AssertPlaceHolder>" ; sds . getReadOnlyConnection ( null ) ; sds . close ( ) ; org . junit . Assert . fail ( "Should<sp>not<sp>get<sp>here" ) ; } finally { java . sql . DriverManager . deregisterDriver ( driver ) ; } } getReadOnlyConnection ( java . lang . String ) { return getReadWriteConnection ( tableName ) ; }
org . junit . Assert . assertNotNull ( sds . getReadOnlyConnection ( null ) )
setDevToolsPort ( ) { int devPort = 7777 ; com . openfin . desktop . RuntimeConfiguration configuration = com . openfin . desktop . RuntimeConfigTest . getDefaultRuntimeConfiguration ( ) ; configuration . setDevToolsPort ( devPort ) ; com . openfin . desktop . DesktopConnection conn = com . openfin . desktop . TestUtils . setupConnection ( com . openfin . desktop . RuntimeConfigTest . DESKTOP_UUID , configuration ) ; "<AssertPlaceHolder>" ; com . openfin . desktop . TestUtils . teardownDesktopConnection ( conn ) ; } serverListening ( int ) { java . net . Socket s = null ; try { s = new java . net . Socket ( "localhost" , port ) ; return true ; } catch ( java . lang . Exception e ) { return false ; } finally { if ( s != null ) try { s . close ( ) ; } catch ( java . lang . Exception e ) { } } }
org . junit . Assert . assertTrue ( com . openfin . desktop . RuntimeConfigTest . serverListening ( devPort ) )
shouldReadExampleBsonStream ( ) { byte [ ] bytes = new byte [ ] { 22 , 0 , 0 , 0 , 2 , 104 , 101 , 108 , 108 , 111 , 0 , 6 , 0 , 0 , 0 , 119 , 111 , 114 , 108 , 100 , 0 , 0 } ; output = reader . read ( new java . io . ByteArrayInputStream ( bytes ) ) ; java . lang . String json = org . modeshape . schematic . document . Json . write ( output ) ; java . lang . String expected = "{<sp>\"hello\"<sp>:<sp>\"world\"<sp>}" ; if ( print ) { System . out . println ( json ) ; System . out . flush ( ) ; } "<AssertPlaceHolder>" ; } flush ( ) { }
org . junit . Assert . assertEquals ( expected , json )
verifyEvaluation_SSO_IDP_TRUSTSTORE_PASSWORD_Null ( ) { addEntry ( "SSO_IDP_TRUSTSTORE_PASSWORD" , null ) ; query . execute ( ) ; "<AssertPlaceHolder>" ; } getIDPTruststorePassword ( ) { return idpTruststorePasswd ; }
org . junit . Assert . assertEquals ( "" , query . getIDPTruststorePassword ( ) )
testIncludeExtensionReferenceAsRecurse ( ) { ca . uhn . fhir . jpa . dao . r4 . SearchParameter attendingSp = new ca . uhn . fhir . jpa . dao . r4 . SearchParameter ( ) ; attendingSp . addBase ( "Patient" ) ; attendingSp . setCode ( "attending" ) ; attendingSp . setType ( org . hl7 . fhir . r4 . model . Enumerations . SearchParamType . REFERENCE ) ; attendingSp . setTitle ( "Attending" ) ; attendingSp . setExpression ( "Patient.extension('http://acme.org/attending')" ) ; attendingSp . setXpathUsage ( org . hl7 . fhir . r4 . model . SearchParameter . XPathUsageType . NORMAL ) ; attendingSp . setStatus ( org . hl7 . fhir . r4 . model . Enumerations . PublicationStatus . ACTIVE ) ; attendingSp . getTarget ( ) . add ( new ca . uhn . fhir . jpa . dao . r4 . CodeType ( "Practitioner" ) ) ; org . hl7 . fhir . instance . model . api . IIdType spId = mySearchParameterDao . create ( attendingSp , mySrd ) . getId ( ) . toUnqualifiedVersionless ( ) ; mySearchParamRegistry . forceRefresh ( ) ; ca . uhn . fhir . jpa . dao . r4 . Practitioner p1 = new ca . uhn . fhir . jpa . dao . r4 . Practitioner ( ) ; p1 . addName ( ) . setFamily ( "P1" ) ; org . hl7 . fhir . instance . model . api . IIdType p1id = myPractitionerDao . create ( p1 ) . getId ( ) . toUnqualifiedVersionless ( ) ; ca . uhn . fhir . jpa . dao . r4 . Patient p2 = new ca . uhn . fhir . jpa . dao . r4 . Patient ( ) ; p2 . addName ( ) . setFamily ( "P2" ) ; p2 . addExtension ( ) . setUrl ( "http://acme.org/attending" ) . setValue ( new ca . uhn . fhir . jpa . dao . r4 . Reference ( p1id ) ) ; org . hl7 . fhir . instance . model . api . IIdType p2id = myPatientDao . create ( p2 ) . getId ( ) . toUnqualifiedVersionless ( ) ; ca . uhn . fhir . jpa . dao . r4 . Appointment app = new ca . uhn . fhir . jpa . dao . r4 . Appointment ( ) ; app . addParticipant ( ) . getActor ( ) . setReference ( p2id . getValue ( ) ) ; org . hl7 . fhir . instance . model . api . IIdType appId = myAppointmentDao . create ( app ) . getId ( ) . toUnqualifiedVersionless ( ) ; ca . uhn . fhir . jpa . searchparam . SearchParameterMap map ; ca . uhn . fhir . rest . api . server . IBundleProvider results ; java . util . List < java . lang . String > foundResources ; map = new ca . uhn . fhir . jpa . searchparam . SearchParameterMap ( ) ; map . addInclude ( new ca . uhn . fhir . model . api . Include ( "Appointment:patient" , true ) ) ; map . addInclude ( new ca . uhn . fhir . model . api . Include ( "Patient:attending" , true ) ) ; results = myAppointmentDao . search ( map ) ; foundResources = toUnqualifiedVersionlessIdValues ( results ) ; "<AssertPlaceHolder>" ; } getValue ( ) { return myValue ; }
org . junit . Assert . assertThat ( foundResources , contains ( appId . getValue ( ) , p2id . getValue ( ) , p1id . getValue ( ) ) )
testTokens_ignore__fieldsMiddle ( ) { java . util . List < org . apache . ambari . server . api . predicate . Token > listTokens = new java . util . ArrayList ( ) ; listTokens . add ( new org . apache . ambari . server . api . predicate . Token ( Token . TYPE . RELATIONAL_OPERATOR , "=" ) ) ; listTokens . add ( new org . apache . ambari . server . api . predicate . Token ( Token . TYPE . PROPERTY_OPERAND , "foo" ) ) ; listTokens . add ( new org . apache . ambari . server . api . predicate . Token ( Token . TYPE . VALUE_OPERAND , "1" ) ) ; listTokens . add ( new org . apache . ambari . server . api . predicate . Token ( Token . TYPE . LOGICAL_OPERATOR , "&" ) ) ; listTokens . add ( new org . apache . ambari . server . api . predicate . Token ( Token . TYPE . RELATIONAL_OPERATOR , "=" ) ) ; listTokens . add ( new org . apache . ambari . server . api . predicate . Token ( Token . TYPE . PROPERTY_OPERAND , "bar" ) ) ; listTokens . add ( new org . apache . ambari . server . api . predicate . Token ( Token . TYPE . VALUE_OPERAND , "2" ) ) ; org . apache . ambari . server . api . predicate . QueryLexer lexer = new org . apache . ambari . server . api . predicate . QueryLexer ( ) ; org . apache . ambari . server . api . predicate . Token [ ] tokens = lexer . tokens ( "foo=1&fields=a/b&bar=2" ) ; "<AssertPlaceHolder>" ; } size ( ) { java . util . Set < java . lang . String > nodes = new java . util . HashSet < java . lang . String > ( ) ; for ( org . apache . ambari . eventdb . model . WorkflowDag . WorkflowDagEntry entry : entries ) { nodes . add ( entry . getSource ( ) ) ; nodes . addAll ( entry . getTargets ( ) ) ; } return nodes . size ( ) ; }
org . junit . Assert . assertArrayEquals ( listTokens . toArray ( new org . apache . ambari . server . api . predicate . Token [ listTokens . size ( ) ] ) , tokens )
testCountEitherMobileOrZeroDomainZero ( ) { org . apache . pig . data . Tuple input = tupleFactory . newTuple ( 2 ) ; input . set ( 0 , "http://en.zero.wikipedia.org/wiki/James_Ingram" ) ; input . set ( 1 , "zero-saudi-telecom.tab" ) ; org . wikimedia . analytics . kraken . pig . ZeroFilterFunc zero = new org . wikimedia . analytics . kraken . pig . ZeroFilterFunc ( "legacy" ) ; "<AssertPlaceHolder>" ; } exec ( org . apache . pig . data . Tuple ) { if ( ( input == null ) || ( ( input . get ( 0 ) ) == null ) ) { return null ; } java . lang . String url = ( ( java . lang . String ) ( input . get ( 0 ) ) ) ; java . lang . String referer = ( ( java . lang . String ) ( input . get ( 1 ) ) ) ; java . lang . String userAgent = ( ( input . get ( 2 ) ) != null ) ? ( ( java . lang . String ) ( input . get ( 2 ) ) ) : "-" ; java . lang . String statusCode = ( ( input . get ( 3 ) ) != null ) ? ( ( java . lang . String ) ( input . get ( 3 ) ) ) : "-" ; java . lang . String ip = ( ( input . get ( 4 ) ) != null ) ? ( ( java . lang . String ) ( input . get ( 4 ) ) ) : "-" ; java . lang . String mimeType = ( ( input . get ( 5 ) ) != null ) ? ( ( java . lang . String ) ( input . get ( 5 ) ) ) : "-" ; java . lang . String requestMethod = ( ( input . get ( 6 ) ) != null ) ? ( ( java . lang . String ) ( input . get ( 6 ) ) ) : "-" ; org . wikimedia . analytics . kraken . pageview . Pageview pageview = new org . wikimedia . analytics . kraken . pageview . Pageview ( url , referer , userAgent , statusCode , ip , mimeType , requestMethod ) ; output = tupleFactory . newTuple ( 3 ) ; output . set ( 0 , ( pageview . isPageview ( ) ? 1 : 0 ) ) ; output . set ( 1 , ( pageview . isWebstatscollectorPageview ( ) ? 1 : 0 ) ) ; output . set ( 2 , ( pageview . isWikistatsMobileReportPageview ( ) ? 1 : 0 ) ) ; return output ; }
org . junit . Assert . assertTrue ( zero . exec ( input ) )
resetWithoutMarkReturnsToStart ( ) { final byte [ ] data = new byte [ ] { 1 , 2 , 3 , 4 } ; final java . io . ByteArrayInputStream stream = new java . io . ByteArrayInputStream ( data ) ; final com . flagstone . transform . coder . BigDecoder fixture = new com . flagstone . transform . coder . BigDecoder ( stream ) ; fixture . readBytes ( new byte [ 3 ] ) ; fixture . reset ( ) ; "<AssertPlaceHolder>" ; } readByte ( ) { if ( ( ( size ) - ( index ) ) < 1 ) { fill ( ) ; } if ( ( ( index ) + 1 ) > ( size ) ) { throw new java . lang . ArrayIndexOutOfBoundsException ( ) ; } return ( buffer [ ( ( index ) ++ ) ] ) & ( com . flagstone . transform . coder . SWFDecoder . BYTE_MASK ) ; }
org . junit . Assert . assertEquals ( 1 , fixture . readByte ( ) )
testGetRefundInvalidPaymentValue ( ) { org . oscarehr . common . dao . BillingONPaymentDao paymentDao = ( ( org . oscarehr . common . dao . BillingONPaymentDao ) ( org . oscarehr . util . SpringUtils . getBean ( org . oscarehr . common . dao . BillingONPaymentDao . class ) ) ) ; org . oscarehr . common . model . BillingONPayment paymentRecord = new org . oscarehr . common . model . BillingONPayment ( ) ; paymentRecord . setBillingNo ( 1 ) ; paymentRecord . setPaymentDate ( new java . util . Date ( ) ) ; org . oscarehr . common . model . BillingONExt extraBillingPayment = new org . oscarehr . common . model . BillingONExt ( ) ; extraBillingPayment . setBillingNo ( 1 ) ; extraBillingPayment . setKeyVal ( "refund" ) ; extraBillingPayment . setValue ( "abc123" ) ; extraBillingPayment . setPaymentId ( 1 ) ; paymentDao . persist ( paymentRecord ) ; dao . persist ( extraBillingPayment ) ; java . math . BigDecimal refund = dao . getRefund ( paymentRecord ) ; "<AssertPlaceHolder>" ; } getRefund ( org . oscarehr . common . model . BillingONPayment ) { java . lang . String sql = "select<sp>bExt<sp>from<sp>BillingONExt<sp>bExt<sp>where<sp>paymentId=?<sp>and<sp>billingNo=?<sp>and<sp>keyVal=?" ; javax . persistence . Query query = entityManager . createQuery ( sql ) ; query . setParameter ( 1 , paymentRecord . getId ( ) ) ; query . setParameter ( 2 , paymentRecord . getBillingNo ( ) ) ; query . setParameter ( 3 , "refund" ) ; java . util . List < org . oscarehr . common . model . BillingONExt > results = query . getResultList ( ) ; java . math . BigDecimal amtRefunded = null ; if ( ( results . size ( ) ) > 1 ) { org . oscarehr . util . MiscUtils . getLogger ( ) . warn ( ( "Multiple<sp>payments<sp>found<sp>for<sp>Payment<sp>Id:" + ( paymentRecord . getId ( ) ) ) ) ; } if ( results . isEmpty ( ) ) { amtRefunded = new java . math . BigDecimal ( "0.00" ) ; } else { org . oscarehr . common . model . BillingONExt refund = results . get ( 0 ) ; try { amtRefunded = new java . math . BigDecimal ( refund . getValue ( ) ) ; } catch ( java . lang . NumberFormatException e ) { org . oscarehr . util . MiscUtils . getLogger ( ) . warn ( ( ( ( "Refund<sp>not<sp>a<sp>valid<sp>currency<sp>amount<sp>(" + ( refund . getValue ( ) ) ) + ")<sp>for<sp>Payment<sp>Id:" ) + ( paymentRecord . getId ( ) ) ) ) ; amtRefunded = new java . math . BigDecimal ( "0.00" ) ; } } return amtRefunded ; }
org . junit . Assert . assertEquals ( new java . math . BigDecimal ( "0.00" ) , refund )
search_direct_deep ( ) { touch ( "a.csv" ) ; touch ( "a/a.csv" ) ; touch ( "a/a/a.csv" ) ; touch ( "a/a/a/a.csv" ) ; org . apache . hadoop . fs . FileSystem fs = getTempFileSystem ( ) ; java . util . List < org . apache . hadoop . fs . FileStatus > results = com . asakusafw . runtime . directio . hadoop . HadoopDataSourceUtil . search ( fs , getBase ( ) , com . asakusafw . runtime . directio . FilePattern . compile ( "a/a/a.csv" ) ) ; "<AssertPlaceHolder>" ; } normalize ( java . lang . String ) { assert url != null ; if ( url . endsWith ( "/" ) ) { return url ; } return url + "/" ; }
org . junit . Assert . assertThat ( normalize ( results ) , is ( path ( "a/a/a.csv" ) ) )
testShuffle ( ) { RandomUtil . random = new com . liferay . portal . kernel . security . RandomUtilTest . PredictableRandom ( com . liferay . portal . kernel . security . RandomUtilTest . _NUMBERS ) ; java . lang . String inputString = "abcdefghij" ; java . lang . String shutffledString = com . liferay . portal . kernel . security . RandomUtil . shuffle ( inputString ) ; char [ ] shutffledChars = shutffledString . toCharArray ( ) ; java . util . Arrays . sort ( shutffledChars ) ; "<AssertPlaceHolder>" ; } sort ( java . util . Collection ) { java . util . List < java . lang . String > list = new java . util . ArrayList ( collection ) ; java . util . Collections . sort ( list ) ; return list . toString ( ) ; }
org . junit . Assert . assertEquals ( inputString , new java . lang . String ( shutffledChars ) )
testHasDisabledFeaturesNot ( ) { java . lang . String version = "2.15" ; when ( gerritServerOne . getGerritVersion ( ) ) . thenReturn ( version ) ; listener . checkGerritVersionFeatures ( ) ; "<AssertPlaceHolder>" ; } hasDisabledFeatures ( ) { if ( ( ( gerritConnectionListener ) != null ) && ( gerritConnectionListener . isConnected ( ) ) ) { java . util . List < com . sonyericsson . hudson . plugins . gerrit . trigger . version . GerritVersionChecker . Feature > disabledFeatures = gerritConnectionListener . getDisabledFeatures ( ) ; if ( ( disabledFeatures != null ) && ( ! ( disabledFeatures . isEmpty ( ) ) ) ) { return true ; } } return false ; }
org . junit . Assert . assertFalse ( gerritServerOne . hasDisabledFeatures ( ) )
analyzeTest ( ) { org . sonar . plugins . delphi . antlr . analyzer . LexerMetrics [ ] metrics = new org . sonar . plugins . delphi . antlr . analyzer . LexerMetrics [ ] { org . sonar . plugins . delphi . antlr . analyzer . LexerMetrics . PUBLIC , org . sonar . plugins . delphi . antlr . analyzer . LexerMetrics . PUBLIC , org . sonar . plugins . delphi . antlr . analyzer . LexerMetrics . PRIVATE } ; int i = 0 ; do { analyzer . analyze ( code , results ) ; org . sonar . plugins . delphi . antlr . analyzer . LexerMetrics visibility = results . getParseVisibility ( ) ; "<AssertPlaceHolder>" ; code . setCurrentNode ( advanceOp . execute ( code . getCurrentCodeNode ( ) . getNode ( ) ) ) ; } while ( code . getCurrentCodeNode ( ) . isValid ( ) ) ; } getParseVisibility ( ) { return parseVisibility ; }
org . junit . Assert . assertEquals ( metrics [ ( i ++ ) ] , visibility )
testStackedAssignments ( ) { spoon . reflect . declaration . CtType < spoon . test . variable . testclasses . StackedAssignmentSample > type = spoon . testing . utils . ModelUtils . buildClass ( spoon . test . variable . testclasses . StackedAssignmentSample . class ) ; java . util . List < spoon . reflect . code . CtAssignment > l = type . getElements ( new spoon . reflect . visitor . filter . TypeFilter ( spoon . reflect . code . CtAssignment . class ) ) ; "<AssertPlaceHolder>" ; } size ( ) { throw new java . lang . UnsupportedOperationException ( ) ; }
org . junit . Assert . assertEquals ( 3 , l . size ( ) )
testGetOsName ( ) { final java . lang . String expected = "Windows<sp>Me" ; com . vmware . xenon . common . SystemHostInfo systemHostInfo = new com . vmware . xenon . common . SystemHostInfo ( ) ; systemHostInfo . properties . put ( SystemHostInfo . PROPERTY_NAME_OS_NAME , expected ) ; "<AssertPlaceHolder>" ; } getOsName ( ) { return this . properties . get ( com . vmware . xenon . common . SystemHostInfo . PROPERTY_NAME_OS_NAME ) ; }
org . junit . Assert . assertEquals ( expected , systemHostInfo . getOsName ( ) )
metadataCheck ( ) { org . easydevelop . business . domain . User order = new org . easydevelop . business . domain . User ( ) ; order . setUserId ( 1 ) ; keyTest . metadataCheck ( order ) ; "<AssertPlaceHolder>" ; } metadataCheck ( org . easydevelop . business . domain . User ) { return testUser . getName ( ) ; }
org . junit . Assert . assertTrue ( order . getName ( ) . equals ( "1" ) )
testDateLookupInMessage ( ) { final java . lang . String template = "${date:YYYY-MM-dd}" ; context . getLogger ( org . apache . logging . log4j . core . layout . PatternLayoutNoLookupDateTest . class . getName ( ) ) . info ( template ) ; final org . apache . logging . log4j . test . appender . ListAppender listAppender = context . getListAppender ( "List" ) ; final java . lang . String string = listAppender . getMessages ( ) . get ( 0 ) ; "<AssertPlaceHolder>" ; } contains ( java . lang . Object ) { return list . contains ( o ) ; }
org . junit . Assert . assertTrue ( string , string . contains ( template ) )
getIpAddress_NIC3 ( ) { parameters . put ( VMPropertyHandler . TS_NIC1_IP_ADDRESS , new org . oscm . app . v2_0 . data . Setting ( VMPropertyHandler . TS_NIC1_IP_ADDRESS , "ip<sp>address<sp>1" ) ) ; parameters . put ( VMPropertyHandler . TS_NIC2_IP_ADDRESS , new org . oscm . app . v2_0 . data . Setting ( VMPropertyHandler . TS_NIC2_IP_ADDRESS , "ip<sp>address<sp>2" ) ) ; parameters . put ( VMPropertyHandler . TS_NIC3_IP_ADDRESS , new org . oscm . app . v2_0 . data . Setting ( VMPropertyHandler . TS_NIC3_IP_ADDRESS , "ip<sp>address<sp>3" ) ) ; parameters . put ( VMPropertyHandler . TS_NIC4_IP_ADDRESS , new org . oscm . app . v2_0 . data . Setting ( VMPropertyHandler . TS_NIC4_IP_ADDRESS , "ip<sp>address<sp>4" ) ) ; java . lang . String ipAddress = propertyHandler . getIpAddress ( 3 ) ; "<AssertPlaceHolder>" ; } getIpAddress ( com . vmware . vim25 . GuestInfo ) { java . lang . StringBuilder sb = new java . lang . StringBuilder ( ) ; for ( int i = 1 ; i <= ( paramHandler . getNumberOfNetworkAdapter ( ) ) ; i ++ ) { com . vmware . vim25 . GuestNicInfo info = getNicInfo ( guestInfo , paramHandler . getNetworkAdapter ( i ) ) ; if ( info != null ) { if ( ( ( paramHandler . getNetworkAdapter ( i ) ) != null ) && ( ! ( paramHandler . getNetworkAdapter ( i ) . trim ( ) . isEmpty ( ) ) ) ) { sb . append ( ( ( paramHandler . getNetworkAdapter ( i ) ) + ":<sp>" ) ) ; } sb . append ( info . getIpAddress ( ) ) ; if ( i < ( paramHandler . getNumberOfNetworkAdapter ( ) ) ) { sb . append ( ",<sp>" ) ; } } } return sb . toString ( ) ; }
org . junit . Assert . assertEquals ( "ip<sp>address<sp>3" , ipAddress )