2013:getting_legacy_c_c_under_test
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
2013:getting_legacy_c_c_under_test [2012/10/31 13:36] – created jonjagger | 2013:getting_legacy_c_c_under_test [2016/06/11 14:05] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 2: | Line 2: | ||
Back to [[conference: | Back to [[conference: | ||
\\ | \\ | ||
- | **Title**: | + | **Title**: |
**Proposer**: | **Proposer**: | ||
- | **Type**: | + | **Proposer**: |
- | **Duration**: | + | **Type**: |
- | **Description**: | + | **Duration**: |
+ | **Description**: | ||
\\ | \\ | ||
+ | C++ has a rich set of libraries which support the creation of fake and mock objects (i. e., test doubles). The overwhelming part of them are based on subtype polymorphism by inheriting the test doubles from a common base class to be able to inject them as well as the real objects into the system under test (SUT). This has the known disadvantages of decreased run-time performance and the software engineering issues that come along with inheritance like tight coupling and fragility. Beside this, these libraries often lack an integration into an IDE.\\ | ||
+ | \\ | ||
+ | We at the Institute for Software, are eager to improve this situation and address this with Mockator Pro, a new mock object library and a supporting Eclipse C++ Development Tooling (CDT) plug-in that assists the user in creating test doubles. Mockator Pro both supports C++03 and the new standard C++11.\\ | ||
+ | \\ | ||
+ | Beside the mentioned subtype polymorphism - which is supported by a new „extract base class“ refactoring - Mockator Pro offers static polymorphism to inject the test double into the SUT via template parameters. The test doubles are realized as local classes, therefore located in the same function as the unit test code, leading to an increased locality that makes it easier to keep them in sync. A third form of mocking is the use of link seams which allow us to replace existing functions with our own test double functions without touching the SUT.\\ | ||
+ | \\ | ||
+ | This talk shows how useful Mockator Pro can be for getting rid of fixed dependencies in your code base by extracting template parameters and base classes. You will see that Mockator Pro is able to generate code for test doubles that allows you to track if your SUT is properly using them. Our static code analysis checkers recognize missing member functions, constructors and operators in the injected test doubles and provide default implementations for them through Eclipse quick fixes.\\ | ||
+ | \\ | ||
+ | Beside a practical session with many code examples we will also give an introduction into testing with mock objects in general and compare Mockator Pro to other well-known mock object libraries. Additionally, | ||
+ | \\ | ||
+ | Keywords: C++, mock object, Eclipse, static polymorphism, | ||
+ | \\ | ||
+ | Roger: Yes from me\\ | ||
+ | Asti: yes - Peter is always a great speaker \\ | ||
2013/getting_legacy_c_c_under_test.1351690572.txt.gz · Last modified: 2016/06/11 14:05 (external edit)