Closed yogyogi closed 7 months ago
Have you put a break point and se what has happened? So we can see the real reason of the internal error
I have provided error message itself.
@yogyogi
As shown and commented in the code, the database is InMemory and the query will not execute
@yogyogi
If you want the test to pass you can use the LINQ query instead of SQL raw query
@ParsaMehdipour I think all test should pass beforehand. People should not have to do manual settings on the fresh download copy. I have also seen the previous version of this repo where all test were passing so this is probably a bug that needs to be corrected.
The issue appears to be two things. The column name needs to be aliased to PhoneNumber
(to work with ContributorDTO
) and NULL values need to be set to an empty string since PhoneNumber
on the ContributorDTO
is string
and not string?
. Updating the SQL to the following allows the test to pass (at least for sqlite which is the current default I believe):
SELECT Id, Name, COALESCE(PhoneNumber_Number, '') AS PhoneNumber FROM Contributors
I'll submit a PR for the change if no one has any objections?
Test function
ReturnsTwoContributors()
fails.Steps to Reproduce:
ReturnsTwoContributors()
is failing.The error screenshot:
Error Message: