lib/pact_broker/badges/service.rb in pact_broker-2.62.0 vs lib/pact_broker/badges/service.rb in pact_broker-2.63.0
- old
+ new
@@ -31,9 +31,20 @@
status = badge_status(pseudo_branch_verification_status)
color = badge_color(pseudo_branch_verification_status)
build_shield_io_uri(title, status, color)
end
+ def can_i_deploy_badge_url(pacticipant_name, tag, environment_tag, label, deployable)
+ title = label || "Can I deploy #{tag} #{pacticipant_name} to #{environment_tag}?"
+ status = deployable ? "yes" : "no"
+ color = deployable ? "brightgreen" : "red"
+ build_shield_io_uri(title, status, color)
+ end
+
+ def error_badge_url(left_text, right_text)
+ build_shield_io_uri(left_text, right_text, "lightgrey")
+ end
+
def clear_cache
CACHE.clear
end
private