Skip to content
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

Create coverage report in Travis. #102

Merged
merged 3 commits into from Sep 17, 2015
Merged

Create coverage report in Travis. #102

merged 3 commits into from Sep 17, 2015

Conversation

mauritsvanrees
Copy link
Sponsor Member

This should solve issue #93, in a slightly different way than my last proposal there.

Generate nosetests script also under the 'test' name. Then
bin/createcoverage works.

In Travis call the new correct script names:

  • The new bin/test is the old bin/nosetests.
  • The new bin/test-plone_addon is the old bin/test.

Created bin/alltests script. This runs bin/test, and the two
test-plone_addon scripts. We could call that in Travis too.

Added initial simple test to show coverage in hooks.py.

@mauritsvanrees
Copy link
Sponsor Member Author

Travis is expected to fail, see a different pull request for the plone5 /plone.app.event stuff.
But after it is done, coveralls should hopefully get some data.

@mauritsvanrees
Copy link
Sponsor Member Author

Yes! The Plone 5 builds work and they pass info to coveralls.
The Plone 4 builds fail, so they do not contact coveralls, but we know that they fail.
Ready for review.

- bin/test
- bin/createcoverage
Copy link
Sponsor Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think createcoverage should run in the after_success sestion. This is not a test.

Copy link
Sponsor Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Problem is that it then runs after bin/test-plone_addon, which leaves behind a test.plone_addon directory that the nosetests then also get run on, causing ImportErrors. Ah, but of course this directory only gets left behind when the command fails, so then there is no need to call createcoverage. I will move it.

In that case, we should move createcoverage in the generated package too. I will move that too.

@tisto
Copy link
Sponsor Member

tisto commented Sep 17, 2015

@mauritsvanrees would you prefer to fix the Plone 4 build in this branch or shall we merge first?

Generate nosetests script also under the 'test' name.  Then
bin/createcoverage works.

In Travis call the new correct script names:

- The new bin/test is the old bin/nosetests.
- The new bin/test-plone_addon is the old bin/test.

Created bin/alltests script.  This runs bin/test, and the two
test-plone_addon scripts.  We could call that in Travis too.

Added initial simple test to show coverage in hooks.py.
@mauritsvanrees
Copy link
Sponsor Member Author

Plone 4 fixes have been merged to master.
I have fixed the issues you raised on this pull request, rebased on master, and did a force push, cleaning things up. Let's see what Travis and Coveralls think of it.

@mauritsvanrees
Copy link
Sponsor Member Author

Two minor changes added. Let me stop now. :-)

@tisto
Copy link
Sponsor Member

tisto commented Sep 17, 2015

Thanks so much @mauritsvanrees! Great work! Will do a release soon.

tisto added a commit that referenced this pull request Sep 17, 2015
Create coverage report in Travis.
@tisto tisto merged commit 74aa609 into master Sep 17, 2015
@tisto tisto deleted the maurits-coverage branch September 17, 2015 13:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants