* Use a combination of command line, file and declare where there are duplicate parameters.
* Result: Declare has highest priority.
*/
@Test
public void testCmdlineFileDeclareComboDuplicates() throws Exception{
ParameterSubstitutionPreprocessor ps = new ParameterSubstitutionPreprocessor(50);
pigIStream = new BufferedReader(new FileReader(basedir + "/inputThreeParams.pig"));
pigOStream = new FileWriter(basedir + "/output1.pig");
String[] arg = {"date='20080228'" , "tableName=\"skip this\""};
String[] argFiles = {basedir+"/ConfFile2.txt"};
ps.genSubstitutedFile(pigIStream , pigOStream , arg , argFiles);
FileInputStream pigResultStream = new FileInputStream(basedir + "/output1.pig");
pigExResultStream = new FileInputStream(basedir + "/ExpectedResult.pig");
BufferedReader inExpected = new BufferedReader(new InputStreamReader(pigExResultStream));
BufferedReader inResult = new BufferedReader(new InputStreamReader(pigResultStream));