Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
L
laravel-mongodb
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sinan
laravel-mongodb
Commits
20b0418b
Commit
20b0418b
authored
Jul 02, 2016
by
Jens Segers
Committed by
StyleCI Bot
Jul 02, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Applied fixes from StyleCI
parent
296716e3
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
6 additions
and
22 deletions
+6
-22
Model.php
src/Jenssegers/Mongodb/Eloquent/Model.php
+0
-1
SoftDeletes.php
src/Jenssegers/Mongodb/Eloquent/SoftDeletes.php
+0
-1
AuthTest.php
tests/AuthTest.php
+0
-1
ConnectionTest.php
tests/ConnectionTest.php
+0
-1
EmbeddedRelationsTest.php
tests/EmbeddedRelationsTest.php
+0
-1
ModelTest.php
tests/ModelTest.php
+0
-1
MysqlRelationsTest.php
tests/MysqlRelationsTest.php
+0
-1
QueryBuilderTest.php
tests/QueryBuilderTest.php
+0
-1
QueryTest.php
tests/QueryTest.php
+6
-7
RelationsTest.php
tests/RelationsTest.php
+0
-3
SchemaTest.php
tests/SchemaTest.php
+0
-1
SeederTest.php
tests/SeederTest.php
+0
-1
ValidationTest.php
tests/ValidationTest.php
+0
-1
UserTableSeeder.php
tests/seeds/UserTableSeeder.php
+0
-1
No files found.
src/Jenssegers/Mongodb/Eloquent/Model.php
View file @
20b0418b
...
@@ -14,7 +14,6 @@ use ReflectionMethod;
...
@@ -14,7 +14,6 @@ use ReflectionMethod;
abstract
class
Model
extends
BaseModel
abstract
class
Model
extends
BaseModel
{
{
use
HybridRelations
;
use
HybridRelations
;
/**
/**
...
...
src/Jenssegers/Mongodb/Eloquent/SoftDeletes.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
trait
SoftDeletes
trait
SoftDeletes
{
{
use
\Illuminate\Database\Eloquent\SoftDeletes
;
use
\Illuminate\Database\Eloquent\SoftDeletes
;
/**
/**
...
...
tests/AuthTest.php
View file @
20b0418b
...
@@ -5,7 +5,6 @@ use Illuminate\Foundation\Application;
...
@@ -5,7 +5,6 @@ use Illuminate\Foundation\Application;
class
AuthTest
extends
TestCase
class
AuthTest
extends
TestCase
{
{
public
function
tearDown
()
public
function
tearDown
()
{
{
User
::
truncate
();
User
::
truncate
();
...
...
tests/ConnectionTest.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
class
ConnectionTest
extends
TestCase
class
ConnectionTest
extends
TestCase
{
{
public
function
testConnection
()
public
function
testConnection
()
{
{
$connection
=
DB
::
connection
(
'mongodb'
);
$connection
=
DB
::
connection
(
'mongodb'
);
...
...
tests/EmbeddedRelationsTest.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
class
EmbeddedRelationsTest
extends
TestCase
class
EmbeddedRelationsTest
extends
TestCase
{
{
public
function
tearDown
()
public
function
tearDown
()
{
{
Mockery
::
close
();
Mockery
::
close
();
...
...
tests/ModelTest.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
class
ModelTest
extends
TestCase
class
ModelTest
extends
TestCase
{
{
public
function
tearDown
()
public
function
tearDown
()
{
{
User
::
truncate
();
User
::
truncate
();
...
...
tests/MysqlRelationsTest.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
class
MysqlRelationsTest
extends
TestCase
class
MysqlRelationsTest
extends
TestCase
{
{
public
function
setUp
()
public
function
setUp
()
{
{
parent
::
setUp
();
parent
::
setUp
();
...
...
tests/QueryBuilderTest.php
View file @
20b0418b
...
@@ -5,7 +5,6 @@ use MongoDB\BSON\Regex;
...
@@ -5,7 +5,6 @@ use MongoDB\BSON\Regex;
class
QueryBuilderTest
extends
TestCase
class
QueryBuilderTest
extends
TestCase
{
{
public
function
tearDown
()
public
function
tearDown
()
{
{
DB
::
collection
(
'users'
)
->
truncate
();
DB
::
collection
(
'users'
)
->
truncate
();
...
...
tests/QueryTest.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
class
QueryTest
extends
TestCase
class
QueryTest
extends
TestCase
{
{
protected
static
$started
=
false
;
protected
static
$started
=
false
;
public
function
setUp
()
public
function
setUp
()
...
@@ -216,25 +215,25 @@ class QueryTest extends TestCase
...
@@ -216,25 +215,25 @@ class QueryTest extends TestCase
public
function
testSubquery
()
public
function
testSubquery
()
{
{
$users
=
User
::
where
(
'title'
,
'admin'
)
->
orWhere
(
function
(
$query
)
{
$users
=
User
::
where
(
'title'
,
'admin'
)
->
orWhere
(
function
(
$query
)
{
$query
->
where
(
'name'
,
'Tommy Toe'
)
$query
->
where
(
'name'
,
'Tommy Toe'
)
->
orWhere
(
'name'
,
'Error'
);
->
orWhere
(
'name'
,
'Error'
);
})
})
->
get
();
->
get
();
$this
->
assertEquals
(
5
,
count
(
$users
));
$this
->
assertEquals
(
5
,
count
(
$users
));
$users
=
User
::
where
(
'title'
,
'user'
)
->
where
(
function
(
$query
)
{
$users
=
User
::
where
(
'title'
,
'user'
)
->
where
(
function
(
$query
)
{
$query
->
where
(
'age'
,
35
)
$query
->
where
(
'age'
,
35
)
->
orWhere
(
'name'
,
'like'
,
'%harry%'
);
->
orWhere
(
'name'
,
'like'
,
'%harry%'
);
})
})
->
get
();
->
get
();
$this
->
assertEquals
(
2
,
count
(
$users
));
$this
->
assertEquals
(
2
,
count
(
$users
));
$users
=
User
::
where
(
'age'
,
35
)
->
orWhere
(
function
(
$query
)
{
$users
=
User
::
where
(
'age'
,
35
)
->
orWhere
(
function
(
$query
)
{
$query
->
where
(
'title'
,
'admin'
)
$query
->
where
(
'title'
,
'admin'
)
->
orWhere
(
'name'
,
'Error'
);
->
orWhere
(
'name'
,
'Error'
);
})
})
->
get
();
->
get
();
$this
->
assertEquals
(
5
,
count
(
$users
));
$this
->
assertEquals
(
5
,
count
(
$users
));
...
...
tests/RelationsTest.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
class
RelationsTest
extends
TestCase
class
RelationsTest
extends
TestCase
{
{
public
function
tearDown
()
public
function
tearDown
()
{
{
Mockery
::
close
();
Mockery
::
close
();
...
@@ -413,13 +412,11 @@ class RelationsTest extends TestCase
...
@@ -413,13 +412,11 @@ class RelationsTest extends TestCase
$authors
=
User
::
whereHas
(
'books'
,
function
(
$query
)
{
$authors
=
User
::
whereHas
(
'books'
,
function
(
$query
)
{
$query
->
where
(
'rating'
,
5
);
$query
->
where
(
'rating'
,
5
);
})
->
get
();
})
->
get
();
$this
->
assertCount
(
1
,
$authors
);
$this
->
assertCount
(
1
,
$authors
);
$authors
=
User
::
whereHas
(
'books'
,
function
(
$query
)
{
$authors
=
User
::
whereHas
(
'books'
,
function
(
$query
)
{
$query
->
where
(
'rating'
,
'<'
,
5
);
$query
->
where
(
'rating'
,
'<'
,
5
);
})
->
get
();
})
->
get
();
$this
->
assertCount
(
1
,
$authors
);
$this
->
assertCount
(
1
,
$authors
);
}
}
...
...
tests/SchemaTest.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
class
SchemaTest
extends
TestCase
class
SchemaTest
extends
TestCase
{
{
public
function
tearDown
()
public
function
tearDown
()
{
{
Schema
::
drop
(
'newcollection'
);
Schema
::
drop
(
'newcollection'
);
...
...
tests/SeederTest.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
class
SeederTest
extends
TestCase
class
SeederTest
extends
TestCase
{
{
public
function
tearDown
()
public
function
tearDown
()
{
{
User
::
truncate
();
User
::
truncate
();
...
...
tests/ValidationTest.php
View file @
20b0418b
...
@@ -2,7 +2,6 @@
...
@@ -2,7 +2,6 @@
class
ValidationTest
extends
TestCase
class
ValidationTest
extends
TestCase
{
{
public
function
tearDown
()
public
function
tearDown
()
{
{
User
::
truncate
();
User
::
truncate
();
...
...
tests/seeds/UserTableSeeder.php
View file @
20b0418b
...
@@ -5,7 +5,6 @@ use Illuminate\Support\Facades\DB;
...
@@ -5,7 +5,6 @@ use Illuminate\Support\Facades\DB;
class
UserTableSeeder
extends
Seeder
class
UserTableSeeder
extends
Seeder
{
{
public
function
run
()
public
function
run
()
{
{
DB
::
collection
(
'users'
)
->
delete
();
DB
::
collection
(
'users'
)
->
delete
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment