Skip to content

Commit a0cf8bf

Browse files
committed
Fixed TestDecodeMessageNotSensitiveLogging
1 parent 0d2fc96 commit a0cf8bf

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Test/UnitTests/TestDataLayer/TestMyLoggerProviderActionOut.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,10 +164,12 @@ public void TestDecodeMessageNotSensitiveLogging()
164164

165165
//VERIFY
166166
var sqlCommand = decoded.Split('\n').Skip(1).Select(x => x.Trim()).ToArray();
167+
sqlCommand.Length.ShouldEqual(4);
167168
sqlCommand[0].ShouldEqual(
168169
"SELECT \"b\".\"BookId\", \"b\".\"Description\", \"b\".\"ImageUrl\", \"b\".\"Price\", \"b\".\"PublishedOn\", \"b\".\"Publisher\", \"b\".\"SoftDeleted\", \"b\".\"Title\"");
169170
sqlCommand[1].ShouldEqual("FROM \"Books\" AS \"b\"");
170-
sqlCommand[2].ShouldContain("WHERE NOT (\"\"b\"\".\"\"SoftDeleted\"\") AND \"\"b\"\".\"\"BookId\"\" = @id\"\r\n");
171+
sqlCommand[2].ShouldContain("WHERE NOT (\"b\".\"SoftDeleted\") AND \"b\".\"BookId\" = @id");
172+
sqlCommand[3].ShouldContain("LIMIT 2");
171173
}
172174
}
173175
}

0 commit comments

Comments
 (0)