zedkit 1.1.5 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,38 @@
1
+ #
2
+ # Copyright (c) Zedkit.
3
+ #
4
+ # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation
5
+ # files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy,
6
+ # modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the
7
+ # Software is furnished to do so, subject to the following conditions:
8
+ #
9
+ # The above copyright notice and this permission notice shall be included in all copies or substantial portions of the
10
+ # Software.
11
+ #
12
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
13
+ # WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
14
+ # COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
15
+ # ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
16
+ #
17
+
18
+ require "helper"
19
+
20
+ class TestShortenedUrls < Test::Unit::TestCase
21
+ def test_get
22
+ end
23
+ def test_get_with_block
24
+ end
25
+
26
+ def test_create
27
+ end
28
+ def test_create_with_block
29
+ end
30
+
31
+ def test_update
32
+ end
33
+ def test_update_with_block
34
+ end
35
+
36
+ def test_delete
37
+ end
38
+ end
@@ -0,0 +1,41 @@
1
+ #
2
+ # Copyright (c) Zedkit.
3
+ #
4
+ # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation
5
+ # files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy,
6
+ # modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the
7
+ # Software is furnished to do so, subject to the following conditions:
8
+ #
9
+ # The above copyright notice and this permission notice shall be included in all copies or substantial portions of the
10
+ # Software.
11
+ #
12
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
13
+ # WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
14
+ # COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
15
+ # ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
16
+ #
17
+
18
+ require "helper"
19
+
20
+ class TestShorteners < Test::Unit::TestCase
21
+ def test_get
22
+ end
23
+ def test_get_with_block
24
+ end
25
+
26
+ def test_create
27
+ sh = Zedkit::Shorteners.create(:user_key => @uu["user_key"],
28
+ :project => { :uuid => @uu["projects"][0] }, :shortener => { :domain => "yo.im" })
29
+ assert_equal "yo.im", sh["domain"]
30
+ end
31
+ def test_create_with_block
32
+ end
33
+
34
+ def test_update
35
+ end
36
+ def test_update_with_block
37
+ end
38
+
39
+ def test_delete
40
+ end
41
+ end
@@ -1,4 +1,4 @@
1
- ##
1
+ #
2
2
  # Copyright (c) Zedkit.
3
3
  #
4
4
  # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation
@@ -13,69 +13,69 @@
13
13
  # WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
14
14
  # COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
15
15
  # ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
16
- ##
16
+ #
17
17
 
18
- require 'helper'
18
+ require "helper"
19
19
 
20
20
  class TestUsers < Test::Unit::TestCase
21
21
  def test_verify_fails
22
- assert_nil Zedkit::Users.verify(:username => TEST_GEMS_LOGIN, :password => 'not.the.password')
22
+ assert_nil Zedkit::Users.verify(:username => TEST_GEMS_LOGIN, :password => "not.the.password")
23
23
  end
24
24
  def test_verify
25
25
  assert @uu.is_a? Hash
26
- assert_equal 32, @uu['uuid'].length
27
- assert_equal TEST_GEMS_LOGIN, @uu['email']
26
+ assert_equal 32, @uu["uuid"].length
27
+ assert_equal TEST_GEMS_LOGIN, @uu["email"]
28
28
  end
29
29
  def test_verify_with_block
30
30
  Zedkit::Users.verify(:username => TEST_GEMS_LOGIN, :password => TEST_GEMS_PASSWORD) do |uu|
31
31
  assert @uu.is_a? Hash
32
- assert_equal 32, @uu['uuid'].length
32
+ assert_equal 32, @uu["uuid"].length
33
33
  end
34
34
  end
35
35
 
36
36
  def test_projects_list
37
- pp = Zedkit::Users::Projects.get(:user_key => @uu['user_key'], :whatever => "yo")
37
+ pp = Zedkit::Users::Projects.get(:user_key => @uu["user_key"], :whatever => "yo")
38
38
  assert pp.is_a? Array
39
39
  assert_equal 1, pp.length
40
40
  end
41
41
  def test_projects_list_with_block
42
- Zedkit::Users::Projects.get(:user_key => @uu['user_key']) do |pp|
43
- assert_not_nil pp['project']
44
- assert_not_nil pp['permissions']
42
+ Zedkit::Users::Projects.get(:user_key => @uu["user_key"]) do |pp|
43
+ assert_not_nil pp["project"]
44
+ assert_not_nil pp["permissions"]
45
45
  end
46
46
  end
47
47
 
48
48
  def test_get_fails
49
- assert_nil Zedkit::Users.get(:user_key => 'whatever', :uuid => 'notvaliduuid')
49
+ assert_nil Zedkit::Users.get(:user_key => "whatever", :uuid => "notvaliduuid")
50
50
  end
51
51
  def test_get
52
- uu = Zedkit::Users.get(:user_key => @uu['user_key'], :uuid => @uu['uuid'])
52
+ uu = Zedkit::Users.get(:user_key => @uu["user_key"], :uuid => @uu["uuid"])
53
53
  assert uu.is_a? Hash
54
- assert_equal 32, uu['uuid'].length
55
- assert_equal TEST_GEMS_LOGIN, uu['email']
54
+ assert_equal 32, uu["uuid"].length
55
+ assert_equal TEST_GEMS_LOGIN, uu["email"]
56
56
  end
57
57
  def test_get_with_block
58
- Zedkit::Users.get(:user_key => @uu['user_key'], :uuid => @uu['uuid']) do |uu|
58
+ Zedkit::Users.get(:user_key => @uu["user_key"], :uuid => @uu["uuid"]) do |uu|
59
59
  assert uu.is_a? Hash
60
- assert_equal 32, uu['uuid'].length
60
+ assert_equal 32, uu["uuid"].length
61
61
  end
62
62
  end
63
63
 
64
64
  def test_create
65
- uu = Zedkit::Users.create(:user_key => @uu['user_key'], :user => { :first_name => 'Fred', :surname => 'Flinstone',
66
- :email => 'gemusertest@zedkit.com',
67
- :password => 'password' })
68
- assert uu.is_a? Hash
69
- assert_equal 32, uu['uuid'].length
70
- assert_equal 'Fred', uu['first_name']
71
- assert_equal 'gemusertest@zedkit.com', uu['email']
65
+ # uu = Zedkit::Users.create(:user_key => @uu["user_key"], :user => { :first_name => "Fred", :surname => "Flinstone",
66
+ # :email => "gemusertest@zedkit.com",
67
+ # :password => "password" })
68
+ # assert uu.is_a? Hash
69
+ # assert_equal 32, uu["uuid"].length
70
+ # assert_equal "Fred", uu["first_name"]
71
+ # assert_equal "gemusertest@zedkit.com", uu["email"]
72
72
  end
73
73
  def test_create_with_block
74
- Zedkit::Users.create(:user_key => @uu['user_key'], :user => { :first_name => 'Fred', :surname => 'Flinstone',
75
- :email => 'gemusertest@zedkit.com',
76
- :password => 'password' }) do |uu|
77
- assert uu.is_a? Hash
78
- assert_equal 32, uu['uuid'].length
79
- end
74
+ # Zedkit::Users.create(:user_key => @uu["user_key"], :user => { :first_name => "Fred", :surname => "Flinstone",
75
+ # :email => "gemusertest@zedkit.com",
76
+ # :password => "password" }) do |uu|
77
+ # assert uu.is_a? Hash
78
+ # assert_equal 32, uu["uuid"].length
79
+ # end
80
80
  end
81
81
  end
metadata CHANGED
@@ -1,60 +1,47 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: zedkit
3
- version: !ruby/object:Gem::Version
4
- prerelease: false
5
- segments:
6
- - 1
7
- - 1
8
- - 5
9
- version: 1.1.5
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.2.0
5
+ prerelease:
10
6
  platform: ruby
11
- authors:
7
+ authors:
12
8
  - Zedkit
13
9
  autorequire:
14
10
  bindir: bin
15
11
  cert_chain: []
16
-
17
- date: 2011-01-06 00:00:00 -08:00
18
- default_executable: zedkit
19
- dependencies:
20
- - !ruby/object:Gem::Dependency
12
+ date: 2012-01-08 00:00:00.000000000Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
21
15
  name: json
22
- prerelease: false
23
- requirement: &id001 !ruby/object:Gem::Requirement
16
+ requirement: &70306627927740 !ruby/object:Gem::Requirement
24
17
  none: false
25
- requirements:
26
- - - ">="
27
- - !ruby/object:Gem::Version
28
- segments:
29
- - 1
30
- - 4
31
- - 0
18
+ requirements:
19
+ - - ! '>='
20
+ - !ruby/object:Gem::Version
32
21
  version: 1.4.0
33
22
  type: :runtime
34
- version_requirements: *id001
35
- - !ruby/object:Gem::Dependency
36
- name: nestful
37
23
  prerelease: false
38
- requirement: &id002 !ruby/object:Gem::Requirement
24
+ version_requirements: *70306627927740
25
+ - !ruby/object:Gem::Dependency
26
+ name: nestful
27
+ requirement: &70306627921220 !ruby/object:Gem::Requirement
39
28
  none: false
40
- requirements:
41
- - - ">="
42
- - !ruby/object:Gem::Version
43
- segments:
44
- - 0
45
- version: "0"
29
+ requirements:
30
+ - - ! '>='
31
+ - !ruby/object:Gem::Version
32
+ version: '0'
46
33
  type: :runtime
47
- version_requirements: *id002
34
+ prerelease: false
35
+ version_requirements: *70306627921220
48
36
  description: gem for Zedkit with all the applicable good stuff easily accessible
49
37
  email: support@zedkit.com
50
- executables:
38
+ executables:
51
39
  - zedkit
52
40
  extensions: []
53
-
54
- extra_rdoc_files:
41
+ extra_rdoc_files:
55
42
  - LICENSE
56
43
  - README.rdoc
57
- files:
44
+ files:
58
45
  - LICENSE
59
46
  - README.rdoc
60
47
  - Rakefile
@@ -67,59 +54,58 @@ files:
67
54
  - lib/zedkit/cli/projects.rb
68
55
  - lib/zedkit/cli/runner.rb
69
56
  - lib/zedkit/cli/text.rb
57
+ - lib/zedkit/cli/users.rb
70
58
  - lib/zedkit/client/client.rb
71
59
  - lib/zedkit/client/configuration.rb
72
60
  - lib/zedkit/client/exceptions.rb
61
+ - lib/zedkit/ext/array.rb
62
+ - lib/zedkit/ext/benchmark.rb
73
63
  - lib/zedkit/ext/hash.rb
74
64
  - lib/zedkit/instances/instance.rb
75
65
  - lib/zedkit/instances/project.rb
76
66
  - lib/zedkit/rails/sessions.rb
67
+ - lib/zedkit/resources/blog_posts.rb
68
+ - lib/zedkit/resources/blogs.rb
77
69
  - lib/zedkit/resources/email_settings.rb
78
70
  - lib/zedkit/resources/emails.rb
71
+ - lib/zedkit/resources/project_admins.rb
72
+ - lib/zedkit/resources/project_keys.rb
79
73
  - lib/zedkit/resources/projects.rb
74
+ - lib/zedkit/resources/shortened_urls.rb
75
+ - lib/zedkit/resources/shorteners.rb
80
76
  - lib/zedkit/resources/users.rb
81
77
  - test/helper.rb
78
+ - test/test_blog_posts.rb
79
+ - test/test_blogs.rb
82
80
  - test/test_email_settings.rb
83
81
  - test/test_emails.rb
84
82
  - test/test_entities.rb
85
83
  - test/test_projects.rb
84
+ - test/test_shortened_urls.rb
85
+ - test/test_shorteners.rb
86
86
  - test/test_users.rb
87
- has_rdoc: true
88
87
  homepage: http://github.com/zedkit/zedkit
89
88
  licenses: []
90
-
91
89
  post_install_message:
92
90
  rdoc_options: []
93
-
94
- require_paths:
91
+ require_paths:
95
92
  - lib
96
- required_ruby_version: !ruby/object:Gem::Requirement
93
+ required_ruby_version: !ruby/object:Gem::Requirement
97
94
  none: false
98
- requirements:
99
- - - ">="
100
- - !ruby/object:Gem::Version
101
- segments:
102
- - 0
103
- version: "0"
104
- required_rubygems_version: !ruby/object:Gem::Requirement
95
+ requirements:
96
+ - - ! '>='
97
+ - !ruby/object:Gem::Version
98
+ version: '0'
99
+ required_rubygems_version: !ruby/object:Gem::Requirement
105
100
  none: false
106
- requirements:
107
- - - ">="
108
- - !ruby/object:Gem::Version
109
- segments:
110
- - 0
111
- version: "0"
101
+ requirements:
102
+ - - ! '>='
103
+ - !ruby/object:Gem::Version
104
+ version: '0'
112
105
  requirements: []
113
-
114
106
  rubyforge_project: zedkit
115
- rubygems_version: 1.3.7
107
+ rubygems_version: 1.8.10
116
108
  signing_key:
117
109
  specification_version: 3
118
110
  summary: gem for Zedkit
119
- test_files:
120
- - test/helper.rb
121
- - test/test_email_settings.rb
122
- - test/test_emails.rb
123
- - test/test_entities.rb
124
- - test/test_projects.rb
125
- - test/test_users.rb
111
+ test_files: []