htty 1.5.4 → 1.5.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +12 -9
- data/.rspec +2 -1
- data/.travis.yml +11 -8
- data/.yardopts +1 -1
- data/Gemfile +22 -10
- data/Guardfile +31 -13
- data/History.markdown +6 -0
- data/README.markdown +29 -13
- data/Rakefile +2 -64
- data/bin/console +10 -0
- data/bin/setup +8 -0
- data/exe/htty +5 -0
- data/htty.gemspec +27 -29
- data/lib/htty.rb +29 -4
- data/lib/htty/cli.rb +9 -16
- data/lib/htty/cli/body_open_command.rb +2 -7
- data/lib/htty/cli/command.rb +10 -18
- data/lib/htty/cli/commands.rb +76 -11
- data/lib/htty/cli/commands/address.rb +1 -14
- data/lib/htty/cli/commands/body_clear.rb +1 -8
- data/lib/htty/cli/commands/body_edit.rb +1 -11
- data/lib/htty/cli/commands/body_request.rb +1 -12
- data/lib/htty/cli/commands/body_request_open.rb +1 -10
- data/lib/htty/cli/commands/body_response.rb +1 -12
- data/lib/htty/cli/commands/body_response_open.rb +1 -11
- data/lib/htty/cli/commands/body_set.rb +1 -10
- data/lib/htty/cli/commands/body_unset.rb +1 -9
- data/lib/htty/cli/commands/cd.rb +1 -8
- data/lib/htty/cli/commands/cookie_add.rb +1 -8
- data/lib/htty/cli/commands/cookie_remove.rb +1 -8
- data/lib/htty/cli/commands/cookies.rb +1 -15
- data/lib/htty/cli/commands/cookies_add.rb +1 -11
- data/lib/htty/cli/commands/cookies_clear.rb +1 -8
- data/lib/htty/cli/commands/cookies_remove.rb +1 -11
- data/lib/htty/cli/commands/cookies_remove_all.rb +1 -11
- data/lib/htty/cli/commands/cookies_use.rb +1 -14
- data/lib/htty/cli/commands/delete.rb +1 -8
- data/lib/htty/cli/commands/exit.rb +1 -8
- data/lib/htty/cli/commands/follow.rb +1 -10
- data/lib/htty/cli/commands/form.rb +1 -7
- data/lib/htty/cli/commands/form_add.rb +1 -7
- data/lib/htty/cli/commands/form_clear.rb +1 -8
- data/lib/htty/cli/commands/form_remove.rb +1 -7
- data/lib/htty/cli/commands/form_remove_all.rb +1 -7
- data/lib/htty/cli/commands/fragment_clear.rb +1 -8
- data/lib/htty/cli/commands/fragment_set.rb +1 -10
- data/lib/htty/cli/commands/fragment_unset.rb +1 -9
- data/lib/htty/cli/commands/get.rb +1 -8
- data/lib/htty/cli/commands/header_set.rb +1 -8
- data/lib/htty/cli/commands/header_unset.rb +1 -8
- data/lib/htty/cli/commands/headers_clear.rb +1 -8
- data/lib/htty/cli/commands/headers_request.rb +1 -15
- data/lib/htty/cli/commands/headers_response.rb +1 -15
- data/lib/htty/cli/commands/headers_set.rb +1 -10
- data/lib/htty/cli/commands/headers_unset.rb +1 -10
- data/lib/htty/cli/commands/headers_unset_all.rb +1 -10
- data/lib/htty/cli/commands/help.rb +4 -12
- data/lib/htty/cli/commands/history.rb +1 -10
- data/lib/htty/cli/commands/history_verbose.rb +1 -12
- data/lib/htty/cli/commands/host_set.rb +1 -8
- data/lib/htty/cli/commands/http_delete.rb +1 -12
- data/lib/htty/cli/commands/http_get.rb +1 -13
- data/lib/htty/cli/commands/http_head.rb +1 -9
- data/lib/htty/cli/commands/http_options.rb +1 -9
- data/lib/htty/cli/commands/http_patch.rb +1 -13
- data/lib/htty/cli/commands/http_post.rb +1 -13
- data/lib/htty/cli/commands/http_put.rb +1 -12
- data/lib/htty/cli/commands/http_trace.rb +1 -9
- data/lib/htty/cli/commands/patch.rb +1 -8
- data/lib/htty/cli/commands/path_set.rb +11 -11
- data/lib/htty/cli/commands/port_set.rb +1 -9
- data/lib/htty/cli/commands/post.rb +1 -8
- data/lib/htty/cli/commands/put.rb +1 -8
- data/lib/htty/cli/commands/query_add.rb +1 -13
- data/lib/htty/cli/commands/query_clear.rb +1 -8
- data/lib/htty/cli/commands/query_remove.rb +1 -13
- data/lib/htty/cli/commands/query_set.rb +1 -13
- data/lib/htty/cli/commands/query_unset.rb +1 -13
- data/lib/htty/cli/commands/query_unset_all.rb +1 -10
- data/lib/htty/cli/commands/quit.rb +1 -7
- data/lib/htty/cli/commands/reuse.rb +5 -12
- data/lib/htty/cli/commands/scheme_set.rb +1 -9
- data/lib/htty/cli/commands/ssl_verification.rb +1 -11
- data/lib/htty/cli/commands/ssl_verification_off.rb +1 -10
- data/lib/htty/cli/commands/ssl_verification_on.rb +1 -10
- data/lib/htty/cli/commands/status.rb +1 -11
- data/lib/htty/cli/commands/undo.rb +1 -7
- data/lib/htty/cli/commands/userinfo_clear.rb +1 -8
- data/lib/htty/cli/commands/userinfo_set.rb +1 -11
- data/lib/htty/cli/commands/userinfo_unset.rb +1 -9
- data/lib/htty/cli/display.rb +4 -6
- data/lib/htty/cli/http_method_command.rb +1 -10
- data/lib/htty/cli/input_device.rb +1 -0
- data/lib/htty/cli/url_escaping.rb +1 -6
- data/lib/htty/cookies_util.rb +3 -3
- data/lib/htty/headers.rb +3 -4
- data/lib/htty/http_patch.rb +20 -23
- data/lib/htty/no_header_error.rb +1 -1
- data/lib/htty/no_location_header_error.rb +1 -3
- data/lib/htty/no_response_error.rb +1 -1
- data/lib/htty/no_set_cookie_header_error.rb +1 -3
- data/lib/htty/payload.rb +1 -5
- data/lib/htty/platform.rb +1 -1
- data/lib/htty/preferences.rb +1 -1
- data/lib/htty/request.rb +3 -13
- data/lib/htty/requests_util.rb +1 -5
- data/lib/htty/response.rb +1 -4
- data/lib/htty/session.rb +1 -3
- data/lib/htty/tempfile_preserving_extname.rb +1 -2
- data/lib/htty/uri.rb +1 -2
- data/lib/htty/version.rb +1 -1
- data/lib/tasks.rb +3 -0
- data/lib/tasks/build_doc.rake +8 -0
- data/lib/tasks/lib_each.rake +25 -0
- data/lib/tasks/spec.rake +68 -0
- data/lib/tasks/spec_each.rake +19 -0
- metadata +48 -209
- data/bin/htty +0 -5
- data/spec/integration/htty/cli/commands/query_add_spec.rb +0 -57
- data/spec/integration/htty/cli/commands/query_remove_spec.rb +0 -55
- data/spec/integration/htty/cli/commands/query_set_spec.rb +0 -78
- data/spec/integration/htty/cli/commands/query_unset_spec.rb +0 -43
- data/spec/spec_helper.rb +0 -76
- data/spec/unit/htty/cli/commands/address_spec.rb +0 -103
- data/spec/unit/htty/cli/commands/body_clear_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/body_edit_spec.rb +0 -18
- data/spec/unit/htty/cli/commands/body_request_spec.rb +0 -67
- data/spec/unit/htty/cli/commands/body_response_spec.rb +0 -72
- data/spec/unit/htty/cli/commands/body_set_spec.rb +0 -71
- data/spec/unit/htty/cli/commands/body_unset_spec.rb +0 -69
- data/spec/unit/htty/cli/commands/cd_spec.rb +0 -57
- data/spec/unit/htty/cli/commands/cookie_add_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/cookie_remove_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/cookies_add_spec.rb +0 -78
- data/spec/unit/htty/cli/commands/cookies_clear_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/cookies_remove_all_spec.rb +0 -73
- data/spec/unit/htty/cli/commands/cookies_remove_spec.rb +0 -69
- data/spec/unit/htty/cli/commands/cookies_spec.rb +0 -76
- data/spec/unit/htty/cli/commands/cookies_use_spec.rb +0 -75
- data/spec/unit/htty/cli/commands/delete_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/exit_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/follow_spec.rb +0 -70
- data/spec/unit/htty/cli/commands/form_add_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/form_clear_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/form_remove_all_spec.rb +0 -66
- data/spec/unit/htty/cli/commands/form_remove_spec.rb +0 -57
- data/spec/unit/htty/cli/commands/form_spec.rb +0 -57
- data/spec/unit/htty/cli/commands/fragment_clear_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/fragment_set_spec.rb +0 -73
- data/spec/unit/htty/cli/commands/fragment_unset_spec.rb +0 -72
- data/spec/unit/htty/cli/commands/get_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/header_set_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/header_unset_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/headers_clear_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/headers_request_spec.rb +0 -81
- data/spec/unit/htty/cli/commands/headers_response_spec.rb +0 -77
- data/spec/unit/htty/cli/commands/headers_set_spec.rb +0 -74
- data/spec/unit/htty/cli/commands/headers_unset_all_spec.rb +0 -71
- data/spec/unit/htty/cli/commands/headers_unset_spec.rb +0 -63
- data/spec/unit/htty/cli/commands/help_spec.rb +0 -67
- data/spec/unit/htty/cli/commands/history_spec.rb +0 -65
- data/spec/unit/htty/cli/commands/history_verbose_spec.rb +0 -72
- data/spec/unit/htty/cli/commands/host_set_spec.rb +0 -71
- data/spec/unit/htty/cli/commands/http_delete_spec.rb +0 -75
- data/spec/unit/htty/cli/commands/http_get_spec.rb +0 -77
- data/spec/unit/htty/cli/commands/http_head_spec.rb +0 -69
- data/spec/unit/htty/cli/commands/http_options_spec.rb +0 -69
- data/spec/unit/htty/cli/commands/http_patch_spec.rb +0 -73
- data/spec/unit/htty/cli/commands/http_post_spec.rb +0 -73
- data/spec/unit/htty/cli/commands/http_put_spec.rb +0 -71
- data/spec/unit/htty/cli/commands/http_trace_spec.rb +0 -69
- data/spec/unit/htty/cli/commands/patch_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/path_set_spec.rb +0 -72
- data/spec/unit/htty/cli/commands/port_set_spec.rb +0 -73
- data/spec/unit/htty/cli/commands/post_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/put_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/query_add_spec.rb +0 -82
- data/spec/unit/htty/cli/commands/query_clear_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/query_remove_spec.rb +0 -82
- data/spec/unit/htty/cli/commands/query_set_spec.rb +0 -82
- data/spec/unit/htty/cli/commands/query_unset_all_spec.rb +0 -74
- data/spec/unit/htty/cli/commands/query_unset_spec.rb +0 -75
- data/spec/unit/htty/cli/commands/quit_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/reuse_spec.rb +0 -72
- data/spec/unit/htty/cli/commands/scheme_set_spec.rb +0 -74
- data/spec/unit/htty/cli/commands/shared_examples_for_commands.rb +0 -55
- data/spec/unit/htty/cli/commands/ssl_verification_off_spec.rb +0 -67
- data/spec/unit/htty/cli/commands/ssl_verification_on_spec.rb +0 -60
- data/spec/unit/htty/cli/commands/ssl_verification_spec.rb +0 -65
- data/spec/unit/htty/cli/commands/status_spec.rb +0 -73
- data/spec/unit/htty/cli/commands/undo_spec.rb +0 -57
- data/spec/unit/htty/cli/commands/userinfo_clear_spec.rb +0 -64
- data/spec/unit/htty/cli/commands/userinfo_set_spec.rb +0 -97
- data/spec/unit/htty/cli/commands/userinfo_unset_spec.rb +0 -72
- data/spec/unit/htty/cli/display_spec.rb +0 -84
- data/spec/unit/htty/cli_spec.rb +0 -28
- data/spec/unit/htty/command.rb +0 -47
- data/spec/unit/htty/headers_spec.rb +0 -40
- data/spec/unit/htty/payload_spec.rb +0 -60
- data/spec/unit/htty/preferences_spec.rb +0 -8
- data/spec/unit/htty/request_follow_spec.rb +0 -94
- data/spec/unit/htty/request_spec.rb +0 -1232
- data/spec/unit/htty/request_userinfo_spec.rb +0 -208
- data/spec/unit/htty/response_spec.rb +0 -0
- data/spec/unit/htty/session_spec.rb +0 -10
- data/spec/unit/htty/shared_examples_for_requests.rb +0 -32
- data/spec/unit/htty/url_escaping.rb +0 -70
- data/spec/unit/htty/version_spec.rb +0 -8
@@ -0,0 +1,19 @@
|
|
1
|
+
begin
|
2
|
+
require 'rspec/core/rake_task'
|
3
|
+
rescue LoadError
|
4
|
+
else
|
5
|
+
namespace :spec do
|
6
|
+
desc "Run each spec individually, looking for missing 'require' statements"
|
7
|
+
task :each do
|
8
|
+
add_separator = false
|
9
|
+
Dir.glob( 'spec/**/*_spec.rb' ) do |f|
|
10
|
+
puts '-' * `tput cols`.chomp.to_i if add_separator
|
11
|
+
add_separator = true
|
12
|
+
puts "Running #{f} ..."
|
13
|
+
unless system( "/usr/bin/env bundle exec rspec --format=progress --no-profile #{f.inspect}" )
|
14
|
+
fail
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
metadata
CHANGED
@@ -1,61 +1,73 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: htty
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nils Jonsson
|
8
8
|
autorequire:
|
9
|
-
bindir:
|
9
|
+
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-10-
|
11
|
+
date: 2015-10-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mime-types
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - ~>
|
17
|
+
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '1'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - ~>
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: bundler
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '1'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
25
39
|
- !ruby/object:Gem::Version
|
26
40
|
version: '1'
|
27
41
|
- !ruby/object:Gem::Dependency
|
28
42
|
name: rake
|
29
43
|
requirement: !ruby/object:Gem::Requirement
|
30
44
|
requirements:
|
31
|
-
- -
|
45
|
+
- - "~>"
|
32
46
|
- !ruby/object:Gem::Version
|
33
|
-
version: '
|
47
|
+
version: '10'
|
34
48
|
type: :development
|
35
49
|
prerelease: false
|
36
50
|
version_requirements: !ruby/object:Gem::Requirement
|
37
51
|
requirements:
|
38
|
-
- -
|
52
|
+
- - "~>"
|
39
53
|
- !ruby/object:Gem::Version
|
40
|
-
version: '
|
54
|
+
version: '10'
|
41
55
|
- !ruby/object:Gem::Dependency
|
42
56
|
name: rspec
|
43
57
|
requirement: !ruby/object:Gem::Requirement
|
44
58
|
requirements:
|
45
|
-
- - ~>
|
59
|
+
- - "~>"
|
46
60
|
- !ruby/object:Gem::Version
|
47
|
-
version: '
|
61
|
+
version: '3.3'
|
48
62
|
type: :development
|
49
63
|
prerelease: false
|
50
64
|
version_requirements: !ruby/object:Gem::Requirement
|
51
65
|
requirements:
|
52
|
-
- - ~>
|
66
|
+
- - "~>"
|
53
67
|
- !ruby/object:Gem::Version
|
54
|
-
version: '
|
55
|
-
description:
|
56
|
-
|
57
|
-
It's a fun way to explore web APIs and to learn the ins and
|
58
|
-
outs of HTTP.
|
68
|
+
version: '3.3'
|
69
|
+
description: htty is a console application for interacting with web servers. It's
|
70
|
+
a fun way to explore web APIs and to learn the ins and outs of HTTP.
|
59
71
|
email:
|
60
72
|
- htty@nilsjonsson.com
|
61
73
|
executables:
|
@@ -63,19 +75,21 @@ executables:
|
|
63
75
|
extensions: []
|
64
76
|
extra_rdoc_files: []
|
65
77
|
files:
|
66
|
-
- .gemtest
|
67
|
-
- .gitignore
|
68
|
-
- .rspec
|
69
|
-
- .travis.yml
|
70
|
-
- .yardopts
|
78
|
+
- ".gemtest"
|
79
|
+
- ".gitignore"
|
80
|
+
- ".rspec"
|
81
|
+
- ".travis.yml"
|
82
|
+
- ".yardopts"
|
71
83
|
- Gemfile
|
72
84
|
- Guardfile
|
73
85
|
- History.markdown
|
74
86
|
- License.markdown
|
75
87
|
- README.markdown
|
76
88
|
- Rakefile
|
77
|
-
- bin/
|
89
|
+
- bin/console
|
90
|
+
- bin/setup
|
78
91
|
- examples.markdown
|
92
|
+
- exe/htty
|
79
93
|
- htty.gemspec
|
80
94
|
- lib/htty.rb
|
81
95
|
- lib/htty/cli.rb
|
@@ -175,96 +189,11 @@ files:
|
|
175
189
|
- lib/htty/tempfile_preserving_extname.rb
|
176
190
|
- lib/htty/uri.rb
|
177
191
|
- lib/htty/version.rb
|
178
|
-
-
|
179
|
-
-
|
180
|
-
-
|
181
|
-
-
|
182
|
-
-
|
183
|
-
- spec/unit/htty/cli/commands/address_spec.rb
|
184
|
-
- spec/unit/htty/cli/commands/body_clear_spec.rb
|
185
|
-
- spec/unit/htty/cli/commands/body_edit_spec.rb
|
186
|
-
- spec/unit/htty/cli/commands/body_request_spec.rb
|
187
|
-
- spec/unit/htty/cli/commands/body_response_spec.rb
|
188
|
-
- spec/unit/htty/cli/commands/body_set_spec.rb
|
189
|
-
- spec/unit/htty/cli/commands/body_unset_spec.rb
|
190
|
-
- spec/unit/htty/cli/commands/cd_spec.rb
|
191
|
-
- spec/unit/htty/cli/commands/cookie_add_spec.rb
|
192
|
-
- spec/unit/htty/cli/commands/cookie_remove_spec.rb
|
193
|
-
- spec/unit/htty/cli/commands/cookies_add_spec.rb
|
194
|
-
- spec/unit/htty/cli/commands/cookies_clear_spec.rb
|
195
|
-
- spec/unit/htty/cli/commands/cookies_remove_all_spec.rb
|
196
|
-
- spec/unit/htty/cli/commands/cookies_remove_spec.rb
|
197
|
-
- spec/unit/htty/cli/commands/cookies_spec.rb
|
198
|
-
- spec/unit/htty/cli/commands/cookies_use_spec.rb
|
199
|
-
- spec/unit/htty/cli/commands/delete_spec.rb
|
200
|
-
- spec/unit/htty/cli/commands/exit_spec.rb
|
201
|
-
- spec/unit/htty/cli/commands/follow_spec.rb
|
202
|
-
- spec/unit/htty/cli/commands/form_add_spec.rb
|
203
|
-
- spec/unit/htty/cli/commands/form_clear_spec.rb
|
204
|
-
- spec/unit/htty/cli/commands/form_remove_all_spec.rb
|
205
|
-
- spec/unit/htty/cli/commands/form_remove_spec.rb
|
206
|
-
- spec/unit/htty/cli/commands/form_spec.rb
|
207
|
-
- spec/unit/htty/cli/commands/fragment_clear_spec.rb
|
208
|
-
- spec/unit/htty/cli/commands/fragment_set_spec.rb
|
209
|
-
- spec/unit/htty/cli/commands/fragment_unset_spec.rb
|
210
|
-
- spec/unit/htty/cli/commands/get_spec.rb
|
211
|
-
- spec/unit/htty/cli/commands/header_set_spec.rb
|
212
|
-
- spec/unit/htty/cli/commands/header_unset_spec.rb
|
213
|
-
- spec/unit/htty/cli/commands/headers_clear_spec.rb
|
214
|
-
- spec/unit/htty/cli/commands/headers_request_spec.rb
|
215
|
-
- spec/unit/htty/cli/commands/headers_response_spec.rb
|
216
|
-
- spec/unit/htty/cli/commands/headers_set_spec.rb
|
217
|
-
- spec/unit/htty/cli/commands/headers_unset_all_spec.rb
|
218
|
-
- spec/unit/htty/cli/commands/headers_unset_spec.rb
|
219
|
-
- spec/unit/htty/cli/commands/help_spec.rb
|
220
|
-
- spec/unit/htty/cli/commands/history_spec.rb
|
221
|
-
- spec/unit/htty/cli/commands/history_verbose_spec.rb
|
222
|
-
- spec/unit/htty/cli/commands/host_set_spec.rb
|
223
|
-
- spec/unit/htty/cli/commands/http_delete_spec.rb
|
224
|
-
- spec/unit/htty/cli/commands/http_get_spec.rb
|
225
|
-
- spec/unit/htty/cli/commands/http_head_spec.rb
|
226
|
-
- spec/unit/htty/cli/commands/http_options_spec.rb
|
227
|
-
- spec/unit/htty/cli/commands/http_patch_spec.rb
|
228
|
-
- spec/unit/htty/cli/commands/http_post_spec.rb
|
229
|
-
- spec/unit/htty/cli/commands/http_put_spec.rb
|
230
|
-
- spec/unit/htty/cli/commands/http_trace_spec.rb
|
231
|
-
- spec/unit/htty/cli/commands/patch_spec.rb
|
232
|
-
- spec/unit/htty/cli/commands/path_set_spec.rb
|
233
|
-
- spec/unit/htty/cli/commands/port_set_spec.rb
|
234
|
-
- spec/unit/htty/cli/commands/post_spec.rb
|
235
|
-
- spec/unit/htty/cli/commands/put_spec.rb
|
236
|
-
- spec/unit/htty/cli/commands/query_add_spec.rb
|
237
|
-
- spec/unit/htty/cli/commands/query_clear_spec.rb
|
238
|
-
- spec/unit/htty/cli/commands/query_remove_spec.rb
|
239
|
-
- spec/unit/htty/cli/commands/query_set_spec.rb
|
240
|
-
- spec/unit/htty/cli/commands/query_unset_all_spec.rb
|
241
|
-
- spec/unit/htty/cli/commands/query_unset_spec.rb
|
242
|
-
- spec/unit/htty/cli/commands/quit_spec.rb
|
243
|
-
- spec/unit/htty/cli/commands/reuse_spec.rb
|
244
|
-
- spec/unit/htty/cli/commands/scheme_set_spec.rb
|
245
|
-
- spec/unit/htty/cli/commands/shared_examples_for_commands.rb
|
246
|
-
- spec/unit/htty/cli/commands/ssl_verification_off_spec.rb
|
247
|
-
- spec/unit/htty/cli/commands/ssl_verification_on_spec.rb
|
248
|
-
- spec/unit/htty/cli/commands/ssl_verification_spec.rb
|
249
|
-
- spec/unit/htty/cli/commands/status_spec.rb
|
250
|
-
- spec/unit/htty/cli/commands/undo_spec.rb
|
251
|
-
- spec/unit/htty/cli/commands/userinfo_clear_spec.rb
|
252
|
-
- spec/unit/htty/cli/commands/userinfo_set_spec.rb
|
253
|
-
- spec/unit/htty/cli/commands/userinfo_unset_spec.rb
|
254
|
-
- spec/unit/htty/cli/display_spec.rb
|
255
|
-
- spec/unit/htty/cli_spec.rb
|
256
|
-
- spec/unit/htty/command.rb
|
257
|
-
- spec/unit/htty/headers_spec.rb
|
258
|
-
- spec/unit/htty/payload_spec.rb
|
259
|
-
- spec/unit/htty/preferences_spec.rb
|
260
|
-
- spec/unit/htty/request_follow_spec.rb
|
261
|
-
- spec/unit/htty/request_spec.rb
|
262
|
-
- spec/unit/htty/request_userinfo_spec.rb
|
263
|
-
- spec/unit/htty/response_spec.rb
|
264
|
-
- spec/unit/htty/session_spec.rb
|
265
|
-
- spec/unit/htty/shared_examples_for_requests.rb
|
266
|
-
- spec/unit/htty/url_escaping.rb
|
267
|
-
- spec/unit/htty/version_spec.rb
|
192
|
+
- lib/tasks.rb
|
193
|
+
- lib/tasks/build_doc.rake
|
194
|
+
- lib/tasks/lib_each.rake
|
195
|
+
- lib/tasks/spec.rake
|
196
|
+
- lib/tasks/spec_each.rake
|
268
197
|
homepage: http://htty.github.io
|
269
198
|
licenses:
|
270
199
|
- MIT
|
@@ -275,109 +204,19 @@ require_paths:
|
|
275
204
|
- lib
|
276
205
|
required_ruby_version: !ruby/object:Gem::Requirement
|
277
206
|
requirements:
|
278
|
-
- -
|
207
|
+
- - ">="
|
279
208
|
- !ruby/object:Gem::Version
|
280
209
|
version: 1.8.7
|
281
210
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
282
211
|
requirements:
|
283
|
-
- -
|
212
|
+
- - ">="
|
284
213
|
- !ruby/object:Gem::Version
|
285
214
|
version: '0'
|
286
215
|
requirements: []
|
287
|
-
rubyforge_project:
|
288
|
-
rubygems_version: 2.4.
|
216
|
+
rubyforge_project:
|
217
|
+
rubygems_version: 2.4.5.1
|
289
218
|
signing_key:
|
290
219
|
specification_version: 4
|
291
220
|
summary: The HTTP TTY
|
292
|
-
test_files:
|
293
|
-
|
294
|
-
- spec/integration/htty/cli/commands/query_remove_spec.rb
|
295
|
-
- spec/integration/htty/cli/commands/query_set_spec.rb
|
296
|
-
- spec/integration/htty/cli/commands/query_unset_spec.rb
|
297
|
-
- spec/spec_helper.rb
|
298
|
-
- spec/unit/htty/cli/commands/address_spec.rb
|
299
|
-
- spec/unit/htty/cli/commands/body_clear_spec.rb
|
300
|
-
- spec/unit/htty/cli/commands/body_edit_spec.rb
|
301
|
-
- spec/unit/htty/cli/commands/body_request_spec.rb
|
302
|
-
- spec/unit/htty/cli/commands/body_response_spec.rb
|
303
|
-
- spec/unit/htty/cli/commands/body_set_spec.rb
|
304
|
-
- spec/unit/htty/cli/commands/body_unset_spec.rb
|
305
|
-
- spec/unit/htty/cli/commands/cd_spec.rb
|
306
|
-
- spec/unit/htty/cli/commands/cookie_add_spec.rb
|
307
|
-
- spec/unit/htty/cli/commands/cookie_remove_spec.rb
|
308
|
-
- spec/unit/htty/cli/commands/cookies_add_spec.rb
|
309
|
-
- spec/unit/htty/cli/commands/cookies_clear_spec.rb
|
310
|
-
- spec/unit/htty/cli/commands/cookies_remove_all_spec.rb
|
311
|
-
- spec/unit/htty/cli/commands/cookies_remove_spec.rb
|
312
|
-
- spec/unit/htty/cli/commands/cookies_spec.rb
|
313
|
-
- spec/unit/htty/cli/commands/cookies_use_spec.rb
|
314
|
-
- spec/unit/htty/cli/commands/delete_spec.rb
|
315
|
-
- spec/unit/htty/cli/commands/exit_spec.rb
|
316
|
-
- spec/unit/htty/cli/commands/follow_spec.rb
|
317
|
-
- spec/unit/htty/cli/commands/form_add_spec.rb
|
318
|
-
- spec/unit/htty/cli/commands/form_clear_spec.rb
|
319
|
-
- spec/unit/htty/cli/commands/form_remove_all_spec.rb
|
320
|
-
- spec/unit/htty/cli/commands/form_remove_spec.rb
|
321
|
-
- spec/unit/htty/cli/commands/form_spec.rb
|
322
|
-
- spec/unit/htty/cli/commands/fragment_clear_spec.rb
|
323
|
-
- spec/unit/htty/cli/commands/fragment_set_spec.rb
|
324
|
-
- spec/unit/htty/cli/commands/fragment_unset_spec.rb
|
325
|
-
- spec/unit/htty/cli/commands/get_spec.rb
|
326
|
-
- spec/unit/htty/cli/commands/header_set_spec.rb
|
327
|
-
- spec/unit/htty/cli/commands/header_unset_spec.rb
|
328
|
-
- spec/unit/htty/cli/commands/headers_clear_spec.rb
|
329
|
-
- spec/unit/htty/cli/commands/headers_request_spec.rb
|
330
|
-
- spec/unit/htty/cli/commands/headers_response_spec.rb
|
331
|
-
- spec/unit/htty/cli/commands/headers_set_spec.rb
|
332
|
-
- spec/unit/htty/cli/commands/headers_unset_all_spec.rb
|
333
|
-
- spec/unit/htty/cli/commands/headers_unset_spec.rb
|
334
|
-
- spec/unit/htty/cli/commands/help_spec.rb
|
335
|
-
- spec/unit/htty/cli/commands/history_spec.rb
|
336
|
-
- spec/unit/htty/cli/commands/history_verbose_spec.rb
|
337
|
-
- spec/unit/htty/cli/commands/host_set_spec.rb
|
338
|
-
- spec/unit/htty/cli/commands/http_delete_spec.rb
|
339
|
-
- spec/unit/htty/cli/commands/http_get_spec.rb
|
340
|
-
- spec/unit/htty/cli/commands/http_head_spec.rb
|
341
|
-
- spec/unit/htty/cli/commands/http_options_spec.rb
|
342
|
-
- spec/unit/htty/cli/commands/http_patch_spec.rb
|
343
|
-
- spec/unit/htty/cli/commands/http_post_spec.rb
|
344
|
-
- spec/unit/htty/cli/commands/http_put_spec.rb
|
345
|
-
- spec/unit/htty/cli/commands/http_trace_spec.rb
|
346
|
-
- spec/unit/htty/cli/commands/patch_spec.rb
|
347
|
-
- spec/unit/htty/cli/commands/path_set_spec.rb
|
348
|
-
- spec/unit/htty/cli/commands/port_set_spec.rb
|
349
|
-
- spec/unit/htty/cli/commands/post_spec.rb
|
350
|
-
- spec/unit/htty/cli/commands/put_spec.rb
|
351
|
-
- spec/unit/htty/cli/commands/query_add_spec.rb
|
352
|
-
- spec/unit/htty/cli/commands/query_clear_spec.rb
|
353
|
-
- spec/unit/htty/cli/commands/query_remove_spec.rb
|
354
|
-
- spec/unit/htty/cli/commands/query_set_spec.rb
|
355
|
-
- spec/unit/htty/cli/commands/query_unset_all_spec.rb
|
356
|
-
- spec/unit/htty/cli/commands/query_unset_spec.rb
|
357
|
-
- spec/unit/htty/cli/commands/quit_spec.rb
|
358
|
-
- spec/unit/htty/cli/commands/reuse_spec.rb
|
359
|
-
- spec/unit/htty/cli/commands/scheme_set_spec.rb
|
360
|
-
- spec/unit/htty/cli/commands/shared_examples_for_commands.rb
|
361
|
-
- spec/unit/htty/cli/commands/ssl_verification_off_spec.rb
|
362
|
-
- spec/unit/htty/cli/commands/ssl_verification_on_spec.rb
|
363
|
-
- spec/unit/htty/cli/commands/ssl_verification_spec.rb
|
364
|
-
- spec/unit/htty/cli/commands/status_spec.rb
|
365
|
-
- spec/unit/htty/cli/commands/undo_spec.rb
|
366
|
-
- spec/unit/htty/cli/commands/userinfo_clear_spec.rb
|
367
|
-
- spec/unit/htty/cli/commands/userinfo_set_spec.rb
|
368
|
-
- spec/unit/htty/cli/commands/userinfo_unset_spec.rb
|
369
|
-
- spec/unit/htty/cli/display_spec.rb
|
370
|
-
- spec/unit/htty/cli_spec.rb
|
371
|
-
- spec/unit/htty/command.rb
|
372
|
-
- spec/unit/htty/headers_spec.rb
|
373
|
-
- spec/unit/htty/payload_spec.rb
|
374
|
-
- spec/unit/htty/preferences_spec.rb
|
375
|
-
- spec/unit/htty/request_follow_spec.rb
|
376
|
-
- spec/unit/htty/request_spec.rb
|
377
|
-
- spec/unit/htty/request_userinfo_spec.rb
|
378
|
-
- spec/unit/htty/response_spec.rb
|
379
|
-
- spec/unit/htty/session_spec.rb
|
380
|
-
- spec/unit/htty/shared_examples_for_requests.rb
|
381
|
-
- spec/unit/htty/url_escaping.rb
|
382
|
-
- spec/unit/htty/version_spec.rb
|
383
|
-
has_rdoc: true
|
221
|
+
test_files: []
|
222
|
+
has_rdoc:
|
data/bin/htty
DELETED
@@ -1,57 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
require File.expand_path("#{File.dirname __FILE__}/../../../../../lib/htty/session")
|
3
|
-
require File.expand_path("#{File.dirname __FILE__}/../../../../../lib/htty/cli/commands/query_add")
|
4
|
-
|
5
|
-
describe HTTY::CLI::Commands::QueryAdd do
|
6
|
-
let :klass do
|
7
|
-
subject.class
|
8
|
-
end
|
9
|
-
|
10
|
-
let :session do
|
11
|
-
HTTY::Session.new nil
|
12
|
-
end
|
13
|
-
|
14
|
-
def instance(*arguments)
|
15
|
-
klass.new :session => session, :arguments => arguments
|
16
|
-
end
|
17
|
-
|
18
|
-
describe 'without an argument' do
|
19
|
-
it 'should raise an error' do
|
20
|
-
expect{instance.perform}.to raise_error(ArgumentError)
|
21
|
-
end
|
22
|
-
end
|
23
|
-
|
24
|
-
describe 'with key argument only' do
|
25
|
-
describe 'without key already present' do
|
26
|
-
it 'should add key' do
|
27
|
-
instance('test').perform
|
28
|
-
session.requests.last.uri.query.should == 'test'
|
29
|
-
end
|
30
|
-
end
|
31
|
-
|
32
|
-
describe 'with key already present' do
|
33
|
-
it 'should add key' do
|
34
|
-
session.requests.last.uri.query = 'test=true'
|
35
|
-
instance('test').perform
|
36
|
-
session.requests.last.uri.query.should == 'test=true&test'
|
37
|
-
end
|
38
|
-
end
|
39
|
-
end
|
40
|
-
|
41
|
-
describe 'with key and value arguments' do
|
42
|
-
describe 'without key already present' do
|
43
|
-
it 'should add key and value' do
|
44
|
-
instance('test', 'true').perform
|
45
|
-
session.requests.last.uri.query.should == 'test=true'
|
46
|
-
end
|
47
|
-
end
|
48
|
-
|
49
|
-
describe 'with key already present' do
|
50
|
-
it 'should add key and value' do
|
51
|
-
session.requests.last.uri.query = 'test=true'
|
52
|
-
instance('test', 'false').perform
|
53
|
-
session.requests.last.uri.query.should == 'test=true&test=false'
|
54
|
-
end
|
55
|
-
end
|
56
|
-
end
|
57
|
-
end
|
@@ -1,55 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
require File.expand_path("#{File.dirname __FILE__}/../../../../../lib/htty/session")
|
3
|
-
require File.expand_path("#{File.dirname __FILE__}/../../../../../lib/htty/cli/commands/query_remove")
|
4
|
-
|
5
|
-
describe HTTY::CLI::Commands::QueryRemove do
|
6
|
-
let :klass do
|
7
|
-
subject.class
|
8
|
-
end
|
9
|
-
|
10
|
-
let :session do
|
11
|
-
HTTY::Session.new nil
|
12
|
-
end
|
13
|
-
|
14
|
-
def instance(*arguments)
|
15
|
-
klass.new :session => session, :arguments => arguments
|
16
|
-
end
|
17
|
-
|
18
|
-
describe 'with existing query string with only one key and value' do
|
19
|
-
before :each do
|
20
|
-
session.requests.last.uri.query = 'test=true'
|
21
|
-
end
|
22
|
-
|
23
|
-
describe 'with only key in query string' do
|
24
|
-
it 'should empty the query string' do
|
25
|
-
instance('test').perform
|
26
|
-
session.requests.last.uri.query.should be_nil
|
27
|
-
end
|
28
|
-
|
29
|
-
it 'should not leave a trailing question mark' do
|
30
|
-
instance('test').perform
|
31
|
-
session.requests.last.uri.to_s.should_not end_with('?')
|
32
|
-
end
|
33
|
-
end
|
34
|
-
end
|
35
|
-
|
36
|
-
describe 'with existing query string with duplicate keys set' do
|
37
|
-
before :each do
|
38
|
-
session.requests.last.uri.query = 'test=true&test=false'
|
39
|
-
end
|
40
|
-
|
41
|
-
describe 'with only key specified' do
|
42
|
-
it 'should remove last entry' do
|
43
|
-
instance('test').perform
|
44
|
-
session.requests.last.uri.query.should == 'test=true'
|
45
|
-
end
|
46
|
-
end
|
47
|
-
|
48
|
-
describe 'with key and value specified' do
|
49
|
-
it 'should remove matching entry only' do
|
50
|
-
instance('test', 'true').perform
|
51
|
-
session.requests.last.uri.query.should == 'test=false'
|
52
|
-
end
|
53
|
-
end
|
54
|
-
end
|
55
|
-
end
|