citrulu 0.1.1 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -1,7 +1,7 @@
1
1
  Citrulu
2
2
  =======
3
3
 
4
- [Citrulu](https://www.citrulu.com/) exposes an [api](https://www.citrulu.com/api) for creating, editing and compiling test files. This gem provides a wrapper around that api which allows you to work with TestFile objects locally.
4
+ [Citrulu](https://www.citrulu.com/) exposes an [api](https://app.citrulu.com/api) for creating, editing and compiling test files. This gem provides a wrapper around that api which allows you to work with TestFile objects locally.
5
5
 
6
6
  The gem has not yet been widely used. It's probably very unlikely to cause anything bad to happen in your app, but please **use at your own risk** and raise an issue if you find any bugs.
7
7
 
@@ -19,7 +19,7 @@ gem "citrulu"
19
19
  Setup
20
20
  -----
21
21
 
22
- You need an account on Citrulu to use the gem: Sign up at <http://www.citrulu.com>, and once you're signed in you can create an API key on the '[Account Settings](https://www.citrulu.com/settings)' page.
22
+ You need an account on Citrulu to use the gem: Sign up at <http://www.citrulu.com>, and once you're signed in you can create an API key on the '[Account Settings](https://app.citrulu.com/settings)' page.
23
23
 
24
24
  Configure your API key by adding it to an initializer:
25
25
 
data/Rakefile CHANGED
@@ -43,7 +43,7 @@ Rake::RDocTask.new do |rdoc|
43
43
  version = File.exist?('VERSION') ? File.read('VERSION') : ""
44
44
 
45
45
  rdoc.rdoc_dir = 'rdoc'
46
- rdoc.title = "citrulu-api #{version}"
46
+ rdoc.title = "Citrulu API #{version}"
47
47
  rdoc.rdoc_files.include('README*')
48
48
  rdoc.rdoc_files.include('lib/**/*.rb')
49
49
  end
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.1
1
+ 0.2.0
data/citrulu.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "citrulu"
8
- s.version = "0.1.1"
8
+ s.version = "0.2.0"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Duncan Stuart"]
12
- s.date = "2012-10-29"
12
+ s.date = "2012-12-11"
13
13
  s.description = "Citrulu exposes an api for creating, editing and compiling test files (http://www.citrulu.com/api). This gem provides a wrapper around that api which allows you to work with TestFile objects locally."
14
14
  s.email = ["contact@dxw.com", "duncan@dxw.com"]
15
15
  s.extra_rdoc_files = [
data/lib/citrulu.rb CHANGED
@@ -4,7 +4,7 @@ require 'faraday'
4
4
 
5
5
  module Citrulu
6
6
  # The address of the Citrulu API
7
- BASE_URL = "https://www.citrulu.com/api/v1"
7
+ BASE_URL = "https://app.citrulu.com/api/v1"
8
8
 
9
9
  # Sets up the connection to the Citrulu API using the api key, which must already have been set to CITRULU_API_KEY
10
10
  def self.connection
@@ -75,14 +75,14 @@ class TestFile
75
75
  # Class Methods #
76
76
  #################
77
77
 
78
- # GET "https://www.citrulu.com/api/v1/test_files?auth_token=abcdefg"
78
+ # GET "https://app.citrulu.com/api/v1/test_files?auth_token=abcdefg"
79
79
  def self.all
80
80
  response = Citrulu.connection.get "test_files"
81
81
  attr_array = JSON.parse(response.body)
82
82
  attr_array.map{ |attrs| build(attrs)}
83
83
  end
84
84
 
85
- # GET "https://www.citrulu.com/api/v1/test_files/2?auth_token=abcdefg"
85
+ # GET "https://app.citrulu.com/api/v1/test_files/2?auth_token=abcdefg"
86
86
  def self.find(id)
87
87
  response = Citrulu.connection.get "test_files/#{id}"
88
88
  # parse_response(response.body)
@@ -93,7 +93,7 @@ class TestFile
93
93
  build(attrs.first)
94
94
  end
95
95
 
96
- # POST "https://www.citrulu.com/api/v1/test_files?name=foo&test_file_text=bar&run_tests=false&auth_token=abcdefg"
96
+ # POST "https://app.citrulu.com/api/v1/test_files?name=foo&test_file_text=bar&run_tests=false&auth_token=abcdefg"
97
97
  def self.create(options={})
98
98
  response = Citrulu.connection.post "test_files", options
99
99
  body = JSON.parse(response.body)
@@ -107,7 +107,7 @@ class TestFile
107
107
  end
108
108
  end
109
109
 
110
- # PUT "https://www.citrulu.com/api/v1/test_files/2?name=foz&test_file_text=baz&run_tests=true&auth_token=abcdefg"
110
+ # PUT "https://app.citrulu.com/api/v1/test_files/2?name=foz&test_file_text=baz&run_tests=true&auth_token=abcdefg"
111
111
  def self.update(id, options={})
112
112
  response = Citrulu.connection.put "test_files/#{id}", options
113
113
  body = JSON.parse(response.body)
@@ -121,13 +121,13 @@ class TestFile
121
121
  end
122
122
  end
123
123
 
124
- # DELETE "https://www.citrulu.com/api/v1/test_files/2?auth_token=abcdefg"
124
+ # DELETE "https://app.citrulu.com/api/v1/test_files/2?auth_token=abcdefg"
125
125
  # Status 204 = successful deletion
126
126
  def self.delete(id)
127
127
  Citrulu.connection.delete "test_files/#{id}"
128
128
  end
129
129
 
130
- # POST "https://www.citrulu.com/api/v1/test_files/compile/?auth_token=abcdefg"
130
+ # POST "https://app.citrulu.com/api/v1/test_files/compile/?auth_token=abcdefg"
131
131
  # status: 201 = successful compilation
132
132
  def self.compile(id)
133
133
  response = Citrulu.connection.post "test_files/compile/#{id}"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: citrulu
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-10-29 00:00:00.000000000 Z
12
+ date: 2012-12-11 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: faraday
@@ -199,7 +199,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
199
199
  version: '0'
200
200
  segments:
201
201
  - 0
202
- hash: -1012160131491449687
202
+ hash: -2632210776876192041
203
203
  required_rubygems_version: !ruby/object:Gem::Requirement
204
204
  none: false
205
205
  requirements: