You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
hey All
mock.ExpectExec("SELECT * FROM permission WHERE roleid = $1").WithArgs(2) this is my mock queey i just compare that one with the original query which one is db.Get(&programinfo, "SELECT * FROM permission WHERE roleid = $1", roleid)
but i found that error
call to Query 'SELECT * FROM permission WHERE roleid = $1' with args [{Name: Ordinal:1 Value:2}], was not expected, next expectation is: ExpectedExec => expecting Exec or ExecContext which:
matches sql: 'SELECT * FROM permission WHERE roleid = $1'
is with arguments:
there is a remaining expectation which was not matched: ExpectedExec => expecting Exec or ExecContext which:
- matches sql: 'SELECT * FROM permission WHERE roleid = $1'
- is with arguments:
0 - 2
Can SomeOne please help me how i fixed this issue
Thanks
The text was updated successfully, but these errors were encountered:
hey All
mock.ExpectExec("SELECT * FROM permission WHERE roleid = $1").WithArgs(2) this is my mock queey i just compare that one with the original query which one is db.Get(&programinfo, "SELECT * FROM permission WHERE roleid = $1", roleid)
but i found that error
call to Query 'SELECT * FROM permission WHERE roleid = $1' with args [{Name: Ordinal:1 Value:2}], was not expected, next expectation is: ExpectedExec => expecting Exec or ExecContext which:
there is a remaining expectation which was not matched: ExpectedExec => expecting Exec or ExecContext which:
- matches sql: 'SELECT * FROM permission WHERE roleid = $1'
- is with arguments:
0 - 2
Can SomeOne please help me how i fixed this issue
Thanks
The text was updated successfully, but these errors were encountered: