Skip to content

Conversation

@fabianvf
Copy link
Member

  • Rename get_exception to get_exception_class, to match corresponding change in other helpers
  • Remove apiVersion from request body, fixes stateful set api mismatch errors.

Copy link
Contributor

@detiber detiber left a comment

Choose a reason for hiding this comment

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

apiVerson is an optional field, and since we are mapping the version of the resource to the version of the API we are calling into three shouldn't be an issue with not specifying it here.

@fabianvf
Copy link
Member Author

I'll add some tests for stateful sets and replicasets tomorrow as well

@fabianvf fabianvf force-pushed the stateful-set-fixes branch from 09a5971 to 7fb3e3d Compare April 11, 2017 18:52
version_mismatch = pytest.mark.skipif(
float(pytest.config.getoption('--openshift-version')) < 1.5,
reason='This API is not supported in openshift versions < 1.5'
)
Copy link
Contributor

Choose a reason for hiding this comment

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

Instead of defining version_mismatch here, it might be better to move this to test/functional/conftest.py and rename it to version_gte_1_5. Then it would be available for other tests as well.

@fabianvf fabianvf force-pushed the stateful-set-fixes branch 3 times, most recently from b1b1fbd to 370f9e4 Compare April 12, 2017 18:53
@fabianvf fabianvf force-pushed the stateful-set-fixes branch from 370f9e4 to 9beb266 Compare April 12, 2017 19:04
@fabianvf
Copy link
Member Author

@detiber ready for review




def version_mismatch(lowest_version=None, highest_version=None, skip_latest=False):
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm probably missing something, but I'm not seeing if this is used anywhere.

Copy link
Member Author

Choose a reason for hiding this comment

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

Whoops, totally thought I'd removed that. Copy paste error, my bad.

@detiber detiber merged commit dc84254 into openshift:master Apr 14, 2017
fabianvf added a commit to fabianvf/openshift-restclient-python that referenced this pull request Sep 1, 2017
* No longer pass API version in request body
* add tests for replica and stateful sets
* add test for horizontal pod autoscaler
* add skip condition on version mismatch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants