Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-analytics-data-api-client
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
edx-analytics-data-api-client
Commits
d582df72
Commit
d582df72
authored
Oct 23, 2014
by
Clinton Blackburn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added enrollment mode constants
parent
dc0d6f0d
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
18 additions
and
10 deletions
+18
-10
analyticsclient/constants/education_level.py
+0
-2
analyticsclient/constants/enrollment_modes.py
+6
-0
analyticsclient/constants/gender.py
+0
-2
analyticsclient/tests/test_helpers.py
+11
-5
setup.py
+1
-1
No files found.
analyticsclient/constants/education_level.py
View file @
d582df72
""" Enrollment education types. """
NONE
=
'none'
NONE
=
'none'
OTHER
=
'other'
OTHER
=
'other'
PRIMARY
=
'primary'
PRIMARY
=
'primary'
...
...
analyticsclient/constants/enrollment_modes.py
0 → 100644
View file @
d582df72
AUDIT
=
u'audit'
HONOR
=
u'honor'
PROFESSIONAL
=
u'professional'
VERIFIED
=
u'verified'
ALL
=
[
AUDIT
,
HONOR
,
PROFESSIONAL
,
VERIFIED
]
analyticsclient/constants/gender.py
View file @
d582df72
""" Enrollment gender types. """
FEMALE
=
'female'
FEMALE
=
'female'
MALE
=
'male'
MALE
=
'male'
OTHER
=
'other'
OTHER
=
'other'
...
...
analyticsclient/tests/test_helpers.py
View file @
d582df72
from
unittest
import
TestCase
from
unittest
import
TestCase
from
analyticsclient.constants
import
activity_type
,
demographic
,
education_level
,
gender
from
analyticsclient.constants
import
activity_type
,
demographic
,
education_level
,
gender
,
enrollment_modes
class
HelperTests
(
TestCase
):
class
HelperTests
(
TestCase
):
...
@@ -7,18 +7,18 @@ class HelperTests(TestCase):
...
@@ -7,18 +7,18 @@ class HelperTests(TestCase):
Basic checks for typos.
Basic checks for typos.
"""
"""
def
test_activity_type
(
self
):
def
test_activity_type
s
(
self
):
self
.
assertEqual
(
'any'
,
activity_type
.
ANY
)
self
.
assertEqual
(
'any'
,
activity_type
.
ANY
)
self
.
assertEqual
(
'attempted_problem'
,
activity_type
.
ATTEMPTED_PROBLEM
)
self
.
assertEqual
(
'attempted_problem'
,
activity_type
.
ATTEMPTED_PROBLEM
)
self
.
assertEqual
(
'played_video'
,
activity_type
.
PLAYED_VIDEO
)
self
.
assertEqual
(
'played_video'
,
activity_type
.
PLAYED_VIDEO
)
self
.
assertEqual
(
'posted_forum'
,
activity_type
.
POSTED_FORUM
)
self
.
assertEqual
(
'posted_forum'
,
activity_type
.
POSTED_FORUM
)
def
test_demographic
(
self
):
def
test_demographic
s
(
self
):
self
.
assertEqual
(
'birth_year'
,
demographic
.
BIRTH_YEAR
)
self
.
assertEqual
(
'birth_year'
,
demographic
.
BIRTH_YEAR
)
self
.
assertEqual
(
'education'
,
demographic
.
EDUCATION
)
self
.
assertEqual
(
'education'
,
demographic
.
EDUCATION
)
self
.
assertEqual
(
'gender'
,
demographic
.
GENDER
)
self
.
assertEqual
(
'gender'
,
demographic
.
GENDER
)
def
test_education_
type
(
self
):
def
test_education_
levels
(
self
):
self
.
assertEqual
(
'none'
,
education_level
.
NONE
)
self
.
assertEqual
(
'none'
,
education_level
.
NONE
)
self
.
assertEqual
(
'other'
,
education_level
.
OTHER
)
self
.
assertEqual
(
'other'
,
education_level
.
OTHER
)
self
.
assertEqual
(
'primary'
,
education_level
.
PRIMARY
)
self
.
assertEqual
(
'primary'
,
education_level
.
PRIMARY
)
...
@@ -29,8 +29,14 @@ class HelperTests(TestCase):
...
@@ -29,8 +29,14 @@ class HelperTests(TestCase):
self
.
assertEqual
(
'masters'
,
education_level
.
MASTERS
)
self
.
assertEqual
(
'masters'
,
education_level
.
MASTERS
)
self
.
assertEqual
(
'doctorate'
,
education_level
.
DOCTORATE
)
self
.
assertEqual
(
'doctorate'
,
education_level
.
DOCTORATE
)
def
test_gender
_type
(
self
):
def
test_gender
s
(
self
):
self
.
assertEqual
(
'female'
,
gender
.
FEMALE
)
self
.
assertEqual
(
'female'
,
gender
.
FEMALE
)
self
.
assertEqual
(
'male'
,
gender
.
MALE
)
self
.
assertEqual
(
'male'
,
gender
.
MALE
)
self
.
assertEqual
(
'other'
,
gender
.
OTHER
)
self
.
assertEqual
(
'other'
,
gender
.
OTHER
)
self
.
assertEqual
(
'unknown'
,
gender
.
UNKNOWN
)
self
.
assertEqual
(
'unknown'
,
gender
.
UNKNOWN
)
def
test_enrollment_modes
(
self
):
self
.
assertEqual
(
'audit'
,
enrollment_modes
.
AUDIT
)
self
.
assertEqual
(
'honor'
,
enrollment_modes
.
HONOR
)
self
.
assertEqual
(
'professional'
,
enrollment_modes
.
PROFESSIONAL
)
self
.
assertEqual
(
'verified'
,
enrollment_modes
.
VERIFIED
)
setup.py
View file @
d582df72
...
@@ -2,7 +2,7 @@ from distutils.core import setup
...
@@ -2,7 +2,7 @@ from distutils.core import setup
setup
(
setup
(
name
=
'edx-analytics-data-api-client'
,
name
=
'edx-analytics-data-api-client'
,
version
=
'0.
2.4
'
,
version
=
'0.
3.0
'
,
packages
=
[
'analyticsclient'
],
packages
=
[
'analyticsclient'
],
url
=
'https://github.com/edx/edx-analytics-data-api-client'
,
url
=
'https://github.com/edx/edx-analytics-data-api-client'
,
description
=
'Client used to access edX analytics data warehouse'
,
description
=
'Client used to access edX analytics data warehouse'
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment