Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
public
/
sequelize
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
不要怂,就是干,撸起袖子干!
Commit 9ce683e2
authored
Sep 13, 2013
by
wenyuxiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add test case for `does not modify the passed arguments - count`
1 parent
a578ff2e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletions
test/dao-factory.test.js
test/dao-factory.test.js
View file @
9ce683e
...
@@ -1486,7 +1486,7 @@ describe(Support.getTestDialectTeaser("DAOFactory"), function () {
...
@@ -1486,7 +1486,7 @@ describe(Support.getTestDialectTeaser("DAOFactory"), function () {
})
})
})
})
it
(
'does not modify the passed arguments'
,
function
(
done
)
{
it
(
'does not modify the passed arguments
- find
'
,
function
(
done
)
{
var
options
=
{
where
:
[
'specialkey = ?'
,
'awesome'
]}
var
options
=
{
where
:
[
'specialkey = ?'
,
'awesome'
]}
this
.
UserPrimary
.
find
(
options
).
success
(
function
(
user
)
{
this
.
UserPrimary
.
find
(
options
).
success
(
function
(
user
)
{
...
@@ -1494,6 +1494,14 @@ describe(Support.getTestDialectTeaser("DAOFactory"), function () {
...
@@ -1494,6 +1494,14 @@ describe(Support.getTestDialectTeaser("DAOFactory"), function () {
done
()
done
()
})
})
})
})
it
(
'does not modify the passed arguments - count'
,
function
(
done
)
{
var
options
=
{
where
:
[
'specialkey = ?'
,
'awesome'
]}
this
.
UserPrimary
.
count
(
options
).
success
(
function
(
count
)
{
expect
(
options
).
to
.
deep
.
equal
({
where
:
[
'specialkey = ?'
,
'awesome'
]})
done
()
})
})
it
(
'doesn\'t throw an error when entering in a non integer value for a specified primary field'
,
function
(
done
)
{
it
(
'doesn\'t throw an error when entering in a non integer value for a specified primary field'
,
function
(
done
)
{
this
.
UserPrimary
.
find
(
'a string'
).
success
(
function
(
user
)
{
this
.
UserPrimary
.
find
(
'a string'
).
success
(
function
(
user
)
{
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment