Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

require json in spec_helper #61

Merged
merged 1 commit into from

3 participants

@ktdreyer

When running the tests outside of rake or bundler (for example, during RPM packaging), the tests fail because we don't require the json gem before calling to_json.

Executing(%check): /bin/sh -e /var/tmp/rpm-tmp.vwpgPn
+ umask 022
+ cd /builddir/build/BUILD
~/build/BUILD/hipchat-1.0.1/usr/share/gems/gems/hipchat-1.0.1 ~/build/BUILD/hipchat-1.0.1
+ cd hipchat-1.0.1
+ pushd ./usr/share/gems/gems/hipchat-1.0.1
+ rspec -Ilib spec
DEPRECATION: RSpec::Core::Configuration#backtrace_clean_patterns is deprecated. Use RSpec::Core::Configuration#backtrace_exclusion_patterns instead. Called from /usr/share/rubygems/rubygems/core_ext/kernel_require.rb:55:in `require'.
.......................FFFFFFFFFFF.F..
Failures:
  1) HipChat#topic (API v2) is successful without custom options
     Failure/Error: mock_successful_topic_change("Nice topic")
     NoMethodError:
       undefined method `to_json' for {:room_id=>"Hipchat", :from=>"API", :topic=>"Nice topic"}:Hash
     # ./spec/shared_hipchat.rb:66:in `mock_successful_topic_change'
     # ./spec/hipchat_spec.rb:183:in `block (3 levels) in <top (required)>'
@ktdreyer ktdreyer require json in spec_helper
When running the tests outside of rake or bundler, the tests fail
because we don't require the json gem before calling `to_json`.
138103e
@coveralls

Coverage Status

Coverage remained the same when pulling 138103e on ktdreyer:spec-json into b57e24e on hipchat:master.

@zsiddique zsiddique merged commit 4db8aac into hipchat:master
@ktdreyer ktdreyer deleted the ktdreyer:spec-json branch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Dec 28, 2013
  1. @ktdreyer

    require json in spec_helper

    ktdreyer authored
    When running the tests outside of rake or bundler, the tests fail
    because we don't require the json gem before calling `to_json`.
This page is out of date. Refresh to see the latest.
Showing with 1 addition and 0 deletions.
  1. +1 −0  spec/spec_helper.rb
View
1  spec/spec_helper.rb
@@ -3,6 +3,7 @@
require 'hipchat'
require 'rspec'
require 'rspec/autorun'
+require 'json'
require 'webmock/rspec'
require 'coveralls'
Something went wrong with that request. Please try again.