Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 10 for Textfmt (0.14 sec)

  1. src/cmd/go/testdata/script/cover_build_pkg_select.txt

    # Examine the result.
    go tool covdata percent -i=$WORK/covdata
    stdout 'coverage: 100.0% of statements'
    
    # By default we want to see packages resident in the module covered,
    # but not dependencies.
    go tool covdata textfmt -i=$WORK/covdata -o=$WORK/covdata/out.txt
    grep 'mode: set' $WORK/covdata/out.txt
    grep 'mod.example/main/main.go:' $WORK/covdata/out.txt
    grep 'mod.example/sub/sub.go:' $WORK/covdata/out.txt
    ! grep 'rsc.io' $WORK/covdata/out.txt
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 28 11:50:58 UTC 2022
    - 2.7K bytes
    - Viewed (0)
  2. src/cmd/covdata/tool_test.go

    	dargs := []string{"-pkg=" + mainPkgPath, "-i=" + s.outdirs[0] + "," + s.outdirs[1],
    		"-o", outf}
    	lines := runToolOp(t, s, "textfmt", dargs)
    
    	// No output expected.
    	if len(lines) != 0 {
    		dumplines(lines)
    		t.Errorf("unexpected output from go tool covdata textfmt")
    	}
    
    	// Open and read the first few bits of the file.
    	payload, err := os.ReadFile(outf)
    	if err != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 07 20:46:32 UTC 2024
    - 24.5K bytes
    - Viewed (0)
  3. src/cmd/covdata/dump.go

    package main
    
    // This file contains functions and apis to support the "go tool
    // covdata" sub-commands that relate to dumping text format summaries
    // and reports: "pkglist", "func",  "debugdump", "percent", and
    // "textfmt".
    
    import (
    	"flag"
    	"fmt"
    	"internal/coverage"
    	"internal/coverage/calloc"
    	"internal/coverage/cformat"
    	"internal/coverage/cmerge"
    	"internal/coverage/decodecounter"
    	"internal/coverage/decodemeta"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 23 11:36:57 UTC 2023
    - 11.2K bytes
    - Viewed (0)
  4. src/cmd/covdata/covdata.go

    }
    
    func usage(msg string) {
    	if len(msg) > 0 {
    		fmt.Fprintf(os.Stderr, "error: %s\n", msg)
    	}
    	fmt.Fprintf(os.Stderr, "usage: go tool covdata [command]\n")
    	fmt.Fprintf(os.Stderr, `
    Commands are:
    
    textfmt     convert coverage data to textual format
    percent     output total percentage of statements covered
    pkglist     output list of package import paths
    func        output coverage profile information for each function
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 19:41:17 UTC 2024
    - 5.7K bytes
    - Viewed (0)
  5. src/cmd/covdata/doc.go

    	cov-example/p/p.go:12:		emptyFn			0.0%
    	cov-example/p/p.go:32:		Small			100.0%
    	cov-example/p/p.go:47:		Medium			90.9%
    	...
    	$
    
    4. Convert coverage data to legacy textual format:
    
    	$ go tool covdata textfmt -i=profiledir -o=cov.txt
    	$ head cov.txt
    	mode: set
    	cov-example/p/p.go:12.22,13.2 0 0
    	cov-example/p/p.go:15.31,16.2 1 0
    	cov-example/p/p.go:16.3,18.3 0 0
    	cov-example/p/p.go:19.3,21.3 0 0
    	...
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Oct 03 12:57:25 UTC 2023
    - 2K bytes
    - Viewed (0)
  6. src/cmd/go/internal/work/cover.go

    // -cover" on a package that has functions but no tests.
    func WriteCoverageProfile(b *Builder, runAct *Action, mf, outf string, w io.Writer) error {
    	dir := filepath.Dir(mf)
    	output, err := b.CovData(runAct, "textfmt", "-i", dir, "-o", outf)
    	if err != nil {
    		return b.Shell(runAct).reportCmd("", "", output, err)
    	}
    	_, werr := w.Write(output)
    	return werr
    }
    
    // WriteCoverMetaFilesFile writes out a summary file ("meta-files
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 19:09:38 UTC 2023
    - 5.2K bytes
    - Viewed (0)
  7. pilot/cmd/pilot-agent/status/server.go

    	}
    }
    
    const (
    	// nolint: revive, stylecheck
    	FmtOpenMetrics_0_0_1 = expfmt.OpenMetricsType + `; version=` + expfmt.OpenMetricsVersion_0_0_1 + `; charset=utf-8`
    	// nolint: revive, stylecheck
    	FmtOpenMetrics_1_0_0 = expfmt.OpenMetricsType + `; version=` + expfmt.OpenMetricsVersion_1_0_0 + `; charset=utf-8`
    	FmtText              = `text/plain; version=` + expfmt.TextVersion + `; charset=utf-8`
    )
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu May 23 15:07:03 UTC 2024
    - 31.1K bytes
    - Viewed (0)
  8. cmd/metrics.go

    				return
    			}
    		}
    
    		contentType := expfmt.Negotiate(r.Header)
    		w.Header().Set("Content-Type", string(contentType))
    
    		enc := expfmt.NewEncoder(w, contentType)
    		for _, mf := range mfs {
    			if err := enc.Encode(mf); err != nil {
    				// client may disconnect for any reasons
    				// we do not have to log this.
    				return
    			}
    		}
    		if closer, ok := enc.(expfmt.Closer); ok {
    			closer.Close()
    		}
    	})
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 16.6K bytes
    - Viewed (0)
  9. pilot/cmd/pilot-agent/status/server_test.go

    		},
    		{
    			name:        "plaintext accept header",
    			contentType: "text/plain; version=0.0.4; charset=utf-8",
    			expected:    expfmt.NewFormat(expfmt.TypeTextPlain),
    		},
    		{
    			name:        "empty accept header",
    			contentType: "",
    			expected:    expfmt.NewFormat(expfmt.TypeTextPlain),
    		},
    	}
    	for _, tt := range cases {
    		t.Run(tt.name, func(t *testing.T) {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu May 23 15:07:03 UTC 2024
    - 42.6K bytes
    - Viewed (0)
  10. cmd/metrics-v2.go

    			return
    		}
    
    		contentType := expfmt.Negotiate(r.Header)
    		w.Header().Set("Content-Type", string(contentType))
    
    		enc := expfmt.NewEncoder(w, contentType)
    		for _, mf := range mfs {
    			if err := enc.Encode(mf); err != nil {
    				// client may disconnect for any reasons
    				// we do not have to log this.
    				return
    			}
    		}
    		if closer, ok := enc.(expfmt.Closer); ok {
    			closer.Close()
    		}
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu Jun 13 22:26:54 UTC 2024
    - 131.9K bytes
    - Viewed (0)
Back to top