Skip to content

"notest" comment does not work in my setup #31

Description

@lixvbnet

Hi, it's great to find this tool.
But after trying for hours, I'm still having trouble to have it work.

pac.go: (you can see I have tried adding "notest" everywhere..

package newpac

import "fmt"

func max(a, b int) int {
	if a > b {
		// notest
		fmt.Println("gt") // notest
		return a          // notest
	} else {
		fmt.Println("lt")
		return b
	}
}

pac_test.go

package newpac

import (
	"fmt"
	"testing"
)

func Test1(t *testing.T) {
	res := max(3, 5)
	fmt.Println(res)
}

Run command:

go install github.com/dave/courtney@latest
go install github.com/axw/gocov/gocov@latest
go install github.com/AlekSi/gocov-xml@latest
go install github.com/matm/gocov-html@latest

courtney -v -o c.out && gocov convert c.out | gocov-html > C.html 

But still getting same report as before,
image

My Go version is 1.17, and I have downgraded to 1.16 but still got same result. Am I missing anything?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions