Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-5420

Go library should not depend on "testing" in the main package

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 0.14.0, 0.14.1
    • None
    • Go - Library
    • None

    Description

      From https://github.com/jaegertracing/jaeger-client-go/issues/585:

      Describe the bug
      Importing jaeger-client-go adds a dependency on the standard library "testing" package. This is undesirable because production Go programs should not depend on the testing package. In addition to unnecessary bloat, "testing" adds a bunch of command line flags.

      The dependency is coming from https://github.com/apache/thrift/blob/66d897667c451ef6560d89b979b7001c57a3eda6/lib/go/thrift/logger.go#L58

      Recommendation

      Move TestLogger to a sub-module like "testutils". Or remove completely since it's a trivial implementation that can be easily reproduced. Or replace testing.TB argument with a locally defined interface that exposes Errorf function.

      Attachments

        Activity

          People

            Unassigned Unassigned
            Shkuro Yuri Shkuro
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: