()
| 824 | } |
| 825 | |
| 826 | @Test |
| 827 | public void fsCommandTest() throws Exception { |
| 828 | PrintWriter w = new PrintWriter(new FileWriter(PIG_FILE)); |
| 829 | w.println("fs -mv nonexist.file dummy.file"); |
| 830 | w.close(); |
| 831 | |
| 832 | try { |
| 833 | String[] args = { "-x", execType, PIG_FILE }; |
| 834 | PigStats stats = PigRunner.run(args, new TestNotificationListener(execType)); |
| 835 | |
| 836 | assertTrue(!stats.isSuccessful()); |
| 837 | assertTrue(stats.getReturnCode() == PigRunner.ReturnCode.IO_EXCEPTION); |
| 838 | } finally { |
| 839 | new File(PIG_FILE).delete(); |
| 840 | } |
| 841 | } |
| 842 | |
| 843 | @Test // PIG-2006 |
| 844 | public void testEmptyFile() throws IOException { |
nothing calls this directly
no test coverage detected