summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2015-03-25 17:54:54 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2015-03-25 17:54:54 -0700
commita78333f35970947c0d8d9159b0c1785e59e8b26b (patch)
tree1546bd441d909fb69ae40ef83802e92852edea1c
parent629492b5934a74c97e7030a197f80a7444268a6d (diff)
parent32522cd92f51ddacd55736e555c754fe15b43ac4 (diff)
downloadffi-yajl-a78333f35970947c0d8d9159b0c1785e59e8b26b.tar.gz
Merge pull request #50 from chef/lcg/add-appveyor-config
Lcg/add appveyor config
-rw-r--r--appveyor.yml34
-rw-r--r--spec/ffi_yajl/parser_spec.rb4
-rw-r--r--spec/spec_helper.rb1
3 files changed, 38 insertions, 1 deletions
diff --git a/appveyor.yml b/appveyor.yml
new file mode 100644
index 0000000..df5879c
--- /dev/null
+++ b/appveyor.yml
@@ -0,0 +1,34 @@
+version: "master-{build}"
+
+os: Windows Server 2012
+platform:
+ - x64
+
+environment:
+ matrix:
+ - ruby_version: "200"
+
+clone_folder: c:\projects\ffi-yajl
+clone_depth: 1
+skip_tags: true
+branches:
+ only:
+ - master
+
+install:
+ - SET PATH=C:\Ruby%ruby_version%\bin;%SystemRoot%\System32;%SystemRoot%;%SystemRoot%\System32\Wbem
+ - echo %PATH%
+ - ruby --version
+ - gem --version
+ - gem install bundler --quiet --no-ri --no-rdoc
+ - bundler --version
+
+build_script:
+ - bundle install || bundle install || bundle install
+
+test_script:
+ # compile needs to have the devkit loaded up
+ - C:\Ruby21\DevKit\devkitvars.bat
+ - echo %PATH%
+ - bundle exec rake compile
+ - bundle exec rake spec
diff --git a/spec/ffi_yajl/parser_spec.rb b/spec/ffi_yajl/parser_spec.rb
index 0afae3f..ea67879 100644
--- a/spec/ffi_yajl/parser_spec.rb
+++ b/spec/ffi_yajl/parser_spec.rb
@@ -453,7 +453,9 @@ describe "FFI_Yajl::Parser" do
end
end
- context "when parsing big floats", :ruby_gte_193 => true do
+ # NOTE: parsing floats with 8 million digits on windows has some kind of huge
+ # perf issues likely in ruby and/or the underlying windows libs
+ context "when parsing big floats", :ruby_gte_193 => true, :unix_only => true do
let(:json) { '[0.' + '1' * 2**23 + ']' }
it "parses" do
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index 50c3454..71a397b 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -3,6 +3,7 @@ $: << File.expand_path(File.join(File.dirname( __FILE__ ), "../lib"))
require 'ffi_yajl'
RSpec.configure do |c|
+ c.filter_run_excluding :unix_only => true unless RUBY_PLATFORM !~ /mswin|mingw|windows/
c.filter_run_excluding :ruby_gte_19 => true unless RUBY_VERSION.to_f >= 1.9
c.filter_run_excluding :ruby_gte_193 => true unless RUBY_VERSION.to_f >= 2.0 || RUBY_VERSION =~ /^1\.9\.3/