withArgs(['must_confirm_account', false])->once(); } /** * @covers \FireflyIII\Http\Controllers\Admin\ConfigurationController::index */ public function testIndex() { $this->be($this->user()); $falseConfig = new Configuration; $falseConfig->data = false; $trueConfig = new Configuration; $trueConfig->data = true; FireflyConfig::shouldReceive('get')->withArgs(['single_user_mode', true])->once()->andReturn($trueConfig); FireflyConfig::shouldReceive('get')->withArgs(['must_confirm_account', false])->once()->andReturn($falseConfig); FireflyConfig::shouldReceive('get')->withArgs(['is_demo_site', false])->times(2)->andReturn($falseConfig); // new settings: FireflyConfig::shouldReceive('get')->withArgs(['mail_for_lockout', false])->once()->andReturn($falseConfig); FireflyConfig::shouldReceive('get')->withArgs(['mail_for_blocked_domain', false])->once()->andReturn($falseConfig); FireflyConfig::shouldReceive('get')->withArgs(['mail_for_blocked_email', false])->once()->andReturn($falseConfig); FireflyConfig::shouldReceive('get')->withArgs(['mail_for_bad_login', false])->once()->andReturn($falseConfig); FireflyConfig::shouldReceive('get')->withArgs(['mail_for_blocked_login', false])->once()->andReturn($falseConfig); $this->call('GET', route('admin.configuration.index')); $this->assertResponseStatus(200); // has bread crumb $this->see('