-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
GH-45796: [C++] Add integration directory to Meson configuration #45797
base: main
Are you sure you want to change the base?
Conversation
|
|
exc = executable( | ||
'arrow-json-integration-test', | ||
sources: ['json_integration_test.cc'], | ||
dependencies: [arrow_dep, rapidjson_dep, gflags_dep, gtest_dep], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kou there is some inconsistency in the tests here that you alluded to before. Most tests do not define a main
function and therefore use gtest_main_dep
as a dependency. However, this JSON integration test does define its own main, so you have to link just gtest_dep
or you end up with duplicate main symbols.
I don't know the history of this test enough to know if it is intentional that some tests define their own main function while others do not. Does it make sense to have two different dependencies or should we consider removing main from this test module?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that this is intentional. The test is used for an unit test and an integration test with other implementations. If the test is used for an integration test with other implementations, we pass a custom --integration
flag. So we have a custom main()
.
Could you use gtest_dep
not gtest_main_dep
here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good - yes this is already using gtest_dep :-)
cpp/src/arrow/meson.build
Outdated
else | ||
rapidjson_dep = disabler() | ||
endif | ||
rapidjson_dep = dependency('rapidjson', include_type: 'system') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need to remove the if needs_json
check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The integration tests requires RapidJSON but does not require the JSON option to be set, so to get that to work without disabling the integration test I think this need to exist without branching
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK. Then can we use if needs_json or needs_integration
instead of removing this condition?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No problem - done
exc = executable( | ||
'arrow-json-integration-test', | ||
sources: ['json_integration_test.cc'], | ||
dependencies: [arrow_dep, rapidjson_dep, gflags_dep, gtest_dep], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that this is intentional. The test is used for an unit test and an integration test with other implementations. If the test is used for an integration test with other implementations, we pass a custom --integration
flag. So we have a custom main()
.
Could you use gtest_dep
not gtest_main_dep
here?
467fc64
to
1311f6e
Compare
@github-actions crossbow submit *meson |
Revision: 1311f6e Submitted crossbow builds: ursacomputing/crossbow @ actions-d35184ccea
|
@github-actions crossbow submit *meson |
Revision: d10ffa7 Submitted crossbow builds: ursacomputing/crossbow @ actions-c950246fa9
|
Rationale for this change
This continues to add features to the Meson build configuration
What changes are included in this PR?
The integration directory has been added
Are these changes tested?
Yes
Are there any user-facing changes?
No