File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed
src/Illuminate/Support/Facades
tests/Integration/Database Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change 45
45
* @method static void mixin(object $mixin, bool $replace = true)
46
46
* @method static bool hasMacro(string $name)
47
47
* @method static void flushMacros()
48
+ * @method static int|null getConnectionCount()
48
49
*
49
50
* @see \Illuminate\Database\Schema\Builder
50
51
*/
Original file line number Diff line number Diff line change @@ -874,4 +874,14 @@ public function testAddingMacros()
874
874
$ this ->assertTrue (Schema::hasForeignKeyForColumn ('question_id ' , 'answers ' , 'questions ' ));
875
875
$ this ->assertFalse (Schema::hasForeignKeyForColumn ('body ' , 'answers ' , 'questions ' ));
876
876
}
877
+
878
+ public function testGetConnectionCount ()
879
+ {
880
+ $ count = Schema::getConnectionCount ();
881
+ if ($ this ->driver === 'sqlite ' ) {
882
+ $ this ->assertNull ($ count , 'SQLite does not support connection count ' );
883
+ } else {
884
+ $ this ->assertGreaterThanOrEqual (1 , $ count );
885
+ }
886
+ }
877
887
}
You can’t perform that action at this time.
0 commit comments