<Comment on #19941 Is there a way to only run test...
# github-notifications
c
Comment on #19941 Is there a way to only run tests with a certain dependency? Discussion answered by kaos I think you were pretty close, as there is no advanced search/filtering built into Pants. Perhaps something like:
Copy code
$ pants dependents --transitive <some dependency> | sort > tgts-depending-on-some-dep.specs
$ pants list :: | sort > all.specs
$ comm -1 -3 some-deps.specs all.specs > tgts-not-depending-on-some-dep.specs
Then you can use the two
tgts-..specs
files as needed with subsequent runs:
Copy code
$ pants --spec-files=tgts-not-depending-on-some-dep.specs test
# etc..
pantsbuild/pants