From eb5423d08403e24ef3bc00d47f116fa1be1a68c8 Mon Sep 17 00:00:00 2001 From: Lars Eggert Date: Mon, 21 Mar 2022 18:50:23 +0100 Subject: [PATCH] ci: Also check generated HTML with the "vnu" validator (#3682) * ci: Also check generated HTML with the "vnu" validator Because HTML Tidy apparently misses a bunch of errors. * thead -> tbody * More fixes * More fixes * Start checker in test runner --- docker/app.Dockerfile | 6 + ietf/api/templates/api/base.html | 2 +- .../templates/dbtemplate/template_edit.html | 2 +- ietf/doc/templatetags/ietf_filters.py | 1 + ietf/group/tests_review.py | 5 +- ietf/ipr/tests.py | 4 +- ietf/liaisons/widgets.py | 10 +- ietf/release/tests.py | 3 +- ietf/secr/templates/announcement/main.html | 2 +- ietf/secr/templates/areas/people.html | 2 +- ietf/secr/templates/areas/view.html | 2 +- ietf/secr/templates/base_secr.html | 16 +- ietf/secr/templates/base_secr_bootstrap.html | 14 +- ietf/secr/templates/base_site.html | 8 +- ietf/secr/templates/base_site_bootstrap.html | 8 +- ietf/secr/templates/confirm_cancel.html | 2 +- ietf/secr/templates/confirm_delete.html | 2 +- ietf/secr/templates/groups/people.html | 4 +- ietf/secr/templates/groups/search.html | 2 +- ietf/secr/templates/groups/view.html | 2 +- .../includes/sessions_request_form.html | 20 +-- .../includes/sessions_request_view.html | 2 +- ietf/secr/templates/main.html | 12 +- ietf/secr/templates/meetings/add.html | 2 +- .../templates/meetings/base_rooms_times.html | 2 +- ietf/secr/templates/meetings/main.html | 2 +- .../templates/meetings/misc_sessions.html | 6 +- .../meetings/regular_session_edit.html | 4 +- ietf/secr/templates/meetings/rooms.html | 4 +- ietf/secr/templates/meetings/times.html | 2 +- ietf/secr/templates/meetings/view.html | 25 +-- .../proceedings/interim_directory.html | 10 +- .../secr/templates/proceedings/recording.html | 2 +- .../templates/proceedings/recording_edit.html | 2 +- ietf/secr/templates/proceedings/view.html | 31 +--- ietf/secr/templates/roles/main.html | 4 +- ietf/secr/templates/rolodex/add.html | 4 +- ietf/secr/templates/rolodex/add_proceed.html | 2 +- ietf/secr/templates/rolodex/delete.html | 2 +- ietf/secr/templates/rolodex/edit.html | 2 +- ietf/secr/templates/rolodex/search.html | 2 +- ietf/secr/templates/rolodex/view.html | 2 +- ietf/secr/templates/sreq/main.html | 4 +- ietf/secr/templates/sreq/tool_status.html | 2 +- .../templates/telechat/base_telechat.html | 2 +- ietf/secr/templates/telechat/doc.html | 8 +- ietf/secr/templates/telechat/group.html | 2 +- ietf/secr/templates/telechat/main.html | 2 +- ietf/secr/templates/telechat/roll_call.html | 2 +- ietf/static/js/liaisons.js | 3 +- ietf/submit/forms.py | 4 +- ietf/templates/base.html | 2 +- .../doc/ballot/approve_downrefs.html | 2 +- .../doc/charter/action_announcement_text.html | 3 +- ietf/templates/doc/document_bofreq.html | 2 +- ietf/templates/doc/document_draft.html | 2 - ietf/templates/doc/document_history.html | 8 +- .../doc/draft/review_possibly_replaces.html | 2 +- .../templates/doc/drafts_in_iesg_process.html | 4 +- ietf/templates/doc/edit_action_holders.html | 2 +- ietf/templates/doc/revisions_list.html | 4 +- ietf/templates/doc/search/search_results.html | 4 +- .../doc/status_change/edit_related_rows.html | 4 +- .../doc/status_change/status_changes.html | 4 +- ietf/templates/googlea30ad1dacffb5e5b.html | 2 +- ietf/templates/group/active_adm.html | 4 +- ietf/templates/group/active_iabgroups.html | 4 +- .../group/group_about_rendertest.html | 2 +- .../group/reset_charter_milestones.html | 2 +- ietf/templates/group/reset_next_reviewer.html | 2 +- ietf/templates/group/review_requests.html | 16 +- ietf/templates/iesg/agenda_documents.html | 1 + ietf/templates/iesg/moderator_package.html | 2 +- ietf/templates/ietfauth/review_overview.html | 2 +- ietf/templates/ietfauth/testemail.html | 2 +- ietf/templates/ietfauth/whitelist_form.html | 2 +- ietf/templates/ipr/details_history.html | 2 +- ietf/templates/ipr/search_doc_result.html | 4 +- .../templates/ipr/search_doctitle_result.html | 4 +- ietf/templates/ipr/search_result.html | 8 +- ietf/templates/ipr/search_wg_result.html | 4 +- ietf/templates/liaisons/edit.html | 2 +- ietf/templates/meeting/agenda.html | 2 +- .../meeting/edit_meeting_schedule.html | 4 +- ietf/templates/meeting/group_materials.html | 12 +- ietf/templates/meeting/import_minutes.html | 1 - ietf/templates/meeting/interim_request.html | 2 +- .../meeting/interim_request_cancel.html | 2 +- .../meeting/interim_request_edit.html | 2 +- .../meeting/interim_send_announcement.html | 2 +- .../meeting/interim_skip_announce.html | 2 +- .../meeting/materials_editable_groups.html | 4 +- ietf/templates/meeting/requests.html | 4 +- .../meeting/session_buttons_include.html | 1 - ietf/templates/meeting/timeslot_edit.html | 4 +- ietf/templates/meeting/tz-display.html | 3 - ietf/templates/meeting/week-view.html | 2 +- .../nomcom/iesg_position_requirements.html | 2 + ietf/templates/nomcom/private_index.html | 76 ++++----- ietf/templates/nomcom/send_reminder_mail.html | 2 +- ietf/templates/oidc_provider/authorize.html | 2 +- ietf/templates/person/merge.html | 2 +- .../registration/change_password.html | 2 +- .../registration/confirm_account.html | 2 +- ietf/templates/registration/index.html | 10 +- ietf/templates/submit/manual_post.html | 3 +- ietf/templates/submit/tool_instructions.html | 20 +-- ietf/templates/submit/upload_submission.html | 1 - ietf/utils/test_runner.py | 22 ++- ietf/utils/test_utils.py | 144 +++++++++++++----- 110 files changed, 381 insertions(+), 332 deletions(-) diff --git a/docker/app.Dockerfile b/docker/app.Dockerfile index b4d78f3cc..7911e8169 100644 --- a/docker/app.Dockerfile +++ b/docker/app.Dockerfile @@ -124,6 +124,12 @@ RUN sed -i '/imklog/s/^/#/' /etc/rsyslog.conf # Colorize the bash shell RUN sed -i 's/#force_color_prompt=/force_color_prompt=/' /root/.bashrc +# Install the Nu Html Checker (v.Nu) +ADD https://github.com/validator/validator/releases/download/latest/vnu.linux.zip / +RUN unzip -d / /vnu.linux.zip +RUN cp -r /vnu-runtime-image/* /usr/local +RUN rm -rf /vnu.linux.zip /vnu-runtime-image + ADD https://raw.githubusercontent.com/eficode/wait-for/v2.1.3/wait-for /usr/local/bin/ RUN chmod +rx /usr/local/bin/wait-for diff --git a/ietf/api/templates/api/base.html b/ietf/api/templates/api/base.html index dbfc1fdfe..4185da8bf 100644 --- a/ietf/api/templates/api/base.html +++ b/ietf/api/templates/api/base.html @@ -1,6 +1,6 @@ -