Improve testing code coverage

This commit is contained in:
Gwendal Roué committed 2015-09-30 08:38:45 +02:00
1 parent 0830bc0657
commit 9bcebc3cb8
1 file changed
+7 -1
@@ -9,12 +9,18 @@ class BlobTests: GRDBTestCase {
XCTAssertTrue(blob == nil)
}
func testBlobCanNotStoreZeroLengthBuffer() {
func testBlobCanNotCopyZeroLengthBuffer() {
// SQLite can't store zero-length blob.
let blob = Blob(bytes: nil, length: 0)
XCTAssertTrue(blob == nil)
}
func testBlobCanNotReferebceZeroLengthBuffer() {
// SQLite can't store zero-length blob.
let blob = Blob(bytesNoCopy: nil, length: 0, freeWhenDone: false)
XCTAssertTrue(blob == nil)
}
func testMemoryBehavior() {
assertNoError {
try dbQueue.inDatabase { db in