ticketmaster-unfuddle 0.4.0 → 0.5.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.
data/README.md CHANGED
@@ -2,6 +2,17 @@
2
2
 
3
3
  Ticketmaster provider for Unfuddle.
4
4
 
5
+ ## Usage
6
+
7
+ Instantiate the TicketMaster instance
8
+
9
+ unfuddle = TicketMaster.new(:unfuddle, :username => "user", :password => "p4ss!", :account => 'unfud')
10
+
11
+ if this gives you trouble when trying to access projects or tickets, you can set the protocol explicitly. By default,
12
+ as of version 0.4.0, the protocol is 'https'. Some older projects may need to set to 'http'.
13
+
14
+ unfuddle = TicketMaster.new(:unfuddle, :username => "user", :password => "p4ss!", :account => 'unfud', :protocol => 'http')
15
+
5
16
  ## Note on Patches/Pull Requests
6
17
 
7
18
  * Fork the project.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.4.0
1
+ 0.5.0
@@ -25,6 +25,14 @@ module TicketMaster::Provider
25
25
 
26
26
  # declare needed overloaded methods here
27
27
 
28
+ def valid?
29
+ begin
30
+ PROJECT_API.find(:first)
31
+ true
32
+ rescue
33
+ false
34
+ end
35
+ end
28
36
  end
29
37
  end
30
38
 
@@ -1,9 +1,16 @@
1
1
  require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
2
2
 
3
3
  describe "Ticketmaster::Provider::Unfuddle" do
4
+ before(:each) do
5
+ @ticketmaster = TicketMaster.new(:unfuddle, {:account => 'ticketmaster', :username => 'foo', :password => '000000'})
6
+ headers = {'Authorization' => 'Basic Zm9vOjAwMDAwMA==', 'Accept' => 'application/xml'}
7
+ ActiveResource::HttpMock.respond_to do |mock|
8
+ mock.get '/api/v1/projects.xml', headers, fixture_for('projects'), 200
9
+ end
10
+ end
4
11
 
5
12
  it "should be able to instantiate a new instance" do
6
- @ticketmaster = TicketMaster.new(:unfuddle, {:account => 'ticketmaster', :username => 'foo', :password => '000000'})
13
+
7
14
  @ticketmaster.should be_an_instance_of(TicketMaster)
8
15
  @ticketmaster.should be_a_kind_of(TicketMaster::Provider::Unfuddle)
9
16
  end
@@ -13,4 +20,8 @@ describe "Ticketmaster::Provider::Unfuddle" do
13
20
  @ticketmaster.provider::TICKET_API.site.should be_an_instance_of(URI::HTTPS)
14
21
  @ticketmaster.provider::PROJECT_API.site.should be_an_instance_of(URI::HTTPS)
15
22
  end
23
+
24
+ it "should return true for a valid authentication" do
25
+ @ticketmaster.valid?.should be_true
26
+ end
16
27
  end
@@ -1,73 +1,68 @@
1
1
  # Generated by jeweler
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
3
+ # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{ticketmaster-unfuddle}
8
- s.version = "0.4.0"
8
+ s.version = "0.5.0"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Luis Hurtado"]
12
- s.date = %q{2011-01-07}
12
+ s.date = %q{2011-06-06}
13
13
  s.description = %q{Unfuddle provider for ticketmaster implemented with ActiveResource}
14
14
  s.email = %q{luis@hybridgroup.com}
15
15
  s.extra_rdoc_files = [
16
16
  "LICENSE",
17
- "README.md",
18
- "README.rdoc"
17
+ "README.md"
19
18
  ]
20
19
  s.files = [
21
20
  ".document",
22
- ".gitignore",
23
- "LICENSE",
24
- "README.md",
25
- "README.rdoc",
26
- "Rakefile",
27
- "VERSION",
28
- "lib/provider/comment.rb",
29
- "lib/provider/project.rb",
30
- "lib/provider/ticket.rb",
31
- "lib/provider/unfuddle.rb",
32
- "lib/ticketmaster-unfuddle.rb",
33
- "lib/unfuddle/unfuddle-api.rb",
34
- "spec/comments_spec.rb",
35
- "spec/fixtures/comments.xml",
36
- "spec/fixtures/comments/0.xml",
37
- "spec/fixtures/comments/2.xml",
38
- "spec/fixtures/comments/3.xml",
39
- "spec/fixtures/comments/create.xml",
40
- "spec/fixtures/projects.xml",
41
- "spec/fixtures/projects/33041.xml",
42
- "spec/fixtures/projects/33042.xml",
43
- "spec/fixtures/projects/create.xml",
44
- "spec/fixtures/tickets.xml",
45
- "spec/fixtures/tickets/476814.xml",
46
- "spec/fixtures/tickets/476816.xml",
47
- "spec/fixtures/tickets/476834.xml",
48
- "spec/fixtures/tickets/create.xml",
49
- "spec/projects_spec.rb",
50
- "spec/spec.opts",
51
- "spec/spec_helper.rb",
52
- "spec/ticketmaster-unfuddle_spec.rb",
53
- "spec/tickets_spec.rb",
54
- "ticketmaster-unfuddle.gemspec"
21
+ "LICENSE",
22
+ "README.md",
23
+ "Rakefile",
24
+ "VERSION",
25
+ "lib/provider/comment.rb",
26
+ "lib/provider/project.rb",
27
+ "lib/provider/ticket.rb",
28
+ "lib/provider/unfuddle.rb",
29
+ "lib/ticketmaster-unfuddle.rb",
30
+ "lib/unfuddle/unfuddle-api.rb",
31
+ "spec/comments_spec.rb",
32
+ "spec/fixtures/comments.xml",
33
+ "spec/fixtures/comments/0.xml",
34
+ "spec/fixtures/comments/2.xml",
35
+ "spec/fixtures/comments/3.xml",
36
+ "spec/fixtures/comments/create.xml",
37
+ "spec/fixtures/projects.xml",
38
+ "spec/fixtures/projects/33041.xml",
39
+ "spec/fixtures/projects/33042.xml",
40
+ "spec/fixtures/projects/create.xml",
41
+ "spec/fixtures/tickets.xml",
42
+ "spec/fixtures/tickets/476814.xml",
43
+ "spec/fixtures/tickets/476816.xml",
44
+ "spec/fixtures/tickets/476834.xml",
45
+ "spec/fixtures/tickets/create.xml",
46
+ "spec/projects_spec.rb",
47
+ "spec/spec.opts",
48
+ "spec/spec_helper.rb",
49
+ "spec/ticketmaster-unfuddle_spec.rb",
50
+ "spec/tickets_spec.rb",
51
+ "ticketmaster-unfuddle.gemspec"
55
52
  ]
56
53
  s.homepage = %q{http://github.com/hybridgroup/ticketmaster-unfuddle}
57
- s.rdoc_options = ["--charset=UTF-8"]
58
54
  s.require_paths = ["lib"]
59
- s.rubygems_version = %q{1.3.7}
55
+ s.rubygems_version = %q{1.6.1}
60
56
  s.summary = %q{The Unfuddle provider for ticketmaster.}
61
57
  s.test_files = [
62
58
  "spec/comments_spec.rb",
63
- "spec/projects_spec.rb",
64
- "spec/spec_helper.rb",
65
- "spec/ticketmaster-unfuddle_spec.rb",
66
- "spec/tickets_spec.rb"
59
+ "spec/projects_spec.rb",
60
+ "spec/spec_helper.rb",
61
+ "spec/ticketmaster-unfuddle_spec.rb",
62
+ "spec/tickets_spec.rb"
67
63
  ]
68
64
 
69
65
  if s.respond_to? :specification_version then
70
- current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
71
66
  s.specification_version = 3
72
67
 
73
68
  if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ticketmaster-unfuddle
3
3
  version: !ruby/object:Gem::Version
4
- hash: 15
5
- prerelease: false
4
+ hash: 11
5
+ prerelease:
6
6
  segments:
7
7
  - 0
8
- - 4
8
+ - 5
9
9
  - 0
10
- version: 0.4.0
10
+ version: 0.5.0
11
11
  platform: ruby
12
12
  authors:
13
13
  - Luis Hurtado
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-01-07 00:00:00 -08:00
18
+ date: 2011-06-06 00:00:00 -04:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
@@ -43,13 +43,10 @@ extensions: []
43
43
  extra_rdoc_files:
44
44
  - LICENSE
45
45
  - README.md
46
- - README.rdoc
47
46
  files:
48
47
  - .document
49
- - .gitignore
50
48
  - LICENSE
51
49
  - README.md
52
- - README.rdoc
53
50
  - Rakefile
54
51
  - VERSION
55
52
  - lib/provider/comment.rb
@@ -84,8 +81,8 @@ homepage: http://github.com/hybridgroup/ticketmaster-unfuddle
84
81
  licenses: []
85
82
 
86
83
  post_install_message:
87
- rdoc_options:
88
- - --charset=UTF-8
84
+ rdoc_options: []
85
+
89
86
  require_paths:
90
87
  - lib
91
88
  required_ruby_version: !ruby/object:Gem::Requirement
@@ -109,7 +106,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
109
106
  requirements: []
110
107
 
111
108
  rubyforge_project:
112
- rubygems_version: 1.3.7
109
+ rubygems_version: 1.6.1
113
110
  signing_key:
114
111
  specification_version: 3
115
112
  summary: The Unfuddle provider for ticketmaster.
data/.gitignore DELETED
@@ -1,21 +0,0 @@
1
- ## MAC OS
2
- .DS_Store
3
-
4
- ## TEXTMATE
5
- *.tmproj
6
- tmtags
7
-
8
- ## EMACS
9
- *~
10
- \#*
11
- .\#*
12
-
13
- ## VIM
14
- *.swp
15
-
16
- ## PROJECT::GENERAL
17
- coverage
18
- rdoc
19
- pkg
20
-
21
- ## PROJECT::SPECIFIC
@@ -1,17 +0,0 @@
1
- = ticketmaster-unfuddle
2
-
3
- Description goes here.
4
-
5
- == Note on Patches/Pull Requests
6
-
7
- * Fork the project.
8
- * Make your feature addition or bug fix.
9
- * Add tests for it. This is important so I don't break it in a
10
- future version unintentionally.
11
- * Commit, do not mess with rakefile, version, or history.
12
- (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
13
- * Send me a pull request. Bonus points for topic branches.
14
-
15
- == Copyright
16
-
17
- Copyright (c) 2010 Luis Hurtado. See LICENSE for details.