BigW Consortium Gitlab
Isolate CarrierWave uploads in test enviroment Purpose of this merge request is to isolate CarrierWave uploads in test environment, from regular development/production uploads. We need to persist some files in order to test some features thoroughly. If we - for example - want to check if file exists after being uploaded via API, or we need to write tests that check if file has been correctly removed we need to persist uploads using CarrierWave. This approach simply sets `root` path for uploads in test environment and removes temporary directory after executing RSpec tests suite. We set this in `spec_helper` to keep this in one place, this also can be set up in test environment initializer. This issue is a workaround for #12968, but does not solve this problem completely, because if uploader defines absolute path in `store_dir` or defines custom `root` path, this may not work correctly (but it looks like we do have such uploaders at this moment). See merge request !3435
Name |
Last commit
|
Last update |
---|---|---|
.. | ||
config | Loading commit data... | |
controllers | Loading commit data... | |
factories | Loading commit data... | |
features | Loading commit data... | |
finders | Loading commit data... | |
fixtures | Loading commit data... | |
helpers | Loading commit data... | |
initializers | Loading commit data... | |
javascripts | Loading commit data... | |
lib | Loading commit data... | |
mailers | Loading commit data... | |
models | Loading commit data... | |
requests | Loading commit data... | |
routing | Loading commit data... | |
services | Loading commit data... | |
support | Loading commit data... | |
tasks/gitlab | Loading commit data... | |
views | Loading commit data... | |
workers | Loading commit data... | |
factories_spec.rb | Loading commit data... | |
rails_helper.rb | Loading commit data... | |
spec_helper.rb | Loading commit data... | |
teaspoon_env.rb | Loading commit data... |