Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add googletest to write unit tests for pi.proto #49

Merged
merged 1 commit into from
Oct 31, 2016
Merged

Conversation

antoninbas
Copy link
Member

Added it as a submodule rather than copying whole code, but using my own
makefile. Only compiled when running 'make check' and if configure was
run with '--with-proto' (since we are only going to write unit tests for
pi.proto and proto frontend at first).

Added it as a submodule rather than copying whole code, but using my own
makefile. Only compiled when running 'make check' and if configure was
run with '--with-proto' (since we are only going to write unit tests for
pi.proto and proto frontend at first).
@antoninbas
Copy link
Member Author

@teverman in case there is any objection from you

@@ -43,6 +43,9 @@ AS_IF([test "$with_proto" = yes && test "$want_fe_cpp" = no], [
AM_CONDITIONAL([WITH_FE_CPP], [test "$want_fe_cpp" = yes])

AM_CONDITIONAL([WITH_PROTO], [test "$with_proto" = yes])
# may add other conditions later for GTEST to be compiled if we use GTEST
# somewhere else
AM_CONDITIONAL([WITH_GTEST], [test "$with_proto" = yes])
Copy link

Choose a reason for hiding this comment

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

with_gtest?

Copy link
Member Author

Choose a reason for hiding this comment

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

no, with_proto
the comment explains that if googletest is used for something else than testing pi.proto, another condition can be added; right now it is only used for pi.proto so we only build it then

Copy link
Contributor

@teverman teverman left a comment

Choose a reason for hiding this comment

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

We already have googletest elsewhere in our build environment. I'm wondering if this can be set up in such a way that it can be a submodule if and only if needed. We may also be able to direct appropriately at configure or compile time. FYI only, no need to change anything now,

@antoninbas
Copy link
Member Author

@teverman thanks for the feedback. I'll merge this so I can start writing tests. I'll also open an issue so that we can later update configure.ac to use a pre-existing googletest.
right now this is modeled after the gRPC public repository
note that the current code won't install any googletest code, it is only built and used for unit tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants