Comments (9)
I haven't run the suite in a while. Going to mess with it tonight and report back. Perhaps I can do something clever with the VCR cassettes so we can commit them without sensitive data.
from harvested.
You're looking for filter_sensitive_data. In your VCR configuration block, starting on line 7 of spec_helper.rb, you can do something like:
VCR.configure do |c|
c.cassette_library_dir = '.cassettes'
c.hook_into :webmock
c.filter_sensitive_data('RANDOMGIBBERISH') { 'my-secret-harvest-password' }
end
VCR.config and c.stub_with :webmock are deprecated. I've changed to VCR.configure and c.hook_into :webmock
from harvested.
Nice. Thanks for the tip!
from harvested.
I also got the same failing tests.
from harvested.
I'm not sure yet if these failures are due to API bugs or the library. I'll investigate when I have some time.
Also on filter_sensitive_data
: that's not quite what I want. I want VCR to record the requests and responses but not put in the harvest username, password or subdomain. And I don't want to have to manually mess with the cassettes. That doesn't seem easily doable. Open to suggestions though.
from harvested.
This is what filter_sensitive data does. I'll mock up an example and submit a pull request.
from harvested.
Cool, please do. I'm under the impression it's looking for tokens in an existing cassette and replaces it with what you specify in the configuration. If I can have the server calls to create the cassettes and use filter_sensitive_data
... uber win.
from harvested.
I believe @prsimp has a fully green suite locally.
from harvested.
Closing this bad boy now that @prsimp green'd up our suite.
from harvested.
Related Issues (20)
- time_by_user report broken HOT 1
- Remove non-SSL option HOT 2
- time_by_user hardcodes options HOT 2
- Getting a 404 on all tasks HOT 1
- 404 on time_by_user HOT 5
- Uninitialized constant Harvest::OAuthCredentials HOT 3
- Wrong number of arguments (1 for 3..4) HOT 3
- 500 Harvest Internal Server error HOT 1
- Loosen dependency on Hashie HOT 4
- Locking time entries via API? HOT 1
- Mark a time_entry as invoiced HOT 1
- Remove hashie HOT 3
- Duplicated key's in timezones.rb
- Company info HOT 2
- Unexpected results from filtering .all HOT 1
- Get expenses for a date range HOT 3
- csv_line_items not returned for invoice(s) HOT 2
- I am interested in maintaining harvested. HOT 1
- External Reference URL HOT 2
- Harvested and the V2 Harvest API HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from harvested.