language stringclasses 1
value | owner stringlengths 2 15 | repo stringlengths 2 21 | sha stringlengths 45 45 | message stringlengths 7 36.3k | path stringlengths 1 199 | patch stringlengths 15 102k | is_multipart bool 2
classes |
|---|---|---|---|---|---|---|---|
Other | laravel | framework | ed8d75bfa193415986495016e89aac5f9ef0d96b.json | Clarify delay time (#41167) | src/Illuminate/Queue/Jobs/SqsJob.php | @@ -42,7 +42,7 @@ public function __construct(Container $container, SqsClient $sqs, array $job, $c
}
/**
- * Release the job back into the queue.
+ * Release the job back into the queue after (n) seconds.
*
* @param int $delay
* @return void | true |
Other | laravel | framework | ed8d75bfa193415986495016e89aac5f9ef0d96b.json | Clarify delay time (#41167) | src/Illuminate/Queue/Jobs/SyncJob.php | @@ -39,7 +39,7 @@ public function __construct(Container $container, $payload, $connectionName, $qu
}
/**
- * Release the job back into the queue.
+ * Release the job back into the queue after (n) seconds.
*
* @param int $delay
* @return void | true |
Other | laravel | framework | ed8d75bfa193415986495016e89aac5f9ef0d96b.json | Clarify delay time (#41167) | src/Illuminate/Queue/NullQueue.php | @@ -44,7 +44,7 @@ public function pushRaw($payload, $queue = null, array $options = [])
}
/**
- * Push a new job onto the queue after a delay.
+ * Push a new job onto the queue after (n) seconds.
*
* @param \DateTimeInterface|\DateInterval|int $delay
* @param string $job | true |
Other | laravel | framework | ed8d75bfa193415986495016e89aac5f9ef0d96b.json | Clarify delay time (#41167) | src/Illuminate/Queue/Queue.php | @@ -58,7 +58,7 @@ public function pushOn($queue, $job, $data = '')
}
/**
- * Push a new job onto the queue after a delay.
+ * Push a new job onto a specific queue after (n) seconds.
*
* @param string $queue
* @param \DateTimeInterface|\DateInterval|int $delay | true |
Other | laravel | framework | ed8d75bfa193415986495016e89aac5f9ef0d96b.json | Clarify delay time (#41167) | src/Illuminate/Queue/RedisQueue.php | @@ -167,7 +167,7 @@ function ($payload, $queue, $delay) {
}
/**
- * Push a raw job onto the queue after a delay.
+ * Push a raw job onto the queue after (n) seconds.
*
* @param \DateTimeInterface|\DateInterval|int $delay
* @param string $payload | true |
Other | laravel | framework | ed8d75bfa193415986495016e89aac5f9ef0d96b.json | Clarify delay time (#41167) | src/Illuminate/Queue/SqsQueue.php | @@ -116,7 +116,7 @@ public function pushRaw($payload, $queue = null, array $options = [])
}
/**
- * Push a new job onto the queue after a delay.
+ * Push a new job onto the queue after (n) seconds.
*
* @param \DateTimeInterface|\DateInterval|int $delay
* @param string $job | true |
Other | laravel | framework | ed8d75bfa193415986495016e89aac5f9ef0d96b.json | Clarify delay time (#41167) | src/Illuminate/Queue/SyncQueue.php | @@ -134,7 +134,7 @@ public function pushRaw($payload, $queue = null, array $options = [])
}
/**
- * Push a new job onto the queue after a delay.
+ * Push a new job onto the queue after (n) seconds.
*
* @param \DateTimeInterface|\DateInterval|int $delay
* @param string $job | true |
Other | laravel | framework | ed8d75bfa193415986495016e89aac5f9ef0d96b.json | Clarify delay time (#41167) | src/Illuminate/Support/Testing/Fakes/QueueFake.php | @@ -299,7 +299,7 @@ public function pushRaw($payload, $queue = null, array $options = [])
}
/**
- * Push a new job onto the queue after a delay.
+ * Push a new job onto the queue after (n) seconds.
*
* @param \DateTimeInterface|\DateInterval|int $delay
* @param string $job
@@ -... | true |
Other | laravel | framework | dec6b72b690d8bc673413856bbb9b72f4f05078d.json | Remove some useless import. (#41169) | src/Illuminate/Mail/Mailable.php | @@ -23,7 +23,6 @@
use Symfony\Component\Mailer\Header\MetadataHeader;
use Symfony\Component\Mailer\Header\TagHeader;
use Symfony\Component\Mime\Address;
-use Symfony\Component\Mime\Email;
class Mailable implements MailableContract, Renderable
{ | false |
Other | laravel | framework | 6c0ffe3b274aeff16661efc33921ae5211b5f7d2.json | Apply fixes from StyleCI | tests/Validation/ValidationValidatorTest.php | @@ -754,13 +754,13 @@ public function message()
$this->assertSame('my custom message', $v->messages()->first('name'));
$trans = $this->getIlluminateArrayTranslator();
- $v = new Validator($trans, ['name' => 'Ryan'], ['name' => $rule], ['name.' . $rule::class => 'my custom message']);
+ ... | false |
Other | laravel | framework | 40abea870dbb802b752eb294fad5ab9de1eec1e5.json | Fix setPriority Call for MailChannel (#41120) | src/Illuminate/Notifications/Channels/MailChannel.php | @@ -143,7 +143,7 @@ protected function buildMessage($mailMessage, $notifiable, $notification, $messa
$this->addAttachments($mailMessage, $message);
if (! is_null($message->priority)) {
- $mailMessage->setPriority($message->priority);
+ $mailMessage->priority($message->priority)... | true |
Other | laravel | framework | 40abea870dbb802b752eb294fad5ab9de1eec1e5.json | Fix setPriority Call for MailChannel (#41120) | tests/Integration/Notifications/SendingMailNotificationsTest.php | @@ -98,7 +98,7 @@ public function testMailIsSent()
$message->shouldReceive('subject')->once()->with('Test Mail Notification');
- $message->shouldReceive('setPriority')->once()->with(1);
+ $message->shouldReceive('priority')->once()->with(1);
$closure... | true |
Other | laravel | framework | 502a5054025a81996d45d2657a598809db3c2aab.json | Remove duplicate queries to find batch (#41121) | src/Illuminate/Queue/CallQueuedHandler.php | @@ -179,12 +179,13 @@ protected function ensureSuccessfulBatchJobIsRecorded($command)
$uses = class_uses_recursive($command);
if (! in_array(Batchable::class, $uses) ||
- ! in_array(InteractsWithQueue::class, $uses) ||
- is_null($command->batch())) {
+ ! in_array(Int... | false |
Other | laravel | framework | 9236336c554fb88f6a5372814e4e993e64c2ecca.json | Add missing test for Password Reset (#41104)
Signed-off-by: Mior Muhammad Zaki <crynobone@gmail.com> | tests/Integration/Auth/ForgotPasswordTest.php | @@ -12,6 +12,14 @@
class ForgotPasswordTest extends TestCase
{
+ protected function tearDown(): void
+ {
+ ResetPassword::$createUrlCallback = null;
+ ResetPassword::$toMailCallback = null;
+
+ parent::tearDown();
+ }
+
protected function defineEnvironment($app)
{
$a... | true |
Other | laravel | framework | 9236336c554fb88f6a5372814e4e993e64c2ecca.json | Add missing test for Password Reset (#41104)
Signed-off-by: Mior Muhammad Zaki <crynobone@gmail.com> | tests/Integration/Auth/ForgotPasswordWithoutDefaultRoutesTest.php | @@ -0,0 +1,126 @@
+<?php
+
+namespace Illuminate\Tests\Integration\Auth;
+
+use Illuminate\Auth\Notifications\ResetPassword;
+use Illuminate\Notifications\Messages\MailMessage;
+use Illuminate\Support\Facades\Notification;
+use Illuminate\Support\Facades\Password;
+use Illuminate\Tests\Integration\Auth\Fixtures\Authent... | true |
Other | laravel | framework | 0c710c5769ed8bb8e5c487c9885afec9be96f76e.json | Update Enumerable interface | src/Illuminate/Collections/Enumerable.php | @@ -964,7 +964,7 @@ public function splitIn($numberOfGroups);
/**
* Sort through each item with a callback.
*
- * @param (callable(TValue, TValue): bool)|null|int $callback
+ * @param (callable(TValue, TValue): int)|null|int $callback
* @return static
*/
public function sor... | false |
Other | laravel | framework | b74e66b1588e6517f93a759c301246aaaa5135d0.json | add test for CacheManager (#41022) | tests/Cache/CacheManagerTest.php | @@ -4,8 +4,11 @@
use Illuminate\Cache\ArrayStore;
use Illuminate\Cache\CacheManager;
+use Illuminate\Cache\NullStore;
use Illuminate\Config\Repository;
use Illuminate\Container\Container;
+use Illuminate\Contracts\Events\Dispatcher;
+use Illuminate\Events\Dispatcher as Event;
use InvalidArgumentException;
use M... | false |
Other | laravel | framework | c5166e83d1b1f9ce1b9ea04093b329388ed3404a.json | add test for cache increment (#41013) | tests/Cache/CacheArrayStoreTest.php | @@ -70,6 +70,33 @@ public function testValuesCanBeIncremented()
$result = $store->increment('foo');
$this->assertEquals(2, $result);
$this->assertEquals(2, $store->get('foo'));
+
+ $result = $store->increment('foo', 2);
+ $this->assertEquals(4, $result);
+ $this->assertEq... | true |
Other | laravel | framework | c5166e83d1b1f9ce1b9ea04093b329388ed3404a.json | add test for cache increment (#41013) | tests/Cache/CacheFileStoreTest.php | @@ -2,6 +2,7 @@
namespace Illuminate\Tests\Cache;
+use Exception;
use Illuminate\Cache\FileStore;
use Illuminate\Contracts\Filesystem\FileNotFoundException;
use Illuminate\Filesystem\Filesystem;
@@ -186,17 +187,80 @@ public function testForeversAreNotRemovedOnIncrement()
$this->assertSame('Hello World'... | true |
Other | laravel | framework | fdcd963158587e9c69980bbf53ad8e1c34d70d9f.json | add tests for cacheManager (#40981) | src/Illuminate/Cache/CacheManager.php | @@ -328,7 +328,7 @@ protected function getPrefix(array $config)
* Get the cache connection configuration.
*
* @param string $name
- * @return array
+ * @return array|null
*/
protected function getConfig($name)
{ | true |
Other | laravel | framework | fdcd963158587e9c69980bbf53ad8e1c34d70d9f.json | add tests for cacheManager (#40981) | tests/Cache/CacheManagerTest.php | @@ -4,6 +4,9 @@
use Illuminate\Cache\ArrayStore;
use Illuminate\Cache\CacheManager;
+use Illuminate\Config\Repository;
+use Illuminate\Container\Container;
+use InvalidArgumentException;
use Mockery as m;
use PHPUnit\Framework\TestCase;
@@ -72,4 +75,54 @@ public function testForgetDriverForgets()
$cach... | true |
Other | laravel | framework | 11251f24318ed806f07323faf747d7e318922723.json | Add filtering of the route list by domain (#40970) | src/Illuminate/Foundation/Console/RouteListCommand.php | @@ -212,9 +212,10 @@ protected function getMiddleware($route)
*/
protected function filterRoute(array $route)
{
- if (($this->option('name') && ! str_contains($route['name'], $this->option('name'))) ||
- $this->option('path') && ! str_contains($route['uri'], $this->option('path')) ||
-... | false |
Other | laravel | framework | 3bfc5703728191b0fd6a6c07420ca881aef706a7.json | Update ExceptionHandler.php (#40956) | src/Illuminate/Contracts/Debug/ExceptionHandler.php | @@ -41,6 +41,8 @@ public function render($request, Throwable $e);
* @param \Symfony\Component\Console\Output\OutputInterface $output
* @param \Throwable $e
* @return void
+ *
+ * @internal This method is not meant to be used or overwritten outside the framework.
*/
public functi... | false |
Other | laravel | framework | 4a474ced7889979f50e794fff9091eace57dc5bd.json | Fix typo in method documentation (#40951) | src/Illuminate/Cache/DynamoDbStore.php | @@ -211,7 +211,7 @@ public function put($key, $value, $seconds)
}
/**
- * Store multiple items in the cache for a given number of $seconds.
+ * Store multiple items in the cache for a given number of seconds.
*
* @param array $values
* @param int $seconds | false |
Other | laravel | framework | 705642d1983443a94182973de3306b9144cee3bd.json | Apply fixes from StyleCI | src/Illuminate/Routing/Router.php | @@ -374,7 +374,7 @@ public function apiResource($name, $controller, array $options = [])
* @return void
*/
public function group(array $attributes, $routes)
- {
+ {
foreach (Arr::wrap($routes) as $groupRoutes) {
$this->updateGroupStack($attributes);
| false |
Other | laravel | framework | 3ef58e60e27baf5bac0a43cb95560f33a156bae9.json | Fix Mailable->priority() (#40917)
Fixes #40916 | src/Illuminate/Mail/Mailable.php | @@ -488,7 +488,7 @@ public function locale($locale)
public function priority($level = 3)
{
$this->callbacks[] = function ($message) use ($level) {
- $message->setPriority($level);
+ $message->priority($level);
};
return $this; | true |
Other | laravel | framework | 3ef58e60e27baf5bac0a43cb95560f33a156bae9.json | Fix Mailable->priority() (#40917)
Fixes #40916 | tests/Mail/MailMailableTest.php | @@ -2,11 +2,20 @@
namespace Illuminate\Tests\Mail;
+use Illuminate\Contracts\View\Factory;
use Illuminate\Mail\Mailable;
+use Illuminate\Mail\Mailer;
+use Illuminate\Mail\Transport\ArrayTransport;
+use Mockery as m;
use PHPUnit\Framework\TestCase;
class MailMailableTest extends TestCase
{
+ protected func... | true |
Other | laravel | framework | f2ce3d50073eedb49c806a6f2f0049b58b3b04bc.json | Fix publishing visibility (#40918) | src/Illuminate/Foundation/Console/VendorPublishCommand.php | @@ -11,6 +11,8 @@
use League\Flysystem\Filesystem as Flysystem;
use League\Flysystem\Local\LocalFilesystemAdapter as LocalAdapter;
use League\Flysystem\MountManager;
+use League\Flysystem\UnixVisibility\PortableVisibilityConverter;
+use League\Flysystem\Visibility;
class VendorPublishCommand extends Command
{
@@... | false |
Other | laravel | framework | ed70b724bd1d10230465bf5c8ae5453f5be40949.json | fix non-existing property | types/Database/Eloquent/Collection.php | @@ -135,7 +135,7 @@
assertType('User', $user);
assertType('int', $int);
- return $user->id;
+ return $user->primaryKey;
}));
assertType('Illuminate\Database\Eloquent\Collection<int, User>', $collection->unique('string'));
| true |
Other | laravel | framework | ed70b724bd1d10230465bf5c8ae5453f5be40949.json | fix non-existing property | types/Support/Collection.php | @@ -747,7 +747,7 @@
assertType('User', $user);
assertType('int', $int);
- return $user->id;
+ return $user->primaryKey;
}));
assertType('Illuminate\Support\Collection<string, string>', $collection->make(['string' => 'string'])->unique(function ($stringA, $stringB) {
assertType('string', $string... | true |
Other | laravel | framework | ed70b724bd1d10230465bf5c8ae5453f5be40949.json | fix non-existing property | types/Support/LazyCollection.php | @@ -745,7 +745,7 @@
assertType('User', $user);
assertType('int', $int);
- return $user->id;
+ return $user->primaryKey;
}));
assertType('Illuminate\Support\LazyCollection<string, string>', $collection->make(['string' => 'string'])->unique(function ($stringA, $stringB) {
assertType('string', $st... | true |
Other | laravel | framework | 368fabca7e936174eb10305d76c590ce67311417.json | Improve types on model factory methods | src/Illuminate/Database/Eloquent/Factories/Factory.php | @@ -148,7 +148,7 @@ abstract public function definition();
/**
* Get a new factory instance for the given attributes.
*
- * @param (callable(): array<string, mixed>)|array<string, mixed> $attributes
+ * @param (callable(array<string, mixed>): array<string, mixed>)|array<string, mixed> $attr... | false |
Other | laravel | framework | cefd1c8a00d69aefb944c9c53f052039e6aa3d05.json | Apply fixes from StyleCI | src/Illuminate/Support/Str.php | @@ -918,6 +918,7 @@ public static function substrReplace($string, $replace, $offset = 0, $length = n
public static function swap(array $map, $subject)
{
return strtr($subject, $map);
+
return str_replace(array_keys($map), array_values($map), $subject);
}
| false |
Other | laravel | framework | 2246744061de4bfd2d3a42d715e6b760015fa074.json | add test for cache Repository class (#40817) | tests/Cache/CacheRepositoryTest.php | @@ -205,6 +205,36 @@ public function testCacheAddCallsRedisStoreAdd()
$this->assertTrue($repository->add('k', 'v', 60));
}
+ public function testAddMethodCanAcceptDateIntervals()
+ {
+ $storeWithAdd = m::mock(RedisStore::class);
+ $storeWithAdd->shouldReceive('add')->once()->with('k'... | false |
Other | laravel | framework | c7f4c23e17013b9c6f86a8fd1d37a590e2ad29b4.json | Add tests for put method of FileStore (#40811) | tests/Cache/CacheFileStoreTest.php | @@ -62,7 +62,43 @@ public function testPutCreatesMissingDirectories()
$this->assertTrue($result);
}
- public function testExpiredItemsReturnNull()
+ public function testPutWillConsiderZeroAsEternalTime()
+ {
+ $files = $this->mockFilesystem();
+
+ $hash = sha1('O--L / key');
+ ... | false |
Other | laravel | framework | 1c15d0883bbe316f374c9f5e74a3a1e168184649.json | Create pull-requests.yml (#40808) | .github/workflows/pull-requests.yml | @@ -0,0 +1,64 @@
+name: Pull Requests
+
+# Credit: https://github.com/github/docs/blob/main/.github/workflows/notify-when-maintainers-cannot-edit.yaml
+
+on:
+ pull_request_target:
+ types:
+ - opened
+
+permissions:
+ pull-requests: write
+
+jobs:
+ uneditable:
+ if: github.repository == 'laravel/framewo... | false |
Other | laravel | framework | 870bc7d6c106a3391da90372d488b89da3bc8236.json | add directory visibility | src/Illuminate/Filesystem/FilesystemManager.php | @@ -271,9 +271,13 @@ protected function formatS3Config(array $config)
*/
protected function createFlysystem(FlysystemAdapter $adapter, array $config)
{
- $config = Arr::only($config, ['visibility', 'disable_asserts', 'url', 'temporary_url']);
-
- return new Flysystem($adapter, $config);
+ ... | false |
Other | laravel | framework | 5164e0e83ab7d580124c9b777f12c88d6c5ced06.json | Simplify mocking assertions. (#40786) | tests/Database/DatabaseConnectorTest.php | @@ -129,8 +129,8 @@ public function testPostgresSearchPathCommaSeparatedValueSupported()
$config = ['host' => 'foo', 'database' => 'bar', 'search_path' => 'public, "user"', 'charset' => 'utf8'];
$connector = $this->getMockBuilder('Illuminate\Database\Connectors\PostgresConnector')->setMethods(['create... | true |
Other | laravel | framework | 5164e0e83ab7d580124c9b777f12c88d6c5ced06.json | Simplify mocking assertions. (#40786) | tests/Foundation/Testing/DatabaseMigrationsTest.php | @@ -46,7 +46,7 @@ private function __reflectAndSetupAccessibleForProtectedTraitMethod($methodName)
public function testRefreshTestDatabaseDefault()
{
$this->traitObject
- ->expects($this->exactly(1))
+ ->expects($this->once())
->method('artisan')
->with... | true |
Other | laravel | framework | 5164e0e83ab7d580124c9b777f12c88d6c5ced06.json | Simplify mocking assertions. (#40786) | tests/Foundation/Testing/RefreshDatabaseTest.php | @@ -46,7 +46,7 @@ private function __reflectAndSetupAccessibleForProtectedTraitMethod($methodName)
public function testRefreshTestDatabaseDefault()
{
$this->traitObject
- ->expects($this->exactly(1))
+ ->expects($this->once())
->method('artisan')
->with... | true |
Other | laravel | framework | 5164e0e83ab7d580124c9b777f12c88d6c5ced06.json | Simplify mocking assertions. (#40786) | tests/Support/SupportNamespacedItemResolverTest.php | @@ -30,9 +30,7 @@ public function testParsedItemsAreCached()
public function testParsedItemsMayBeFlushed()
{
$r = $this->getMockBuilder(NamespacedItemResolver::class)->onlyMethods(['parseBasicSegments', 'parseNamespacedSegments'])->getMock();
- $r->expects($this->once())->method('parseBasicSeg... | true |
Other | laravel | framework | dccf13e2c831c990e96d4c62a229f5ce3c2208ea.json | Avoid FQCN in code. (#40789) | src/Illuminate/Database/Eloquent/Concerns/HasAttributes.php | @@ -4,6 +4,7 @@
use Carbon\CarbonImmutable;
use Carbon\CarbonInterface;
+use DateTimeImmutable;
use DateTimeInterface;
use Illuminate\Contracts\Database\Eloquent\Castable;
use Illuminate\Contracts\Database\Eloquent\CastsInboundAttributes;
@@ -1345,7 +1346,7 @@ protected function asTimestamp($value)
*/
... | true |
Other | laravel | framework | dccf13e2c831c990e96d4c62a229f5ce3c2208ea.json | Avoid FQCN in code. (#40789) | src/Illuminate/Routing/RouteDependencyResolverTrait.php | @@ -7,6 +7,7 @@
use ReflectionFunctionAbstract;
use ReflectionMethod;
use ReflectionParameter;
+use stdClass;
trait RouteDependencyResolverTrait
{
@@ -42,7 +43,7 @@ public function resolveMethodDependencies(array $parameters, ReflectionFunctionA
$values = array_values($parameters);
- $skippab... | true |
Other | laravel | framework | dccf13e2c831c990e96d4c62a229f5ce3c2208ea.json | Avoid FQCN in code. (#40789) | tests/Database/DatabaseEloquentSoftDeletesIntegrationTest.php | @@ -3,6 +3,7 @@
namespace Illuminate\Tests\Database;
use BadMethodCallException;
+use Exception;
use Illuminate\Database\Capsule\Manager as DB;
use Illuminate\Database\Eloquent\Model as Eloquent;
use Illuminate\Database\Eloquent\SoftDeletes;
@@ -212,7 +213,7 @@ public function testForceDeleteDoesntUpdateExistsPr... | true |
Other | laravel | framework | dccf13e2c831c990e96d4c62a229f5ce3c2208ea.json | Avoid FQCN in code. (#40789) | tests/Foundation/Testing/DatabaseMigrationsTest.php | @@ -5,7 +5,9 @@
use Illuminate\Contracts\Console\Kernel;
use Illuminate\Foundation\Testing\DatabaseMigrations;
use Illuminate\Foundation\Testing\RefreshDatabaseState;
+use Mockery;
use PHPUnit\Framework\TestCase;
+use ReflectionMethod;
class DatabaseMigrationsTest extends TestCase
{
@@ -20,7 +22,7 @@ protected ... | true |
Other | laravel | framework | dccf13e2c831c990e96d4c62a229f5ce3c2208ea.json | Avoid FQCN in code. (#40789) | tests/Foundation/Testing/RefreshDatabaseTest.php | @@ -5,7 +5,9 @@
use Illuminate\Contracts\Console\Kernel;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Illuminate\Foundation\Testing\RefreshDatabaseState;
+use Mockery;
use PHPUnit\Framework\TestCase;
+use ReflectionMethod;
class RefreshDatabaseTest extends TestCase
{
@@ -20,7 +22,7 @@ protected functi... | true |
Other | laravel | framework | dccf13e2c831c990e96d4c62a229f5ce3c2208ea.json | Avoid FQCN in code. (#40789) | tests/Foundation/Testing/Traits/CanConfigureMigrationCommandsTest.php | @@ -4,6 +4,7 @@
use Illuminate\Foundation\Testing\Traits\CanConfigureMigrationCommands;
use PHPUnit\Framework\TestCase;
+use ReflectionMethod;
class CanConfigureMigrationCommandsTest extends TestCase
{
@@ -16,7 +17,7 @@ protected function setup(): void
private function __reflectAndSetupAccessibleForProte... | true |
Other | laravel | framework | dccf13e2c831c990e96d4c62a229f5ce3c2208ea.json | Avoid FQCN in code. (#40789) | tests/Integration/Database/EloquentStrictLoadingTest.php | @@ -8,6 +8,7 @@
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Event;
use Illuminate\Support\Facades\Schema;
+use RuntimeException;
class EloquentStrictLoadingTest extends DatabaseTestCase
{
@@ -134,7 +135,7 @@ public function testStrictModeWithCustomCallbackOnLazyLoading()
publi... | true |
Other | laravel | framework | dccf13e2c831c990e96d4c62a229f5ce3c2208ea.json | Avoid FQCN in code. (#40789) | tests/Support/SupportHelpersTest.php | @@ -12,6 +12,7 @@
use LogicException;
use Mockery as m;
use PHPUnit\Framework\TestCase;
+use ReflectionClass;
use RuntimeException;
use stdClass;
use Traversable;
@@ -377,11 +378,11 @@ public function testStr()
$this->assertTrue($stringable->isEmpty());
$strAccessor = str();
- $this->as... | true |
Other | laravel | framework | 6f4480b48125480feaa053445817a9c00103a5e1.json | add selected directive | src/Illuminate/View/Compilers/Concerns/CompilesConditionals.php | @@ -305,6 +305,17 @@ public function compileEndOnce()
return '<?php endif; ?>';
}
+ /**
+ * Compile a selected block into valid PHP.
+ *
+ * @param string $condition
+ * @return string
+ */
+ protected function compileSelected($condition)
+ {
+ return "<?php if{$con... | true |
Other | laravel | framework | 6f4480b48125480feaa053445817a9c00103a5e1.json | add selected directive | tests/View/Blade/BladeCheckedStatementsTest.php | @@ -4,6 +4,14 @@
class BladeCheckedStatementsTest extends AbstractBladeTestCase
{
+ public function testSelectedStatementsAreCompiled()
+ {
+ $string = '<input @selected(name(foo(bar)))/>';
+ $expected = "<input <?php if(name(foo(bar))): echo 'selected'; endif; ?>/>";
+
+ $this->assertEqu... | true |
Other | laravel | framework | 84d433d7d7acd44cce5d9f0b7562439346e6fe19.json | add checked helper | src/Illuminate/Foundation/Testing/Concerns/InteractsWithRedis.php | @@ -76,10 +76,14 @@ public function setUpRedis()
*/
public function tearDownRedis()
{
- $this->redis['phpredis']->connection()->flushdb();
+ if (isset($this->redis['phpredis'])) {
+ $this->redis['phpredis']->connection()->flushdb();
+ }
foreach ($this->redisDri... | true |
Other | laravel | framework | 84d433d7d7acd44cce5d9f0b7562439346e6fe19.json | add checked helper | src/Illuminate/View/Compilers/Concerns/CompilesConditionals.php | @@ -304,4 +304,15 @@ public function compileEndOnce()
{
return '<?php endif; ?>';
}
+
+ /**
+ * Compile a checked block into valid PHP.
+ *
+ * @param string $condition
+ * @return string
+ */
+ protected function compileChecked($condition)
+ {
+ return "<?php if... | true |
Other | laravel | framework | 84d433d7d7acd44cce5d9f0b7562439346e6fe19.json | add checked helper | tests/View/Blade/BladeCheckedStatementsTest.php | @@ -0,0 +1,14 @@
+<?php
+
+namespace Illuminate\Tests\View\Blade;
+
+class BladeCheckedStatementsTest extends AbstractBladeTestCase
+{
+ public function testCheckedStatementsAreCompiled()
+ {
+ $string = '<input @checked(name(foo(bar)))/>';
+ $expected = "<input <?php if(name(foo(bar))): echo 'check... | true |
Other | laravel | framework | 442b6d0e7e086a5775c97ccd61111c75cd2d2037.json | Make PendingRequest conditionable (#40762) | src/Illuminate/Http/Client/PendingRequest.php | @@ -13,13 +13,14 @@
use Illuminate\Http\Client\Events\ResponseReceived;
use Illuminate\Support\Collection;
use Illuminate\Support\Str;
+use Illuminate\Support\Traits\Conditionable;
use Illuminate\Support\Traits\Macroable;
use Psr\Http\Message\MessageInterface;
use Symfony\Component\VarDumper\VarDumper;
class P... | false |
Other | laravel | framework | 5ea6689a39fc05376cd20832b531e9cb1d71096e.json | Fix errored namespaces. (#40752) | tests/Foundation/Http/KernelTest.php | @@ -1,6 +1,6 @@
<?php
-namespace Illuminate\Tests\Foundation\Bootstrap\Http;
+namespace Illuminate\Tests\Foundation\Http;
use Illuminate\Events\Dispatcher;
use Illuminate\Foundation\Application; | true |
Other | laravel | framework | 5ea6689a39fc05376cd20832b531e9cb1d71096e.json | Fix errored namespaces. (#40752) | tests/Foundation/Http/Middleware/ConvertEmptyStringsToNullTest.php | @@ -1,6 +1,6 @@
<?php
-namespace Illuminate\Tests\Foundation\Bootstrap\Http\Middleware;
+namespace Illuminate\Tests\Foundation\Http\Middleware;
use Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull;
use Illuminate\Http\Request; | true |
Other | laravel | framework | 5ea6689a39fc05376cd20832b531e9cb1d71096e.json | Fix errored namespaces. (#40752) | tests/Foundation/Http/Middleware/TransformsRequestTest.php | @@ -1,6 +1,6 @@
<?php
-namespace Illuminate\Tests\Foundation\Bootstrap\Http\Middleware;
+namespace Illuminate\Tests\Foundation\Http\Middleware;
use Illuminate\Foundation\Http\Middleware\TransformsRequest;
use Illuminate\Http\Request; | true |
Other | laravel | framework | 5ea6689a39fc05376cd20832b531e9cb1d71096e.json | Fix errored namespaces. (#40752) | tests/Foundation/Http/Middleware/TrimStringsTest.php | @@ -1,6 +1,6 @@
<?php
-namespace Illuminate\Tests\Foundation\Bootstrap\Http\Middleware;
+namespace Illuminate\Tests\Foundation\Http\Middleware;
use Illuminate\Foundation\Http\Middleware\TrimStrings;
use Illuminate\Http\Request; | true |
Other | laravel | framework | 5ea6689a39fc05376cd20832b531e9cb1d71096e.json | Fix errored namespaces. (#40752) | tests/Foundation/Testing/Concerns/InteractsWithContainerTest.php | @@ -1,6 +1,6 @@
<?php
-namespace Illuminate\Tests\Foundation\Bootstrap\Testing\Concerns;
+namespace Illuminate\Tests\Foundation\Testing\Concerns;
use Illuminate\Foundation\Mix;
use Orchestra\Testbench\TestCase; | true |
Other | laravel | framework | 5ea6689a39fc05376cd20832b531e9cb1d71096e.json | Fix errored namespaces. (#40752) | tests/Foundation/Testing/Concerns/InteractsWithViewsTest.php | @@ -1,6 +1,6 @@
<?php
-namespace Illuminate\Tests\Foundation\Bootstrap\Testing\Concerns;
+namespace Illuminate\Tests\Foundation\Testing\Concerns;
use Illuminate\Foundation\Testing\Concerns\InteractsWithViews;
use Illuminate\View\Component; | true |
Other | laravel | framework | 5ea6689a39fc05376cd20832b531e9cb1d71096e.json | Fix errored namespaces. (#40752) | tests/Foundation/Testing/Concerns/MakesHttpRequestsTest.php | @@ -1,6 +1,6 @@
<?php
-namespace Illuminate\Tests\Foundation\Bootstrap\Testing\Concerns;
+namespace Illuminate\Tests\Foundation\Testing\Concerns;
use Illuminate\Contracts\Routing\Registrar;
use Illuminate\Contracts\Routing\UrlGenerator; | true |
Other | laravel | framework | 5ea6689a39fc05376cd20832b531e9cb1d71096e.json | Fix errored namespaces. (#40752) | tests/Foundation/Testing/WormholeTest.php | @@ -1,6 +1,6 @@
<?php
-namespace Illuminate\Tests\Foundation\Bootstrap\Testing;
+namespace Illuminate\Tests\Foundation\Testing;
use Carbon\CarbonImmutable;
use Illuminate\Foundation\Testing\Wormhole; | true |
Other | laravel | framework | 4f5c5cc1ef773d8bac72fc9bd2ae178ce3991f9f.json | Apply fixes from StyleCI | src/Illuminate/Foundation/Console/ComponentMakeCommand.php | @@ -53,7 +53,7 @@ public function handle()
return;
}
-
+
if (parent::handle() === false && ! $this->option('force')) {
return false;
}
@@ -66,7 +66,7 @@ public function handle()
/**
* Write the view for the component.
*
- * @param call... | false |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Auth/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Broadcasting/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Bus/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Cache/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Collections/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Conditionable/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Config/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Console/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Container/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Contracts/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Cookie/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Database/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Encryption/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Events/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Filesystem/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Hashing/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Http/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Log/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Macroable/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Mail/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Notifications/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Pagination/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Pipeline/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Queue/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Redis/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Routing/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Session/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Support/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Testing/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Translation/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/Validation/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | d69867d97506597c6fdf4dbb552cf457e0095723.json | Add .gitattributes to components (#40733) | src/Illuminate/View/.gitattributes | @@ -0,0 +1,2 @@
+/.github export-ignore
+.gitattributes export-ignore | true |
Other | laravel | framework | 56d433aaec40e8383f28e8f0e835cd977845fcde.json | fix breaking change | src/Illuminate/Queue/QueueServiceProvider.php | @@ -235,7 +235,8 @@ protected function registerFailedJobServices()
$this->app->singleton('queue.failer', function ($app) {
$config = $app['config']['queue.failed'];
- if (! isset($config['driver']) || $config['driver'] === 'null') {
+ if (array_key_exists('driver', $config)... | false |
Other | laravel | framework | b12f44c37bc057e98757743cd67ba47e934dac2a.json | return collection (#40699) | src/Illuminate/Support/Stringable.php | @@ -779,11 +779,11 @@ public function ucfirst()
/**
* Split a string by uppercase characters.
*
- * @return array
+ * @return \Illuminate\Support\Collection
*/
public function ucsplit()
{
- return Str::ucsplit($this->value);
+ return collect(Str::ucsplit($this->val... | false |
Other | laravel | framework | 498fdd2b40644bb48529c2530978555cf4b0766c.json | return array from ucsplit (#40694) | src/Illuminate/Support/Stringable.php | @@ -779,11 +779,11 @@ public function ucfirst()
/**
* Split a string by uppercase characters.
*
- * @return static
+ * @return array
*/
public function ucsplit()
{
- return new static(Str::ucsplit($this->value));
+ return Str::ucsplit($this->value);
}
/... | false |
Other | laravel | framework | f64cfa3f2ee711606723e6018e343eb2c39368cb.json | Fix conflict (#40619) | src/Illuminate/Auth/Access/Gate.php | @@ -239,7 +239,7 @@ public function resource($name, $class, array $abilities = null)
protected function buildAbilityCallback($ability, $callback)
{
return function () use ($ability, $callback) {
- if (Str::contains($callback, '@')) {
+ if (str_contains($callback, '@')) {
... | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.