tests: Implement TorrentController API tests

As part of this effort, a dedicated "torrents" storage location was
added to filesystems.php, which affects the torrent file storage
location. Accordingly, the torrent files in existing installations will
need to be moved (or symlinked) upon upgrade. The primary reason for
this change is mentioned in the Laravel docs: "This convention will
keep your publicly accessible files in one directory that can be easily
shared across deployments when using zero down-time deployment systems
like Envoyer."
This commit is contained in:
Ben Johnson
2020-02-21 22:04:34 -05:00
parent 563f19031b
commit aa32a893fa
7 changed files with 179 additions and 119 deletions
+6 -2
View File
@@ -308,10 +308,14 @@ class ChatRepository
public function systemMessage($message, $bot = null)
{
$systemUserId = User::where('username', 'System')->first()->id;
if ($bot) {
$this->message(1, $this->systemChatroom(), $message, null, $bot);
$this->message($systemUserId, $this->systemChatroom(), $message, null, $bot);
} else {
$this->message(1, $this->systemChatroom(), $message, null, 1);
$systemBotId = Bot::where('slug', 'systembot')->first()->id;
$this->message($systemUserId, $this->systemChatroom(), $message, null, $systemBotId);
}
return $this;