New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patchinfo tests #3160

Merged
merged 3 commits into from May 30, 2017

Conversation

Projects
None yet
2 participants
@bgeuken
Copy link
Member

bgeuken commented May 30, 2017

No description provided.

bgeuken added some commits May 30, 2017

[ci] Add tests Webui::PatchinfoHelper#patchinfo_bread_crumb
The generation of the package link was failing calling patchinfo_bread_crumb
in the helper spec. Thus I changed this in the helper.

====

ActionController::UrlGenerationError: No route matches {:action=>"show", :package=>"package_1", :project=>"project_1"}

@bgeuken bgeuken force-pushed the bgeuken:patchinfo_tests branch from d72f4fc to bf54b05 May 30, 2017

@codecov

This comment has been minimized.

Copy link

codecov bot commented May 30, 2017

Codecov Report

Merging #3160 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3160      +/-   ##
==========================================
+ Coverage   88.93%   88.93%   +<.01%     
==========================================
  Files         263      263              
  Lines       17591    17587       -4     
==========================================
- Hits        15644    15641       -3     
+ Misses       1947     1946       -1
Flag Coverage Δ
#api 83.68% <33.33%> (+0.01%) ⬆️
#rspec 65.91% <100%> (+0.02%) ⬆️
#webui 64.47% <100%> (+0.57%) ⬆️

@bgeuken bgeuken force-pushed the bgeuken:patchinfo_tests branch from bf54b05 to a574661 May 30, 2017

@@ -41,7 +41,10 @@
- if @issues.present?
%ul
- @issues.each do |issue|
= issue_link(issue)
- if issue[0] == "CVE"
= content_tag(:li, link_to((issue[1]).to_s, issue[2]) + ": #{issue[3]}")

This comment has been minimized.

@DavidKang

DavidKang May 30, 2017

Contributor

Why content_tag?, and not something like %li= link_to((issue[1]).to_s, issue[2]) + ": #{issue[3]}"

This comment has been minimized.

@bgeuken

bgeuken May 30, 2017

Member

Good point. Didn't think of that

- if issue[0] == "CVE"
= content_tag(:li, link_to((issue[1]).to_s, issue[2]) + ": #{issue[3]}")
- else
= content_tag(:li, link_to("#{issue[0]}##{issue[1]}", issue[2]) + ": #{issue[3]}")

This comment has been minimized.

@DavidKang

DavidKang May 30, 2017

Contributor

same here

@DavidKang

This comment has been minimized.

Copy link
Contributor

DavidKang commented May 30, 2017

Nice work!

[webui] Move patchinfo issue handling from helper to view
The code is only used once and not very complex. No need to have it in a
helper.

@bgeuken bgeuken force-pushed the bgeuken:patchinfo_tests branch from a574661 to 7aa9674 May 30, 2017

@bgeuken

This comment has been minimized.

Copy link
Member

bgeuken commented May 30, 2017

@DavidKang Changed it now

@bgeuken bgeuken merged commit 799c0c9 into openSUSE:master May 30, 2017

4 checks passed

Hakiri No security warnings were found.
Details
codecov/patch 100% of diff hit (target 88.93%)
Details
codecov/project 88.93% (+<.01%) compared to 80f7035
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@bgeuken bgeuken deleted the bgeuken:patchinfo_tests branch May 30, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment