Unified Team Conventions
To unify and enforce all engineers to write in a unified manner, BELLATRIX comes with two static analysis modules for helping you to apply coding standards and item templates for generating standardized page objects.
Enforce Coding Standards and Naming Conventions
BELLATRIX comes with two static analysis modules for applying coding standards.
Coding standards define a programming style. A coding standard does not usually concern itself with wrong or right in a more abstract sense. It is merely a set of rules and guidelines for the formatting of source code.
- Seamless code integration
- Team member integration
- Easy to debug and maintain
- Minimizes communication
- Minimizes performance pitfalls
- Saves money due to fewer man hours
BELLATRIX comes with two modules for helping you apply coding standards in your tests- .editorconfig and StyleCop.
The EditorConfig project consists of a file format for defining coding styles and a collection of text editor plugins that enable editors to read the file format and adhere to defined styles. StyleCop is an open source static code analysis tool from Microsoft which checks C# code for conformance to StyleCop’s recommended coding styles, a subset of Microsoft’s .NET Framework Design Guidelines.
Static analysis integrates with all versions of Visual Studio. It contains a set of style and consistency rules. The code is checked on a build. If some of the rules are violated, warning messages are displayed. This way, you can quickly locate the problems and fix them.
All BELLATRIX projects come with predefined StyleCop and .editorconfig rules: StyleCopeRules.ruleset and .editorconfig. In the files, you can enable and disable particular rules and configure the severity of violations reported by individual rules.
Structured Code Using Page Object Templates
Item templates for generating standardized page objects.
Page objects as any design pattern can be created in various ways and can easily pollute your code if you don’t have a way to enforce all engineers to write them in a unified way. This is done in case each page object is created in a different way – such as one in a single file and another with partial classes or navigation properties – as this can make your code harder to navigate, read, and maintain. To solve this problem, BELLATRIX comes with standardized page object item templates.
Choose one of the 2 iOS page objects templates
- Bellatrix-AssertedIOSPage – contains 3 files- one for actions, one for element declarations and one for assertions (all of them make one-page object).
- Bellatrix-IOSPage – one for actions and one for elements (all of them make a one-page object), don’t have methods for navigation.
The files are generated automatically. This way, all page objects have the same structure, parent classes, properties, usages, etc.