aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/test/dev-cmd
diff options
context:
space:
mode:
Diffstat (limited to 'Library/Homebrew/test/dev-cmd')
-rw-r--r--Library/Homebrew/test/dev-cmd/create_spec.rb13
1 files changed, 13 insertions, 0 deletions
diff --git a/Library/Homebrew/test/dev-cmd/create_spec.rb b/Library/Homebrew/test/dev-cmd/create_spec.rb
new file mode 100644
index 000000000..b7f96ec7f
--- /dev/null
+++ b/Library/Homebrew/test/dev-cmd/create_spec.rb
@@ -0,0 +1,13 @@
+describe "brew create", :integration_test do
+ let(:url) { "file://#{TEST_FIXTURE_DIR}/tarballs/testball-0.1.tbz" }
+ let(:formula_file) { CoreTap.new.formula_dir/"testball.rb" }
+
+ it "creates a new Formula file for a given URL" do
+ shutup do
+ brew "create", url, "HOMEBREW_EDITOR" => "/bin/cat"
+ end
+
+ expect(formula_file).to exist
+ expect(formula_file.read).to match(%Q(sha256 "#{TESTBALL_SHA256}"))
+ end
+end