fastly 0.5

Sign up to get free protection for your applications and to get access to all the features.
data/test/helper.rb ADDED
@@ -0,0 +1,24 @@
1
+ require File.expand_path(File.dirname(__FILE__) + '/common')
2
+
3
+ def login_opts(mode=:full)
4
+ opts = { }
5
+ [:url,:port].each do |what|
6
+ key = "FASTLY_TEST_BASE_#{what.to_s.upcase}"
7
+ opts["base_#{what}".to_sym] = ENV[key] if ENV.has_key?(key)
8
+ end
9
+
10
+ required = :full == mode ? [:user, :name, :password, :customer] : [:api_key]
11
+ required.each do |what|
12
+ key ="FASTLY_TEST_#{what.to_s.upcase}"
13
+ unless ENV.has_key?(key)
14
+ warn "You haven't set the environment variable #{key}"
15
+ exit(-1)
16
+ end
17
+ opts[what] = ENV[key]
18
+ end
19
+ opts
20
+ end
21
+
22
+ def get_rand
23
+ "#{Process.pid}-#{Time.now.to_i}-#{Kernel.rand(1000)}"
24
+ end
metadata ADDED
@@ -0,0 +1,157 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: fastly
3
+ version: !ruby/object:Gem::Version
4
+ hash: 1
5
+ prerelease:
6
+ segments:
7
+ - 0
8
+ - 5
9
+ version: "0.5"
10
+ platform: ruby
11
+ authors:
12
+ - Fastly Inc
13
+ autorequire:
14
+ bindir: bin
15
+ cert_chain: []
16
+
17
+ date: 2011-11-02 00:00:00 Z
18
+ dependencies:
19
+ - !ruby/object:Gem::Dependency
20
+ name: json
21
+ prerelease: false
22
+ requirement: &id001 !ruby/object:Gem::Requirement
23
+ none: false
24
+ requirements:
25
+ - - ">="
26
+ - !ruby/object:Gem::Version
27
+ hash: 3
28
+ segments:
29
+ - 0
30
+ version: "0"
31
+ type: :runtime
32
+ version_requirements: *id001
33
+ - !ruby/object:Gem::Dependency
34
+ name: curb
35
+ prerelease: false
36
+ requirement: &id002 !ruby/object:Gem::Requirement
37
+ none: false
38
+ requirements:
39
+ - - ">="
40
+ - !ruby/object:Gem::Version
41
+ hash: 29
42
+ segments:
43
+ - 0
44
+ - 7
45
+ - 15
46
+ version: 0.7.15
47
+ type: :runtime
48
+ version_requirements: *id002
49
+ - !ruby/object:Gem::Dependency
50
+ name: curb-fu
51
+ prerelease: false
52
+ requirement: &id003 !ruby/object:Gem::Requirement
53
+ none: false
54
+ requirements:
55
+ - - ">="
56
+ - !ruby/object:Gem::Version
57
+ hash: 5
58
+ segments:
59
+ - 0
60
+ - 6
61
+ - 1
62
+ version: 0.6.1
63
+ type: :runtime
64
+ version_requirements: *id003
65
+ - !ruby/object:Gem::Dependency
66
+ name: rdoc
67
+ prerelease: false
68
+ requirement: &id004 !ruby/object:Gem::Requirement
69
+ none: false
70
+ requirements:
71
+ - - ">="
72
+ - !ruby/object:Gem::Version
73
+ hash: 17
74
+ segments:
75
+ - 3
76
+ - 11
77
+ version: "3.11"
78
+ type: :runtime
79
+ version_requirements: *id004
80
+ description: Client library for the Fastly acceleration system
81
+ email:
82
+ - support@fastly.com
83
+ executables:
84
+ - fastly_upload_vcl
85
+ extensions: []
86
+
87
+ extra_rdoc_files: []
88
+
89
+ files:
90
+ - .gitignore
91
+ - Gemfile
92
+ - README.md
93
+ - Rakefile
94
+ - bin/fastly_upload_vcl
95
+ - fastly.gemspec
96
+ - lib/fastly.rb
97
+ - lib/fastly/backend.rb
98
+ - lib/fastly/base.rb
99
+ - lib/fastly/belongs_to_service_and_version.rb
100
+ - lib/fastly/client.rb
101
+ - lib/fastly/customer.rb
102
+ - lib/fastly/director.rb
103
+ - lib/fastly/domain.rb
104
+ - lib/fastly/fetcher.rb
105
+ - lib/fastly/invoice.rb
106
+ - lib/fastly/match.rb
107
+ - lib/fastly/origin.rb
108
+ - lib/fastly/service.rb
109
+ - lib/fastly/settings.rb
110
+ - lib/fastly/user.rb
111
+ - lib/fastly/vcl.rb
112
+ - lib/fastly/version.rb
113
+ - test/admin_test.rb
114
+ - test/api_key_test.rb
115
+ - test/common.rb
116
+ - test/full_login_test.rb
117
+ - test/helper.rb
118
+ homepage: http://github.com/fastly/fastly-ruby
119
+ licenses: []
120
+
121
+ post_install_message:
122
+ rdoc_options: []
123
+
124
+ require_paths:
125
+ - lib
126
+ required_ruby_version: !ruby/object:Gem::Requirement
127
+ none: false
128
+ requirements:
129
+ - - ">="
130
+ - !ruby/object:Gem::Version
131
+ hash: 3
132
+ segments:
133
+ - 0
134
+ version: "0"
135
+ required_rubygems_version: !ruby/object:Gem::Requirement
136
+ none: false
137
+ requirements:
138
+ - - ">="
139
+ - !ruby/object:Gem::Version
140
+ hash: 3
141
+ segments:
142
+ - 0
143
+ version: "0"
144
+ requirements: []
145
+
146
+ rubyforge_project:
147
+ rubygems_version: 1.8.11
148
+ signing_key:
149
+ specification_version: 3
150
+ summary: Client library for the Fastly acceleration system
151
+ test_files:
152
+ - test/admin_test.rb
153
+ - test/api_key_test.rb
154
+ - test/common.rb
155
+ - test/full_login_test.rb
156
+ - test/helper.rb
157
+ has_rdoc: