SQLite

Check-in [8fb23d4281]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Disable one of the test cases from check-in [21ecbce1378f3cc4] when API_ARMOR is not enabled.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 8fb23d4281915b4507e4d42a300f4b5f958ad88ad408218659c7459775d7b114
User & Date: drh 2018-03-14 15:06:42.860
Context
2018-03-14
15:25
Add the SQLITE_DBSTATUS_CACHE_SPILL option to sqlite3_db_status(). (check-in: 48a06eb02b user: drh tags: trunk)
15:06
Disable one of the test cases from check-in [21ecbce1378f3cc4] when API_ARMOR is not enabled. (check-in: 8fb23d4281 user: drh tags: trunk)
08:27
Improve detection of out-of-range parameters in sqlite3_stmt_status() for SQLITE_ENABLE_API_ARMOR builds. (check-in: 21ecbce137 user: dan tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to test/dbstatus.test.
429
430
431
432
433
434
435

436

437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
  set ::stmt [sqlite3_prepare db "SELECT * FROM t1" -1 dummy]
  sqlite3_step $::stmt
  sqlite3_step $::stmt
  sqlite3_step $::stmt
  sqlite3_reset $::stmt
} {SQLITE_OK}


do_test 5.2 { sqlite3_stmt_status $::stmt -1 0 } 0

do_test 5.3 { sqlite3_stmt_status $::stmt  7 0 } 0
do_test 5.4 { 
  expr [sqlite3_stmt_status $::stmt 99 0]>0 
} 1
foreach {tn id res} {
  1 SQLITE_STMTSTATUS_MEMUSED 1
  2 SQLITE_STMTSTATUS_FULLSCAN_STEP 1
  3 SQLITE_STMTSTATUS_SORT 0
  4 SQLITE_STMTSTATUS_AUTOINDEX 0
  5 SQLITE_STMTSTATUS_VM_STEP 1
  6 SQLITE_STMTSTATUS_REPREPARE 0
  7 SQLITE_STMTSTATUS_RUN 1
} {
if {$tn==2} breakpoint
  do_test 5.5.$tn { expr [sqlite3_stmt_status $::stmt $id 0]>0 } $res
}

sqlite3_finalize $::stmt
finish_test








>
|
>
|


















<
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457

  set ::stmt [sqlite3_prepare db "SELECT * FROM t1" -1 dummy]
  sqlite3_step $::stmt
  sqlite3_step $::stmt
  sqlite3_step $::stmt
  sqlite3_reset $::stmt
} {SQLITE_OK}

ifcapable api_armor {
  do_test 5.2 { sqlite3_stmt_status $::stmt -1 0 } 0
}
do_test 5.3 { sqlite3_stmt_status $::stmt  0 0 } 0
do_test 5.4 { 
  expr [sqlite3_stmt_status $::stmt 99 0]>0 
} 1
foreach {tn id res} {
  1 SQLITE_STMTSTATUS_MEMUSED 1
  2 SQLITE_STMTSTATUS_FULLSCAN_STEP 1
  3 SQLITE_STMTSTATUS_SORT 0
  4 SQLITE_STMTSTATUS_AUTOINDEX 0
  5 SQLITE_STMTSTATUS_VM_STEP 1
  6 SQLITE_STMTSTATUS_REPREPARE 0
  7 SQLITE_STMTSTATUS_RUN 1
} {
if {$tn==2} breakpoint
  do_test 5.5.$tn { expr [sqlite3_stmt_status $::stmt $id 0]>0 } $res
}

sqlite3_finalize $::stmt
finish_test