From 9d816e65e8594e4bd7d2b6e6fd1e807934f6ebb2 Mon Sep 17 00:00:00 2001 From: Baptiste Fontaine Date: Fri, 20 Mar 2015 13:50:05 +0100 Subject: dhex: test added Closes #37910. Signed-off-by: Mike McQuaid --- Library/Formula/dhex.rb | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'Library/Formula') diff --git a/Library/Formula/dhex.rb b/Library/Formula/dhex.rb index 6d4550735..bef2dbd10 100644 --- a/Library/Formula/dhex.rb +++ b/Library/Formula/dhex.rb @@ -1,14 +1,18 @@ -require 'formula' - class Dhex < Formula - homepage 'http://www.dettus.net/dhex/' - url 'http://www.dettus.net/dhex/dhex_0.68.tar.gz' - sha1 'd23d65a7b330b47f8254f6c1ff25a30c4778440e' + homepage "http://www.dettus.net/dhex/" + url "http://www.dettus.net/dhex/dhex_0.68.tar.gz" + sha256 "126c34745b48a07448cfe36fe5913d37ec562ad72d3f732b99bd40f761f4da08" def install - system "make" - bin.install 'dhex' - man1.install 'dhex.1' - man5.install Dir['*.5'] + inreplace "Makefile", "$(DESTDIR)/man", "$(DESTDIR)/share/man" + bin.mkpath + man1.mkpath + man5.mkpath + system "make", "install", "DESTDIR=#{prefix}" + end + + test do + assert_match("GNU GENERAL PUBLIC LICENSE", + pipe_output("#{bin}/dhex -g 2>&1", "", 0)) end end -- cgit v1.2.3