Sha256: cb7385ac2946a9a9f49310e866ccb8952c765253cb75186cfe1d6b6045286810

Contents?: true

Size: 1.12 KB

Versions: 7

Compression:

Stored size: 1.12 KB

Contents

# typed: false
# frozen_string_literal: true

module Webmocks
  module <%= capital_plug_name %>Webmock
    extend T::Sig
    extend T::Helpers

    # TODO: Add webmocks here which are specific to your application
    # For example, if your application interacts with GitHub, you can add webmocks for GitHub here
    #
    # sig { params(state: String).returns(T.untyped) }
    # def assert_requested_user_access_token(state)
    #   assert_requested(:post, "https://github.com/login/oauth/access_token?#{token_query_params(state)}")
    # end

    # sig { params(state: String, valid: T::Boolean, status: Integer).returns(T.untyped) }
    # def stub_request_user_access_token(state, valid: true, status: 200)
    #   response_body = JSON.parse(file_fixture_path("access_token", valid ? "valid.json" : "invalid.json").read).deep_symbolize_keys
    #   stub_request(:post, "https://github.com/login/oauth/access_token?#{token_query_params(state)}")
    #     .to_return(
    #       status: status,
    #       headers: { content_type: "application/json; charset=utf-8" },
    #       body: response_body.to_json,
    #     )
    # end

  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
hephaestus-0.8.16.1 templates/test/support/webmocks/app_webmock.rb.tt
hephaestus-0.8.16 templates/test/support/webmocks/app_webmock.rb.tt
hephaestus-0.8.15.5 templates/test/support/webmocks/app_webmock.rb.tt
hephaestus-0.8.15.4 templates/test/support/webmocks/app_webmock.rb.tt
hephaestus-0.8.15.3 templates/test/support/webmocks/app_webmock.rb.tt
hephaestus-0.8.15.2 templates/test/support/webmocks/app_webmock.rb.tt
hephaestus-0.8.15.1 templates/test/support/webmocks/app_webmock.rb.tt