如何使用gopkg安装ginkgo和gomega?

时间:2018-06-29 06:01:30

标签: go ginkgo gomega

我正在尝试使用ginkgo安装gomegagopkg。 它抛出以下错误:

src/gopkg.in/onsi/ginkgo.v1/ginkgo_dsl.go:24:2: use of internal package not allowed
src/gopkg.in/onsi/ginkgo.v1/ginkgo_dsl.go:25:2: use of internal package not allowed
src/gopkg.in/onsi/ginkgo.v1/ginkgo_dsl.go:26:2: use of internal package not allowed
src/gopkg.in/onsi/ginkgo.v1/ginkgo_dsl.go:27:2: use of internal package not allowed
src/gopkg.in/onsi/ginkgo.v1/ginkgo_dsl.go:28:2: use of internal package not allowed
src/gopkg.in/onsi/ginkgo.v1/ginkgo_dsl.go:29:2: use of internal package not allowed

src/gopkg.in/onsi/gomega.v1/gomega_dsl.go:21:2: use of internal package not allowed
src/gopkg.in/onsi/gomega.v1/gomega_dsl.go:22:2: use of internal package not allowed
src/gopkg.in/onsi/gomega.v1/gomega_dsl.go:23:2: use of internal package not allowed

1 个答案:

答案 0 :(得分:0)

据我了解,这不是致命错误。即使收到相同的警告消息,我也可以使用ginkgo下载gomegagopkg。简要查看源代码可发现gomega_dsl.goginkgo_dsl.gointernal子目录导入代码。我不明白为什么这应该是一个问题。尽管有这些警告,仍使软件包正常工作。