Skip to content
This repository has been archived by the owner on Jan 26, 2024. It is now read-only.

Add mocktracer library. #47

Merged
merged 35 commits into from
Jan 15, 2018
Merged

Add mocktracer library. #47

merged 35 commits into from
Jan 15, 2018

Conversation

rnburn
Copy link
Contributor

@rnburn rnburn commented Jan 8, 2018

This PR adds a mocktracer library similar in design to that included in the other OpenTracing language bindings (for example, Go). It will make it easier for users to test their instrumentation code.

Additionally, I switched all the testing code to use catch2 since it was outgrowing the existing testing framework.

Copy link
Contributor

@heyleke heyleke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would also make the opentracing_mocktracer configurable, so for e.g. embedded systems you can skip the build of the mocktracer
forget this comment, I see it is added in one of the commits

@rnburn
Copy link
Contributor Author

rnburn commented Jan 11, 2018

@yurishkuro, @isaachier -- are you guys ok with this PR? It doesn't make any changes to the actual API.

install(TARGETS opentracing_mocktracer EXPORT OpenTracingTargets
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib)
endif(BUILD_SHARED_LIBS)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not asking you to change this, just an FYI, the CMake docs seem to be wrong about this point. The expression need not/should not be included in endif arguments. None of the CMake modules follow that pattern.

include(CTest)
if(BUILD_TESTING)
add_subdirectory(test)
endif()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, great work on the CMake stuff :). Very few projects get this right.

@rnburn rnburn merged commit 29dc428 into opentracing:master Jan 15, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants