forked from ericrvass/ttdrest
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Starts specs for the gem for testing and stability. @todo make these …
…specs actually do something.
- Loading branch information
Stephen Reid
committed
May 11, 2016
1 parent
45f977f
commit d094003
Showing
6 changed files
with
179 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,12 @@ | ||
require "bundler/gem_tasks" | ||
|
||
Bundler::GemHelper.install_tasks | ||
|
||
|
||
require 'rspec/core' | ||
require 'rspec/core/rake_task' | ||
|
||
desc "Run all specs" | ||
RSpec::Core::RakeTask.new(:spec) do |t| | ||
t.pattern = "./spec/**/*_spec.rb" | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
require 'rubygems' | ||
# Need active support for to_json and symbolize_keys! | ||
require 'active_support/all' | ||
|
||
# Require webmock and VCR to test requests | ||
require 'webmock/rspec' | ||
require 'vcr' | ||
|
||
require 'rspec' | ||
require 'ttdrest' | ||
|
||
VCR.configure do |c| | ||
c.cassette_library_dir = "spec/vcr" | ||
c.hook_into :webmock | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
require File.expand_path(File.dirname(__FILE__) + '/../spec_helper') | ||
|
||
describe Ttdrest::Client do | ||
it 'can initialize' do | ||
expect(Ttdrest::Client.new).to be_an_instance_of(Ttdrest::Client) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') | ||
|
||
describe Ttdrest::Client do | ||
describe "with initialized client" do | ||
let(:client) { Ttdrest::Client.new } | ||
|
||
it '#get_creatives' do | ||
VCR.use_cassette('get_creatives') do | ||
expect(client.get_creatives).to eq nil | ||
end | ||
end | ||
end | ||
end |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters