Sha256: c3b2f7b08cf7ae0108c5e03b4a4c99d3cc290a5c633614d8a647bdf7e4188067

Contents?: true

Size: 437 Bytes

Versions: 3

Compression:

Stored size: 437 Bytes

Contents

require "spec_helper"
require "support/sinatra_helper"
require "sucker_punch/testing/inline"

describe "GitHub web hooks receiver" do
  it "kicks an async job doing all the work" do
    expected_param = { "something" => "ok" }
    Fourchette::PullRequest.any_instance
      .should_receive(:perform)
      .with(expected_param)

    post "/hooks",
         expected_param.to_json,
         "CONTENT_TYPE" => "application/json"
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
fourchette-0.1.2 spec/lib/web/hooks_spec.rb
fourchette-0.1.1 spec/lib/web/hooks_spec.rb
fourchette-0.1.0 spec/lib/web/hooks_spec.rb