Commit Graph

42 Commits (e8b6607ece43e6fcda99e76f8db0ad40d54b50b6)

Author SHA1 Message Date
Jonny Saunders 9074c1fac9
Use `likes` and `shares` totalItems on status creations and updates ()
Matt Jankowski 6b6a80b407
Remove `body_as_json` in favor of built-in `response.parsed_body` for JSON response specs ()
Matt Jankowski f1003b2560
Enable "zero monkey patching" mode in RSpec ()
Matt Jankowski 79b1841805
Disable `without_verify_partial_doubles` in statuses/show view spec ()
Matt Jankowski 40f993b3a0
Use built-in `response.parsed_body` for JSON response specs ()
Matt Jankowski bcc4b1078c
Fix `Rails/RootPathnameMethods` cop ()
Matt Jankowski 6beead3867
Move `simplecov` config into `rails_helper` ()
Claire b71904816a
Change registrations to be disabled by default for new servers ()
Matt Jankowski 04121bd020
Disable simplecov `enable_coverage_for_eval` option, move to standalone file ()
Matt Jankowski 7c72944661
Use `Lcov` simplecov formatter on CI and `HTML` elsewhere ()
Nick Schonning 36d7d1781f
Add CodeCov for Ruby coverage reports ()
Matt Jankowski ae7c20b00c
Move search and streaming spec manager classes to separate support files ()
Matt Jankowski 1d51e10510
Consolidate JSON parsing in serializers specs ()
Matt Jankowski 49e2772064
Fix `RSpec/MessageSpies` cop ()
Claire e9dc30cdba
Fix duplicate github annotations for rspec failures ()
Nick Schonning 5ef26d8fd5
Add RSpec GitHub annotations gem ()
jsgoldstein 4d9186a48c
Add search tests ()
Renaud Chaput 4d1b67f664
Add end-to-end (system) tests ()
Matt Jankowski 7824df0eca
Exclude `lib/linter` from simplecov report ()
Matt Jankowski b276b3bb83
Remove Ruby GC config from spec helper ()
Nick Schonning 1fe04f740a
Enable Rubocop Rails/FilePath ()
Matt Jankowski 9ee83a9f3b
Add policies and serializers groups to simplecov output ()
Nick Schonning 84cc805cae
Enable Style/FrozenStringLiteralComment for specs ()
Nick Schonning 81ad6c2e39
Autofix Rubocop Style/StringLiterals ()
Nick Schonning 5069769cbe
Autofix Rubocop Style/TrailingCommaInHashLiteral ()
Claire 2af03164cb
Improve tests involving push_bulk ()
sidekiq-bulk's push_bulk can either accept arguments directly or run them
through a block.

Setting expectations on the result of evaluating the blocks allows testing
more code (the block itself) and the test is moved closer to the *interface*
of the tested code than its precise implementation.
Yamagishi Kazutoshi e598ce0bd9 Move rspec examples to tmp dir ()
Dimitri Merejkowsky cb3e9a2934 Store rspec statuses in .cache/rspec ()
This allows using rspec with `--only-failures`
ThibG 730c4053d6 Add ActivityPub actor representing the entire server ()
* Add support for an instance actor

* Skip username validation for local Application accounts

* Add migration script to create instance actor

* Make Codeclimate happy

* Switch to id -99 for instance actor

* Remove unused `icon` and `image` attributes from instance actor

* Use if/elsif/else instead of return + ternary operator

* Add instance actor to fresh installs

* Use instance actor as instance representative

Use instance actor for forwarding reports, relay operations, and spam
auto-reporting.

* Seed database in test environment

* Fix single-user mode

* Fix tests

* Fix specs to accomodate for an extra `Account`

* Auto-reject follows on instance actor

Following an instance actor might make sense, but we are not handling that
right now, so auto-reject.

* Fix webfinger lookup and serialization for instance actor

* Rename instance actor

* Make it clear in the HTML view that the instance actor should not be blocked

* Raise cache time for instance actor as there's no dynamic content

* Re-use /about/more with a flash message for instance actor profile
Yamagishi Kazutoshi ac788ad47e Disable simplecov on CircleCI ()
* Disable simplecov on CircleCI

* Remove --format progress
Yamagishi Kazutoshi 8c35d163a5 Port travis_retry for CI ()
* Port travis_retry for CI

* Add license
Eugen Rochko cb5b5cb5f7
Slightly reduce RAM usage ()
* No need to re-require sidekiq plugins, they are required via Gemfile

* Add derailed_benchmarks tool, no need to require TTY gems in Gemfile

* Replace ruby-oembed with FetchOEmbedService

Reduce startup by 45382 allocated objects

* Remove preloaded JSON-LD in favour of caching HTTP responses

Reduce boot RAM by about 6 MiB

* Fix tests

* Fix test suite by stubbing out JSON-LD contexts
Yamagishi Kazutoshi b438224751 Introduce rspec-retry ()
Eugen Rochko 3ebc0ad4d3
Full-text search for authorized statuses ()
* Add full-text search for authorized statuses

- Search API will return statuses that match the query
- Only for logged in users
- Only if you are author of the status,
- Or you were mentioned in it
- Or you favourited or reblogged it
- Configuration over `ES_ENABLED`, `ES_HOST`, `ES_PORT`, `ES_PREFIX`
- Run `rails chewy:deploy` to create & populate index

Fix 
Fix 
Fix 

* Add commented out docker-compose configuration for ES container

* Optimize index import, filter search results

* Add basic normalization to the index

* Add better stemming and normalization to the index

* Skip webfinger request if search query includes both @ and a space

* Fix code style

* Visually separate search result sections

* Fix code style issues
Eugen Rochko c66fe2aeba Minor performance improvement for test suite ()
Eugen 6bd1019235 Add more tests for AtomSerializer ()
Matt Jankowski 3834e1e69b View spec fix ()
* Add option to disable verify partial doubles

* Add show_landing_strip? helper method

* Use show_landing_strip? helper in accounts and stream entries views

* Fix naming in view specs
Matt Jankowski b330d1f000 Organize coverage dirs ()
* Add `Presenters` group to SimpleCov configuration

* Move validators to app/validators, add to simplecov config
Eugen Rochko 83ccdeb87a Fix tests
Eugen Rochko e46abc71ca Fix notifications in UI, added new API for fetching account relationships
Eugen Rochko ae1fac0062 Add API to upload media attachments
Eugen Rochko 71fe24096c Adding a Mention model, test stubs