jcleary/blade

View on GitHub
app/views/builds/index.html.haml

Summary

Maintainability
Test Coverage
= render '/shared/project_bar'
%h3 Builds
%table.table
  %tr.active
    %th Build date
    %th Tests
    %th Failures
    %th Duration
    %th 10 slowest tests
  - @builds.each do |build|
    %tr
      %td= link_to build.created_at.strftime('%d/%m/%Y %H:%M:%S'), project_build_path(@project, build)
      %td= link_to build.test_count, project_build_test_runs_path(@project, build)
      %td= link_to build.failed_count, project_build_test_runs_path(@project, build, status: 'failed') if build.failed_count > 0
      %td= minutes_and_seconds(build.duration)
      %td= minutes_and_seconds(build.x_slowest_duration)