diff --git a/spec/integration/unmanaged_spec.rb b/spec/integration/unmanaged_spec.rb new file mode 100644 index 0000000..c3f582f --- /dev/null +++ b/spec/integration/unmanaged_spec.rb @@ -0,0 +1,27 @@ +require 'spec_helper' + +describe Neography::Rest do + before(:each) do + @neo = Neography::Rest.new + end + + describe "call unmanaged extensions", :unmanaged_extensions => true do + it "can call a get based unmanaged extension" do + results = @neo.get_extension('/example/service/queries/fofof/13343') + results.should_not be_null + end + + it "can call a POST based unmanaged extension" do + results = @neo.post_extention('/movie/recommend', {"title" => "Rambo"}) + results.should_not be_null + end + + it "can call a POST based unmanaged extension that uses form-urlencoded" do + headers = {'Content-Type' =>'application/x-www-form-urlencoded'} + results = @neo.post_extention('/music/recommend', {"artist" => "Ministry", "song" => "Just one Fix"}, headers) + results.should_not be_null + end + + end + +end \ No newline at end of file diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index d9a2bb4..45eaa73 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -17,7 +17,7 @@ def generate_text(length=8) end RSpec.configure do |c| - c.filter_run_excluding :slow => true, :gremlin => true, :reference => true, :neo_is_broken => true + c.filter_run_excluding :slow => true, :gremlin => true, :reference => true, :neo_is_broken => true, :unmanaged_extensions => true end