New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unittest actions #272
Comments
It's kind of weird getting used to class PathTest extends TestCase {
#[@test, @action(class= 'unittest.action.IsPlatform', args= array('WIN'))]
public function leading_backslash_yields_current_drive() {
// ...
}
} Unfortunately, it's much longer... |
Instead of this [@test, @action(class= 'unittest.action.IsPlatform', args= array('WIN'))] ...we could now - since xp-framework/xp-framework#328 - also use: [@test, @action(new IsPlatform('WIN'))] ...and Will rewrite the RFC accordingly 🕐 |
|
✅ Set status to accepted. |
Merged successfully. |
…tegration tests # See xp-framework/rfc#272
Added possibility for multiple actions by supplying an array to #[@action([
# new \unittest\action\ExtensionAvailable('mssql'),
# new \unittest\action\IsPlatform('WIN')
#])]
class MsSqlWindowsDriverTest extends TestCase {
// ...
} |
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
…s= ...) # See xp-framework/rfc#272 (comment) # Made possible by xp-framework/xp-framework#328
…tegration tests # See xp-framework/rfc#272
Scope of Change
Unittest actions will be introduced to be able to create reusable beforeClass / afterClass / setUp / tearDown handling.
Rationale
Repeated code inside the beforeClass / afterClass / setUp / tearDown methods, like
Functionality
Usage
For all tests of a given class:
For only a single test:
Example implementation
The test action itself:
Security considerations
Speed impact
Dependencies
Related documents
http://nunit.org/index.php?p=actionAttributes&r=2.6.2
https://github.com/junit-team/junit/wiki/4.12-release-notes#pull-request-552-stopwatch-rule
The text was updated successfully, but these errors were encountered: