target stringlengths 20 113k | src_fm stringlengths 11 86.3k | src_fm_fc stringlengths 21 86.4k | src_fm_fc_co stringlengths 30 86.4k | src_fm_fc_ms stringlengths 42 86.8k | src_fm_fc_ms_ff stringlengths 43 86.8k |
|---|---|---|---|---|---|
@Test public void testGetOutputResourceFields() throws Exception { XMLField[] outputFields = new XMLField[2]; XMLField field1 = mock( XMLField.class ); XMLField field2 = mock( XMLField.class ); outputFields[0] = field1; outputFields[1] = field2; when( field1.getFieldName() ).thenReturn( "field1" ); when( field2.getFiel... | @Override public Set<String> getOutputResourceFields( XMLOutputMeta meta ) { Set<String> fields = new HashSet<>(); XMLField[] outputFields = meta.getOutputFields(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField outputField = outputFields[ i ]; fields.add( outputField.getFieldName() ); } return fields; } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public Set<String> getOutputResourceFields( XMLOutputMeta meta ) { Set<String> fields = new HashSet<>(); XMLField[] outputFields = meta.getOutputFields(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField outputField = output... | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public Set<String> getOutputResourceFields( XMLOutputMeta meta ) { Set<String> fields = new HashSet<>(); XMLField[] outputFields = meta.getOutputFields(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField outputField = output... | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public Set<String> getOutputResourceFields( XMLOutputMeta meta ) { Set<String> fields = new HashSet<>(); XMLField[] outputFields = meta.getOutputFields(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField outputField = output... | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public Set<String> getOutputResourceFields( XMLOutputMeta meta ) { Set<String> fields = new HashSet<>(); XMLField[] outputFields = meta.getOutputFields(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField outputField = output... |
@Test public void testCreateResourceNode() throws Exception { IExternalResourceInfo res = mock( IExternalResourceInfo.class ); when( res.getName() ).thenReturn( "file: IMetaverseNode resourceNode = analyzer.createResourceNode( res ); assertNotNull( resourceNode ); assertEquals( DictionaryConst.NODE_TYPE_FILE, resourceN... | @Override public IMetaverseNode createResourceNode( IExternalResourceInfo resource ) throws MetaverseException { return createFileNode( resource.getName(), getDescriptor() ); } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public IMetaverseNode createResourceNode( IExternalResourceInfo resource ) throws MetaverseException { return createFileNode( resource.getName(), getDescriptor() ); } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public IMetaverseNode createResourceNode( IExternalResourceInfo resource ) throws MetaverseException { return createFileNode( resource.getName(), getDescriptor() ); } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public IMetaverseNode createResourceNode( IExternalResourceInfo resource ) throws MetaverseException { return createFileNode( resource.getName(), getDescriptor() ); } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); ... | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public IMetaverseNode createResourceNode( IExternalResourceInfo resource ) throws MetaverseException { return createFileNode( resource.getName(), getDescriptor() ); } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); ... |
@Test public void testGetResourceInputNodeType() throws Exception { assertNull( analyzer.getResourceInputNodeType() ); } | @Override public String getResourceInputNodeType() { return null; } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public String getResourceInputNodeType() { return null; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public String getResourceInputNodeType() { return null; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public String getResourceInputNodeType() { return null; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ); @Override String getResourceIn... | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public String getResourceInputNodeType() { return null; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ); @Override String getResourceIn... |
@Test public void testGetResourceOutputNodeType() throws Exception { assertEquals( DictionaryConst.NODE_TYPE_FILE_FIELD, analyzer.getResourceOutputNodeType() ); } | @Override public String getResourceOutputNodeType() { return DictionaryConst.NODE_TYPE_FILE_FIELD; } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public String getResourceOutputNodeType() { return DictionaryConst.NODE_TYPE_FILE_FIELD; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public String getResourceOutputNodeType() { return DictionaryConst.NODE_TYPE_FILE_FIELD; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public String getResourceOutputNodeType() { return DictionaryConst.NODE_TYPE_FILE_FIELD; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ... | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public String getResourceOutputNodeType() { return DictionaryConst.NODE_TYPE_FILE_FIELD; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ... |
@Test public void testIsOutput() throws Exception { assertTrue( analyzer.isOutput() ); } | @Override public boolean isOutput() { return true; } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public boolean isOutput() { return true; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public boolean isOutput() { return true; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public boolean isOutput() { return true; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ); @Override String getResourceInputNodeType(); ... | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public boolean isOutput() { return true; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ); @Override String getResourceInputNodeType(); ... |
@Test public void testInsertJobEntryDatabase() throws KettleException { doReturn( getNullIntegerRow() ).when( repo.connectionDelegate ).getOneRow( anyString(), anyString(), any( ObjectId.class ) ); ArgumentCaptor<String> argumentTableName = ArgumentCaptor.forClass( String.class ); ArgumentCaptor<RowMetaAndData> argumen... | public synchronized void insertJobEntryDatabase( ObjectId id_job, ObjectId id_jobentry, ObjectId id_database ) throws KettleException { RowMetaAndData check = getJobEntryDatabase( id_jobentry ); if ( check.getInteger( 0 ) == null ) { RowMetaAndData table = new RowMetaAndData(); table.addValue( new ValueMetaInteger( Ket... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized void insertJobEntryDatabase( ObjectId id_job, ObjectId id_jobentry, ObjectId id_database ) throws KettleException { RowMetaAndData check = getJobEntryDatabase( id_jobentry ); if ( check.getInteger( 0 ) == null ) { RowMetaAndData table =... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized void insertJobEntryDatabase( ObjectId id_job, ObjectId id_jobentry, ObjectId id_database ) throws KettleException { RowMetaAndData check = getJobEntryDatabase( id_jobentry ); if ( check.getInteger( 0 ) == null ) { RowMetaAndData table =... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized void insertJobEntryDatabase( ObjectId id_job, ObjectId id_jobentry, ObjectId id_database ) throws KettleException { RowMetaAndData check = getJobEntryDatabase( id_jobentry ); if ( check.getInteger( 0 ) == null ) { RowMetaAndData table =... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized void insertJobEntryDatabase( ObjectId id_job, ObjectId id_jobentry, ObjectId id_database ) throws KettleException { RowMetaAndData check = getJobEntryDatabase( id_jobentry ); if ( check.getInteger( 0 ) == null ) { RowMetaAndData table =... |
@Test public void testIsInput() throws Exception { assertFalse( analyzer.isInput() ); } | @Override public boolean isInput() { return false; } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public boolean isInput() { return false; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public boolean isInput() { return false; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public boolean isInput() { return false; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ); @Override String getResourceInputNodeType(); ... | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override public boolean isInput() { return false; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ); @Override String getResourceInputNodeType(); ... |
@Test public void testGetUsedFields() throws Exception { assertNull( analyzer.getUsedFields( meta ) ); } | @Override protected Set<StepField> getUsedFields( XMLOutputMeta meta ) { return null; } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override protected Set<StepField> getUsedFields( XMLOutputMeta meta ) { return null; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override protected Set<StepField> getUsedFields( XMLOutputMeta meta ) { return null; } } | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override protected Set<StepField> getUsedFields( XMLOutputMeta meta ) { return null; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ); @Override ... | XMLOutputStepAnalyzer extends ExternalResourceStepAnalyzer<XMLOutputMeta> { @Override protected Set<StepField> getUsedFields( XMLOutputMeta meta ) { return null; } @Override Set<Class<? extends BaseStepMeta>> getSupportedSteps(); @Override IMetaverseNode createResourceNode( IExternalResourceInfo resource ); @Override ... |
@Test public void testLoadAndGetXml() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); Node stepnode = getTestNode(); DatabaseMeta dbMeta = mock( DatabaseMeta.class ); IMetaStore metaStore = mock( IMetaStore.class ); xmlOutputMeta.loadXML( stepnode, Collections.singletonList( dbMeta ), metaStore );... | public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } } | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } XMLOutputMeta(); } | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } XMLOutputMeta(); boolean isDateInFilename(); void setDateInFilename( boolean dateInFilename ); String getExtensio... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } XMLOutputMeta(); boolean isDateInFilename(); void setDateInFilename( boolean dateInFilename ); String getExtensio... |
@SuppressWarnings( "ConstantConditions" ) @Test public void testReadRep() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); Repository rep = mock( Repository.class ); IMetaStore metastore = mock( IMetaStore.class ); DatabaseMeta dbMeta = mock( DatabaseMeta.class ); String encoding = "UTF-8"; String ... | public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "name_space" ); mainElement = rep.getStepAttributeString( id_step, "xm... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "nam... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "nam... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "nam... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "nam... |
@Test public void testGetNewline() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); assertEquals( "\r\n", xmlOutputMeta.getNewLine( "DOS" ) ); assertEquals( "\n", xmlOutputMeta.getNewLine( "UNIX" ) ); assertEquals( System.getProperty( "line.separator" ), xmlOutputMeta.getNewLine( null ) ); } | public String getNewLine( String fformat ) { String nl = System.getProperty( "line.separator" ); if ( fformat != null ) { if ( fformat.equalsIgnoreCase( "DOS" ) ) { nl = "\r\n"; } else if ( fformat.equalsIgnoreCase( "UNIX" ) ) { nl = "\n"; } } return nl; } | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String getNewLine( String fformat ) { String nl = System.getProperty( "line.separator" ); if ( fformat != null ) { if ( fformat.equalsIgnoreCase( "DOS" ) ) { nl = "\r\n"; } else if ( fformat.equalsIgnoreCase( "UNIX" ) ) { nl = "\n"; } } return nl;... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String getNewLine( String fformat ) { String nl = System.getProperty( "line.separator" ); if ( fformat != null ) { if ( fformat.equalsIgnoreCase( "DOS" ) ) { nl = "\r\n"; } else if ( fformat.equalsIgnoreCase( "UNIX" ) ) { nl = "\n"; } } return nl;... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String getNewLine( String fformat ) { String nl = System.getProperty( "line.separator" ); if ( fformat != null ) { if ( fformat.equalsIgnoreCase( "DOS" ) ) { nl = "\r\n"; } else if ( fformat.equalsIgnoreCase( "UNIX" ) ) { nl = "\n"; } } return nl;... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String getNewLine( String fformat ) { String nl = System.getProperty( "line.separator" ); if ( fformat != null ) { if ( fformat.equalsIgnoreCase( "DOS" ) ) { nl = "\r\n"; } else if ( fformat.equalsIgnoreCase( "UNIX" ) ) { nl = "\n"; } } return nl;... |
@Test public void testClone() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); Node stepnode = getTestNode(); DatabaseMeta dbMeta = mock( DatabaseMeta.class ); IMetaStore metaStore = mock( IMetaStore.class ); xmlOutputMeta.loadXML( stepnode, Collections.singletonList( dbMeta ), metaStore ); XMLOutp... | public Object clone() { XMLOutputMeta retval = (XMLOutputMeta) super.clone(); int nrfields = outputFields.length; retval.allocate( nrfields ); for ( int i = 0; i < nrfields; i++ ) { retval.outputFields[i] = (XMLField) outputFields[i].clone(); } return retval; } | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public Object clone() { XMLOutputMeta retval = (XMLOutputMeta) super.clone(); int nrfields = outputFields.length; retval.allocate( nrfields ); for ( int i = 0; i < nrfields; i++ ) { retval.outputFields[i] = (XMLField) outputFields[i].clone(); } return re... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public Object clone() { XMLOutputMeta retval = (XMLOutputMeta) super.clone(); int nrfields = outputFields.length; retval.allocate( nrfields ); for ( int i = 0; i < nrfields; i++ ) { retval.outputFields[i] = (XMLField) outputFields[i].clone(); } return re... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public Object clone() { XMLOutputMeta retval = (XMLOutputMeta) super.clone(); int nrfields = outputFields.length; retval.allocate( nrfields ); for ( int i = 0; i < nrfields; i++ ) { retval.outputFields[i] = (XMLField) outputFields[i].clone(); } return re... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public Object clone() { XMLOutputMeta retval = (XMLOutputMeta) super.clone(); int nrfields = outputFields.length; retval.allocate( nrfields ); for ( int i = 0; i < nrfields; i++ ) { retval.outputFields[i] = (XMLField) outputFields[i].clone(); } return re... |
@Test public void testSetDefault() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); xmlOutputMeta.setDefault(); assertEquals( "file", xmlOutputMeta.getFileName() ); assertEquals( "xml", xmlOutputMeta.getExtension() ); assertFalse( xmlOutputMeta.isStepNrInFilename() ); assertFalse( xmlOutputMeta.isD... | public void setDefault() { fileName = "file"; extension = "xml"; stepNrInFilename = false; doNotOpenNewFileInit = false; dateInFilename = false; timeInFilename = false; addToResultFilenames = false; zipped = false; splitEvery = 0; encoding = Const.XML_ENCODING; nameSpace = ""; date_time_format = null; SpecifyFormat = f... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void setDefault() { fileName = "file"; extension = "xml"; stepNrInFilename = false; doNotOpenNewFileInit = false; dateInFilename = false; timeInFilename = false; addToResultFilenames = false; zipped = false; splitEvery = 0; encoding = Const.XML_EN... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void setDefault() { fileName = "file"; extension = "xml"; stepNrInFilename = false; doNotOpenNewFileInit = false; dateInFilename = false; timeInFilename = false; addToResultFilenames = false; zipped = false; splitEvery = 0; encoding = Const.XML_EN... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void setDefault() { fileName = "file"; extension = "xml"; stepNrInFilename = false; doNotOpenNewFileInit = false; dateInFilename = false; timeInFilename = false; addToResultFilenames = false; zipped = false; splitEvery = 0; encoding = Const.XML_EN... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void setDefault() { fileName = "file"; extension = "xml"; stepNrInFilename = false; doNotOpenNewFileInit = false; dateInFilename = false; timeInFilename = false; addToResultFilenames = false; zipped = false; splitEvery = 0; encoding = Const.XML_EN... |
@Test public void testGetFiles() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); xmlOutputMeta.setDefault(); xmlOutputMeta.setStepNrInFilename( true ); xmlOutputMeta.setSplitEvery( 100 ); xmlOutputMeta.setSpecifyFormat( true ); xmlOutputMeta.setDateTimeFormat( "99" ); String[] files = xmlOutputMet... | public String[] getFiles( VariableSpace space ) { int copies = 1; int splits = 1; if ( stepNrInFilename ) { copies = 3; } if ( splitEvery != 0 ) { splits = 3; } int nr = copies * splits; if ( nr > 1 ) { nr++; } String[] retval = new String[nr]; int i = 0; for ( int copy = 0; copy < copies; copy++ ) { for ( int split = ... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String[] getFiles( VariableSpace space ) { int copies = 1; int splits = 1; if ( stepNrInFilename ) { copies = 3; } if ( splitEvery != 0 ) { splits = 3; } int nr = copies * splits; if ( nr > 1 ) { nr++; } String[] retval = new String[nr]; int i = 0... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String[] getFiles( VariableSpace space ) { int copies = 1; int splits = 1; if ( stepNrInFilename ) { copies = 3; } if ( splitEvery != 0 ) { splits = 3; } int nr = copies * splits; if ( nr > 1 ) { nr++; } String[] retval = new String[nr]; int i = 0... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String[] getFiles( VariableSpace space ) { int copies = 1; int splits = 1; if ( stepNrInFilename ) { copies = 3; } if ( splitEvery != 0 ) { splits = 3; } int nr = copies * splits; if ( nr > 1 ) { nr++; } String[] retval = new String[nr]; int i = 0... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String[] getFiles( VariableSpace space ) { int copies = 1; int splits = 1; if ( stepNrInFilename ) { copies = 3; } if ( splitEvery != 0 ) { splits = 3; } int nr = copies * splits; if ( nr > 1 ) { nr++; } String[] retval = new String[nr]; int i = 0... |
@Test public void testGetFields() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); xmlOutputMeta.setDefault(); XMLField xmlField = new XMLField(); xmlField.setFieldName( "aField" ); xmlField.setLength( 10 ); xmlField.setPrecision( 3 ); xmlOutputMeta.setOutputFields( new XMLField[] { xmlField } ); R... | public void getFields( RowMetaInterface row, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) { for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i]; ValueMetaInterface v = row.searchValueMeta( field.getFieldName() ... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void getFields( RowMetaInterface row, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) { for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i];... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void getFields( RowMetaInterface row, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) { for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i];... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void getFields( RowMetaInterface row, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) { for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i];... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void getFields( RowMetaInterface row, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) { for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i];... |
@Test public void testLoadXmlException() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); DatabaseMeta dbMeta = mock( DatabaseMeta.class ); IMetaStore metaStore = mock( IMetaStore.class ); Node stepNode = mock( Node.class ); when( stepNode.getChildNodes() ).thenThrow( new RuntimeException( "some wo... | public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } } | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } XMLOutputMeta(); } | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } XMLOutputMeta(); boolean isDateInFilename(); void setDateInFilename( boolean dateInFilename ); String getExtensio... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void loadXML( Node stepnode, List<DatabaseMeta> databases, IMetaStore metaStore ) throws KettleXMLException { readData( stepnode ); } XMLOutputMeta(); boolean isDateInFilename(); void setDateInFilename( boolean dateInFilename ); String getExtensio... |
@Test public void testInsertTransformationPartitionSchema() throws KettleException { ArgumentCaptor<String> argumentTableName = ArgumentCaptor.forClass( String.class ); ArgumentCaptor<RowMetaAndData> argumentTableData = ArgumentCaptor.forClass( RowMetaAndData.class ); doNothing().when( repo.connectionDelegate ).insertT... | public synchronized ObjectId insertTransformationPartitionSchema( ObjectId id_transformation, ObjectId id_partition_schema ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationPartitionSchemaID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( new ValueMetaInteger( KettleDataba... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationPartitionSchema( ObjectId id_transformation, ObjectId id_partition_schema ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationPartitionSchemaID(); RowMetaAndData table = new RowM... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationPartitionSchema( ObjectId id_transformation, ObjectId id_partition_schema ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationPartitionSchemaID(); RowMetaAndData table = new RowM... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationPartitionSchema( ObjectId id_transformation, ObjectId id_partition_schema ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationPartitionSchemaID(); RowMetaAndData table = new RowM... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationPartitionSchema( ObjectId id_transformation, ObjectId id_partition_schema ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationPartitionSchemaID(); RowMetaAndData table = new RowM... |
@Test public void testReadRepException() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); Repository rep = mock( Repository.class ); IMetaStore metastore = mock( IMetaStore.class ); DatabaseMeta dbMeta = mock( DatabaseMeta.class ); ObjectId oid = new StringObjectId( "oid" ); when( rep.getStepAttrib... | public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "name_space" ); mainElement = rep.getStepAttributeString( id_step, "xm... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "nam... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "nam... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "nam... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException { try { encoding = rep.getStepAttributeString( id_step, "encoding" ); nameSpace = rep.getStepAttributeString( id_step, "nam... |
@Test public void testGetRequiredFields() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); xmlOutputMeta.setDefault(); XMLField xmlField = new XMLField(); xmlField.setFieldName( "aField" ); xmlField.setType( 1 ); xmlField.setLength( 10 ); xmlField.setPrecision( 3 ); XMLField xmlField2 = new XMLFiel... | public RowMetaInterface getRequiredFields( VariableSpace space ) throws KettleException { RowMeta row = new RowMeta(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i]; row.addValueMeta( new ValueMeta( field.getFieldName(), field.getType(), field.getLength(), field.getPrecision() ) ); ... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public RowMetaInterface getRequiredFields( VariableSpace space ) throws KettleException { RowMeta row = new RowMeta(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i]; row.addValueMeta( new ValueMeta( field.getFieldName... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public RowMetaInterface getRequiredFields( VariableSpace space ) throws KettleException { RowMeta row = new RowMeta(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i]; row.addValueMeta( new ValueMeta( field.getFieldName... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public RowMetaInterface getRequiredFields( VariableSpace space ) throws KettleException { RowMeta row = new RowMeta(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i]; row.addValueMeta( new ValueMeta( field.getFieldName... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public RowMetaInterface getRequiredFields( VariableSpace space ) throws KettleException { RowMeta row = new RowMeta(); for ( int i = 0; i < outputFields.length; i++ ) { XMLField field = outputFields[i]; row.addValueMeta( new ValueMeta( field.getFieldName... |
@Test public void testExportResources() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); xmlOutputMeta.setDefault(); ResourceNamingInterface resourceNamingInterface = mock( ResourceNamingInterface.class ); Variables space = new Variables(); when( resourceNamingInterface.nameResource( any( FileObjec... | public String exportResources( VariableSpace space, Map<String, ResourceDefinition> definitions, ResourceNamingInterface resourceNamingInterface, Repository repository, IMetaStore metaStore ) throws KettleException { try { if ( !Utils.isEmpty( fileName ) ) { FileObject fileObject = KettleVFS.getFileObject( space.enviro... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String exportResources( VariableSpace space, Map<String, ResourceDefinition> definitions, ResourceNamingInterface resourceNamingInterface, Repository repository, IMetaStore metaStore ) throws KettleException { try { if ( !Utils.isEmpty( fileName )... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String exportResources( VariableSpace space, Map<String, ResourceDefinition> definitions, ResourceNamingInterface resourceNamingInterface, Repository repository, IMetaStore metaStore ) throws KettleException { try { if ( !Utils.isEmpty( fileName )... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String exportResources( VariableSpace space, Map<String, ResourceDefinition> definitions, ResourceNamingInterface resourceNamingInterface, Repository repository, IMetaStore metaStore ) throws KettleException { try { if ( !Utils.isEmpty( fileName )... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public String exportResources( VariableSpace space, Map<String, ResourceDefinition> definitions, ResourceNamingInterface resourceNamingInterface, Repository repository, IMetaStore metaStore ) throws KettleException { try { if ( !Utils.isEmpty( fileName )... |
@Test public void testCheck() throws Exception { XMLOutputMeta xmlOutputMeta = new XMLOutputMeta(); xmlOutputMeta.setDefault(); TransMeta transMeta = mock( TransMeta.class ); StepMeta stepInfo = mock( StepMeta.class ); RowMetaInterface prev = mock( RowMetaInterface.class ); Repository repos = mock( Repository.class ); ... | public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepinfo, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { CheckResult cr; if ( prev != null && prev.size() > 0 ) { cr = new CheckResult... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepinfo, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { CheckResult... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepinfo, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { CheckResult... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepinfo, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { CheckResult... | XMLOutputMeta extends BaseStepMeta implements StepMetaInterface { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepinfo, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { CheckResult... |
@Test public void exceptionIsThrowsForNonExistingFiles() throws Exception { GoogleAnalyticsApiFacade.createFor( "application-name", "account", path ); } | public static GoogleAnalyticsApiFacade createFor( String application, String oauthServiceAccount, String oauthKeyFile ) throws GeneralSecurityException, IOException, KettleFileException { return new GoogleAnalyticsApiFacade( GoogleNetHttpTransport.newTrustedTransport(), JacksonFactory.getDefaultInstance(), application,... | GoogleAnalyticsApiFacade { public static GoogleAnalyticsApiFacade createFor( String application, String oauthServiceAccount, String oauthKeyFile ) throws GeneralSecurityException, IOException, KettleFileException { return new GoogleAnalyticsApiFacade( GoogleNetHttpTransport.newTrustedTransport(), JacksonFactory.getDefa... | GoogleAnalyticsApiFacade { public static GoogleAnalyticsApiFacade createFor( String application, String oauthServiceAccount, String oauthKeyFile ) throws GeneralSecurityException, IOException, KettleFileException { return new GoogleAnalyticsApiFacade( GoogleNetHttpTransport.newTrustedTransport(), JacksonFactory.getDefa... | GoogleAnalyticsApiFacade { public static GoogleAnalyticsApiFacade createFor( String application, String oauthServiceAccount, String oauthKeyFile ) throws GeneralSecurityException, IOException, KettleFileException { return new GoogleAnalyticsApiFacade( GoogleNetHttpTransport.newTrustedTransport(), JacksonFactory.getDefa... | GoogleAnalyticsApiFacade { public static GoogleAnalyticsApiFacade createFor( String application, String oauthServiceAccount, String oauthKeyFile ) throws GeneralSecurityException, IOException, KettleFileException { return new GoogleAnalyticsApiFacade( GoogleNetHttpTransport.newTrustedTransport(), JacksonFactory.getDefa... |
@Test public void testGetFields() throws Exception { dialog.getFields(); verify( query ).setMaxResults( 1 ); verify( table, times( 19 ) ).getItem( anyInt() ); verify( tableItem, times( 7 ) ).setText( 1, GaInputStepMeta.FIELD_TYPE_DIMENSION ); verify( tableItem, times( 7 ) ).setText( 1, GaInputStepMeta.FIELD_TYPE_METRIC... | void getFields() { Analytics.Data.Ga.Get query = getPreviewQuery(); if ( query == null ) { return; } query.setMaxResults( 1 ); try { GaData dataFeed = query.execute(); if ( dataFeed == null || dataFeed.getRows() == null || dataFeed.getRows().size() < 1 ) { MessageBox mb = new MessageBox( shell, SWT.OK | SWT.ICON_ERROR ... | GaInputStepDialog extends BaseStepDialog implements StepDialogInterface { void getFields() { Analytics.Data.Ga.Get query = getPreviewQuery(); if ( query == null ) { return; } query.setMaxResults( 1 ); try { GaData dataFeed = query.execute(); if ( dataFeed == null || dataFeed.getRows() == null || dataFeed.getRows().size... | GaInputStepDialog extends BaseStepDialog implements StepDialogInterface { void getFields() { Analytics.Data.Ga.Get query = getPreviewQuery(); if ( query == null ) { return; } query.setMaxResults( 1 ); try { GaData dataFeed = query.execute(); if ( dataFeed == null || dataFeed.getRows() == null || dataFeed.getRows().size... | GaInputStepDialog extends BaseStepDialog implements StepDialogInterface { void getFields() { Analytics.Data.Ga.Get query = getPreviewQuery(); if ( query == null ) { return; } query.setMaxResults( 1 ); try { GaData dataFeed = query.execute(); if ( dataFeed == null || dataFeed.getRows() == null || dataFeed.getRows().size... | GaInputStepDialog extends BaseStepDialog implements StepDialogInterface { void getFields() { Analytics.Data.Ga.Get query = getPreviewQuery(); if ( query == null ) { return; } query.setMaxResults( 1 ); try { GaData dataFeed = query.execute(); if ( dataFeed == null || dataFeed.getRows() == null || dataFeed.getRows().size... |
@Test public void testSetCalendarStartNull() throws KettleException { SalesforceConnection connection = new SalesforceConnection( logInterface, url, username, password ); GregorianCalendar endDate = new GregorianCalendar( 2000, 2, 10 ); try { connection.setCalendar( recordsFilter, null, endDate ); fail(); } catch ( Ket... | public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( BaseMessages.getString(... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... |
@Test public void testSetCalendarEndNull() throws KettleException { SalesforceConnection connection = new SalesforceConnection( logInterface, url, username, password ); GregorianCalendar startDate = new GregorianCalendar( 2000, 2, 10 ); try { connection.setCalendar( recordsFilter, startDate, null ); fail(); } catch ( K... | public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( BaseMessages.getString(... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... |
@Test public void testSetCalendarStartDateTooOlder() throws KettleException { SalesforceConnection connection = new SalesforceConnection( logInterface, url, username, password ); GregorianCalendar startDate = new GregorianCalendar( 2000, 3, 20 ); GregorianCalendar endDate = new GregorianCalendar( 2000, 2, 10 ); try { c... | public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( BaseMessages.getString(... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... |
@Test public void testSetCalendarDatesTooFarApart() throws KettleException { SalesforceConnection connection = new SalesforceConnection( logInterface, url, username, password ); GregorianCalendar startDate = new GregorianCalendar( 2000, 1, 1 ); GregorianCalendar endDate = new GregorianCalendar( 2000, 2, 11 ); try { con... | public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( BaseMessages.getString(... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... |
@Test public void testInsertClusterSlave() throws KettleException { ArgumentCaptor<String> argumentTableName = ArgumentCaptor.forClass( String.class ); ArgumentCaptor<RowMetaAndData> argumentTableData = ArgumentCaptor.forClass( RowMetaAndData.class ); doNothing().when( repo.connectionDelegate ).insertTableRow( argument... | public synchronized ObjectId insertClusterSlave( ClusterSchema clusterSchema, SlaveServer slaveServer ) throws KettleException { ObjectId id = connectionDelegate.getNextClusterSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( new ValueMetaInteger( KettleDatabaseRepository.FIELD_CLUSTER_SLAVE_ID_CL... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertClusterSlave( ClusterSchema clusterSchema, SlaveServer slaveServer ) throws KettleException { ObjectId id = connectionDelegate.getNextClusterSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( new Valu... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertClusterSlave( ClusterSchema clusterSchema, SlaveServer slaveServer ) throws KettleException { ObjectId id = connectionDelegate.getNextClusterSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( new Valu... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertClusterSlave( ClusterSchema clusterSchema, SlaveServer slaveServer ) throws KettleException { ObjectId id = connectionDelegate.getNextClusterSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( new Valu... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertClusterSlave( ClusterSchema clusterSchema, SlaveServer slaveServer ) throws KettleException { ObjectId id = connectionDelegate.getNextClusterSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( new Valu... |
@Test public void testSetCalendar() { SalesforceConnection conn = mock( SalesforceConnection.class, Mockito.CALLS_REAL_METHODS ); try { conn.setCalendar( new Random().nextInt( SalesforceConnectionUtils.recordsFilterDesc.length ), new GregorianCalendar( 2016, Calendar.JANUARY, 1 ), new GregorianCalendar( 2016, Calendar.... | public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( BaseMessages.getString(... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... | SalesforceConnection { public void setCalendar( int recordsFilter, GregorianCalendar startDate, GregorianCalendar endDate ) throws KettleException { this.startDate = startDate; this.endDate = endDate; this.recordsFilter = recordsFilter; if ( this.startDate == null || this.endDate == null ) { throw new KettleException( ... |
@Test public void testCreateBinding() throws KettleException, ConnectionException { SalesforceConnection conn = new SalesforceConnection( null, "http: ConnectorConfig config = new ConnectorConfig(); config.setAuthEndpoint( Connector.END_POINT ); config.setManualLogin( true ); assertNull( conn.getBinding() ); conn.creat... | public PartnerConnection createBinding( ConnectorConfig config ) throws ConnectionException { if ( this.binding == null ) { this.binding = new PartnerConnection( config ); } return this.binding; } | SalesforceConnection { public PartnerConnection createBinding( ConnectorConfig config ) throws ConnectionException { if ( this.binding == null ) { this.binding = new PartnerConnection( config ); } return this.binding; } } | SalesforceConnection { public PartnerConnection createBinding( ConnectorConfig config ) throws ConnectionException { if ( this.binding == null ) { this.binding = new PartnerConnection( config ); } return this.binding; } SalesforceConnection( LogChannelInterface logInterface, String url, String username, String password... | SalesforceConnection { public PartnerConnection createBinding( ConnectorConfig config ) throws ConnectionException { if ( this.binding == null ) { this.binding = new PartnerConnection( config ); } return this.binding; } SalesforceConnection( LogChannelInterface logInterface, String url, String username, String password... | SalesforceConnection { public PartnerConnection createBinding( ConnectorConfig config ) throws ConnectionException { if ( this.binding == null ) { this.binding = new PartnerConnection( config ); } return this.binding; } SalesforceConnection( LogChannelInterface logInterface, String url, String username, String password... |
@Test public void testGetRecordValue() throws Exception { SalesforceConnection conn = mock( SalesforceConnection.class, Mockito.CALLS_REAL_METHODS ); SObject sObject = new SObject(); sObject.setName( new QName( Constants.PARTNER_SOBJECT_NS, "sObject" ) ); SObject testObject = createObject( "field", "value" ); sObject.a... | public String getRecordValue( SObject con, String fieldname ) throws KettleException { String[] fieldHierarchy = fieldname.split( "\\." ); if ( con == null ) { return null; } else { XmlObject element = getMessageElementForHierarchy( con, fieldHierarchy ); if ( element != null ) { Object object = element.getValue(); if ... | SalesforceConnection { public String getRecordValue( SObject con, String fieldname ) throws KettleException { String[] fieldHierarchy = fieldname.split( "\\." ); if ( con == null ) { return null; } else { XmlObject element = getMessageElementForHierarchy( con, fieldHierarchy ); if ( element != null ) { Object object = ... | SalesforceConnection { public String getRecordValue( SObject con, String fieldname ) throws KettleException { String[] fieldHierarchy = fieldname.split( "\\." ); if ( con == null ) { return null; } else { XmlObject element = getMessageElementForHierarchy( con, fieldHierarchy ); if ( element != null ) { Object object = ... | SalesforceConnection { public String getRecordValue( SObject con, String fieldname ) throws KettleException { String[] fieldHierarchy = fieldname.split( "\\." ); if ( con == null ) { return null; } else { XmlObject element = getMessageElementForHierarchy( con, fieldHierarchy ); if ( element != null ) { Object object = ... | SalesforceConnection { public String getRecordValue( SObject con, String fieldname ) throws KettleException { String[] fieldHierarchy = fieldname.split( "\\." ); if ( con == null ) { return null; } else { XmlObject element = getMessageElementForHierarchy( con, fieldHierarchy ); if ( element != null ) { Object object = ... |
@Test public void testErrorHandling() { SalesforceStepMeta meta = new SalesforceUpdateMeta(); assertTrue( meta.supportsErrorHandling() ); } | public boolean supportsErrorHandling() { return true; } | SalesforceUpdateMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } } | SalesforceUpdateMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceUpdateMeta(); } | SalesforceUpdateMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceUpdateMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); Bool... | SalesforceUpdateMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceUpdateMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); Bool... |
@Test public void testGetFields() throws KettleStepException { SalesforceUpdateMeta meta = new SalesforceUpdateMeta(); meta.setDefault(); RowMetaInterface r = new RowMeta(); meta.getFields( r, "thisStep", null, null, new Variables(), null, null ); assertEquals( 0, r.size() ); r.clear(); r.addValueMeta( new ValueMetaStr... | public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } | SalesforceUpdateMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } } | SalesforceUpdateMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } SalesforceUpdateMeta(); } | SalesforceUpdateMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } SalesforceUpdateMeta(); boolean isRollbackAllChangesOnError(); void setR... | SalesforceUpdateMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } SalesforceUpdateMeta(); boolean isRollbackAllChangesOnError(); void setR... |
@Test public void testCheck() { SalesforceUpdateMeta meta = new SalesforceUpdateMeta(); meta.setDefault(); List<CheckResultInterface> remarks = new ArrayList<CheckResultInterface>(); meta.check( remarks, null, null, null, null, null, null, null, null, null ); boolean hasError = false; for ( CheckResultInterface cr : re... | public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, transMeta, stepMeta, prev, input, output, info, space, ... | SalesforceUpdateMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceUpdateMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceUpdateMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceUpdateMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... |
@Test public void testSalesforceUpdateMeta() throws KettleException { List<String> attributes = new ArrayList<String>(); attributes.addAll( SalesforceMetaTest.getDefaultAttributes() ); attributes.addAll( Arrays.asList( "batchSize", "updateLookup", "updateStream", "useExternalId", "rollbackAllChangesOnError" ) ); Map<St... | public SalesforceUpdateMeta() { super(); } | SalesforceUpdateMeta extends SalesforceStepMeta { public SalesforceUpdateMeta() { super(); } } | SalesforceUpdateMeta extends SalesforceStepMeta { public SalesforceUpdateMeta() { super(); } SalesforceUpdateMeta(); } | SalesforceUpdateMeta extends SalesforceStepMeta { public SalesforceUpdateMeta() { super(); } SalesforceUpdateMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); Boolean[] getUseE... | SalesforceUpdateMeta extends SalesforceStepMeta { public SalesforceUpdateMeta() { super(); } SalesforceUpdateMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); Boolean[] getUseE... |
@Test public void testErrorHandling() { SalesforceStepMeta meta = new SalesforceUpsertMeta(); assertTrue( meta.supportsErrorHandling() ); } | public boolean supportsErrorHandling() { return true; } | SalesforceUpsertMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } } | SalesforceUpsertMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceUpsertMeta(); } | SalesforceUpsertMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceUpsertMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); Stri... | SalesforceUpsertMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceUpsertMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); Stri... |
@Test public void testGetFields() throws KettleStepException { SalesforceUpsertMeta meta = new SalesforceUpsertMeta(); meta.setDefault(); RowMetaInterface r = new RowMeta(); meta.getFields( r, "thisStep", null, null, new Variables(), null, null ); assertEquals( 1, r.size() ); assertEquals( "Id", r.getFieldNames()[0] );... | public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldName() ); if ( !Utils.isEmpty( realfieldname ) ) { V... | SalesforceUpsertMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldNa... | SalesforceUpsertMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldNa... | SalesforceUpsertMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldNa... | SalesforceUpsertMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldNa... |
@Test public void testCheck() { SalesforceUpsertMeta meta = new SalesforceUpsertMeta(); meta.setDefault(); List<CheckResultInterface> remarks = new ArrayList<CheckResultInterface>(); meta.check( remarks, null, null, null, null, null, null, null, null, null ); boolean hasError = false; for ( CheckResultInterface cr : re... | public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, transMeta, stepMeta, prev, input, output, info, space, ... | SalesforceUpsertMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceUpsertMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceUpsertMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceUpsertMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... |
@Test public void testInsertTransformationCluster() throws KettleException { ArgumentCaptor<String> argumentTableName = ArgumentCaptor.forClass( String.class ); ArgumentCaptor<RowMetaAndData> argumentTableData = ArgumentCaptor.forClass( RowMetaAndData.class ); doNothing().when( repo.connectionDelegate ).insertTableRow(... | public synchronized ObjectId insertTransformationCluster( ObjectId id_transformation, ObjectId id_cluster ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationClusterID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( new ValueMetaInteger( KettleDatabaseRepository.FIELD_TRANS_... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationCluster( ObjectId id_transformation, ObjectId id_cluster ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationClusterID(); RowMetaAndData table = new RowMetaAndData(); table.addVa... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationCluster( ObjectId id_transformation, ObjectId id_cluster ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationClusterID(); RowMetaAndData table = new RowMetaAndData(); table.addVa... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationCluster( ObjectId id_transformation, ObjectId id_cluster ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationClusterID(); RowMetaAndData table = new RowMetaAndData(); table.addVa... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationCluster( ObjectId id_transformation, ObjectId id_cluster ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationClusterID(); RowMetaAndData table = new RowMetaAndData(); table.addVa... |
@Test public void testSalesforceUpsertMeta() throws KettleException { List<String> attributes = new ArrayList<String>(); attributes.addAll( SalesforceMetaTest.getDefaultAttributes() ); attributes.addAll( Arrays.asList( "upsertField", "batchSize", "salesforceIDFieldName", "updateLookup", "updateStream", "useExternalId",... | public SalesforceUpsertMeta() { super(); } | SalesforceUpsertMeta extends SalesforceStepMeta { public SalesforceUpsertMeta() { super(); } } | SalesforceUpsertMeta extends SalesforceStepMeta { public SalesforceUpsertMeta() { super(); } SalesforceUpsertMeta(); } | SalesforceUpsertMeta extends SalesforceStepMeta { public SalesforceUpsertMeta() { super(); } SalesforceUpsertMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); String[] getUpdat... | SalesforceUpsertMeta extends SalesforceStepMeta { public SalesforceUpsertMeta() { super(); } SalesforceUpsertMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); String[] getUpdat... |
@Test public void testFieldWithExtIdYes_StandartObject() { inputFieldName = "Account:ExtID_AccountId__c/Account"; expectedFieldName = "AccountId"; String fieldToNullName = SalesforceUtils.getFieldToNullName( logMock, inputFieldName, true ); assertEquals( expectedFieldName, fieldToNullName ); } | public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUtils.Warn.IncorrectE... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... |
@Test public void testFieldWithExtIdNo_StandartObject() { inputFieldName = "AccountId"; expectedFieldName = "AccountId"; String fieldToNullName = SalesforceUtils.getFieldToNullName( logMock, inputFieldName, false ); assertEquals( expectedFieldName, fieldToNullName ); } | public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUtils.Warn.IncorrectE... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... |
@Test public void testFieldWithExtIdYes_CustomObject() { inputFieldName = "ParentObject__c:Name/ParentObjectId__r"; expectedFieldName = "ParentObjectId__c"; String fieldToNullName = SalesforceUtils.getFieldToNullName( logMock, inputFieldName, true ); assertEquals( expectedFieldName, fieldToNullName ); } | public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUtils.Warn.IncorrectE... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... |
@Test public void testFieldWithExtIdNo_CustomObject() { inputFieldName = "ParentObjectId__c"; expectedFieldName = "ParentObjectId__c"; String fieldToNullName = SalesforceUtils.getFieldToNullName( logMock, inputFieldName, false ); assertEquals( expectedFieldName, fieldToNullName ); } | public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUtils.Warn.IncorrectE... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... |
@Test public void testFieldWithExtIdYesButNameInIncorrectSyntax_StandartObject() { when( logMock.isDebug() ).thenReturn( true ); inputFieldName = "Account"; expectedFieldName = inputFieldName; String fieldToNullName = SalesforceUtils.getFieldToNullName( logMock, inputFieldName, true ); assertEquals( expectedFieldName, ... | public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUtils.Warn.IncorrectE... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... |
@Test public void testIncorrectExternalKeySyntaxWarnIsLoggedInDebugMode() { when( logMock.isDebug() ).thenReturn( true ); inputFieldName = "AccountId"; verify( logMock, never() ).logDebug( anyString() ); SalesforceUtils.getFieldToNullName( logMock, inputFieldName, true ); verify( logMock ).logDebug( "The field has inco... | public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUtils.Warn.IncorrectE... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... |
@Test public void testIncorrectExternalKeySyntaxWarnIsNotLoggedInNotDebugMode() { when( logMock.isDebug() ).thenReturn( false ); inputFieldName = "AccountId"; verify( logMock, never() ).logDebug( anyString() ); SalesforceUtils.getFieldToNullName( logMock, inputFieldName, true ); verify( logMock, never() ).logDebug( "Th... | public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUtils.Warn.IncorrectE... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... |
@Test public void testFinalNullFieldNameIsLoggedInDebugMode_StandartObject() { when( logMock.isDebug() ).thenReturn( true ); inputFieldName = "Account:ExtID_AccountId__c/Account"; verify( logMock, never() ).logDebug( anyString() ); SalesforceUtils.getFieldToNullName( logMock, inputFieldName, true ); verify( logMock ).l... | public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUtils.Warn.IncorrectE... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... |
@Test public void testFinalNullFieldNameIsLoggedInDebugMode_CustomObject() { when( logMock.isDebug() ).thenReturn( true ); inputFieldName = "ParentObject__c:Name/ParentObjectId__r"; verify( logMock, never() ).logDebug( anyString() ); SalesforceUtils.getFieldToNullName( logMock, inputFieldName, true ); verify( logMock )... | public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUtils.Warn.IncorrectE... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... | SalesforceUtils { public static String getFieldToNullName( LogChannelInterface log, String field, boolean isUseExtId ) { String fieldToNullName = field; if ( isUseExtId ) { if ( !FIELD_NAME_WITH_EXTID_PATTERN.matcher( field ).matches() ) { if ( log.isDebug() ) { log.logDebug( BaseMessages.getString( PKG, "SalesforceUti... |
@Test public void testInsertTransformationSlave() throws KettleException { ArgumentCaptor<String> argumentTableName = ArgumentCaptor.forClass( String.class ); ArgumentCaptor<RowMetaAndData> argumentTableData = ArgumentCaptor.forClass( RowMetaAndData.class ); doNothing().when( repo.connectionDelegate ).insertTableRow( a... | public synchronized ObjectId insertTransformationSlave( ObjectId id_transformation, ObjectId id_slave ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( new ValueMetaInteger( KettleDatabaseRepository.FIELD_TRANS_SLAVE_... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationSlave( ObjectId id_transformation, ObjectId id_slave ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( n... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationSlave( ObjectId id_transformation, ObjectId id_slave ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( n... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationSlave( ObjectId id_transformation, ObjectId id_slave ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( n... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized ObjectId insertTransformationSlave( ObjectId id_transformation, ObjectId id_slave ) throws KettleException { ObjectId id = connectionDelegate.getNextTransformationSlaveID(); RowMetaAndData table = new RowMetaAndData(); table.addValue( n... |
@Test public void testErrorHandling() { SalesforceStepMeta meta = new SalesforceDeleteMeta(); assertTrue( meta.supportsErrorHandling() ); } | public boolean supportsErrorHandling() { return true; } | SalesforceDeleteMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } } | SalesforceDeleteMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceDeleteMeta(); } | SalesforceDeleteMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceDeleteMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); void setDeleteField( String DeleteField ); String getDeleteField(); void setBat... | SalesforceDeleteMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceDeleteMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); void setDeleteField( String DeleteField ); String getDeleteField(); void setBat... |
@Test public void testGetFields() throws KettleStepException { SalesforceDeleteMeta meta = new SalesforceDeleteMeta(); meta.setDefault(); RowMetaInterface r = new RowMeta(); meta.getFields( r, "thisStep", null, null, new Variables(), null, null ); assertEquals( 0, r.size() ); r.clear(); r.addValueMeta( new ValueMetaStr... | public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } | SalesforceDeleteMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } } | SalesforceDeleteMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } SalesforceDeleteMeta(); } | SalesforceDeleteMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } SalesforceDeleteMeta(); boolean isRollbackAllChangesOnError(); void setR... | SalesforceDeleteMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { } SalesforceDeleteMeta(); boolean isRollbackAllChangesOnError(); void setR... |
@Test public void testCheck() { SalesforceDeleteMeta meta = new SalesforceDeleteMeta(); meta.setDefault(); List<CheckResultInterface> remarks = new ArrayList<CheckResultInterface>(); meta.check( remarks, null, null, null, null, null, null, null, null, null ); boolean hasError = false; for ( CheckResultInterface cr : re... | public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, transMeta, stepMeta, prev, input, output, info, space, ... | SalesforceDeleteMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceDeleteMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceDeleteMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceDeleteMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... |
@Test public void testSalesforceInputMeta() throws KettleException { List<String> attributes = new ArrayList<String>(); attributes.addAll( SalesforceMetaTest.getDefaultAttributes() ); attributes.addAll( Arrays.asList( "inputFields", "condition", "query", "specifyQuery", "includeTargetURL", "targetURLField", "includeMod... | public SalesforceInputMeta() { super(); } | SalesforceInputMeta extends SalesforceStepMeta { public SalesforceInputMeta() { super(); } } | SalesforceInputMeta extends SalesforceStepMeta { public SalesforceInputMeta() { super(); } SalesforceInputMeta(); } | SalesforceInputMeta extends SalesforceStepMeta { public SalesforceInputMeta() { super(); } SalesforceInputMeta(); SalesforceInputField[] getInputFields(); void setInputFields( SalesforceInputField[] inputFields ); String getQuery(); void setQuery( String query ); boolean isSpecifyQuery(); void setSpecifyQuery( boolean ... | SalesforceInputMeta extends SalesforceStepMeta { public SalesforceInputMeta() { super(); } SalesforceInputMeta(); SalesforceInputField[] getInputFields(); void setInputFields( SalesforceInputField[] inputFields ); String getQuery(); void setQuery( String query ); boolean isSpecifyQuery(); void setSpecifyQuery( boolean ... |
@Test public void testGetFields() throws KettleStepException { SalesforceInputMeta meta = new SalesforceInputMeta(); meta.setDefault(); RowMetaInterface r = new RowMeta(); meta.getFields( r, "thisStep", null, null, new Variables(), null, null ); assertEquals( 0, r.size() ); meta.setInputFields( new SalesforceInputField... | public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { int i; for ( i = 0; i < inputFields.length; i++ ) { SalesforceInputField field = inputFields[i]; int type = field.getType();... | SalesforceInputMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { int i; for ( i = 0; i < inputFields.length; i++ ) { SalesforceInputField fi... | SalesforceInputMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { int i; for ( i = 0; i < inputFields.length; i++ ) { SalesforceInputField fi... | SalesforceInputMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { int i; for ( i = 0; i < inputFields.length; i++ ) { SalesforceInputField fi... | SalesforceInputMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { int i; for ( i = 0; i < inputFields.length; i++ ) { SalesforceInputField fi... |
@Test public void testCheck() { SalesforceInputMeta meta = new SalesforceInputMeta(); meta.setDefault(); List<CheckResultInterface> remarks = new ArrayList<CheckResultInterface>(); meta.check( remarks, null, null, null, null, null, null, null, null, null ); boolean hasError = false; for ( CheckResultInterface cr : rema... | public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, transMeta, stepMeta, prev, input, output, info, space, ... | SalesforceInputMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, transM... | SalesforceInputMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, transM... | SalesforceInputMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, transM... | SalesforceInputMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, transM... |
@Test public void testErrorHandling() { SalesforceStepMeta meta = new SalesforceInsertMeta(); assertTrue( meta.supportsErrorHandling() ); } | public boolean supportsErrorHandling() { return true; } | SalesforceInsertMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } } | SalesforceInsertMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceInsertMeta(); } | SalesforceInsertMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceInsertMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); Stri... | SalesforceInsertMeta extends SalesforceStepMeta { public boolean supportsErrorHandling() { return true; } SalesforceInsertMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); Stri... |
@Test public void testCheck() { SalesforceInsertMeta meta = new SalesforceInsertMeta(); meta.setDefault(); List<CheckResultInterface> remarks = new ArrayList<CheckResultInterface>(); meta.check( remarks, null, null, null, null, null, null, null, null, null ); boolean hasError = false; for ( CheckResultInterface cr : re... | public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, transMeta, stepMeta, prev, input, output, info, space, ... | SalesforceInsertMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceInsertMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceInsertMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... | SalesforceInsertMeta extends SalesforceStepMeta { public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta, RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space, Repository repository, IMetaStore metaStore ) { super.check( remarks, trans... |
@Test public void testGetFields() throws KettleStepException { SalesforceInsertMeta meta = new SalesforceInsertMeta(); meta.setDefault(); RowMetaInterface r = new RowMeta(); meta.getFields( r, "thisStep", null, null, new Variables(), null, null ); assertEquals( 1, r.size() ); assertEquals( "Id", r.getFieldNames()[0] );... | public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldName() ); if ( !Utils.isEmpty( realfieldname ) ) { V... | SalesforceInsertMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldNa... | SalesforceInsertMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldNa... | SalesforceInsertMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldNa... | SalesforceInsertMeta extends SalesforceStepMeta { public void getFields( RowMetaInterface r, String name, RowMetaInterface[] info, StepMeta nextStep, VariableSpace space, Repository repository, IMetaStore metaStore ) throws KettleStepException { String realfieldname = space.environmentSubstitute( getSalesforceIDFieldNa... |
@Test public void testSalesforceInsertMeta() throws KettleException { List<String> attributes = new ArrayList<String>(); attributes.addAll( SalesforceMetaTest.getDefaultAttributes() ); attributes.addAll( Arrays.asList( "batchSize", "salesforceIDFieldName", "updateLookup", "updateStream", "useExternalId", "rollbackAllCh... | public SalesforceInsertMeta() { super(); } | SalesforceInsertMeta extends SalesforceStepMeta { public SalesforceInsertMeta() { super(); } } | SalesforceInsertMeta extends SalesforceStepMeta { public SalesforceInsertMeta() { super(); } SalesforceInsertMeta(); } | SalesforceInsertMeta extends SalesforceStepMeta { public SalesforceInsertMeta() { super(); } SalesforceInsertMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); String[] getUpdat... | SalesforceInsertMeta extends SalesforceStepMeta { public SalesforceInsertMeta() { super(); } SalesforceInsertMeta(); boolean isRollbackAllChangesOnError(); void setRollbackAllChangesOnError( boolean rollbackAllChangesOnError ); String[] getUpdateLookup(); void setUpdateLookup( String[] updateLookup ); String[] getUpdat... |
@Test public void testInsertTransStepCondition() throws KettleException { ArgumentCaptor<String> argumentTableName = ArgumentCaptor.forClass( String.class ); ArgumentCaptor<RowMetaAndData> argumentTableData = ArgumentCaptor.forClass( RowMetaAndData.class ); doNothing().when( repo.connectionDelegate ).insertTableRow( ar... | public synchronized void insertTransStepCondition( ObjectId id_transformation, ObjectId id_step, ObjectId id_condition ) throws KettleException { String tablename = KettleDatabaseRepository.TABLE_R_TRANS_STEP_CONDITION; RowMetaAndData table = new RowMetaAndData(); table .addValue( new ValueMetaInteger( KettleDatabaseRe... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized void insertTransStepCondition( ObjectId id_transformation, ObjectId id_step, ObjectId id_condition ) throws KettleException { String tablename = KettleDatabaseRepository.TABLE_R_TRANS_STEP_CONDITION; RowMetaAndData table = new RowMetaAn... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized void insertTransStepCondition( ObjectId id_transformation, ObjectId id_step, ObjectId id_condition ) throws KettleException { String tablename = KettleDatabaseRepository.TABLE_R_TRANS_STEP_CONDITION; RowMetaAndData table = new RowMetaAn... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized void insertTransStepCondition( ObjectId id_transformation, ObjectId id_step, ObjectId id_condition ) throws KettleException { String tablename = KettleDatabaseRepository.TABLE_R_TRANS_STEP_CONDITION; RowMetaAndData table = new RowMetaAn... | KettleDatabaseRepository extends KettleDatabaseRepositoryBase { public synchronized void insertTransStepCondition( ObjectId id_transformation, ObjectId id_step, ObjectId id_condition ) throws KettleException { String tablename = KettleDatabaseRepository.TABLE_R_TRANS_STEP_CONDITION; RowMetaAndData table = new RowMetaAn... |
@Test public void testLoadAccessData() throws Exception { when( accessBox.getSelectedItem() ).thenReturn( "Native" ); DatabaseInterface dbInterface = mock( DatabaseInterface.class ); when( dbInterface.getDefaultDatabasePort() ).thenReturn( 5309 ); DataHandler.connectionMap.put( "myDb", dbInterface ); dataHandler.loadAc... | public void loadAccessData() { getControls(); pushCache(); Object key = connectionBox.getSelectedItem(); if ( key == null ) { key = connectionMap.firstKey(); connectionBox.setSelectedItem( key ); return; } DatabaseInterface database = connectionMap.get( key ); int[] acc = database.getAccessTypeList(); Object accessKey ... | DataHandler extends AbstractXulEventHandler { public void loadAccessData() { getControls(); pushCache(); Object key = connectionBox.getSelectedItem(); if ( key == null ) { key = connectionMap.firstKey(); connectionBox.setSelectedItem( key ); return; } DatabaseInterface database = connectionMap.get( key ); int[] acc = d... | DataHandler extends AbstractXulEventHandler { public void loadAccessData() { getControls(); pushCache(); Object key = connectionBox.getSelectedItem(); if ( key == null ) { key = connectionMap.firstKey(); connectionBox.setSelectedItem( key ); return; } DatabaseInterface database = connectionMap.get( key ); int[] acc = d... | DataHandler extends AbstractXulEventHandler { public void loadAccessData() { getControls(); pushCache(); Object key = connectionBox.getSelectedItem(); if ( key == null ) { key = connectionMap.firstKey(); connectionBox.setSelectedItem( key ); return; } DatabaseInterface database = connectionMap.get( key ); int[] acc = d... | DataHandler extends AbstractXulEventHandler { public void loadAccessData() { getControls(); pushCache(); Object key = connectionBox.getSelectedItem(); if ( key == null ) { key = connectionMap.firstKey(); connectionBox.setSelectedItem( key ); return; } DatabaseInterface database = connectionMap.get( key ); int[] acc = d... |
@Test public void testAddFieldsFromSOQLQuery() throws Exception { final Set<String> fields = new LinkedHashSet<>(); XmlObject testObject = createObject( "Field1", VALUE, ObjectType.XMLOBJECT ); dialog.addFields( "", fields, testObject ); dialog.addFields( "", fields, testObject ); assertArrayEquals( "No duplicates", ne... | void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject element : SalesforceConnection.getChildren( sobject ) ) { ... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... |
@Test public void testAddFields_nullIdNotAdded() throws Exception { final Set<String> fields = new LinkedHashSet<>(); XmlObject testObject = createObject( "Id", null, ObjectType.XMLOBJECT ); dialog.addFields( "", fields, testObject ); assertArrayEquals( "Null Id field not added", new String[]{}, fields.toArray() ); } | void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject element : SalesforceConnection.getChildren( sobject ) ) { ... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... |
@Test public void testAddFields_IdAdded() throws Exception { final Set<String> fields = new LinkedHashSet<>(); XmlObject testObject = createObject( "Id", VALUE, ObjectType.XMLOBJECT ); dialog.addFields( "", fields, testObject ); assertArrayEquals( "Id field added", new String[]{"Id"}, fields.toArray() ); } | void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject element : SalesforceConnection.getChildren( sobject ) ) { ... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... | SalesforceInputDialog extends SalesforceStepDialog { void addFields( String prefix, Set<String> fieldNames, XmlObject field ) { if ( isNullIdField( field ) ) { return; } String fieldname = prefix + field.getName().getLocalPart(); if ( field instanceof SObject ) { SObject sobject = (SObject) field; for ( XmlObject eleme... |
@Test public void testGetTypes() { String[] types = executionConfigurationManager.getTypes(); assertTrue( Arrays.asList( types ).contains( DefaultRunConfiguration.TYPE ) ); assertTrue( Arrays.asList( types ).contains( SparkRunConfiguration.TYPE ) ); } | public String[] getTypes() { List<String> types = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { types.add( runConfigurationProvider.getType() ); } return types.toArray( new String[ 0 ] ); } | RunConfigurationManager implements RunConfigurationService { public String[] getTypes() { List<String> types = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { types.add( runConfigurationProvider.getType() ); } return types.toArray( new String[ 0 ] ); } } | RunConfigurationManager implements RunConfigurationService { public String[] getTypes() { List<String> types = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { types.add( runConfigurationProvider.getType() ); } return types.toArray( new String[ 0 ] ); } Run... | RunConfigurationManager implements RunConfigurationService { public String[] getTypes() { List<String> types = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { types.add( runConfigurationProvider.getType() ); } return types.toArray( new String[ 0 ] ); } Run... | RunConfigurationManager implements RunConfigurationService { public String[] getTypes() { List<String> types = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { types.add( runConfigurationProvider.getType() ); } return types.toArray( new String[ 0 ] ); } Run... |
@Test public void testLoad() { List<RunConfiguration> runConfigurations = executionConfigurationManager.load(); assertEquals( runConfigurations.size(), 3 ); } | @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load() ); } Collections.sort( runConfigurations, ( o1, o2 ) -> { ... | RunConfigurationManager implements RunConfigurationService { @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load... | RunConfigurationManager implements RunConfigurationService { @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load... | RunConfigurationManager implements RunConfigurationService { @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load... | RunConfigurationManager implements RunConfigurationService { @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load... |
@Test public void testLoadByName() { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) executionConfigurationManager .load( "Default Configuration" ); assertNotNull( defaultRunConfiguration ); assertEquals( defaultRunConfiguration.getName(), "Default Configuration" ); } | @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load() ); } Collections.sort( runConfigurations, ( o1, o2 ) -> { ... | RunConfigurationManager implements RunConfigurationService { @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load... | RunConfigurationManager implements RunConfigurationService { @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load... | RunConfigurationManager implements RunConfigurationService { @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load... | RunConfigurationManager implements RunConfigurationService { @Override public List<RunConfiguration> load() { List<RunConfiguration> runConfigurations = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { runConfigurations.addAll( runConfigurationProvider.load... |
@Test public void testGetNames() { List<String> names = executionConfigurationManager.getNames(); assertTrue( names.contains( DefaultRunConfigurationProvider.DEFAULT_CONFIG_NAME ) ); assertTrue( names.contains( "Default Configuration" ) ); assertTrue( names.contains( "Spark Configuration" ) ); } | public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) -> { if ( o2.equals( DefaultRunConfigurationProvider.DEFAULT_CO... | RunConfigurationManager implements RunConfigurationService { public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) ->... | RunConfigurationManager implements RunConfigurationService { public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) ->... | RunConfigurationManager implements RunConfigurationService { public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) ->... | RunConfigurationManager implements RunConfigurationService { public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) ->... |
@Test public void testGetRunConfigurationByType() { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) executionConfigurationManager.getRunConfigurationByType( DefaultRunConfiguration.TYPE ); SparkRunConfiguration sparkRunConfiguration = (SparkRunConfiguration) executionConfigurationManager.get... | public RunConfiguration getRunConfigurationByType( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getConfiguration(); } return null; } | RunConfigurationManager implements RunConfigurationService { public RunConfiguration getRunConfigurationByType( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getConfiguration(); } return null; } } | RunConfigurationManager implements RunConfigurationService { public RunConfiguration getRunConfigurationByType( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getConfiguration(); } return null; } RunConfi... | RunConfigurationManager implements RunConfigurationService { public RunConfiguration getRunConfigurationByType( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getConfiguration(); } return null; } RunConfi... | RunConfigurationManager implements RunConfigurationService { public RunConfiguration getRunConfigurationByType( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getConfiguration(); } return null; } RunConfi... |
@Test public void testGetExecutor() { DefaultRunConfigurationExecutor defaultRunConfigurationExecutor = (DefaultRunConfigurationExecutor) executionConfigurationManager.getExecutor( DefaultRunConfiguration.TYPE ); assertNotNull( defaultRunConfigurationExecutor ); } | public RunConfigurationExecutor getExecutor( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getExecutor(); } return null; } | RunConfigurationManager implements RunConfigurationService { public RunConfigurationExecutor getExecutor( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getExecutor(); } return null; } } | RunConfigurationManager implements RunConfigurationService { public RunConfigurationExecutor getExecutor( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getExecutor(); } return null; } RunConfigurationMan... | RunConfigurationManager implements RunConfigurationService { public RunConfigurationExecutor getExecutor( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getExecutor(); } return null; } RunConfigurationMan... | RunConfigurationManager implements RunConfigurationService { public RunConfigurationExecutor getExecutor( String type ) { RunConfigurationProvider runConfigurationProvider = getProvider( type ); if ( runConfigurationProvider != null ) { return runConfigurationProvider.getExecutor(); } return null; } RunConfigurationMan... |
@Test public void testCallExtensionPoint() throws Exception { runConfigurationRunExtensionPoint.callExtensionPoint( log, new Object[] { transExecutionConfiguration, abstractMeta, variableSpace } ); verify( runConfigurationExecutor ) .execute( runConfiguration, transExecutionConfiguration, abstractMeta, variableSpace );... | @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta) ( (Object[]) o )[ 1 ]; VariableSpace variableSpace = (VariableSpace) (... | RunConfigurationRunExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta)... | RunConfigurationRunExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta)... | RunConfigurationRunExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta)... | RunConfigurationRunExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta)... |
@Test public void testCreateIndexLenghts() throws KettleException { DatabaseMeta meta = mock( DatabaseMeta.class ); when( meta.getStartQuote() ).thenReturn( "" ); when( meta.getEndQuote() ).thenReturn( "" ); when( meta.getQuotedSchemaTableCombination( anyString(), anyString() ) ).thenAnswer( new Answer<String>() { @Ove... | public synchronized void createRepositorySchema( ProgressMonitorListener monitor, boolean upgrade, List<String> statements, boolean dryrun ) throws KettleException { RowMetaInterface table; String sql; String tablename; String schemaTable; String indexname; String[] keyfield; String[] user, pass, code, desc; int KEY = ... | KettleDatabaseRepositoryCreationHelper { public synchronized void createRepositorySchema( ProgressMonitorListener monitor, boolean upgrade, List<String> statements, boolean dryrun ) throws KettleException { RowMetaInterface table; String sql; String tablename; String schemaTable; String indexname; String[] keyfield; St... | KettleDatabaseRepositoryCreationHelper { public synchronized void createRepositorySchema( ProgressMonitorListener monitor, boolean upgrade, List<String> statements, boolean dryrun ) throws KettleException { RowMetaInterface table; String sql; String tablename; String schemaTable; String indexname; String[] keyfield; St... | KettleDatabaseRepositoryCreationHelper { public synchronized void createRepositorySchema( ProgressMonitorListener monitor, boolean upgrade, List<String> statements, boolean dryrun ) throws KettleException { RowMetaInterface table; String sql; String tablename; String schemaTable; String indexname; String[] keyfield; St... | KettleDatabaseRepositoryCreationHelper { public synchronized void createRepositorySchema( ProgressMonitorListener monitor, boolean upgrade, List<String> statements, boolean dryrun ) throws KettleException { RowMetaInterface table; String sql; String tablename; String schemaTable; String indexname; String[] keyfield; St... |
@Test public void testCallExtensionPointEmbedded() throws Exception { when( runConfigurationManager.load( "RUN_CONF" ) ).thenReturn( null ); try { runConfigurationRunExtensionPoint.callExtensionPoint( log, new Object[] { transExecutionConfiguration, abstractMeta, variableSpace } ); fail(); } catch ( Exception e ) { } } | @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta) ( (Object[]) o )[ 1 ]; VariableSpace variableSpace = (VariableSpace) (... | RunConfigurationRunExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta)... | RunConfigurationRunExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta)... | RunConfigurationRunExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta)... | RunConfigurationRunExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { ExecutionConfiguration executionConfiguration = (ExecutionConfiguration) ( (Object[]) o )[ 0 ]; AbstractMeta meta = (AbstractMeta)... |
@Test public void testCallExtensionPoint() throws Exception { runConfigurationImportExtensionPoint.callExtensionPoint( log, abstractMeta ); verify( abstractMeta ).getEmbeddedMetaStore(); } | @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { AbstractMeta abstractMeta = (AbstractMeta) o; final EmbeddedMetaStore embeddedMetaStore = abstractMeta.getEmbeddedMetaStore(); RunConfigurationManager embeddedRunConfigurationManager = EmbeddedRunConfi... | RunConfigurationImportExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { AbstractMeta abstractMeta = (AbstractMeta) o; final EmbeddedMetaStore embeddedMetaStore = abstractMeta.getEmbeddedMetaStore(); ... | RunConfigurationImportExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { AbstractMeta abstractMeta = (AbstractMeta) o; final EmbeddedMetaStore embeddedMetaStore = abstractMeta.getEmbeddedMetaStore(); ... | RunConfigurationImportExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { AbstractMeta abstractMeta = (AbstractMeta) o; final EmbeddedMetaStore embeddedMetaStore = abstractMeta.getEmbeddedMetaStore(); ... | RunConfigurationImportExtensionPoint implements ExtensionPointInterface { @Override public void callExtensionPoint( LogChannelInterface logChannelInterface, Object o ) throws KettleException { AbstractMeta abstractMeta = (AbstractMeta) o; final EmbeddedMetaStore embeddedMetaStore = abstractMeta.getEmbeddedMetaStore(); ... |
@Test public void testExecuteLocalTrans() throws Exception { DefaultRunConfiguration defaultRunConfiguration = new DefaultRunConfiguration(); defaultRunConfiguration.setName( "Default Configuration" ); defaultRunConfiguration.setLocal( true ); TransExecutionConfiguration transExecutionConfiguration = new TransExecution... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) runConfiguration; if ( executionConfiguration instanceof ... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... |
@Test public void testExecuteRemoteTrans() throws Exception { DefaultRunConfiguration defaultRunConfiguration = new DefaultRunConfiguration(); defaultRunConfiguration.setName( "Default Configuration" ); defaultRunConfiguration.setLocal( false ); defaultRunConfiguration.setRemote( true ); defaultRunConfiguration.setServ... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) runConfiguration; if ( executionConfiguration instanceof ... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... |
@Test public void testExecutePentahoTrans() throws Exception { DefaultRunConfiguration defaultRunConfiguration = new DefaultRunConfiguration(); defaultRunConfiguration.setName( "Default Configuration" ); defaultRunConfiguration.setLocal( false ); defaultRunConfiguration.setPentaho( true ); defaultRunConfiguration.setRe... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) runConfiguration; if ( executionConfiguration instanceof ... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... |
@Test public void testExecuteClusteredTrans() throws Exception { DefaultRunConfiguration defaultRunConfiguration = new DefaultRunConfiguration(); defaultRunConfiguration.setName( "Default Configuration" ); defaultRunConfiguration.setLocal( false ); defaultRunConfiguration.setRemote( false ); defaultRunConfiguration.set... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) runConfiguration; if ( executionConfiguration instanceof ... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... |
@Test public void testExecuteRemoteNotFoundTrans() throws Exception { DefaultRunConfiguration defaultRunConfiguration = new DefaultRunConfiguration(); defaultRunConfiguration.setName( "Default Configuration" ); defaultRunConfiguration.setLocal( false ); defaultRunConfiguration.setRemote( true ); defaultRunConfiguration... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) runConfiguration; if ( executionConfiguration instanceof ... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... |
@Test public void testExecuteLocalJob() throws Exception { DefaultRunConfiguration defaultRunConfiguration = new DefaultRunConfiguration(); defaultRunConfiguration.setName( "Default Configuration" ); defaultRunConfiguration.setLocal( true ); JobExecutionConfiguration jobExecutionConfiguration = new JobExecutionConfigur... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) runConfiguration; if ( executionConfiguration instanceof ... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... |
@Test public void testExecuteRemoteJob() throws Exception { DefaultRunConfiguration defaultRunConfiguration = new DefaultRunConfiguration(); defaultRunConfiguration.setName( "Default Configuration" ); defaultRunConfiguration.setLocal( false ); defaultRunConfiguration.setRemote( true ); defaultRunConfiguration.setServer... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) runConfiguration; if ( executionConfiguration instanceof ... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... |
@Test public void testExecuteRemoteNotFoundJob() throws Exception { DefaultRunConfiguration defaultRunConfiguration = new DefaultRunConfiguration(); defaultRunConfiguration.setName( "Default Configuration" ); defaultRunConfiguration.setLocal( false ); defaultRunConfiguration.setRemote( true ); defaultRunConfiguration.s... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) runConfiguration; if ( executionConfiguration instanceof ... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... |
@Test public void testOracleDBRepoStringLength() throws Exception { KettleEnvironment.init(); DatabaseMeta databaseMeta = new DatabaseMeta( "OraRepo", "ORACLE", "JDBC", null, "test", null, null, null ); repositoryMeta = new KettleDatabaseRepositoryMeta( "KettleDatabaseRepository", "OraRepo", "Ora Repository", databaseM... | protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } | KettleDatabaseRepositoryCreationHelper { protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } } | KettleDatabaseRepositoryCreationHelper { protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } KettleDatabaseReposi... | KettleDatabaseRepositoryCreationHelper { protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } KettleDatabaseReposi... | KettleDatabaseRepositoryCreationHelper { protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } KettleDatabaseReposi... |
@Test public void testExecutePentahoJob() throws Exception { DefaultRunConfiguration defaultRunConfiguration = new DefaultRunConfiguration(); defaultRunConfiguration.setName( "Default Configuration" ); defaultRunConfiguration.setLocal( false ); defaultRunConfiguration.setPentaho( true ); defaultRunConfiguration.setRemo... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunConfiguration) runConfiguration; if ( executionConfiguration instanceof ... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... | DefaultRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration executionConfiguration, AbstractMeta meta, VariableSpace variableSpace ) throws KettleException { DefaultRunConfiguration defaultRunConfiguration = (DefaultRunCo... |
@Test public void testExecuteRSADaemon() { SparkRunConfiguration sparkRunConfiguration = new SparkRunConfiguration(); sparkRunConfiguration.setName( "Spark Configuration" ); sparkRunConfiguration.setUrl( "ws: doReturn( "1.0" ).when( variableSpace ).getVariable( "KETTLE_AEL_PDI_DAEMON_VERSION", "2.0" ); TransExecutionCo... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ); ICapability jaasCapability = capabilityManager.getCapabilityById(... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... |
@Test public void testExecuteNoPortRSADaemon() { SparkRunConfiguration sparkRunConfiguration = new SparkRunConfiguration(); sparkRunConfiguration.setName( "Spark Configuration" ); sparkRunConfiguration.setUrl( "zk: TransExecutionConfiguration transExecutionConfiguration = new TransExecutionConfiguration(); doReturn( "1... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ); ICapability jaasCapability = capabilityManager.getCapabilityById(... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... |
@Test public void testWebSocketVersionExecute() { SparkRunConfiguration sparkRunConfiguration = new SparkRunConfiguration(); sparkRunConfiguration.setName( "Spark Configuration" ); sparkRunConfiguration.setUrl( "http: doReturn( "2.0" ).when( variableSpace ).getVariable( "KETTLE_AEL_PDI_DAEMON_VERSION", "2.0" ); TransEx... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ); ICapability jaasCapability = capabilityManager.getCapabilityById(... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... |
@Test public void testWebSocketVersionExecuteNoPort() { SparkRunConfiguration sparkRunConfiguration = new SparkRunConfiguration(); sparkRunConfiguration.setName( "Spark Configuration" ); doReturn( "2.0" ).when( variableSpace ).getVariable( "KETTLE_AEL_PDI_DAEMON_VERSION", "2.0" ); TransExecutionConfiguration transExecu... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ); ICapability jaasCapability = capabilityManager.getCapabilityById(... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... |
@Test public void testWssWebSocketVersionExecute() { SparkRunConfiguration sparkRunConfiguration = new SparkRunConfiguration(); sparkRunConfiguration.setName( "Spark Configuration" ); sparkRunConfiguration.setUrl( "wss: doReturn( "2.0" ).when( variableSpace ).getVariable( "KETTLE_AEL_PDI_DAEMON_VERSION", "2.0" ); Trans... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ); ICapability jaasCapability = capabilityManager.getCapabilityById(... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... |
@Test public void testUrlWssWebSocketVersionExecute() { SparkRunConfiguration sparkRunConfiguration = new SparkRunConfiguration(); sparkRunConfiguration.setName( "Spark Configuration" ); sparkRunConfiguration.setUrl( " ws: doReturn( "2.0" ).when( variableSpace ).getVariable( "KETTLE_AEL_PDI_DAEMON_VERSION", "2.0" ); Tr... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ); ICapability jaasCapability = capabilityManager.getCapabilityById(... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... |
@Test public void testExecuteWithAelSecurityInstalled() { ICapability aelSecurityCapability = mock( ICapability.class ); setCapability( aelSecurityCapability, SparkRunConfigurationExecutor.AEL_SECURITY_CAPABILITY_ID, true ); ICapability jaasCapability = mock( ICapability.class ); setCapability( jaasCapability, SparkRun... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ); ICapability jaasCapability = capabilityManager.getCapabilityById(... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... |
@Test public void testExecuteWithNoAelSecurityInstalled() { ICapability aelSecurityCapability = mock( ICapability.class ); setCapability( aelSecurityCapability, SparkRunConfigurationExecutor.AEL_SECURITY_CAPABILITY_ID, false ); ICapability jaasCapability = mock( ICapability.class ); setCapability( jaasCapability, Spark... | @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ); ICapability jaasCapability = capabilityManager.getCapabilityById(... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... | SparkRunConfigurationExecutor implements RunConfigurationExecutor { @Override public void execute( RunConfiguration runConfiguration, ExecutionConfiguration configuration, AbstractMeta meta, VariableSpace variableSpace ) { ICapability securityCapability = capabilityManager.getCapabilityById( AEL_SECURITY_CAPABILITY_ID ... |
@Test public void testInputFileSurroundedBySingleQuotes() throws Exception { String datafile = "test-data-file"; loader = new GPBulkLoader( mockHelper.stepMeta, mockHelper.stepDataInterface, 0, mockHelper.transMeta, mockHelper.trans ); DatabaseMeta dbMetaMock = mock( DatabaseMeta.class ); doReturn( "" ).when( dbMetaMoc... | public String getControlFileContents( GPBulkLoaderMeta meta, RowMetaInterface rm, Object[] r ) throws KettleException { DatabaseMeta dm = meta.getDatabaseMeta(); String inputName = "'" + environmentSubstitute( meta.getDataFile() ) + "'"; String loadAction = meta.getLoadAction(); StringBuffer contents = new StringBuffer... | GPBulkLoader extends BaseStep implements StepInterface { public String getControlFileContents( GPBulkLoaderMeta meta, RowMetaInterface rm, Object[] r ) throws KettleException { DatabaseMeta dm = meta.getDatabaseMeta(); String inputName = "'" + environmentSubstitute( meta.getDataFile() ) + "'"; String loadAction = meta.... | GPBulkLoader extends BaseStep implements StepInterface { public String getControlFileContents( GPBulkLoaderMeta meta, RowMetaInterface rm, Object[] r ) throws KettleException { DatabaseMeta dm = meta.getDatabaseMeta(); String inputName = "'" + environmentSubstitute( meta.getDataFile() ) + "'"; String loadAction = meta.... | GPBulkLoader extends BaseStep implements StepInterface { public String getControlFileContents( GPBulkLoaderMeta meta, RowMetaInterface rm, Object[] r ) throws KettleException { DatabaseMeta dm = meta.getDatabaseMeta(); String inputName = "'" + environmentSubstitute( meta.getDataFile() ) + "'"; String loadAction = meta.... | GPBulkLoader extends BaseStep implements StepInterface { public String getControlFileContents( GPBulkLoaderMeta meta, RowMetaInterface rm, Object[] r ) throws KettleException { DatabaseMeta dm = meta.getDatabaseMeta(); String inputName = "'" + environmentSubstitute( meta.getDataFile() ) + "'"; String loadAction = meta.... |
@Test public void testDefaultDBRepoStringLength() throws Exception { KettleEnvironment.init(); DatabaseMeta databaseMeta = new DatabaseMeta(); databaseMeta.setDatabaseInterface( new TestDatabaseMeta() ); repositoryMeta = new KettleDatabaseRepositoryMeta( "KettleDatabaseRepository", "TestRepo", "Test Repository", databa... | protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } | KettleDatabaseRepositoryCreationHelper { protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } } | KettleDatabaseRepositoryCreationHelper { protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } KettleDatabaseReposi... | KettleDatabaseRepositoryCreationHelper { protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } KettleDatabaseReposi... | KettleDatabaseRepositoryCreationHelper { protected int getRepoStringLength() { return database.getDatabaseMeta().getDatabaseInterface().getMaxVARCHARLength() - 1 > 0 ? database.getDatabaseMeta() .getDatabaseInterface().getMaxVARCHARLength() - 1 : KettleDatabaseRepository.REP_ORACLE_STRING_LENGTH; } KettleDatabaseReposi... |
@Test public void testProcessRow() throws KettleException { AggregateRows aggregateRows = new AggregateRows( stepMockHelper.stepMeta, stepMockHelper.stepDataInterface, 0, stepMockHelper.transMeta, stepMockHelper.trans ); aggregateRows.init( stepMockHelper.initStepMetaInterface, stepMockHelper.initStepDataInterface ); a... | public boolean processRow( StepMetaInterface smi, StepDataInterface sdi ) throws KettleException { meta = (AggregateRowsMeta) smi; data = (AggregateRowsData) sdi; Object[] r = getRow(); if ( r == null ) { Object[] agg = buildAggregate(); putRow( data.outputRowMeta, agg ); setOutputDone(); return false; } if ( first ) {... | AggregateRows extends BaseStep implements StepInterface { public boolean processRow( StepMetaInterface smi, StepDataInterface sdi ) throws KettleException { meta = (AggregateRowsMeta) smi; data = (AggregateRowsData) sdi; Object[] r = getRow(); if ( r == null ) { Object[] agg = buildAggregate(); putRow( data.outputRowMe... | AggregateRows extends BaseStep implements StepInterface { public boolean processRow( StepMetaInterface smi, StepDataInterface sdi ) throws KettleException { meta = (AggregateRowsMeta) smi; data = (AggregateRowsData) sdi; Object[] r = getRow(); if ( r == null ) { Object[] agg = buildAggregate(); putRow( data.outputRowMe... | AggregateRows extends BaseStep implements StepInterface { public boolean processRow( StepMetaInterface smi, StepDataInterface sdi ) throws KettleException { meta = (AggregateRowsMeta) smi; data = (AggregateRowsData) sdi; Object[] r = getRow(); if ( r == null ) { Object[] agg = buildAggregate(); putRow( data.outputRowMe... | AggregateRows extends BaseStep implements StepInterface { public boolean processRow( StepMetaInterface smi, StepDataInterface sdi ) throws KettleException { meta = (AggregateRowsMeta) smi; data = (AggregateRowsData) sdi; Object[] r = getRow(); if ( r == null ) { Object[] agg = buildAggregate(); putRow( data.outputRowMe... |
@Test public void convertFromProxyPentahoUser_RetunsNull_WhenErrorOccurs() throws Exception { IRoleSupportSecurityManager manager = mock( IRoleSupportSecurityManager.class ); when( manager.constructUser() ).thenThrow( new KettleException() ); IUser user = convertFromProxyPentahoUser( new ProxyPentahoUser(), Collections... | public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user.getDescription() ); userInfo.setPassword( user.g... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... |
@Test public void convertFromProxyPentahoUser_CopiesDataFromInput() throws Exception { IRoleSupportSecurityManager manager = mockSecurityManager( false ); ProxyPentahoUser pentahoUser = pentahoUser( "name" ); pentahoUser.setPassword( "password" ); pentahoUser.setDescription( "desc" ); pentahoUser.setEnabled( true ); IU... | public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user.getDescription() ); userInfo.setPassword( user.g... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... |
@Test public void convertFromProxyPentahoUser_CopiesRolesForEeUser() throws Exception { IRoleSupportSecurityManager manager = mockSecurityManager( true ); ProxyPentahoUser pentahoUser = pentahoUser( "name" ); List<UserToRoleAssignment> assignments = Collections.singletonList( new UserToRoleAssignment( "name", "role" ) ... | public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user.getDescription() ); userInfo.setPassword( user.g... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... | UserRoleHelper implements java.io.Serializable { public static IUser convertFromProxyPentahoUser( IUserRoleWebService userRoleWebService, ProxyPentahoUser user, UserRoleLookupCache lookupCache, IRoleSupportSecurityManager rsm ) { IUser userInfo = null; try { userInfo = rsm.constructUser(); userInfo.setDescription( user... |
@Test public void convertFromProxyPentahoUsers_ReturnsEmptyList_WhenUsersAreAbsent() throws Exception { UserRoleSecurityInfo info = new UserRoleSecurityInfo(); info.setUsers( null ); IRoleSupportSecurityManager manager = mockSecurityManager( false ); List<IUser> users = convertFromProxyPentahoUsers( info, manager ); as... | public static List<IUser> convertFromProxyPentahoUsers( UserRoleSecurityInfo info, IRoleSupportSecurityManager rsm ) { List<ProxyPentahoUser> users = info.getUsers(); if ( users == null || users.isEmpty() ) { return Collections.emptyList(); } List<UserToRoleAssignment> assignments = info.getAssignments(); List<IUser> u... | UserRoleHelper implements java.io.Serializable { public static List<IUser> convertFromProxyPentahoUsers( UserRoleSecurityInfo info, IRoleSupportSecurityManager rsm ) { List<ProxyPentahoUser> users = info.getUsers(); if ( users == null || users.isEmpty() ) { return Collections.emptyList(); } List<UserToRoleAssignment> a... | UserRoleHelper implements java.io.Serializable { public static List<IUser> convertFromProxyPentahoUsers( UserRoleSecurityInfo info, IRoleSupportSecurityManager rsm ) { List<ProxyPentahoUser> users = info.getUsers(); if ( users == null || users.isEmpty() ) { return Collections.emptyList(); } List<UserToRoleAssignment> a... | UserRoleHelper implements java.io.Serializable { public static List<IUser> convertFromProxyPentahoUsers( UserRoleSecurityInfo info, IRoleSupportSecurityManager rsm ) { List<ProxyPentahoUser> users = info.getUsers(); if ( users == null || users.isEmpty() ) { return Collections.emptyList(); } List<UserToRoleAssignment> a... | UserRoleHelper implements java.io.Serializable { public static List<IUser> convertFromProxyPentahoUsers( UserRoleSecurityInfo info, IRoleSupportSecurityManager rsm ) { List<ProxyPentahoUser> users = info.getUsers(); if ( users == null || users.isEmpty() ) { return Collections.emptyList(); } List<UserToRoleAssignment> a... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.