• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

pantsbuild / pants / 5590 / 2
0%
main: 93%

Build:
Build:
LAST BUILD BRANCH: automation/release/2.33.0.dev4
DEFAULT BRANCH: main
Ran 11 Jul 2015 04:07AM UTC
Files 335
Run time 13s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

11 Jul 2015 04:06AM UTC coverage: 66.275% (+0.2%) from 66.035%
CI_FLAGS="-fkmsrcn -u 0/2 'Unit tests for pants and pants-plugins - shard 1'"

push

travis-ci

Benjy
Reimplement help formatting.

Using the argparse help formatter was no longer viable: we had
to customize it in so many ways it was easier to simply implement
our own. The new implementation:

- Supports subsystem args.
- Separates help info extraction from rendering, which allows
  more code reuse (and less hackiness) in builddict and bash
  completion generation tasks.
- Is better tested than the old code.
- Uses ANSI colors for readability.
- Sensibly handles recursively-registered options (it displays
  them in basic help on the outermost scope the option was
  registered on, but then only in advanced help in the inner
  scopes that inherited the registration via recursion).

This change also makes the implementations of builddict and bash
completion generation simpler and supportive of subsystem options.

This implementation requires knowledge of what a scope represents
(a task, goal, subsystem etc.) and also of who registered each
option on a scope. Note that these overlap but are not identical.
For example, a recursive global option is registered by the global
registrar on all task scopes.

This makes a lot of options code quite a lot simpler, so I took
the opportunity of this refactoring to simplify even further.
For example, we no longer have separate paths for registering
boolean and non-boolean options.

I also deleted a couple of unimportant builddict tests, which
relied more on incidental behavior than on intended properties
of that code.  It was going to be too much effort to get them
to pass (as TestOptions don't expose necessary methods, and it
would be overkill to add them just to support these trivial tests).

Testing Done:
CI passes here: https://travis-ci.org/pantsbuild/pants/builds/70451126

A previous run had one odd test failure which I'm currently investigating.

Reviewed at https://rbcommons.com/s/twitter/r/2458/

13255 of 20000 relevant lines covered (66.27%)

0.66 hits per line

Source Files on job 5590.2 (CI_FLAGS="-fkmsrcn -u 0/2 'Unit tests for pants and pants-plugins - shard 1'")
  • Tree
  • List 0
  • Changed 45
  • Source Changed 12
  • Coverage Changed 44
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 5590
  • Travis Job 5590.2
  • 6376bc98 on github
  • Prev Job for CI_FLAGS="-fkmsrcn -u 0/2 'Unit tests for pants and pants-plugins - shard 1'" on master (#5586.2)
  • Next Job for CI_FLAGS="-fkmsrcn -u 0/2 'Unit tests for pants and pants-plugins - shard 1'" on master (#5598.2)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc