tlopo-request 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f3caa9e0fdfcd49015aab41bb8c1b05cbfbe79622372a7027f6c9b10b7db80ef
4
- data.tar.gz: 9fd0925f8571026c3d69f99139d3e47c4fa4153734d9f3b060bcaf84e3a5ca4c
3
+ metadata.gz: a4bf4018b2f6585c8f9c86aba4fb1c7c988ca268231aa33a6a91ce3c605da808
4
+ data.tar.gz: 67892a85d2ae065de79846a1b8ab90dd75e2f8ae3116eb40b0151db2be09cd3d
5
5
  SHA512:
6
- metadata.gz: 3bb63acc7b5e2039bae1c2dff516f7d9f6a4f2c904f6dce0ee6d949b47a5e1ceef26f93888af45e147d3be35ccabcdc6ff9c8642f6f045b5a1d9b2d606197de9
7
- data.tar.gz: 91879a887d118e0ce6a1beb8a65f5d9a65f14c6fe8a9680e71bd00e6f8543a66ec05b2f45aed620afc5e7a9348c50f3d8c142fc22c45e16854e59c852ad53a7a
6
+ metadata.gz: 342128dab10b3aaf80e3521707e848c286cbdac431d00b4114223bb7eb4d322077aa27a92663e4321e41cfe0cb4e43891d9c8a38cedfd85566ebd74b1abd27c9
7
+ data.tar.gz: 54e06c03b775fb6d66369493e8b07af4c26b7cc4db19673100934db0621fb33fc7f51770583eec499b6746ccbace87b05edd389431d63d8705304d7af7af8205
data/.rubocop.yml CHANGED
@@ -34,3 +34,7 @@ Metrics/BlockLength:
34
34
  Exclude:
35
35
  - rest.rb
36
36
  - infra/**/*
37
+ Lint/OrAssignmentToConstant:
38
+ Enabled: false
39
+ Gemspec/RequireMFA:
40
+ Enabled: false
data/Gemfile CHANGED
@@ -10,3 +10,5 @@ gem 'rake', '~> 13.0'
10
10
  gem 'minitest', '~> 5.0'
11
11
 
12
12
  gem 'rubocop', '~> 1.21'
13
+
14
+ gem 'simplecov', '~> 0.16'
data/README.md CHANGED
@@ -10,12 +10,14 @@ Installing is a simple `gem install tlopo-request`
10
10
 
11
11
  Fluent API:
12
12
  ```ruby
13
- puts Tlopo:Request.new.url('https://postman-echo.com/get').run.code
14
- # "200"
13
+ require 'tlopo/request'
14
+ puts Tlopo:Request.new.url('https://postman-echo.com/get').run.code
15
+ # "200"
15
16
  ```
16
17
 
17
18
  DSL API:
18
19
  ```ruby
20
+ require 'tlopo/request'
19
21
  url = 'https://postman-echo.com/put?foo=bar&bar=foo'
20
22
  payload = { 'foo' => 'bar', 'bar' => 'foo' }
21
23
  headers = { 'Content-Type': 'application/json' }
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Tlopo
4
4
  class Request
5
- VERSION = '0.1.0'
5
+ VERSION = '0.1.1'
6
6
  end
7
7
  end
data/lib/tlopo/request.rb CHANGED
@@ -11,7 +11,7 @@ module Setters
11
11
  names.each do |name|
12
12
  define_method(name) do |val|
13
13
  instance_variable_set("@#{name}", val)
14
- return self
14
+ self
15
15
  end
16
16
  end
17
17
  end
@@ -20,7 +20,7 @@ end
20
20
  module Tlopo
21
21
  class Request
22
22
  extend Setters
23
- make_setter :url, :headers, :method, :payload
23
+ make_setter :url, :headers, :method, :payload, :insecure
24
24
 
25
25
  def initialize
26
26
  @method = 'get'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tlopo-request
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - tlopo