Re: UDFs not Working in Unit Tests

2019-09-20 Thread Charles Givre
Hey Paul, It turns out that I got it to work by added a test dependency in the plugin's pom.xml file. I ended up keeping the unit test because in this instance, one of the fields returned is a VARBINARY field, specifically a shape, which is not really possible to interpret without using one of

Re: UDFs not Working in Unit Tests

2019-09-20 Thread Paul Rogers
Hi Charles, Your workaround sounds right. In general, unit tests should make as few assumptions as possible about the system under test; they should focus on the one part of the system they want to exercise. (There is a large body of testing theory behind this statement...) In your case, it ma

Re: UDFs not Working in Unit Tests

2019-09-20 Thread Charles Givre
Hey Paul, Thanks for your help. I should have clarified that the work I'm doing is for an ESRI Shape File plugin which is in contrib. The unit test in question calls a function which is in the contrib/udfs and I think you've pinpointed the issue. Unfortunately, running the test with maven pr

Re: UDFs not Working in Unit Tests

2019-09-20 Thread Paul Rogers
Hi Charles, I seem to recall fighting with something similar in the past. The problem is not with your setup; it is with how Drill finds your (custom?) UDF on the classpath. My memory is hazy; but I think it had to do with the way that Drill uses the drill-override.conf file to extend class pa

UDFs not Working in Unit Tests

2019-09-20 Thread Charles Givre
Hello Drillers, I'm encountering a strange error in a unit test. The code is included below, and it fails because when Drill attempts to execute the test, it cannot find the function st_astext(). If I build Drill and execute the query in the CLI it works, so I suspect there is some environmen