aboutsummaryrefslogtreecommitdiffstats
path: root/activestorage/test/test_helper.rb
Commit message (Collapse)AuthorAgeFilesLines
* Use a current model to provide the host for service urlsAndrew White2018-04-061-0/+8
| | | | | | | Trying to pass the current request down to the service so that it can create full urls instead of paths makes the API messy so use a model based on ActiveSupport::CurrentAttributes to provide the current host to services that need it (primarily the disk service).
* Flip the order of the after_create callbacksDwight Watson2018-03-271-0/+10
| | | | | | | | | | Addresses rails/rails#32247 Add test that checks identify and analyze work in correct order Break out direct upload test helper Review changes for direct-upload test helper
* Fix purging dependent blobs when attachments aren't loadedGeorge Claghorn2018-03-051-0/+2
|
* Delete dependent attachments with recordGeorge Claghorn2018-03-051-0/+1
| | | | [Matt Jones & George Claghorn]
* Generate root-relative paths in Active Storage disk service URL methodsGeorge Claghorn2018-03-051-3/+0
| | | | Fixes #32129.
* Provide a sensible default hostGeorge Claghorn2018-01-161-1/+1
|
* Extract content types from blob dataGeorge Claghorn2018-01-151-1/+4
|
* Fix direct uploads to local serviceGeorge Claghorn2017-11-201-0/+1
| | | | | | | | Disable CSRF protection for ActiveStorage::DiskController#update. The local disk service is intended to imitate a third-party service like S3 or GCS, so we don't care where direct uploads originate: they’re authorized by signed tokens. Closes #30290. [Shinichi Maeshima & George Claghorn]
* Preserve existing metadata when analyzing a blobGeorge Claghorn2017-11-131-2/+2
| | | | Closes #31138.
* Extract metadata from images and videosGeorge Claghorn2017-10-221-4/+2
|
* Use `require_relative` instead of `require` with full path in activestorage/bogdanvlviv2017-10-131-1/+1
| | | | Related to #29417
* Define path with __dir__ in activestorage/bogdanvlviv2017-10-131-2/+2
| | | | Related to #29176
* Preview PDFs and videosGeorge Claghorn2017-09-281-3/+4
|
* Use nil Logger for testsJon Moss2017-08-171-1/+1
| | | | | | | | | | | | | | | | Makes tests much more quietly, as opposed to the enormous amount of logging that appears right now. This setting is used in AJ, as well as other frameworks. Output from test run: ``` ......................................................... Finished in 3.003355s, 18.9788 runs/s, 45.2827 assertions/s. 57 runs, 136 assertions, 0 failures, 0 errors, 0 skips ```
* Use frozen string literal in Active StorageKoichi ITO2017-08-121-0/+2
|
* Merge pull request #30113 from dixpac/remove_unecessary_require_in_test_helperRafael França2017-08-111-2/+0
|\ | | | | ActiveStorage: Remove unnecessary require in test_helper
| * Remove unecessary require in test_helperdixpac2017-08-091-2/+0
| |
* | Run Active Storage tests in CI (#30144)George Claghorn2017-08-101-2/+11
|/
* Filter out Minitest backtrace.dixpac2017-08-071-0/+4
| | | | | Filter out Minitest backtrace while allowing backtrace from other libraries to be shown.
* Let ActiveStorage tests pass only for Diskclaudiob2017-08-011-1/+3
| | | | | | | | | | | | | | | | If you have a "service/configurations.yml" file, but every single line is commented out, then an error occurs when running tests: ``` git:active-storage-import~/code/rails/activestorage$ rake ~/code/rails/activestorage/test/test_helper.rb:17:in `<top (required)>': undefined method `deep_symbolize_keys' for false:FalseClass (NoMethodError) from ~/code/rails/activestorage/test/controllers/direct_uploads_controller_test.rb:1:in `require' ``` The reason is that `YAML.load(..an empty file content..)` simply returns `false`, and not `{}`. This PR fixes this behavior so tests can also run when no remote service is available.
* Setup travis to be able to run CI tests against S3David Heinemeier Hansson2017-07-311-1/+1
|
* Add 'activestorage/' from commit '3f4a7218a4a4923a0e7ce1b2eb0d2888ce30da58'Rafael Mendonça França2017-07-311-0/+54
git-subtree-dir: activestorage git-subtree-mainline: 0d58e7e478e79c2d6b2a39a4444d2a17a903b2a6 git-subtree-split: 3f4a7218a4a4923a0e7ce1b2eb0d2888ce30da58