~ken-vandine/indicator-transfer/ual_api_change

« back to all changes in this revision

Viewing changes to tests/controller-mock.h

  • Committer: CI Train Bot
  • Author(s): Renato Araujo Oliveira Filho
  • Date: 2015-08-19 19:17:06 UTC
  • mfrom: (29.6.11 add-plugins-fix-model-clear)
  • Revision ID: ci-train-bot@canonical.com-20150819191706-k1jnor3lh4n26zax
Added 'clear' function into the Source interface.
Call 'Source.clear' in the 'Controller.clear_all' function.
Does not keep a separated copy of source model inside of the Controller class.
Changed the return of 'Source.get_model()' to const.
Update unit tests.
Approved by: Charles Kerr, PS Jenkins bot

Show diffs side-by-side

added added

removed removed

Lines of Context:
31
31
class MockController: public Controller
32
32
{
33
33
public:
34
 
  MockController(const std::shared_ptr<MutableModel>& model, 
35
 
                 const std::shared_ptr<Source>& source):
36
 
    Controller(model, source) {}
 
34
  explicit MockController(const std::shared_ptr<Source>& source):
 
35
    Controller(source) {}
37
36
 
38
37
  MOCK_METHOD0(pause_all, void());
39
38
  MOCK_METHOD0(resume_all, void());