Commit 39950e16 by Clinton Blackburn

PEP 257 fixes

Change-Id: Ic109cd838db665d403d6c2057d5ecd973c8ff550
parent 835dd1ec
......@@ -19,4 +19,4 @@ quality:
pylint --rcfile=.pylintrc $(PACKAGE)
# Ignore module level docstrings and all test files
pep257 --ignore=D100 --match='(?!test).*py' $(PACKAGE)
pep257 --ignore=D100,D203 --match='(?!test).*py' $(PACKAGE)
"""
Course activity types.
"""
""" Course activity types. """
ANY = 'any'
ATTEMPTED_PROBLEM = 'attempted_problem'
......
......@@ -13,12 +13,13 @@ log = logging.getLogger(__name__)
class Client(object):
"""
Analytics API client
Analytics API client.
The instance has attributes `status` and `courses` that provide access to instances of
:class: `~analyticsclient.status` and :class: `~analyticsclient.course`. This is the preferred (and only supported)
way to get access to those classes and their methods.
"""
def __init__(self, base_url, auth_token=None):
"""
Initialize the client.
......
......@@ -2,9 +2,7 @@ import analyticsclient.activity_type as at
class Course(object):
"""
Course-related analytics.
"""
""" Course-related analytics. """
def __init__(self, client, course_id):
"""
......
"""
Course demographics
"""
""" Course demographics. """
BIRTH_YEAR = 'birth_year'
EDUCATION = 'education'
......
......@@ -2,10 +2,7 @@ from analyticsclient.exceptions import ClientError
class Status(object):
"""
API server status.
"""
""" API server status. """
def __init__(self, client):
"""
......
......@@ -4,11 +4,10 @@ from analyticsclient.client import Client
class ClientTestCase(TestCase):
"""
Base class for client-related tests.
"""
""" Base class for client-related tests. """
def setUp(self):
""" Configure Client. """
self.api_url = 'http://localhost:9999/api/v0'
self.client = Client(self.api_url)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment