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

BUG: fence pytest import in tomo testutils #982

Merged
merged 2 commits into from
Apr 20, 2017

Conversation

kohr-h
Copy link
Member

@kohr-h kohr-h commented Apr 19, 2017

Another thing that needs last-minute fix. Import in a new environment without pytest installed would fail.

Copy link
Member

@adler-j adler-j left a comment

Choose a reason for hiding this comment

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

One comment

# Make trivial decorator
from odl.util import OptionalArgDecorator

class ident(OptionalArgDecorator):
Copy link
Member

Choose a reason for hiding this comment

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

Why would we need to overwrite this, shouldn't this be the default implementation?

Copy link
Member Author

Choose a reason for hiding this comment

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

You mean the _wrapper? That would make sense, yes.

Copy link
Member

Choose a reason for hiding this comment

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

Yeah the _wrapper

@kohr-h
Copy link
Member Author

kohr-h commented Apr 20, 2017

Needs approval

Copy link
Member

@adler-j adler-j left a comment

Choose a reason for hiding this comment

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

Well minor fix then go


skip_if_no_astra = pytest.mark.skipif("not odl.tomo.ASTRA_AVAILABLE",
reason='ASTRA not available')
class ident(OptionalArgDecorator):
Copy link
Member

Choose a reason for hiding this comment

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

Why even do this? Instead do

from odl.util import OptionalArgDecorator as ident

Fix in other places as well

Copy link
Member Author

Choose a reason for hiding this comment

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

Ha!

@kohr-h kohr-h merged commit ed66b72 into odlgroup:master Apr 20, 2017
@kohr-h kohr-h deleted the fix_pytest_import branch April 20, 2017 08:26
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.

2 participants