Merge pull request #18800 from edx/jmbowman/TE-2646
TE-2646 Use headless Chrome for a11y tests
This commit is contained in:
@@ -179,7 +179,7 @@ from third_party_auth import provider, pipeline
|
||||
<ol class="list-input">
|
||||
<li class="field required text" id="field-email">
|
||||
<label for="email">${_('E-mail')}</label>
|
||||
<input class="" id="email" type="email" name="email" value="" placeholder="${_('example: username@domain.com')}" required aria-required="true" aria-described-by="email-tip" />
|
||||
<input class="" id="email" type="email" name="email" value="" placeholder="${_('example: username@domain.com')}" required aria-required="true" aria-describedby="email-tip" />
|
||||
<span class="tip tip-input" id="email-tip">${_("This is the e-mail address you used to register with {platform}").format(platform=platform_name)}</span>
|
||||
</li>
|
||||
<li class="field required password" id="field-password">
|
||||
|
||||
@@ -23,11 +23,11 @@ ${block_content}
|
||||
% endif
|
||||
% if not disable_staff_debug_info:
|
||||
<div class="wrap-instructor-info">
|
||||
<a class="instructor-info-action" href="#${element_id}_debug" id="${element_id}_trig">${_("Staff Debug Info")}</a>
|
||||
<a class="instructor-info-action" href="#${element_id}_debug" rel="leanModal" id="${element_id}_trig">${_("Staff Debug Info")}</a>
|
||||
|
||||
% if settings.FEATURES.get('ENABLE_STUDENT_HISTORY_VIEW') and \
|
||||
location.block_type == 'problem':
|
||||
<a class="instructor-info-action" href="#${element_id}_history" id="${element_id}_history_trig">${_("Submission history")}</a>
|
||||
<a class="instructor-info-action" href="#${element_id}_history" rel="leanModal" id="${element_id}_history_trig">${_("Submission history")}</a>
|
||||
% endif
|
||||
</div>
|
||||
% endif
|
||||
@@ -139,8 +139,6 @@ ${block_content}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="${element_id}_setup"></div>
|
||||
|
||||
<script type="text/javascript">
|
||||
// assumes courseware.html's loaded this method.
|
||||
$(function () {
|
||||
|
||||
@@ -56,7 +56,7 @@ def handle_course_cert_awarded(sender, user, course_key, mode, status, **kwargs)
|
||||
|
||||
|
||||
@receiver(COURSE_CERT_CHANGED)
|
||||
def handle_course_cert_changed(sender, user, course_key, mode, status, **kwargs): # pylint: disable=unused-argument
|
||||
def handle_course_cert_changed(sender, user, course_key, mode, status, **kwargs):
|
||||
"""
|
||||
If a learner is awarded a course certificate,
|
||||
schedule a celery task to process that course certificate
|
||||
|
||||
6
package-lock.json
generated
6
package-lock.json
generated
@@ -3271,9 +3271,9 @@
|
||||
}
|
||||
},
|
||||
"edx-custom-a11y-rules": {
|
||||
"version": "0.1.3",
|
||||
"resolved": "https://registry.npmjs.org/edx-custom-a11y-rules/-/edx-custom-a11y-rules-0.1.3.tgz",
|
||||
"integrity": "sha1-9XDdo1yWWdhfC2JlBfz7EoTQ0dM=",
|
||||
"version": "1.0.5",
|
||||
"resolved": "https://registry.npmjs.org/edx-custom-a11y-rules/-/edx-custom-a11y-rules-1.0.5.tgz",
|
||||
"integrity": "sha512-0yPTw6IEQ5Eu/Nm2CBQzFVTnmXf5qa9NPopVKz2b9CtYHQcJyqxoiKboUH49S9ozTVMMPrvtc7rt5acdCTSGNg==",
|
||||
"dev": true
|
||||
},
|
||||
"edx-pattern-library": {
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
"devDependencies": {
|
||||
"@edx/stylelint-config-edx": "1.1.0",
|
||||
"babel-jest": "23.0.1",
|
||||
"edx-custom-a11y-rules": "0.1.3",
|
||||
"edx-custom-a11y-rules": "1.0.5",
|
||||
"enzyme": "3.3.0",
|
||||
"enzyme-adapter-react-16": "1.1.1",
|
||||
"eslint-config-edx": "3.0.1",
|
||||
|
||||
@@ -31,7 +31,7 @@ else
|
||||
fi
|
||||
|
||||
echo "Running explicit accessibility tests..."
|
||||
SELENIUM_BROWSER=phantomjs $TOX paver test_a11y
|
||||
SELENIUM_BROWSER=chrome BOKCHOY_HEADLESS=true $TOX paver test_a11y
|
||||
|
||||
# The settings that we use are installed with the pa11ycrawler module
|
||||
export SCRAPY_SETTINGS_MODULE='pa11ycrawler.settings'
|
||||
|
||||
@@ -194,7 +194,7 @@ case "$TEST_SUITE" in
|
||||
;;
|
||||
|
||||
[1-9]|1[0-9]|2[0-1])
|
||||
$TOX paver test_bokchoy --eval-attr="shard==$SHARD" $PAVER_ARGS
|
||||
$TOX paver test_bokchoy --eval-attr="shard==$SHARD and not a11y" $PAVER_ARGS
|
||||
;;
|
||||
|
||||
22|"noshard")
|
||||
|
||||
@@ -2,6 +2,6 @@
|
||||
set -e
|
||||
|
||||
export LOWER_PYLINT_THRESHOLD=1000
|
||||
export UPPER_PYLINT_THRESHOLD=2760
|
||||
export UPPER_PYLINT_THRESHOLD=2715
|
||||
export ESLINT_THRESHOLD=5590
|
||||
export STYLELINT_THRESHOLD=973
|
||||
|
||||
Reference in New Issue
Block a user