about summary refs log tree commit diff
path: root/spec
AgeCommit message (Collapse)Author
2018-05-05Store home feeds for 7 days instead of 14 (#7354)Eugen Rochko
* Store home feeds for 7 days instead of 14 Reduces workload for status fan-out to active followers * Fix test for user model
2018-05-04Store URIs of follows, follow requests and blocks for ActivityPub (#7160)Eugen Rochko
Same URI passed between follow request and follow, since they are the same thing in ActivityPub. Local URIs are generated during creation using UUIDs and are passed to serializers.
2018-05-03Add missing tests for report.rb (#7324)Shuhei Kitagawa
2018-05-02Serialize webfinger XML with Ox instead of Nokogiri (#7319)Eugen Rochko
25ms -> 0.5ms
2018-05-02Slightly reduce RAM usage (#7301)Eugen Rochko
* 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
2018-05-02Keep notification when muting_notifications is true (#7311)abcang
* Keep notification when muting_notifications is true * Retrun mute object * Fix test
2018-05-02Speed up test suite by not generating RSA keys in test environment (#7296)Eugen Rochko
One RSA keypair for all fabricated test accounts is enough
2018-05-02Add missing tests for user.rb (#7306)Shuhei Kitagawa
2018-05-02Support Actors/Statuses with multiple types (#7305)Surinna Curtis
* Add equals_or_includes_any? helper in JsonLdHelper * Support arrays in JSON-LD type fields for actors/tags/objects. * Spec for resolving accounts with extension types * Style tweaks for codeclimate
2018-04-25Append '.test' to hostname in stub data (#7260)MIYAGI Hikaru
2018-04-23Prevent suspended accounts from appearing in AccountSearchService (#7246)Emelia Smith
2018-04-23Paginate descendant statuses in public page (#7148)Akihiko Odaki
2018-04-22Remove "nsfw" category for sensitive statuses in OStatus serializer (#7048)Eugen Rochko
Fix #7011
2018-04-22Fix randomly fail (similar #7219) (#7225)Yamagishi Kazutoshi
2018-04-21Reset locale on registration tests (#7219)Yamagishi Kazutoshi
2018-04-21Use raw status code on have_http_status (#7214)Yamagishi Kazutoshi
2018-04-20Introduce rspec-retry (#7206)Yamagishi Kazutoshi
2018-04-20Improve report layout (#7188)Eugen Rochko
* Use table for statuses in report * Display reported account and reporter in the same table * Split accounts and general report info into two tables again * Redesign report statuses table, notes, merge notes and action log * Remove unused translations * Fix code style issue * Fix code style issue * Fix code style issue
2018-04-18Direct messages column (#4514)Kaito Sinclaire
* Added a timeline for Direct statuses * Lists all Direct statuses you've sent and received * Displayed in Getting Started * Streaming server support for direct TL * Changes to match other timelines in 2.0
2018-04-16Redirect to account status page for page of status stream entry (#7104)Akihiko Odaki
Commit 519119f657cf97ec187008a28dba00c1125a9292 missed a change for stream entry page. Instead of duplicating the change, redirect to account status page. It would also help crawlers (of search engines, for example) to understand a stream entry URL and its corresponding status URL points to the same page.
2018-04-14Add bio fields (#6645)Eugen Rochko
* Add bio fields - Fix #3211 - Fix #232 - Fix #121 * Display bio fields in web UI * Fix output of links and missing fields * Federate bio fields over ActivityPub as PropertyValue * Improve how the fields are stored, add to Edit profile form * Add rel=me to links in fields Fix #121
2018-04-12Allow more than the max pins if account is not local (#7105)Renato "Lond" Cerqueira
Sidekiq sometimes throws errors for users that have more pinned items than the allowed by the local instance. It should only validate the number of pins for local accounts.
2018-04-11update gem, test pam authentication (#7028)Alexander
* update gem, test pam authentication * add description for test parameters * fix inclusion of optional group
2018-04-11Paginate ancestor statuses in public page (#7102)Akihiko Odaki
This also limits the statuses returned by API, but pagination is not implemented in Web API yet. I still expect it brings user experience better than making a user wait to fetch all ancestor statuses and flooding the column with them.
2018-04-10Change custom emoji search to `ILIKE` instead of `=` (#7099)Paul Woolcock
2018-04-10Feature: Allow staff to change user emails (#7074)Emelia Smith
* Admin: Show unconfirmed email address on account page * Admin: Allow staff to change user email addresses * ActionLog: On change_email, log current email address and new unconfirmed email address
2018-04-08Enable updating additional account information from user preferences via ↵Levi Bard
rest api (#6789) * Enable updating additional account information from user preferences via rest api Resolves #6553 * Pacify rubocop * Decoerce incoming settings in UserSettingsDecorator * Create user preferences hash directly from incoming credentials instead of going through ActionController::Parameters * Clean up user preferences update * Use ActiveModel::Type::Boolean instead of manually checking stringified number equivalence
2018-04-04Add contact account to landing page ("Administered by") (#6984)Eugen Rochko
2018-04-03Improve require_admin! and require_staff! filters (#7018)Emelia Smith
Previously these returns 302 redirects instead of 403s, which meant posting links to admin pages in slack caused them to unfurl, rather than stay as a link. Additionally, require_admin! doesn't appear to be actively used, on require_staff!
2018-04-02Feature: Report improvements (#6967) (#7000)Emelia Smith
* Implement Assignment of Reports (#6967) * Change translation of admin.report.comment.label to "Report Comment" for clarity As we'll soon add the ability for reports to have comments on them, this clarification makes sense. * Implement notes for Reports This enables moderators to leave comments about a report whilst they work on it * Fix display of report moderation notes * Allow reports to be reopened / marked as unresolved * Redirect to reports listing upon resolution of report * Implement "resolve with note" functionality * Add inverse relationship for report notes * Remove additional database querying when loading report notes * Fix tests for reports * Fix localisations for report notes / reports
2018-04-01[WIP] Enable custom emoji on account pages and in the sidebar (#6124)David Underwood
Federate custom emojis with accounts
2018-03-27Add a spec for UniqueUsernameValidator (#6927)unarist
Note that this spec has a pending test about dots in the username, because allowing it has been reverted for now.
2018-03-26Validate HTTP response length while receiving (#6891)Akihiko Odaki
to_s method of HTTP::Response keeps blocking while it receives the whole content, no matter how it is big. This means it may waste time to receive unacceptably large files. It may also consume memory and disk in the process. This solves the inefficency by checking response length while receiving.
2018-03-24Change columns in notifications nonnullable (#6764)Akihiko Odaki
2018-03-24Close http connection in perform method of Request class (#6889)Akihiko Odaki
HTTP connections must be explicitly closed in many cases, and letting perform method close connections makes its callers less redundant and prevent them from forgetting to close connections.
2018-03-20request: in the event of failure, try other IPs (#6761) (#6813)Rey Tucker
* request: in the event of failure, try other IPs (#6761) In the case where a name has multiple A/AAAA records, we should try subsequent records instead of immediately failing when we have a failure on the first IP address. This significantly improves delivery success when there are network connectivity problems affecting only IPv4 or IPv6. * fix method call style * request_spec: adjust test case to use Addrinfo * request: Request/open: move private addr check to within begin/rescue * request_spec: add case to test failover, fix exception check * Double Addrinfo.foreach so that it correctly yields instances
2018-03-07Fix #6657 - Use target instead of origin in Remove activity (#6664)Eugen Rochko
2018-03-05Redirect from Web tag timeline to public tag timeline if not signed in (#6633)Akihiko Odaki
This is also implemented in Pawoo: https://github.com/pixiv/mastodon/commit/ceafdbd1bbf30fe20a2a814df0f8cae429a4e9db
2018-03-04Do not default site_title with site_hostname in InstanceHelper (#6624)Akihiko Odaki
site_title is "Mastodon" by default configuration, and there is no need to default site_title with site_hostname in InstanceHelper.
2018-03-04Set the default locale in config (#6580)Akihiko Odaki
Previously the default locale was set by Localized concern for controllers, but it was not enforced for mailers. config is enforced throughout the application and an appropriate place to set the default locale.
2018-03-04Federate pinned statuses over ActivityPub (#6610)Eugen Rochko
* Federate pinned statuses over ActivityPub * Display pinned toots in web UI Fix #6117 * Fix migration * Fix tests * Update outbox_serializer.rb * Update remove_serializer.rb * Update add_serializer.rb * Update fetch_featured_collection_service.rb
2018-03-04Fix missing focalPoint in ActivityPub JSON (#6609)Eugen Rochko
2018-02-28Federated reports (#6570)Eugen Rochko
* Fix #2176: Federated reports * UI for federated reports * Add spec for ActivityPub Flag handler * Add spec for ReportService
2018-02-24Raise Mastodon::HostValidationError when host for HTTP request is private ↵Akihiko Odaki
(#6410)
2018-02-24Do not push status to feed if its reblog is already inserted (#6488)Akihiko Odaki
A complemental change for precompute_feed_service_spec.rb also fixes its random failure which is caused by the Snowlake randomization of the order of an original status and its reblog.
2018-02-22Redesign landing page (again) (#6486)Eugen Rochko
* Redesign landing page (again) * Move login form in small version to the right column * Display closed registrations message * Add site setting for the hero image * Fix test * Increase spacing, maximum width, change call to action section
2018-02-21Fix bug in relationships API introduced by #6482 (#6527)Eugen Rochko
It was merge when it needed to be deep_merge. And added some tests
2018-02-21Account archive download (#6460)Eugen Rochko
* Fix #201: Account archive download * Export actor and private key in the archive * Optimize BackupService - Add conversation to cached associations of status, because somehow it was forgotten and is source of N+1 queries - Explicitly call GC between batches of records being fetched (Model class allocations are the worst offender) - Stream media files into the tar in 1MB chunks (Do not allocate media file (up to 8MB) as string into memory) - Use #bytesize instead of #size to calculate file size for JSON (Fix FileOverflow error) - Segment media into subfolders by status ID because apparently GIF-to-MP4 media are all named "media.mp4" for some reason * Keep uniquely generated filename in Paperclip::GifTranscoder * Ensure dumped files do not overwrite each other by maintaing directory partitions * Give tar archives a good name * Add scheduler to remove week-old backups * Fix code style issue
2018-02-20Improve performance of feed_manager_spec (#6517)abcang
2018-02-18Added fetch_remote_status_service call spec case actibitypub (#6500)Kazushige Tominaga
* Added #link_header spec * Added #call spec * Delete spec of private methods * Added call test case activitypub