Sha256: 9366a0bcbf15c005dfcf5daaa85dc79d2671ba9af6e4ab9a1dcc26523031808e

Contents?: true

Size: 684 Bytes

Versions: 1

Compression:

Stored size: 684 Bytes

Contents

require "coveralls"
Coveralls.wear! do
  add_filter "/spec/"
end

require "rspec"
require "pry"
require "fakeweb"
require "onebox"
require 'mocha/api'

require_relative "support/html_spec_helper"

RSpec.configure do |config|
  config.include HTMLSpecHelper
end

shared_examples_for "an engine" do
  it "has engine behavior" do
    expect(described_class.private_instance_methods).to include(:data, :record, :raw)
  end

  it "has implemented the data functionality" do
    expect { described_class.new(link).send(:data) }.not_to raise_error
  end

  it "correctly matches the url" do
    onebox = Onebox::Matcher.new(link).oneboxed
    expect(onebox).to be(described_class)
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
onebox-1.1.0 spec/spec_helper.rb