mirror of
https://github.com/flarum/core.git
synced 2025-08-04 23:47:32 +02:00
chore: fix typos (#4021)
This commit is contained in:
@@ -32,7 +32,7 @@ class ListWithFulltextSearchTest extends TestCase
|
||||
|
||||
// We need to insert these outside of a transaction, because FULLTEXT indexing,
|
||||
// which is needed for search, doesn't happen in transactions.
|
||||
// We clean it up explcitly at the end.
|
||||
// We clean it up explicitly at the end.
|
||||
$this->database()->table('discussions')->insert($this->rowsThroughFactory(Discussion::class, [
|
||||
['id' => 1, 'title' => 'lightsail in title', 'user_id' => 1],
|
||||
['id' => 2, 'title' => 'lightsail in title too', 'created_at' => Carbon::createFromDate(2020, 01, 01)->toDateTimeString(), 'user_id' => 1],
|
||||
|
@@ -165,7 +165,7 @@ class ApiSerializerTest extends TestCase
|
||||
}
|
||||
|
||||
#[Test]
|
||||
public function custom_attributes_can_be_overriden()
|
||||
public function custom_attributes_can_be_overridden()
|
||||
{
|
||||
$this->extend(
|
||||
(new Extend\ApiResource(UserResource::class))
|
||||
|
@@ -36,7 +36,7 @@ class SearchDriverTest extends TestCase
|
||||
|
||||
// We need to insert these outside of a transaction, because FULLTEXT indexing,
|
||||
// which is needed for search, doesn't happen in transactions.
|
||||
// We clean it up explcitly at the end.
|
||||
// We clean it up explicitly at the end.
|
||||
$this->database()->table('discussions')->insert([
|
||||
Discussion::factory()->raw(['id' => 1, 'title' => 'DISCUSSION 1', 'user_id' => 1]),
|
||||
Discussion::factory()->raw(['id' => 2, 'title' => 'DISCUSSION 2', 'user_id' => 1]),
|
||||
|
@@ -37,7 +37,7 @@ class ServiceProviderTest extends TestCase
|
||||
$this->app();
|
||||
|
||||
$this->assertEquals(
|
||||
'overriden_by_custom_provider_register',
|
||||
'overridden_by_custom_provider_register',
|
||||
$this->app->getContainer()->make('flarum.forum.middleware')
|
||||
);
|
||||
}
|
||||
@@ -54,7 +54,7 @@ class ServiceProviderTest extends TestCase
|
||||
$this->app();
|
||||
|
||||
$this->assertEquals(
|
||||
'overriden_by_second_custom_provider_register',
|
||||
'overridden_by_second_custom_provider_register',
|
||||
$this->app->getContainer()->make('flarum.forum.middleware')
|
||||
);
|
||||
}
|
||||
@@ -72,7 +72,7 @@ class ServiceProviderTest extends TestCase
|
||||
$this->app();
|
||||
|
||||
$this->assertEquals(
|
||||
'overriden_by_third_custom_provider_boot',
|
||||
'overridden_by_third_custom_provider_boot',
|
||||
$this->app->getContainer()->make('flarum.forum.middleware')
|
||||
);
|
||||
}
|
||||
@@ -84,7 +84,7 @@ class CustomServiceProvider extends AbstractServiceProvider
|
||||
{
|
||||
// First we override the singleton here.
|
||||
$this->app->extend('flarum.forum.middleware', function () {
|
||||
return 'overriden_by_custom_provider_register';
|
||||
return 'overridden_by_custom_provider_register';
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -93,9 +93,9 @@ class SecondCustomServiceProvider extends AbstractServiceProvider
|
||||
{
|
||||
public function register()
|
||||
{
|
||||
// Second we check that the singleton was overriden here.
|
||||
// Second we check that the singleton was overridden here.
|
||||
$this->app->extend('flarum.forum.middleware', function ($forumRoutes) {
|
||||
return 'overriden_by_second_custom_provider_register';
|
||||
return 'overridden_by_second_custom_provider_register';
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -106,7 +106,7 @@ class ThirdCustomProvider extends AbstractServiceProvider
|
||||
{
|
||||
// Third we override one last time here, to make sure this is the final result.
|
||||
$this->app->extend('flarum.forum.middleware', function ($forumRoutes) {
|
||||
return 'overriden_by_third_custom_provider_boot';
|
||||
return 'overridden_by_third_custom_provider_boot';
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@@ -40,7 +40,7 @@ class ValidatorTest extends TestCase
|
||||
{
|
||||
$this->app()->getContainer()->make(CustomUserValidator::class)->assertValid(['password' => 'simplePassword']);
|
||||
|
||||
// If we have gotten this far, no validation exception has been thrown, so the test is succesful.
|
||||
// If we have gotten this far, no validation exception has been thrown, so the test is successful.
|
||||
$this->assertTrue(true);
|
||||
}
|
||||
|
||||
@@ -71,7 +71,7 @@ class ValidatorTest extends TestCase
|
||||
|
||||
$this->app()->getContainer()->make(CustomValidator::class)->assertValid(['password' => 'simplePassword']);
|
||||
|
||||
// If we have gotten this far, no validation exception has been thrown, so the test is succesful.
|
||||
// If we have gotten this far, no validation exception has been thrown, so the test is successful.
|
||||
$this->assertTrue(true);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user