Skip to content
This repository was archived by the owner on Jan 16, 2025. It is now read-only.

mailhog 0.1.8 (new formula) #44884

Closed
wants to merge 10 commits into from
Closed

mailhog 0.1.8 (new formula) #44884

wants to merge 10 commits into from

Conversation

maijs
Copy link
Contributor

@maijs maijs commented Oct 13, 2015

MailHog is a Go-based email testing tool for developers.

This formula builds and installs MailHog version 0.1.8.

@maijs maijs changed the title mailhog 0.1.8 mailhog 0.1.8 (new formula) Oct 13, 2015
end

test do
output = shell_output("#{bin}/MailHog -h 2>&1 | head -n 1")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can’t we write a better test than e.g. -h/-help/-version?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Valid point. Given that MailHog outputs debug messages when run directly, test should check against that.

maijs added 7 commits October 16, 2015 16:49
- Starting "A" removed from formula description
- Test updated to check for default ./MailHog output instead of help output
- Information about sendmail replacement is displayed after installation, instead of using caveats function.
- Test caused execution expiration as MailHog kept running in the background. Fixed by redirecting the output to /dev/null.
- Text match assertion wrapped in // instead of %r{}.
- Whitespace removed.
- Test caused execution expiration as MailHog kept running in the background. Fixed by killing the process in 3 seconds.
- Info message removed as sendmail replacement option is documented on MailHog project page.
- Homebrew/homebrew issues #44981 and #44828 have been fixed with PR #45019. "git clone" in resources now checkout the correct revision, no need to get resource from tarball.
@maijs
Copy link
Contributor Author

maijs commented Oct 19, 2015

Is there anything else that needs to be done for this formula to be merged?

end

def install
mkdir_p "#{buildpath}/src/github.com/mailhog/"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use (buildpath/"src/github.com/mailhog/").mkpath

EOS
end

test do
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we use the mpd style test here instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@DomT4 Indeed, utilizing Process.kill is a leaner approach.

@DomT4
Copy link
Contributor

DomT4 commented Oct 25, 2015

Merged in 4e4cab4. Thank you for your contribution to Homebrew @maijs; we appreciate it! 😺

@DomT4 DomT4 closed this in 4e4cab4 Oct 25, 2015
@Homebrew Homebrew locked and limited conversation to collaborators Jul 10, 2016
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants