hi there, new user here :smile: I just cloned inc...
# general
r
hi there, new user here 😄 I just cloned incubator-pinot, and I was trying to run specific tests in the following way, I am inside
incubator-pinot/pinot-controller
Copy code
mvn test -Dtest=LeadControllerManagerTest
but I get this error
Copy code
[ERROR] Failed to execute goal on project pinot-controller: Could not resolve dependencies for project org.apache.pinot:pinot-controller:jar:0.5.0-SNAPSHOT: Failed to collect dependencies at org.apache.pinot:pinot-common:jar:0.5.0-SNAPSHOT: Failed to read artifact descriptor for org.apache.pinot:pinot-common:jar:0.5.0-SNAPSHOT: Failure to find org.apache.pinot:pinot:pom:${revision}${sha1} in <https://repo.maven.apache.org/maven2> was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced -> [Help 1]
any ideas what it could be?
m
Hello, did you build first?
mvn clean install -DskipTests -Pbin-dist
r
I did this
Copy code
mvn install package -DskipTests -Pbin-dist -DdownloadSources -DdownloadJavadocs
or did I miss
-Pbin-dist
?
x
can you run it from root
not inside the pinot-controller
m
Oh yea, i didn't notice that you were running from within the module
r
building
give a few mins and I will report back 🙂 thanks!
no, it didn't work, I got this
Copy code
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.19:test (default-test) on project pinot-spi: No tests were executed!  (Set -DfailIfNoTests=false to ignore this error.) -> [Help 1]
...
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <args> -rf :pinot-spi
I tried running a specific test
Copy code
mvn test -Dtest=org.apache.pinot.controller.LeadControllerManagerTest
m
Set -DfailIfNoTests=false to ignore this error.)
r
thanks! with
-DfailIfNoTests=false
worked, but it ended up building the entire project 🤔
Copy code
[INFO] Pinot .............................................. SUCCESS [  2.615 s]
[INFO] Pinot Service Provider Interface ................... SUCCESS [  0.816 s]
[INFO] Pinot Common ....................................... SUCCESS [  5.578 s]
[INFO] Pinot Plugins ...................................... SUCCESS [  0.329 s]
[INFO] Pinot Input Format ................................. SUCCESS [  0.190 s]
[INFO] Pinot Avro Base .................................... SUCCESS [  0.151 s]
how do you guys run specific unit tests?
m
From IDE is one way
r
ok that might be way easier 😅 I imported incubator-pinot into intellj but tests don't seem to be recognized
x
the issue is we are using
<version>${revision}${sha1}</version>
in pom version
r
that is why the entire project gets rebuilt?
x
which prevent running build from each component
r
I see, yeah then running specific unit tests from cmd line would not be ideal
x
I somehow feel we should change it back to fixed version @Mayank
r
I mean what is the advantage of using
Copy code
<version>${revision}${sha1}</version>
? if you guys are doing the release periodically, then those could change accordingly, and the
sha1
verification could be done when submitting release candidates
x
we are using maven release for that
if you replace
<version>${revision}${sha1}</version>
with
<version>0.5.0-SNAPSHOT</version>
, then you should be able to build/test in child component
👍 1
r
just out of curiosity, what is the advantage of using
Copy code
<version>${revision}${sha1}</version>
?
also is there a specific IDE conf for intellj for it to recognize unit tests? I keep on seeing them as non-executable 😞
m
Hmm, that should not happen.
mvn idea:idea?