Hi I am pretty new for TSQLT Unit tests I am getting error while trying to create a fake table, any help is appreciated.
I have my dev project in one database and TSQLT in another database
EXEC tSQLt.FakeTable @TableName = '[AnotherDB].[dbo].[Table1]'
The error is
[Test].[test that checks the size] failed: (Error) FakeTable could not resolve the object name, '[AnotherDB].[dbo].[Table1]'. (When calling tSQLt.FakeTable, avoid the use of the @SchemaName parameter, as it is deprecated.)[16,10]{Private_ValidateFakeTableParameters,12}
Although this table does exist in another database, select * will work on this table. Also I have seen couple of posts but not clear what to do.
Advertisement
Answer
FakeTable cannot (yet) resolve objects in another database.