Sha256: f862c0247520b5f9b009938dd389400ce0b2ab24549de459da7eb2779fadcad3

Contents?: true

Size: 562 Bytes

Versions: 3

Compression:

Stored size: 562 Bytes

Contents

# frozen_string_literal: true

if ENV.key?('WITH_GIPHY')
  describe Giphy do
    let(:burrito_gif) { 'https://media3.giphy.com/media/xTiTndNDuNFxUW5Xoc/giphy.gif' }
    before do
      Giphy::Configuration.configure do |config|
        config.api_key = 'giphy-api-key'
      end
    end
    after do
      Giphy::Configuration.configure do |config|
        config.api_key = ENV['GIPHY_API_KEY']
      end
    end
    it 'random', vcr: { cassette_name: 'giphy_burrito' } do
      expect(Giphy.random('burrito').image_url.to_s).to eq burrito_gif
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
slack-ruby-bot-0.15.0 spec/slack-ruby-bot/initializers/giphy_spec.rb
slack-ruby-bot-0.14.0 spec/slack-ruby-bot/initializers/giphy_spec.rb
slack-ruby-bot-0.13.0 spec/slack-ruby-bot/initializers/giphy_spec.rb