Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
dist: bionic
sudo: false
language: python
before_install:
# for rpm-py-installer
- sudo apt-get install -y rpm
install: pip install tox
matrix:
include:
Expand Down
3 changes: 1 addition & 2 deletions pubtools/pulplib/_impl/model/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ class DetachedException(Exception):


class InvalidDataException(Exception):
"""Raised if raw Pulp data appears to be invalid (i.e. not matching expected schema).
"""
"""Raised if raw Pulp data appears to be invalid (i.e. not matching expected schema)."""


class PulpObject(object):
Expand Down
10 changes: 7 additions & 3 deletions tests/model/assertions.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,13 @@ def assert_model_fields(model_object):
if value is not None:
# These tests only valid on non-None value.

assert isinstance(value, field.type), (
"%s.%s should be a %s but is not: %s"
% (klass.__name__, field.name, field.type.__name__, model_object)
assert isinstance(
value, field.type
), "%s.%s should be a %s but is not: %s" % (
klass.__name__,
field.name,
field.type.__name__,
model_object,
)

if field.type is list:
Expand Down