System.Data.SQLite
Check-in [aef2b03cf4]
Not logged in

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

Overview
Comment:More work on connection flags handling in the test suite infrastructure.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: aef2b03cf4cad1a1e769664d3a2b3c5f3f7de92d
User & Date: mistachkin 2014-01-04 01:36:57
Context
2014-01-04
02:32
Make sure that all non-legacy tests honor the global connection flags. check-in: 14dd55b26b user: mistachkin tags: trunk
01:36
More work on connection flags handling in the test suite infrastructure. check-in: aef2b03cf4 user: mistachkin tags: trunk
01:23
Test suite infrastructure changes to produce cleaner output when globally testing connection flags. check-in: 26ca8062a7 user: mistachkin tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to Tests/common.eagle.

1373
1374
1375
1376
1377
1378
1379





































1380
1381
1382
1383
1384
1385
1386
....
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502

1503
1504
1505
1506
1507
1508
1509
      try {
        return [uplevel 1 [list \
            sql execute -execute $execute -format $format $db $sql]]
      } finally {
        cleanupDb $fileName db false false false
      }
    }





































 
    proc setupDb {
            fileName {mode ""} {dateTimeFormat ""} {dateTimeKind ""} {flags ""}
            {extra ""} {qualify true} {delete true} {uri false}
            {temporary true} {varName db} {quiet false} } {
      #
      # NOTE: First, see if our caller has requested an in-memory database.
................................................................................
      #       of the connection string now.
      #
      if {[string length $dateTimeKind] > 0} then {
        append connection {;DateTimeKind=${dateTimeKind}}
      }

      #
      # NOTE: If there are any global (per test run) connection flags currently
      #       set, use them now (i.e. by combining them with the ones for this
      #       connection).
      #
      if {[info exists ::connection_flags] && \
          [string length $::connection_flags] > 0} then {
        #
        # NOTE: Show (and log) that the local and global connection flags.
        #
        if {!$quiet} then {
          tputs $::test_channel [appendArgs \
              "---- local connection flags are: " $flags \n]

          tputs $::test_channel [appendArgs \
              "---- global connection flags detected: " $::connection_flags \n]
        }

        #
        # NOTE: Combine and/or replace the connection flags and then show the
        #       new value.
        #
        set flags [combineFlags $flags $::connection_flags]

        #
        # NOTE: Show (and log) the new effective connection flags.
        #
        if {!$quiet} then {
          tputs $::test_channel [appendArgs \
              "---- combined connection flags are: " $flags \n]
        }
      }


      #
      # NOTE: If our caller specified some SQLiteConnectionFlags, add the
      #       necessary portion of the connection string now.
      #
      if {[string length $flags] > 0} then {
        append connection {;Flags=${flags}}







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







 







|
<
<

<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
>







1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
....
1502
1503
1504
1505
1506
1507
1508
1509


1510



























1511
1512
1513
1514
1515
1516
1517
1518
      try {
        return [uplevel 1 [list \
            sql execute -execute $execute -format $format $db $sql]]
      } finally {
        cleanupDb $fileName db false false false
      }
    }
 
    proc getConnectionFlags { flags {quiet false} } {
      #
      # NOTE: If there are any global (per test run) connection flags currently
      #       set, use them now (i.e. by combining them with the ones for this
      #       connection).
      #
      if {[info exists ::connection_flags] && \
          [string length $::connection_flags] > 0} then {
        #
        # NOTE: Show (and log) that the local and global connection flags.
        #
        if {!$quiet} then {
          tputs $::test_channel [appendArgs \
              "---- local connection flags are: " $flags \n]

          tputs $::test_channel [appendArgs \
              "---- global connection flags detected: " $::connection_flags \n]
        }

        #
        # NOTE: Combine and/or replace the connection flags and then show the
        #       new value.
        #
        set flags [combineFlags $flags $::connection_flags]

        #
        # NOTE: Show (and log) the new effective connection flags.
        #
        if {!$quiet} then {
          tputs $::test_channel [appendArgs \
              "---- combined connection flags are: " $flags \n]
        }
      }

      return $flags
    }
 
    proc setupDb {
            fileName {mode ""} {dateTimeFormat ""} {dateTimeKind ""} {flags ""}
            {extra ""} {qualify true} {delete true} {uri false}
            {temporary true} {varName db} {quiet false} } {
      #
      # NOTE: First, see if our caller has requested an in-memory database.
................................................................................
      #       of the connection string now.
      #
      if {[string length $dateTimeKind] > 0} then {
        append connection {;DateTimeKind=${dateTimeKind}}
      }

      #
      # NOTE: Figure out what the final flags for this connection need to be.


      #



























      set flags [getConnectionFlags $flags $quiet]

      #
      # NOTE: If our caller specified some SQLiteConnectionFlags, add the
      #       necessary portion of the connection string now.
      #
      if {[string length $flags] > 0} then {
        append connection {;Flags=${flags}}