codeclimate/test-reporter

View on GitHub
upload/uploader.go

Summary

Maintainability
A
1 hr
Test Coverage

Method Uploader.doRequest has 7 return statements (exceeds 4 allowed).
Open

func (u Uploader) doRequest(in io.Reader, url string) (*http.Response, error) {
    c := http.Client{
        Transport: u.newTransport(),
        Timeout:   30 * time.Second,
    }
Severity: Major
Found in upload/uploader.go - About 45 mins to fix

    Method Uploader.Upload has 7 return statements (exceeds 4 allowed).
    Open

    func (u Uploader) Upload() error {
        if u.ReporterID == "" {
            return errors.New("you must supply a CC_TEST_REPORTER_ID ENV variable or pass it via the -r flag")
        }
    
    
    Severity: Major
    Found in upload/uploader.go - About 45 mins to fix

      exported method Uploader.SendBatches should have comment or be unexported
      Open

      func (u Uploader) SendBatches(rep *TestReport, url string) error {
      Severity: Minor
      Found in upload/uploader.go by golint

      exported type Uploader should have comment or be unexported
      Open

      type Uploader struct {
      Severity: Minor
      Found in upload/uploader.go by golint

      exported method Uploader.Upload should have comment or be unexported
      Open

      func (u Uploader) Upload() error {
      Severity: Minor
      Found in upload/uploader.go by golint

      exported type ErrConflict should have comment or be unexported
      Open

      type ErrConflict struct {
      Severity: Minor
      Found in upload/uploader.go by golint

      exported method Uploader.TransformPostBatchURL should have comment or be unexported
      Open

      func (u Uploader) TransformPostBatchURL(rawURL string) (string, error) {
      Severity: Minor
      Found in upload/uploader.go by golint

      There are no issues that match your filters.

      Category
      Status