~raof/mir/hack-hack-hack-remove-a-hack

« back to all changes in this revision

Viewing changes to tests/unit-tests/graphics/android/test_internal_client_interpreter.cpp

  • Committer: Tarmac
  • Author(s): Kevin DuBois
  • Date: 2013-11-26 19:06:17 UTC
  • mfrom: (1244.3.9 fix-1253486)
  • Revision ID: tarmac-20131126190617-42i8elpsm8exqbzj
clean up unit tests (ran under android) so there's no uninitialized value 
errors for the unit-tests/graphics/android tests, and make the tests run 
without gmock warning, unexpected call errors. (LP: #1172184). Fixes: https://bugs.launchpad.net/bugs/1172184, https://bugs.launchpad.net/bugs/1253486.

Approved by PS Jenkins bot, Alan Griffiths, Daniel van Vugt.

Show diffs side-by-side

added added

removed removed

Lines of Context:
48
48
    {
49
49
        using namespace testing;
50
50
        sz = geom::Size{4, 23};
51
 
        mock_cache = std::make_shared<mtd::MockInterpreterResourceCache>();
52
 
        mock_surface = std::make_shared<MockInternalSurface>();
53
 
        mock_buffer = std::make_shared<mtd::MockBuffer>();
54
 
        stub_native_buffer = std::make_shared<mtd::StubAndroidNativeBuffer>();
 
51
        mock_cache = std::make_shared<NiceMock<mtd::MockInterpreterResourceCache>>();
 
52
        mock_surface = std::make_shared<NiceMock<MockInternalSurface>>();
 
53
        mock_buffer = std::make_shared<NiceMock<mtd::MockBuffer>>();
 
54
        stub_native_buffer = std::make_shared<mtd::StubAndroidNativeBuffer>(); 
55
55
 
56
56
        ON_CALL(*mock_surface, swap_buffers(_))
57
57
            .WillByDefault(SetArg<0>(mock_buffer));