Unable to run junit test class with process.getInputStream() statement
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Anonymous
Posted On:   Monday, August 27, 2007 11:00 AM

Process process = Runtime.getRuntime().exec(cmd); -----(1) InputStreamReader isr = new InputStreamReader(process .getInputStream());-----(2) (cmd=C:Program FilesSybase125OCS-12_5 in cp DBName..TableName in D: empASD200708011025.BCP -m 1 -S DBServerName -U UserID -P Password -c) While iam running my junit testcase it is coming till step (1), after that it is stopping the execution. If iam run the same code in debug mode using Eclipse IDE iam able to complete (1) and (2) without any problem. I tried in googleeee, i came to know this is some kind of bug with windows, but no solution. Note:-If iam run the same thing without junit testcases(using normal unit testclass) iam able to    More>>

Process process = Runtime.getRuntime().exec(cmd); -----(1)

InputStreamReader isr = new InputStreamReader(process
.getInputStream());-----(2)

(cmd=C:Program FilesSybase125OCS-12_5 in cp DBName..TableName in D: empASD200708011025.BCP -m 1 -S DBServerName -U UserID -P Password -c)


While iam running my junit testcase it is coming till step (1), after that it is stopping the execution. If iam run the same code in debug mode using Eclipse IDE iam able to complete (1) and (2) without any problem. I tried in googleeee, i came to know this is some kind of bug with windows, but no solution.


Note:-If iam run the same thing without junit testcases(using normal unit testclass) iam able to execute step (1) and (2) also.


Really appreciate any help on this.


Thanks & Regards

Soma Raja S.

   <<Less
About | Sitemap | Contact