1
0
mirror of https://github.com/golang/go synced 2024-11-05 21:46:13 -07:00
Commit Graph

17 Commits

Author SHA1 Message Date
Daniel Martí
354f9f8b43 cmd/cover: check os.Create error im html output
The error was being written over by Execute.

Change-Id: Id5965542bf4d414043fdbe70ee3f2f790728c01d
Reviewed-on: https://go-review.googlesource.com/34954
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2017-01-08 00:00:17 +00:00
Andrew Gerrand
5ebbcd132f go.tools: use golang.org/x/... import paths
Rewrite performed with this command:
  sed -i '' 's_code.google.com/p/go\._golang.org/x/_g' \
    $(grep -lr 'code.google.com/p/go.' *)

LGTM=rsc
R=rsc
CC=golang-codereviews
https://golang.org/cl/170920043
2014-11-10 08:50:40 +11:00
Andrew Gerrand
573fa9f0bd cmd/cover: show file coverage in HTML drop down
As requested on Stack Overflow: http://goo.gl/ams9fY
(Kudos to sberry for his JavaScript solution, provided there.
This change does the same thing on the server side.)

LGTM=r
R=r
CC=golang-codereviews
https://golang.org/cl/127030043
2014-08-12 09:22:11 +10:00
Andrew Wilkins
df34f98521 go.tools/cover: split parsing code out from cmd/cover
Split the profile parsing code out of cmd/cover into
a reusable package, to support third-party coverage
tools.

R=golang-dev, r, adg
CC=golang-dev
https://golang.org/cl/36050045
2013-12-03 20:55:21 -08:00
Rob Pike
51613a10d7 go.tools/cmd/cover: sort the file names in the output presentation
Present the files in lexical order so the output is reproducible
and easier to navigate. Do a little type rearrangement to simplify
things while we're there.

R=adg
CC=golang-dev
https://golang.org/cl/14357043
2013-10-03 16:37:34 -07:00
Andrew Gerrand
eb130cb481 go.tools/cmd/cover: add content-type meta tag to HTML output
Fixes golang/go#6435.

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/13822045
2013-09-23 13:57:03 +10:00
Rob Pike
4622486b62 go.tools/cmd/cover: add -func mode to print per-function coverage
fmt/format.go:	init			100.0%
fmt/format.go:	clearflags		100.0%
fmt/format.go:	init			100.0%
fmt/format.go:	computePadding		84.6%
fmt/format.go:	writePadding		83.3%
...
total:		(statements)		91.3%

Fixes golang/go#5985.

R=golang-dev, dave, gri
CC=golang-dev
https://golang.org/cl/12454043
2013-08-09 12:55:21 +10:00
Rob Pike
9ac8940d29 all: be more idiomatic when documenting boolean return values.
Phrases like "returns whether or not the image is opaque" could be
describing what the function does (it always returns, regardless of
the opacity) or what it returns (a boolean indicating the opacity).
Even when the "or not" is missing, the phrasing is bizarre.

Go with "reports whether", which is still clunky but at least makes
it clear we're talking about the return value.

R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/11458046
2013-07-23 10:37:43 +10:00
Andrew Gerrand
5b27bc1db9 go.talks/cmd/cover: show simpler legend for "set" mode
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/10738044
2013-07-10 14:03:35 +10:00
Andrew Gerrand
c659fcb7c8 go.tools/cmd/cover: add floating bar with file selector and legend
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/11076043
2013-07-10 13:22:04 +10:00
Andrew Gerrand
2b6515094c go.talks/cmd/cover: better color scheme and fonts
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/11032043
2013-07-09 16:58:15 +10:00
Andrew Gerrand
a82eaff6b7 go.tools/cmd/cover: change color scheme and add legend
R=r, dsymonds
CC=golang-dev
https://golang.org/cl/10991043
2013-07-08 15:24:34 +10:00
Andrew Gerrand
00268482c0 go.tools/cmd/cover: use html/template for html generation
Also includes simple JavaScript dropdown picker.

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/10838045
2013-07-06 16:58:50 +10:00
Andrew Gerrand
d9e6cbb135 go.tools/cmd/cover: use a gradient to colorize "count" profiles
R=r
CC=golang-dev
https://golang.org/cl/10858047
2013-07-05 13:53:09 +10:00
Rob Pike
decfd079c5 go.tools/cmd/cover: skip mode line (first line of profile)
Still to do: use the mode to affect how to present the data.

R=adg, rsc
CC=golang-dev
https://golang.org/cl/10364050
2013-06-21 14:19:57 -07:00
Rob Pike
33ae2b030f go.tools.cmd/cover: define a block to end at the closing brace rather than last statement
Makes for prettier output in many cases.

R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/10360049
2013-06-19 09:11:32 -07:00
Andrew Gerrand
16c6244c27 go.tools/cmd/cover: add HTML output
R=r, dsymonds
CC=golang-dev
https://golang.org/cl/10277043
2013-06-15 08:53:10 +10:00