quickbooks_web_connector 0.6.3 → 0.7.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 7ef87c61fe923ae87d9df6f5ab8190ff512a99e8
4
- data.tar.gz: 9d6f230c1e6a74542951ba5e02996bfd26a10503
2
+ SHA256:
3
+ metadata.gz: bf18fa7e2b122a629b746b1033111cd625e88887815b026a09fd9b313ebf67ca
4
+ data.tar.gz: 1356b0b2d26d2cd16bc57212c82b4273444fefbe782d59d714d2070a174849fd
5
5
  SHA512:
6
- metadata.gz: 7236884d0a4e3cd42eb0e0dac5fa9e9cf8d5b9499547b8fbf99504fa6ee67ebec8f0df4a34f869e642b5da858cf96a1caf09c3d4d2dc38569e0295c7153c2ab8
7
- data.tar.gz: 374486e2ed50479a9371cfdfd22ca016e4766bb93c6d4a19560bc4465aacc3e68e02e184fdce2b286ef9f4ac7831d6f9c0b43bf193f034fd658e70529e827de0
6
+ metadata.gz: d3ca88133cf75113793d8300a2733d20f4541247c708e4388834ba3a6980df5380568d8e8fe5e5edaee4df455cceb8bb9a6f736eebcc5b9748c54cf3a618771f
7
+ data.tar.gz: 7389454a7ff0a918f71f81dca84efbaff859e7eb866576dc29a5f19117c8580b38a4697e0940706ad44cb7f4bf9bedcc7025cef43941fb2c7bb4c05e4d5e9a25
data/README.md CHANGED
@@ -8,7 +8,7 @@ QuickbooksWebConnector is heavily inspired by [QBWC](https://github.com/skryl/qb
8
8
  Requirements
9
9
  ------------
10
10
 
11
- QuickbooksWebConnector is tested on Rails 3.2, 4.0, 4.1, 4.2, and 5.0 as well as Ruby 2.0, 2.1, 2.2, 2.3, and 2.4.
11
+ QuickbooksWebConnector is tested on Rails 5.0 and 5.1 as well as Ruby 2.2, 2.3, 2.4, and 2.5.
12
12
 
13
13
  Usage
14
14
  --------
@@ -1,5 +1,5 @@
1
1
  module QuickbooksWebConnector
2
2
  class QuickbooksWebConnectorController < QuickbooksWebConnector.config.parent_controller.constantize
3
- skip_before_filter :verify_authenticity_token
3
+ skip_before_action :verify_authenticity_token
4
4
  end
5
5
  end
@@ -5,7 +5,7 @@ module QuickbooksWebConnector
5
5
  @user = QuickbooksWebConnector.config.users[params[:username]]
6
6
 
7
7
  if !@user
8
- render nothing: true, status: :not_found
8
+ head :not_found
9
9
  else
10
10
  send_data render_to_string(:qwc),
11
11
  disposition: 'attachment',
@@ -3,7 +3,7 @@ module QuickbooksWebConnector
3
3
 
4
4
  def endpoint
5
5
  # QWC will perform a GET to check the certificate, so we gotta respond
6
- render nothing: true and return if request.get?
6
+ head :no_content and return if request.get?
7
7
 
8
8
  response = SoapWrapper.route(request)
9
9
  render xml: response, content_type: 'text/xml'
@@ -1,3 +1,3 @@
1
1
  module QuickbooksWebConnector
2
- VERSION = "0.6.3"
2
+ VERSION = "0.7.0"
3
3
  end
@@ -8,7 +8,7 @@ RSpec.describe QuickbooksWebConnector::QwcController, type: :controller do
8
8
  it 'renders the QWC file' do
9
9
  QuickbooksWebConnector.config.user 'jane', 'password', '/path/to/company.qbw'
10
10
 
11
- get :download, username: 'jane', format: :xml
11
+ get :download, params: { username: 'jane', format: :xml }
12
12
 
13
13
  expect(response).to be_success
14
14
  expect(response.header['Content-Type']).to match(/application\/xml/)
@@ -19,7 +19,7 @@ RSpec.describe QuickbooksWebConnector::QwcController, type: :controller do
19
19
  end
20
20
 
21
21
  it 'returns a 404 when no user matches the given username' do
22
- get :download, username: 'jane', format: :xml
22
+ get :download, params: { username: 'jane', format: :xml }
23
23
 
24
24
  expect(response.code).to eq('404')
25
25
  expect(response).to_not render_template(:qwc)
@@ -6,8 +6,8 @@ Dummy::Application.configure do
6
6
  # since you don't have to restart the web server when you make code changes.
7
7
  config.cache_classes = false
8
8
 
9
- # Log error messages when you accidentally call methods on nil.
10
- config.whiny_nils = true
9
+ # Do not eager load code on boot.
10
+ config.eager_load = false
11
11
 
12
12
  # Show full error reports and disable caching
13
13
  config.consider_all_requests_local = true
@@ -4,12 +4,18 @@ Dummy::Application.configure do
4
4
  # Code is not reloaded between requests
5
5
  config.cache_classes = true
6
6
 
7
+ # Eager load code on boot. This eager loads most of Rails and
8
+ # your application in memory, allowing both thread web servers
9
+ # and those relying on copy on write to perform better.
10
+ # Rake tasks automatically ignore this option for performance.
11
+ config.eager_load = true
12
+
7
13
  # Full error reports are disabled and caching is turned on
8
14
  config.consider_all_requests_local = false
9
15
  config.action_controller.perform_caching = true
10
16
 
11
17
  # Disable Rails's static asset server (Apache or nginx will already do this)
12
- config.serve_static_assets = false
18
+ config.public_file_server.enabled = false
13
19
 
14
20
  # Compress JavaScripts and CSS
15
21
  config.assets.compress = true
@@ -7,12 +7,16 @@ Dummy::Application.configure do
7
7
  # and recreated between test runs. Don't rely on the data there!
8
8
  config.cache_classes = true
9
9
 
10
- # Configure static asset server for tests with Cache-Control for performance
11
- config.serve_static_assets = true
12
- config.static_cache_control = "public, max-age=3600"
10
+ # Do not eager load code on boot. This avoids loading your whole application
11
+ # just for the purpose of running a single test. If you are using a tool that
12
+ # preloads Rails for running tests, you may have to set it to true.
13
+ config.eager_load = false
13
14
 
14
- # Log error messages when you accidentally call methods on nil
15
- config.whiny_nils = true
15
+ # Configure static asset server for tests with Cache-Control for performance
16
+ config.public_file_server.enabled = true
17
+ config.public_file_server.headers = {
18
+ 'Cache-Control' => 'public, max-age=3600'
19
+ }
16
20
 
17
21
  # Show full error reports and disable caching
18
22
  config.consider_all_requests_local = true
@@ -1,7 +1,11 @@
1
1
  # Be sure to restart your server when you modify this file.
2
2
 
3
- # Your secret key for verifying the integrity of signed cookies.
3
+ # Your secret key is used for verifying the integrity of signed cookies.
4
4
  # If you change this key, all old signed cookies will become invalid!
5
5
  # Make sure the secret is at least 30 characters and all random,
6
6
  # no regular words or you'll be exposed to dictionary attacks.
7
- Dummy::Application.config.secret_token = 'f87d6a9a7539effa76be31b5fe1df70dceb20f4c50b148323485d4c76e6377aad3f3172c3b3e0d872c0cd201835c879a4e22943b84886352b81cb023fb855524'
7
+ # You can use `rake secret` to generate a secure secret key.
8
+
9
+ # Make sure your secret_key_base is kept private
10
+ # if you're sharing your code publicly.
11
+ Dummy::Application.config.secret_key_base = 'f87d6a9a7539effa76be31b5fe1df70dceb20f4c50b148323485d4c76e6377aad3f3172c3b3e0d872c0cd201835c879a4e22943b84886352b81cb023fb855524'