You cannot post messages because only members can post, and you are not currently a member.
Description:
This group was created to provide support for the tSQLt unit testing framework.
More info: tSQLt.org
|
|
|
tSQLt V1.0.4496.29340 Released
|
| |
Hi all, We just released tSQLt V1.0.4496.29340. This latest release includes two bug fixes: - for ResultSetFilter, SQL Server 2008 data types are now supported - for AssertResultSetsHaveSameMetaDa ta, if the metadata for a view contains hidden columns regarding the underlying table structures, those... more »
|
|
FakeTable, Foreign Key Support and the database testing paradigm
|
| |
I blogged recently on the fact that [ApplyConstraint] doesn't
currently support cascading deletes or updates on foreign keys and I
know that this is on the backlog. This isn't necessarily a big issue
as we can run tests against the real tables and keys and depend on
tSQLt to roll back any changes.... more »
|
|
SpyProcedure with User Defined Table Type Parameters - Solved
|
| |
I came up with an easier way to inspect the contents of table parameters. In the test procedure create a table Actual with the same structure as the table type. Then when calling SpyProcedure add the CommandToExecute as "INSERT INTO Actual SELECT * FROM @TableVariable". You can then create the Expected table with the correct results and use AssertEqualsTable to verify... more »
|
|
ApplyTrigger
|
| |
Hi Dennis & Sebastian, I have added support for triggers on faked tables. I have 2 new procedures and some test code. How would you like me to publish the code. Should I just post to the group or is there another method you prefer. Thanks Dave
|
|
SpyProcedure with User Defined Table Type Parameters
|
| |
Hi Dennis & Sebastian, If I try to execute SpyProcedure on a SP that has a table type parameter then I get an error message when SpyProcedure goes to create the log table. I have changed the code so that table type parameters are ignored except for creating the replacement procedure so at least now you can run a successful... more »
|
|
Testing triggers and transaction rollbacks
|
| |
Hi Just getting into using tSQLt and love it so far. It has really helped on a couple of projects. I have some table triggers that I need to test. I know that I could get the trigger source and create in the test proc after calling FakeTable but I am trying to implement a more generic way to do this. Does anyone see any... more »
|
|
How to test multi dataset stored procedures
|
| |
Hi all, I'm trying to test a multiple dataset / table output stored procedure. Here is a simple example. create procedure sp_test begin select x, y, z from TableA select a, b, c,d from TableB select q,t from TableC end Currently I don't have a good way to test these kind of procedures using... more »
|
|
Primary and Unique Key support in ApplyContraint
|
| |
Dennis, Sebastien,
Hi guys how's it going.
First of all, I'm really pleased to see support of IDENTITY columns
being added to FakeTable in the latest release.
Is there any reason why ApplyConstraint only supports foreign keys and
check constraints?
The scenario I'm thinking of in particular is a parent table P1, which... more »
|
|
Computed Columns and FakeTable
|
| |
First off, just wanted to send my kudos to the contributors of the
tSQLt project. It was very easy to add this unit testing capability
to our project and automated build structure. I'm working on a few
strategic unit tests to replace some of our integration tests and ran
into an issue using FakeTable.... more »
|
|
Problems with Stored Procedures and Dynamic SQL
|
| |
We're trying to implement tSQLt in our existing system. One of our
current road blocks is a set of procedures for reports which have
dynamic SQL that we execute results into a series of temp tables and
then join them for the final resultset.
Greatly simplified:
create proc RPT_Ads
as... more »
|
|
|