Mir

Merge lp://staging/~mir-team/mir/gmock-1.8-support-part-1 into lp://staging/mir

Proposed by Daniel van Vugt
Status: Merged
Approved by: Daniel van Vugt
Approved revision: no longer in the source branch.
Merged at revision: 3849
Proposed branch: lp://staging/~mir-team/mir/gmock-1.8-support-part-1
Merge into: lp://staging/mir
Diff against target: 1121 lines (+139/-119)
36 files modified
tests/acceptance-tests/test_client_cookie.cpp (+3/-3)
tests/acceptance-tests/test_client_input.cpp (+8/-5)
tests/acceptance-tests/test_client_library.cpp (+8/-6)
tests/acceptance-tests/test_client_platform_operation.cpp (+1/-1)
tests/acceptance-tests/test_client_scaling.cpp (+1/-1)
tests/acceptance-tests/test_display_configuration.cpp (+1/-1)
tests/acceptance-tests/test_surface_raise.cpp (+1/-1)
tests/integration-tests/test_buffer_scheduling.cpp (+2/-2)
tests/integration-tests/test_stale_frames.cpp (+3/-3)
tests/mir_test/test_dispatchable.cpp (+4/-3)
tests/unit-tests/client/test_client_buffer_stream.cpp (+2/-2)
tests/unit-tests/client/test_client_display_conf.cpp (+1/-1)
tests/unit-tests/client/test_protobuf_rpc_channel.cpp (+3/-3)
tests/unit-tests/client/test_screencast_stream.cpp (+2/-2)
tests/unit-tests/client/test_stream_transport.cpp (+29/-22)
tests/unit-tests/compositor/test_screencast_display_buffer.cpp (+1/-1)
tests/unit-tests/frontend/test_protobuf_buffer_packer.cpp (+3/-3)
tests/unit-tests/frontend/test_session_mediator.cpp (+8/-6)
tests/unit-tests/input/test_x11_platform.cpp (+1/-1)
tests/unit-tests/platforms/android/client/test_buffer.cpp (+2/-2)
tests/unit-tests/platforms/android/server/test_device_detection.cpp (+1/-1)
tests/unit-tests/platforms/android/server/test_display.cpp (+6/-6)
tests/unit-tests/platforms/android/server/test_hwc_configuration.cpp (+5/-5)
tests/unit-tests/platforms/android/server/test_hwc_device.cpp (+11/-11)
tests/unit-tests/platforms/android/server/test_hwc_layerlist.cpp (+12/-10)
tests/unit-tests/platforms/android/server/test_hwc_wrapper.cpp (+2/-2)
tests/unit-tests/platforms/android/server/test_output_builder.cpp (+1/-1)
tests/unit-tests/platforms/mesa/client/test_client_buffer.cpp (+1/-1)
tests/unit-tests/platforms/mesa/client/test_client_platform.cpp (+3/-1)
tests/unit-tests/platforms/mesa/kms-utils/test_drm_mode_resources.cpp (+4/-3)
tests/unit-tests/platforms/mesa/kms/test_display_configuration.cpp (+2/-2)
tests/unit-tests/platforms/mesa/kms/test_ipc_operations.cpp (+1/-1)
tests/unit-tests/platforms/nested/test_buffer.cpp (+1/-1)
tests/unit-tests/platforms/nested/test_nested_display_configuration.cpp (+2/-2)
tests/unit-tests/test_flags.cpp (+1/-1)
tests/unit-tests/test_shared_library_prober.cpp (+2/-2)
To merge this branch: bzr merge lp://staging/~mir-team/mir/gmock-1.8-support-part-1
Reviewer Review Type Date Requested Status
Chris Halse Rogers Approve
Mir CI Bot continuous-integration Approve
Review via email: mp+311708@code.staging.launchpad.net

Commit message

Start fixing signed/unsigned mismatches that break gcc-6 with
gmock 1.8 (now in zesty).

Apparently RAOF's fix for bug 1644062 no longer needs these fixes. I'm not sure how he achieved that, but this branch is still worth keeping.

To post a comment you must log in.
Revision history for this message
Mir CI Bot (mir-ci-bot) wrote :

PASSED: Continuous integration, rev:3849
https://mir-jenkins.ubuntu.com/job/mir-ci/2269/
Executed test runs:
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-mir/2939
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-0-fetch/3004
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/2996
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial+overlay/2996
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=yakkety/2996
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=yakkety/2968
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=yakkety/2968/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial+overlay/2968
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial+overlay/2968/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=yakkety/2968
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=yakkety/2968/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/2968
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/2968/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/2968
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/2968/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial+overlay/2968
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial+overlay/2968/artifact/output/*zip*/output.zip

Click here to trigger a rebuild:
https://mir-jenkins.ubuntu.com/job/mir-ci/2269/rebuild

review: Approve (continuous-integration)
Revision history for this message
Mir CI Bot (mir-ci-bot) wrote :

PASSED: Continuous integration, rev:3851
https://mir-jenkins.ubuntu.com/job/mir-ci/2273/
Executed test runs:
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-mir/2944
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-0-fetch/3009
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/3001
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial+overlay/3001
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-1-sourcepkg/release=yakkety/3001
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=yakkety/2973
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=clang,platform=mesa,release=yakkety/2973/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial+overlay/2973
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=xenial+overlay/2973/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=yakkety/2973
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=amd64,compiler=gcc,platform=mesa,release=yakkety/2973/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/2973
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=cross-armhf,compiler=gcc,platform=android,release=vivid+overlay/2973/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/2973
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=android,release=vivid+overlay/2973/artifact/output/*zip*/output.zip
    SUCCESS: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial+overlay/2973
        deb: https://mir-jenkins.ubuntu.com/job/build-2-binpkg-mir/arch=i386,compiler=gcc,platform=mesa,release=xenial+overlay/2973/artifact/output/*zip*/output.zip

Click here to trigger a rebuild:
https://mir-jenkins.ubuntu.com/job/mir-ci/2273/rebuild

review: Approve (continuous-integration)
Revision history for this message
Chris Halse Rogers (raof) wrote :

+#define ssizeof(X) (static_cast<ssize_t>(sizeof(X)))

Not madly in love with the #define. It looks like this could be improved with a TransferredExactly() MATCHER_P, so that all the various calls go:
EXPECT_THAT(write(...), TransferredExactly(sizeof(dummy));
or
EXPECT_THAT(write(...), TransferredExactly(data.size());

For bonus points you could describe errors with strerror!

Looks reasonable.

review: Approve
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

A custom matcher sounds like it would need more domain knowledge than macros and "ssizeof" would, so I would lean away from that.

strerror I would also stay away from in tests because its answers will vary between locales.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches