You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Vitalii Diravka (JIRA)" <ji...@apache.org> on 2019/02/04 14:20:00 UTC

[jira] [Commented] (DRILL-7025) Running Drill unit tests from within IntelliJ IDEA fails with FileNotFoundException: Source './src/test/resources/tpchmulti' does not exist

    [ https://issues.apache.org/jira/browse/DRILL-7025?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16759874#comment-16759874 ] 

Vitalii Diravka commented on DRILL-7025:
----------------------------------------

[~vladimirsitnikov] Is that only with _TestExampleQueries_ test cases? I run _TestExampleQueries.testExchangeRemoveForJoinPlan()_ without additional adding "exec/java-exec" to "working directory" and it passed. 
Can you advice how to reproduce the issue?

> Running Drill unit tests from within IntelliJ IDEA fails with FileNotFoundException: Source './src/test/resources/tpchmulti' does not exist
> -------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: DRILL-7025
>                 URL: https://issues.apache.org/jira/browse/DRILL-7025
>             Project: Apache Drill
>          Issue Type: Bug
>          Components:  Server, Tools, Build &amp; Test
>    Affects Versions: 1.15.0
>            Reporter: Vladimir Sitnikov
>            Priority: Major
>
> I start org.apache.drill.TestExampleQueries via regular "run tests" button, and it produces the following exception:
> {noformat}
> java.lang.RuntimeException: This should not happen
> at org.apache.drill.test.BaseDirTestWatcher.copyTo(BaseDirTestWatcher.java:298)
> at org.apache.drill.test.BaseDirTestWatcher.copyResourceToRoot(BaseDirTestWatcher.java:223)
> at org.apache.drill.TestExampleQueries.setupTestFiles(TestExampleQueries.java:42)
> Caused by: java.io.FileNotFoundException: Source './src/test/resources/tpchmulti' does not exist
> at org.apache.commons.io.FileUtils.copyFile(FileUtils.java:1074)
> at org.apache.commons.io.FileUtils.copyFile(FileUtils.java:1038)
> at org.apache.drill.test.BaseDirTestWatcher.copyTo(BaseDirTestWatcher.java:296)
> ... 2 more{noformat}
> In fact IDEA creates "run configuration" that uses "/Users/vladimirsitnikov/Documents/work/drill" as "Working directory".
> That directory is a root where all drill sources are located (i.e. I have /Users/vladimirsitnikov/Documents/work/drill/exec, /Users/vladimirsitnikov/Documents/work/drill/exec/java-exec and so on).
> It looks like java-exec tests assume working directory is set to /Users/vladimirsitnikov/Documents/work/drill/exec/java-exec, however it is not the case when individual tests are run.
> The workaround is to add "exec/java-exec" to "working directory".
> It would be so much better if tests could be run from both working directories.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)