Skip to content

PHPUnit doesn't report all risky tests#8

Closed
PVince81 wants to merge 3 commits into
masterfrom
phpunit-weirdo1
Closed

PHPUnit doesn't report all risky tests#8
PVince81 wants to merge 3 commits into
masterfrom
phpunit-weirdo1

Conversation

@PVince81

@PVince81 PVince81 commented Dec 6, 2016

Copy link
Copy Markdown
Contributor

@DeepDiver1975 see the two test classes CustomGroupsBackendTest and CustomGroupsManagerTest.

Each class has one empty test class.

When you run the tests with make test-php (or cd tests/unit; phpunit), it will only report one risky test:

1) OCA\CustomGroups\Tests\unit\CustomGroupsManagerTest::testEmpty
This test did not perform any assertions

/home/vincent/.composer/vendor/phpunit/phpunit/src/TextUI/Command.php:149
/home/vincent/.composer/vendor/phpunit/phpunit/src/TextUI/Command.php:100

OK, but incomplete, skipped, or risky tests!
Tests: 24, Assertions: 104, Risky: 1.

For some reason any risky tests inside of the first class alphabetically CustomGroupsBackendTest are ignored.

@CLAassistant

CLAassistant commented Dec 6, 2016

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.

@PVince81

PVince81 commented Dec 6, 2016

Copy link
Copy Markdown
Contributor Author

(ignore the failing test, you can make it disappear by checking out the branch group-displaynames in core)

@PVince81

PVince81 commented Dec 6, 2016

Copy link
Copy Markdown
Contributor Author

Raised in core: owncloud/core#26772

@DeepDiver1975

Copy link
Copy Markdown
Member

(ignore the failing test, you can make it disappear by checking out the branch group-displaynames in core)

set the branch name in travis.yml - https://github.com/owncloud/customgroups/pull/8/files#diff-354f30a63fb0907d4ad57269548329e3R9

@PVince81

PVince81 commented Dec 6, 2016

Copy link
Copy Markdown
Contributor Author

@DeepDiver1975 not needed, I'd rather have the core branch merged soon...

@PVince81

PVince81 commented Dec 6, 2016

Copy link
Copy Markdown
Contributor Author

Okay, I pushed the setting about empty tests to the app branch: #1

Thanks!

@PVince81 PVince81 closed this Dec 6, 2016
@PVince81
PVince81 deleted the phpunit-weirdo1 branch December 6, 2016 12:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants