From 1ff9c0fc5db1aab393eed5751e94ed8ac127c0c2 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Thu, 28 Apr 2011 17:44:43 -0500 Subject: isotests: massive overview refactor Copy pasted code sucks. Fix it. Also, ensure 500 errors aren't going to be popping up when people start typing invalid URLs for fun, among a lot of other small fixes going in here. Signed-off-by: Dan McGee --- templates/isotests/result_list.html | 4 +- templates/isotests/result_section.html | 26 +++ templates/isotests/results.html | 411 +-------------------------------- 3 files changed, 30 insertions(+), 411 deletions(-) create mode 100644 templates/isotests/result_section.html (limited to 'templates') diff --git a/templates/isotests/result_list.html b/templates/isotests/result_list.html index ac0475b6..29ad19ec 100644 --- a/templates/isotests/result_list.html +++ b/templates/isotests/result_list.html @@ -3,9 +3,7 @@ {% block content %}

Results for: - {% if option %} - {{ option }}: {{ value }} - {% endif %} + {% if option %}{{ option|title }}: {{ value }}{% endif %} {{ iso_name|default:"" }}

diff --git a/templates/isotests/result_section.html b/templates/isotests/result_section.html new file mode 100644 index 00000000..52f03339 --- /dev/null +++ b/templates/isotests/result_section.html @@ -0,0 +1,26 @@ + +

{% if option.is_rollback %}Rollback: {% endif %}{{ option.name|title }}

+ +{% for item in option.values %} + + + + {{ item.value.name|lower }} + + + + {% if item.success %} + + {{ item.success.name }} + + {% else %}Never succeeded{% endif %} + + + {% if item.failure %} + + {{ item.failure.name }} + + {% else %}Never failed{% endif %} + + +{% endfor %} diff --git a/templates/isotests/results.html b/templates/isotests/results.html index d8835121..033fdbfe 100644 --- a/templates/isotests/results.html +++ b/templates/isotests/results.html @@ -9,7 +9,7 @@

This is a overview screen showing a test results matrix of release engineering produced ISOs. Various options and configurations are shown with last success and last failure results, if known. To help improve ISO - quality, you are encouraged to give feedback + quality, you are encouraged to give feedback if you have tested and used any ISOs. Both successful and failed results are encouraged and welcome.

@@ -17,414 +17,9 @@ {{ iso_url }}.

- - - - {% if architecture_list %} - {% for architecture in architecture_list %} - - - - - + {% for option in options %} + {% include "isotests/result_section.html" %} {% endfor %} - {% endif %} - - - - {% if iso_type_list %} - {% for iso_type in iso_type_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if boot_type_list %} - {% for boot_type in boot_type_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if hardware_type_list %} - {% for hardware_type in hardware_type_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if install_type_list %} - {% for install_type in install_type_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if source_list %} - {% for source in source_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if clock_choices_list %} - {% for clock_choice in clock_choices_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if filesystem_list %} - {% for filesystem in filesystem_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if module_list %} - {% for module in module_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if filesystem_list %} - {% for filesystem in filesystem_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if module_list %} - {% for module in module_list %} - - - - - - {% endfor %} - {% endif %} - - - - {% if bootloader_list %} - {% for bootloader in bootloader_list %} - - - - - - {% endfor %} - {% endif %}
-

Architecture

-
- - {{ architecture.name }} - - - {% if architecture.get_success_test %} - - {{ architecture.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if architecture.get_failed_test %} - - {{ architecture.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Image Type

-
- - {{ iso_type.name }} - - - {% if iso_type.get_success_test %} - - {{ iso_type.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if iso_type.get_failed_test %} - - {{ iso_type.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Boot Type

-
- - {{ boot_type.name }} - - - {% if boot_type.get_success_test %} - - {{ boot_type.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if boot_type.get_failed_test %} - - {{ boot_type.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Hardware Type

-
- - {{ hardware_type.name }} - - - {% if hardware_type.get_success_test %} - - {{ hardware_type.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if hardware_type.get_failed_test %} - - {{ hardware_type.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Install Type

-
- - {{ install_type.name }} - - - {% if install_type.get_success_test %} - - {{ install_type.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if install_type.get_failed_test %} - - {{ install_type.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Source Selection

-
- - {{ source.name }} - - - {% if source.get_success_test %} - - {{ source.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if source.get_failed_test %} - - {{ source.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Clock Choice

-
- - {{ clock_choice.name }} - - - {% if clock_choice.get_success_test %} - - {{ clock_choice.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if clock_choice.get_failed_test %} - - {{ clock_choice.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Partitioning & Filesystems

-
- - {{ filesystem.name }} - - - {% if filesystem.get_success_test %} - - {{ filesystem.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if filesystem.get_failed_test %} - - {{ filesystem.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Fancy Stuff

-
- - {{ module.name }} - - - {% if module.get_success_test %} - - {{ module.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if module.get_failed_test %} - - {{ module.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Rollback: Partitioning & Filesystems

-
- - {{ filesystem.name }} - - - {% if filesystem.get_rollback_success_test %} - - {{ filesystem.get_rollback_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if filesystem.get_rollback_failed_test %} - - {{ filesystem.get_rollback_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Rollback: Fancy Stuff

-
- - {{ module.name }} - - - {% if module.get_rollback_success_test %} - - {{ module.get_rollback_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if module.get_rollback_failed_test %} - - {{ module.get_rollback_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
-

Bootloader

-
- - {{ bootloader.name }} - - - {% if bootloader.get_success_test %} - - {{ bootloader.get_success_test.name }} - - {% else %} - Never succeeded - {% endif %} - - {% if bootloader.get_failed_test %} - - {{ bootloader.get_failed_test.name }} - - {% else %} - Never failed - {% endif %} -
{% endblock %} -- cgit v1.2.3-55-g3dc8