System.Data.SQLite

Check-in [611657ba5b]
Login

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

Overview
Comment:Merge updates from trunk.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | tkt-5cee5409f8
Files: files | file ages | folders
SHA1: 611657ba5be8f8e497ca180fcf14e0f7bbe5d707
User & Date: mistachkin 2018-01-26 01:14:43.129
Context
2018-01-26
01:28
Merge updates from trunk. check-in: 82138de582 user: mistachkin tags: tkt-5cee5409f8
01:14
Merge updates from trunk. check-in: 611657ba5b user: mistachkin tags: tkt-5cee5409f8
01:13
Replace a call to String.Format with the helper method. check-in: c1719dd9f5 user: mistachkin tags: trunk
00:00
Merge updates from trunk. check-in: e36ed56d66 user: mistachkin tags: tkt-5cee5409f8
Changes
Side-by-Side Diff Ignore Whitespace Patch
Changes to System.Data.SQLite/SQLiteConnection.cs.
1437
1438
1439
1440
1441
1442
1443








1444
1445
1446
1447
1448
1449
1450
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458







+
+
+
+
+
+
+
+







    private ConnectionState _connectionState;

    /// <summary>
    /// The connection string
    /// </summary>
    private string _connectionString;

    /// <summary>
    /// This string will contain enough information to identify this connection,
    /// e.g. the database file name, original thread, etc.  It is not currently
    /// exposed via the public interface as it is intended for use only when
    /// debugging this library.
    /// </summary>
    private string _debugString;

    /// <summary>
    /// Nesting level of the transactions open on the connection
    /// </summary>
    internal int _transactionLevel;

    /// <summary>
    /// Transaction counter for the connection.  Currently, this is only used
2646
2647
2648
2649
2650
2651
2652
2653

2654
2655
2656
2657
2658
2659
2660
2654
2655
2656
2657
2658
2659
2660

2661
2662
2663
2664
2665
2666
2667
2668







-
+







        if ((_flags & SQLiteConnectionFlags.TraceWarning) == SQLiteConnectionFlags.TraceWarning)
        {
            if (_noDispose)
            {
                System.Diagnostics.Trace.WriteLine(HelperMethods.StringFormat(
                    CultureInfo.CurrentCulture,
                    "WARNING: Disposing of connection \"{0}\" with the no-dispose flag set.",
                    _connectionString));
                    _debugString));
            }
        }
#endif

        _disposing = true;

        try
4190
4191
4192
4193
4194
4195
4196





4197
4198
4199
4200
4201
4202
4203
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216







+
+
+
+
+








          StateChangeEventArgs eventArgs = null;
          OnStateChange(ConnectionState.Open, ref eventArgs);

          OnChanged(this, new ConnectionEventArgs(
              SQLiteConnectionEventType.Opened, eventArgs, null, null, null,
              null, _connectionString, new object[] { opts }));

          _debugString = HelperMethods.StringFormat(
              CultureInfo.InvariantCulture,
              "threadId = {0}, connectionString = {1}",
              HelperMethods.GetThreadId(), _connectionString);
        }
        catch
        {
          _connectionState = oldstate;
          throw;
        }
      }
Changes to System.Data.SQLite/UnsafeNativeMethods.cs.
537
538
539
540
541
542
543

















544
545
546
547
548
549
550
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567







+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+







              //
              lock (staticSyncRoot)
              {
                  debuggerBreak = false;
              }
          }
      }

      /////////////////////////////////////////////////////////////////////////

      /// <summary>
      /// Determines the ID of the current thread.  Only used for debugging.
      /// </summary>
      /// <returns>
      /// The ID of the current thread -OR- zero if it cannot be determined.
      /// </returns>
      internal static int GetThreadId()
      {
#if !PLATFORM_COMPACTFRAMEWORK
          return AppDomain.GetCurrentThreadId();
#else
          return 0;
#endif
      }

      /////////////////////////////////////////////////////////////////////////

      /// <summary>
      /// Determines if preparing a query should be logged.
      /// </summary>
      /// <param name="flags">
Changes to Tests/backup.eagle.
143
144
145
146
147
148
149
150

151
152
153
154
155
156
157
143
144
145
146
147
148
149

150
151
152
153
154
155
156
157







-
+








          public static string BackupAndGetData(
            Interpreter interpreter,
            SQLiteConnection source
            )
          {
            using (SQLiteConnection destination = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty]"))
                "Data Source=${dataSource};[getTestProperties]"))
            {
              destination.Open();

              int pages = ${pages};

              source.BackupDatabase(destination, "main", "main", pages,
                ${callback}, 0);
Changes to Tests/basic.eagle.
177
178
179
180
181
182
183
184

185
186
187
188
189
190
191
177
178
179
180
181
182
183

184
185
186
187
188
189
190
191







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static DataTable GetReservedWords()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            return connection.GetSchema("ReservedWords");
          }
        }

239
240
241
242
243
244
245
246

247
248
249
250
251
252
253
239
240
241
242
243
244
245

246
247
248
249
250
251
252
253







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static DataRowCollection GetForeignKeys()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            return connection.GetSchema("ForeignKeys").Rows;
          }
        }

320
321
322
323
324
325
326
327

328
329
330
331
332
333
334
320
321
322
323
324
325
326

327
328
329
330
331
332
333
334







-
+







      {
        public static bool TestSetAvRetry(
          ref int count,
          ref int interval
          )
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            //
            // NOTE: Set the requested retry parameter values.
            //
            if (connection.SetAvRetry(ref count, ref interval) != 0)
424
425
426
427
428
429
430
431

432
433
434
435
436
437
438
424
425
426
427
428
429
430

431
432
433
434
435
436
437
438







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand("${sql}",
                connection))
            {
              command.ExecuteNonQuery();
480
481
482
483
484
485
486
487

488
489
490
491
492
493
494
480
481
482
483
484
485
486

487
488
489
490
491
492
493
494







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand("${sql}",
                connection))
            {
              using (SQLiteDataReader dataReader = command.ExecuteReader())
540
541
542
543
544
545
546
547

548
549
550
551
552
553
554
540
541
542
543
544
545
546

547
548
549
550
551
552
553
554







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand("${sql}",
                connection))
            {
              using (SQLiteDataReader dataReader = command.ExecuteReader(
1174
1175
1176
1177
1178
1179
1180
1181

1182
1183
1184
1185
1186
1187
1188
1174
1175
1176
1177
1178
1179
1180

1181
1182
1183
1184
1185
1186
1187
1188







-
+







        ///////////////////////////////////////////////////////////////////////

        public static void Main()
        {
          SQLiteFunction.RegisterFunction(typeof(Test${id}));

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteTransaction transaction =
                connection.BeginTransaction())
            {
              try
1256
1257
1258
1259
1260
1261
1262
1263

1264
1265
1266
1267
1268
1269
1270
1256
1257
1258
1259
1260
1261
1262

1263
1264
1265
1266
1267
1268
1269
1270







-
+







        ///////////////////////////////////////////////////////////////////////

        public static int Main()
        {
          SQLiteFunction.RegisterFunction(typeof(Test${id}));

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteTransaction transaction =
                connection.BeginTransaction())
            {
              SQLiteCommand command = connection.CreateCommand();
2547
2548
2549
2550
2551
2552
2553
2554

2555
2556
2557
2558
2559
2560
2561
2547
2548
2549
2550
2551
2552
2553

2554
2555
2556
2557
2558
2559
2560
2561







-
+







        }

        ///////////////////////////////////////////////////////////////////////

        public static object DoTest(bool bindFunction)
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            if (bindFunction)
            {
              connection.BindFunction(new SQLiteFunctionAttribute(
                "MyRandom", 0, FunctionType.Scalar), new Test${id}());
3309
3310
3311
3312
3313
3314
3315
3316

3317
3318
3319
3320
3321
3322
3323
3309
3310
3311
3312
3313
3314
3315

3316
3317
3318
3319
3320
3321
3322
3323







-
+







            functionAttribute = new SQLiteFunctionAttribute(
                "MyRandom", 0, FunctionType.Scalar);
          }

          if (connection == null)
          {
            connection = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty]");
                "Data Source=${dataSource};[getTestProperties]");

            connection.Open();
          }
        }

        ///////////////////////////////////////////////////////////////////////

3466
3467
3468
3469
3470
3471
3472
3473

3474
3475
3476
3477
3478
3479
3480
3466
3467
3468
3469
3470
3471
3472

3473
3474
3475
3476
3477
3478
3479
3480







-
+







                "MyRandom", 0, FunctionType.Scalar);
          }

          if (connection == null)
          {
            connection = new SQLiteConnection(
                "Data Source=${dataSource};Pooling=True;" +
                "[getFlagsProperty UnbindFunctionsOnClose]");
                "[getTestProperties UnbindFunctionsOnClose]");

            connection.Open();
          }
        }

        ///////////////////////////////////////////////////////////////////////

4289
4290
4291
4292
4293
4294
4295
4296

4297
4298
4299
4300
4301
4302
4303
4289
4290
4291
4292
4293
4294
4295

4296
4297
4298
4299
4300
4301
4302
4303







-
+







            functionAttribute = new SQLiteFunctionAttribute(
                "regexp", 2, FunctionType.Scalar);
          }

          if (connection == null)
          {
            connection = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty]");
                "Data Source=${dataSource};[getTestProperties]");

            connection.Open();
          }
        }

        ///////////////////////////////////////////////////////////////////////

Changes to Tests/progress.eagle.
57
58
59
60
61
62
63
64

65
66
67
68
69
70
71
57
58
59
60
61
62
63

64
65
66
67
68
69
70
71







-
+







        }

        ///////////////////////////////////////////////////////////////////////

        public static int Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Progress += MyProgressHandler;
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand("${sql}",
                connection))
            {
132
133
134
135
136
137
138
139

140
141
142
143
144
145
146
132
133
134
135
136
137
138

139
140
141
142
143
144
145
146







-
+







        }

        ///////////////////////////////////////////////////////////////////////

        public static int Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};ProgressOps=1;[getFlagsProperty]"))
              "Data Source=${dataSource};ProgressOps=1;[getTestProperties]"))
          {
            connection.Progress += MyProgressHandler;
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand("${sql}",
                connection))
            {
208
209
210
211
212
213
214
215

216
217
218
219
220
221
222
208
209
210
211
212
213
214

215
216
217
218
219
220
221
222







-
+







        }

        ///////////////////////////////////////////////////////////////////////

        public static int Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};ProgressOps=1;[getFlagsProperty]"))
              "Data Source=${dataSource};ProgressOps=1;[getTestProperties]"))
          {
            connection.Progress += MyProgressHandler;
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand("${sql}",
                connection))
            {
285
286
287
288
289
290
291
292

293
294
295
296
297
298
299
285
286
287
288
289
290
291

292
293
294
295
296
297
298
299







-
+







        }

        ///////////////////////////////////////////////////////////////////////

        public static int Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};ProgressOps=1;[getFlagsProperty]"))
              "Data Source=${dataSource};ProgressOps=1;[getTestProperties]"))
          {
            connection.Progress += MyProgressHandler;
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand("${sql}",
                connection))
            {
Changes to Tests/stress.eagle.
1087
1088
1089
1090
1091
1092
1093
1094

1095
1096
1097
1098
1099

1100
1101
1102
1103
1104
1105
1106
1087
1088
1089
1090
1091
1092
1093

1094
1095
1096
1097
1098

1099
1100
1101
1102
1103
1104
1105
1106







-
+




-
+







            namespace _Dynamic${id}
            {
              public static class Test${id}
              {
                public static void BackupAndGetData()
                {
                  using (SQLiteConnection source = new SQLiteConnection(
                      "FullUri=${dstFileName};[getFlagsProperty {} true]"))
                      "FullUri=${dstFileName};[getTestProperties {} true]"))
                  {
                    source.Open();

                    using (SQLiteConnection destination = new SQLiteConnection(
                        "FullUri=${srcFileName};[getFlagsProperty {} true]"))
                        "FullUri=${srcFileName};[getTestProperties {} true]"))
                    {
                      destination.Open();

                      source.BackupDatabase(
                          destination, "main", "main", -1, null, 0);
                    }
                  }
1170
1171
1172
1173
1174
1175
1176
1177

1178
1179
1180
1181
1182

1183
1184
1185
1186
1187
1188
1189
1170
1171
1172
1173
1174
1175
1176

1177
1178
1179
1180
1181

1182
1183
1184
1185
1186
1187
1188
1189







-
+




-
+







            namespace _Dynamic${id}
            {
              public static class Test${id}
              {
                public static void BackupAndGetData()
                {
                  using (SQLiteConnection source = new SQLiteConnection(
                      "FullUri=${srcFileName};[getFlagsProperty {} true]"))
                      "FullUri=${srcFileName};[getTestProperties {} true]"))
                  {
                    source.Open();

                    using (SQLiteConnection destination = new SQLiteConnection(
                        "FullUri=${dstFileName};[getFlagsProperty {} true]"))
                        "FullUri=${dstFileName};[getTestProperties {} true]"))
                    {
                      destination.Open();

                      source.BackupDatabase(
                          destination, "main", "main", -1, null, 0);
                    }
                  }
Changes to Tests/thread.eagle.
203
204
205
206
207
208
209
210

211
212
213
214
215
216
217
203
204
205
206
207
208
209

210
211
212
213
214
215
216
217







-
+








                //
                // NOTE: Create a new connection object.  We purposely avoid
                //       putting this inside a "using" block to help test our
                //       cleanup via the garbage collector.
                //
                SQLiteConnection connection = new SQLiteConnection(
                    "Data Source=${dataSource};[getFlagsProperty]");
                    "Data Source=${dataSource};[getTestProperties]");

                //
                // NOTE: Open the connection.  After this point, native memory
                //       and resources have been allocated by this thread.
                //
                connection.Open();

Changes to Tests/tkt-0e48e80333.eagle.
190
191
192
193
194
195
196
197

198
199
200
201
202
203
204
190
191
192
193
194
195
196

197
198
199
200
201
202
203
204







-
+








          /////////////////////////////////////////////////////////////////////

          public static SQLiteConnection MakeConnection()
          {
            SQLiteConnection connection = new SQLiteConnection(
                "Data Source=${dataSource};Journal Mode=Wal;Pooling=true;" +
                "[getFlagsProperty AllowNestedTransactions]");
                "[getTestProperties AllowNestedTransactions]");

            connection.Open();
            connection.Trace += handler;

            return connection;
          }

Changes to Tests/tkt-1f7bfff467.eagle.
167
168
169
170
171
172
173
174

175
176
177
178
179
180
181
167
168
169
170
171
172
173

174
175
176
177
178
179
180
181







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty ${flags}]"))
              "Data Source=${dataSource};[getTestProperties ${flags}]"))
          {
            connection.Open();

            using (SQLiteTransaction transaction1 =
                connection.BeginTransaction())
            {
              using (SQLiteCommand command1 = new SQLiteCommand(
250
251
252
253
254
255
256
257

258
259
260
261
262
263
264
250
251
252
253
254
255
256

257
258
259
260
261
262
263
264







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty ${flags}]"))
              "Data Source=${dataSource};[getTestProperties ${flags}]"))
          {
            connection.Open();

            using (SQLiteTransaction transaction1 =
                connection.BeginTransaction())
            {
              using (SQLiteCommand command1 = new SQLiteCommand(
337
338
339
340
341
342
343
344

345
346
347
348
349
350
351
337
338
339
340
341
342
343

344
345
346
347
348
349
350
351







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty ${flags}]"))
              "Data Source=${dataSource};[getTestProperties ${flags}]"))
          {
            connection.Open();

            using (SQLiteTransaction transaction1 =
                connection.BeginTransaction())
            {
              using (SQLiteCommand command1 = new SQLiteCommand(
437
438
439
440
441
442
443
444

445
446
447
448
449
450
451
437
438
439
440
441
442
443

444
445
446
447
448
449
450
451







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty ${flags}]"))
              "Data Source=${dataSource};[getTestProperties ${flags}]"))
          {
            connection.Open();

            using (SQLiteTransaction transaction1 =
                connection.BeginTransaction())
            {
              using (SQLiteCommand command1 = new SQLiteCommand(
Changes to Tests/tkt-343d392b51.eagle.
125
126
127
128
129
130
131
132

133
134
135
136
137
138
139
125
126
127
128
129
130
131

132
133
134
135
136
137
138
139







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = connection.CreateCommand())
            {
              command.CommandText = "${sql(1)}";
              command.ExecuteNonQuery();
232
233
234
235
236
237
238
239

240
241
242
243
244
245
246
232
233
234
235
236
237
238

239
240
241
242
243
244
245
246







-
+







    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};DateTimeFormat=JulianDay;" +
              "[getFlagsProperty]"))
              "[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = connection.CreateCommand())
            {
              command.CommandText = "${sql(1)}";
              command.ExecuteNonQuery();
377
378
379
380
381
382
383
384

385
386
387
388
389
390
391
377
378
379
380
381
382
383

384
385
386
387
388
389
390
391







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = connection.CreateCommand())
            {
              command.CommandText = "${sql(1)}";
              command.ExecuteNonQuery();
Changes to Tests/tkt-3aa50d8413.eagle.
45
46
47
48
49
50
51
52

53
54
55
56
57
58
59
45
46
47
48
49
50
51

52
53
54
55
56
57
58
59







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteDataAdapter dataAdapter = new SQLiteDataAdapter(
                "${sql}", connection))
            {
              using (DataSet dataSet = new DataSet())
Changes to Tests/tkt-47c6fa04d3.eagle.
76
77
78
79
80
81
82
83

84
85
86
87
88
89
90
76
77
78
79
80
81
82

83
84
85
86
87
88
89
90







-
+







      public static class Test${id}
      {
        public static DataTable GetDataTable()
        {
          DataTable dataTable;

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand(@"${sql}",
                connection))
            {
              using (SQLiteDataReader dataReader = command.ExecuteReader())
Changes to Tests/tkt-48a6b8e4ca.eagle.
43
44
45
46
47
48
49
50

51
52
53
54
55
56
57
43
44
45
46
47
48
49

50
51
52
53
54
55
56
57







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand("${sql}",
                connection))
            {
              using (SQLiteDataAdapter dataAdapter = new SQLiteDataAdapter(
Changes to Tests/tkt-4a791e70ab.eagle.
36
37
38
39
40
41
42
43

44
45
46
47
48
49
50
36
37
38
39
40
41
42

43
44
45
46
47
48
49
50







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = connection.CreateCommand())
            {
              command.CommandText = "SELECT x FROM t1 ORDER BY x;";

Changes to Tests/tkt-56b42d99c1.eagle.
42
43
44
45
46
47
48
49

50
51
52
53
54

55
56
57
58
59
60
61
42
43
44
45
46
47
48

49
50
51
52
53

54
55
56
57
58
59
60
61







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadCommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty]"))
                "Data Source=${dataSource};[getTestProperties]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};[getFlagsProperty]"))
                  "Data Source=${dataSource};[getTestProperties]"))
              {
                connection2.Open();

                BindingFlags bindingFlags = BindingFlags.Instance |
                  BindingFlags.NonPublic | BindingFlags.GetField;

                FieldInfo fieldInfo1 = connection1.GetType().GetField(
135
136
137
138
139
140
141
142

143
144
145
146
147

148
149
150
151
152
153
154
135
136
137
138
139
140
141

142
143
144
145
146

147
148
149
150
151
152
153
154







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadCommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty]"))
                "Data Source=${dataSource};[getTestProperties]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};[getFlagsProperty]"))
                  "Data Source=${dataSource};[getTestProperties]"))
              {
                connection2.Open();

                using (SQLiteCommand command1 = connection1.CreateCommand())
                {
                  command1.CommandText = "${sql(1)}";
                  command1.ExecuteNonQuery();
212
213
214
215
216
217
218
219

220
221
222
223
224

225
226
227
228
229
230
231
212
213
214
215
216
217
218

219
220
221
222
223

224
225
226
227
228
229
230
231







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadCommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};Enlist=False;[getFlagsProperty]"))
                "Data Source=${dataSource};Enlist=False;[getTestProperties]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};Enlist=False;[getFlagsProperty]"))
                  "Data Source=${dataSource};Enlist=False;[getTestProperties]"))
              {
                connection2.Open();

                using (SQLiteCommand command1 = connection1.CreateCommand())
                {
                  command1.CommandText = "${sql(1)}";
                  command1.ExecuteNonQuery();
289
290
291
292
293
294
295
296

297
298
299
300
301

302
303
304
305
306
307
308
289
290
291
292
293
294
295

296
297
298
299
300

301
302
303
304
305
306
307
308







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadCommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty]"))
                "Data Source=${dataSource};[getTestProperties]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};Enlist=False;[getFlagsProperty]"))
                  "Data Source=${dataSource};Enlist=False;[getTestProperties]"))
              {
                connection2.Open();

                using (SQLiteCommand command1 = connection1.CreateCommand())
                {
                  command1.CommandText = "${sql(1)}";
                  command1.ExecuteNonQuery();
366
367
368
369
370
371
372
373

374
375
376
377
378

379
380
381
382
383
384
385
366
367
368
369
370
371
372

373
374
375
376
377

378
379
380
381
382
383
384
385







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadCommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};Enlist=False;[getFlagsProperty]"))
                "Data Source=${dataSource};Enlist=False;[getTestProperties]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};[getFlagsProperty]"))
                  "Data Source=${dataSource};[getTestProperties]"))
              {
                connection2.Open();

                using (SQLiteCommand command1 = connection1.CreateCommand())
                {
                  command1.CommandText = "${sql(1)}";
                  command1.ExecuteNonQuery();
439
440
441
442
443
444
445
446

447
448
449
450
451

452
453
454
455
456
457
458
439
440
441
442
443
444
445

446
447
448
449
450

451
452
453
454
455
456
457
458







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadUncommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty $flags]"))
                "Data Source=${dataSource};[getTestProperties $flags]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};[getFlagsProperty $flags]"))
                  "Data Source=${dataSource};[getTestProperties $flags]"))
              {
                connection2.Open();

                BindingFlags bindingFlags = BindingFlags.Instance |
                  BindingFlags.NonPublic | BindingFlags.GetField;

                FieldInfo fieldInfo1 = connection1.GetType().GetField(
532
533
534
535
536
537
538
539

540
541
542
543
544

545
546
547
548
549
550
551
532
533
534
535
536
537
538

539
540
541
542
543

544
545
546
547
548
549
550
551







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadUncommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty $flags]"))
                "Data Source=${dataSource};[getTestProperties $flags]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};[getFlagsProperty $flags]"))
                  "Data Source=${dataSource};[getTestProperties $flags]"))
              {
                connection2.Open();

                using (SQLiteCommand command1 = connection1.CreateCommand())
                {
                  command1.CommandText = "${sql(1)}";
                  command1.ExecuteNonQuery();
609
610
611
612
613
614
615
616

617
618
619
620
621

622
623
624
625
626
627
628
609
610
611
612
613
614
615

616
617
618
619
620

621
622
623
624
625
626
627
628







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadUncommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};Enlist=False;[getFlagsProperty $flags]"))
                "Data Source=${dataSource};Enlist=False;[getTestProperties $flags]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};Enlist=False;[getFlagsProperty $flags]"))
                  "Data Source=${dataSource};Enlist=False;[getTestProperties $flags]"))
              {
                connection2.Open();

                using (SQLiteCommand command1 = connection1.CreateCommand())
                {
                  command1.CommandText = "${sql(1)}";
                  command1.ExecuteNonQuery();
686
687
688
689
690
691
692
693

694
695
696
697
698

699
700
701
702
703
704
705
686
687
688
689
690
691
692

693
694
695
696
697

698
699
700
701
702
703
704
705







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadUncommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty $flags]"))
                "Data Source=${dataSource};[getTestProperties $flags]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};Enlist=False;[getFlagsProperty $flags]"))
                  "Data Source=${dataSource};Enlist=False;[getTestProperties $flags]"))
              {
                connection2.Open();

                using (SQLiteCommand command1 = connection1.CreateCommand())
                {
                  command1.CommandText = "${sql(1)}";
                  command1.ExecuteNonQuery();
763
764
765
766
767
768
769
770

771
772
773
774
775

776
777
778
779
780
781
782
763
764
765
766
767
768
769

770
771
772
773
774

775
776
777
778
779
780
781
782







-
+




-
+







          TransactionOptions transactionOptions = new TransactionOptions();
          transactionOptions.IsolationLevel = IsolationLevel.ReadUncommitted;

          using (TransactionScope transactionScope = new TransactionScope(
              TransactionScopeOption.Required, transactionOptions))
          {
            using (SQLiteConnection connection1 = new SQLiteConnection(
                "Data Source=${dataSource};Enlist=False;[getFlagsProperty $flags]"))
                "Data Source=${dataSource};Enlist=False;[getTestProperties $flags]"))
            {
              connection1.Open();

              using (SQLiteConnection connection2 = new SQLiteConnection(
                  "Data Source=${dataSource};[getFlagsProperty $flags]"))
                  "Data Source=${dataSource};[getTestProperties $flags]"))
              {
                connection2.Open();

                using (SQLiteCommand command1 = connection1.CreateCommand())
                {
                  command1.CommandText = "${sql(1)}";
                  command1.ExecuteNonQuery();
Changes to Tests/tkt-6434e23a0f.eagle.
46
47
48
49
50
51
52
53

54
55
56
57
58
59
60
46
47
48
49
50
51
52

53
54
55
56
57
58
59
60







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteDataAdapter dataAdapter = new SQLiteDataAdapter(
                "${sql}", connection))
            {
              dataAdapter.Fill(new DataSet());
Changes to Tests/tkt-6c6ecccc5f.eagle.
42
43
44
45
46
47
48
49

50
51
52
53
54
55
56
42
43
44
45
46
47
48

49
50
51
52
53
54
55
56







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = new SQLiteCommand("${sql}",
                connection))
            {
              /* IGNORED */
Changes to Tests/tkt-72905c9a77.eagle.
167
168
169
170
171
172
173
174

175
176
177
178
179
180
181
167
168
169
170
171
172
173

174
175
176
177
178
179
180
181







-
+








                  //
                  // NOTE: Create and open a connection and use it to log a
                  //       test message just to make sure that the logging
                  //       system is initialized and in working order.
                  //
                  using (SQLiteConnection connection = new SQLiteConnection(
                      "Data Source=${dataSource};[getFlagsProperty]"))
                      "Data Source=${dataSource};[getTestProperties]"))
                  {
                    connection.Open();
                    connection.LogMessage(0, "TEST ${id}");
                  }
                }
                catch (Exception e)
                {
Changes to Tests/tkt-7e3fa93744.eagle.
93
94
95
96
97
98
99
100

101
102
103
104
105
106
107
93
94
95
96
97
98
99

100
101
102
103
104
105
106
107







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static int Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = connection.CreateCommand())
            {
              command.CommandText = "${sql}";

Changes to Tests/tkt-85b824b736.eagle.
79
80
81
82
83
84
85
86

87
88
89
90
91
92
93
79
80
81
82
83
84
85

86
87
88
89
90
91
92
93







-
+







      public static class Test${id}
      {
        public static StringList GetList(params string\[\] strings)
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            SQLiteModuleTest${id} module = new SQLiteModuleTest${id}(
                "mod${id}", strings);

            connection.CreateModule(module);
198
199
200
201
202
203
204
205

206
207
208
209
210
211
212
198
199
200
201
202
203
204

205
206
207
208
209
210
211
212







-
+







      public static class Test${id}
      {
        public static ByteList GetList(params string\[\] strings)
        {
          ByteList result = new ByteList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            SQLiteModuleTest${id} module = new SQLiteModuleTest${id}(
                "mod${id}", strings);

            connection.CreateModule(module);
Changes to Tests/tkt-996d13cd87.eagle.
146
147
148
149
150
151
152
153

154
155
156
157
158
159
160
146
147
148
149
150
151
152

153
154
155
156
157
158
159
160







-
+







                  //       and then wait a random number of milliseconds before
                  //       doing it again.
                  //
                  Thread.Sleep(random.Next(0, 500));

                  SQLiteConnection connection = new SQLiteConnection(
                      "Data Source=${dataSource};Pooling=${pooling};" +
                      "[getFlagsProperty]");
                      "[getTestProperties]");

                  connection.Open();

                  using (SQLiteCommand command = new SQLiteCommand("${sql}",
                      connection))
                  {
                    command.ExecuteNonQuery();
Changes to Tests/tkt-ae5267b863.eagle.
67
68
69
70
71
72
73
74

75
76
77
78
79
80
81
67
68
69
70
71
72
73

74
75
76
77
78
79
80
81







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteCommand command = connection.CreateCommand())
            {
              command.CommandText = "${sql(1)}";
              command.ExecuteNonQuery();
Changes to Tests/tkt-e1b2e0f769.eagle.
95
96
97
98
99
100
101
102

103
104
105
106
107
108
109
95
96
97
98
99
100
101

102
103
104
105
106
107
108
109







-
+







          }

          /////////////////////////////////////////////////////////////////////

          public static int Main()
          {
            using (SQLiteConnection connection = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty]"))
                "Data Source=${dataSource};[getTestProperties]"))
            {
              connection.Open();

              return Tkt_e1b2e0f769(connection).Count;
            }
          }
        }
Changes to Tests/tkt-e30b820248.eagle.
58
59
60
61
62
63
64
65

66
67
68
69
70
71
72
58
59
60
61
62
63
64

65
66
67
68
69
70
71
72







-
+







              new FileStream("${test_log}", FileMode.Append,
                  FileAccess.Write, FileShare.ReadWrite), "${name}"))
          {
            Trace.Listeners.Add(listener);
            Trace.WriteLine("---- START TRACE \\"${name}\\"");

            using (SQLiteConnection connection = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty]"))
                "Data Source=${dataSource};[getTestProperties]"))
            {
              connection.Open();
              connection.LogMessage(0, "Connection opened.");

              using (SQLiteTransaction transaction =
                  connection.BeginTransaction())
              {
154
155
156
157
158
159
160
161

162
163
164
165
166
167
168
154
155
156
157
158
159
160

161
162
163
164
165
166
167
168







-
+








          /////////////////////////////////////////////////////////////////////

          #region Public Static Methods
          public static void OpenConnection()
          {
            connection = new SQLiteConnection(
                "Data Source=${dataSource};[getFlagsProperty]");
                "Data Source=${dataSource};[getTestProperties]");

            connection.Open();
            connection.LogMessage(0, "Connection opened.");
          }

          /////////////////////////////////////////////////////////////////////

Changes to Tests/tkt-ef2216192d.eagle.
40
41
42
43
44
45
46
47

48
49
50
51
52
53
54
40
41
42
43
44
45
46

47
48
49
50
51
52
53
54







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            using (SQLiteDataAdapter dataAdapter = new SQLiteDataAdapter(
                "${sql}", connection))
            {
              using (SQLiteCommandBuilder commandBuilder =
Changes to Tests/vtab.eagle.
82
83
84
85
86
87
88
89

90
91
92
93
94
95
96
82
83
84
85
86
87
88

89
90
91
92
93
94
95
96







-
+







      /////////////////////////////////////////////////////////////////////////

      public static class Test${id}
      {
        public static void Main()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();
            connection.CreateModule(new SQLiteModuleTest${id}("mod${id}"));

            using (SQLiteCommand command = connection.CreateCommand())
            {
              command.CommandText = "[subst ${sql}]";
151
152
153
154
155
156
157
158

159
160
161
162
163
164
165
151
152
153
154
155
156
157

158
159
160
161
162
163
164
165







-
+







      public static class Test${id}
      {
        public static StringList GetList(params string\[\] strings)
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            connection.CreateModule(new SQLiteModuleEnumerable(
              "mod${id}", strings));

            using (SQLiteCommand command = connection.CreateCommand())
259
260
261
262
263
264
265
266

267
268
269
270
271
272
273
259
260
261
262
263
264
265

266
267
268
269
270
271
272
273







-
+







      public static class Test${id}
      {
        public static StringList GetList(params string\[\] strings)
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            SQLiteModule module = new SQLiteModuleEnumerable(
                "mod${id}", strings);

            connection.CreateModule(module);
371
372
373
374
375
376
377
378

379
380
381
382
383
384
385
371
372
373
374
375
376
377

378
379
380
381
382
383
384
385







-
+







      public static class Test${id}
      {
        public static StringList GetList(params int\[\] integers)
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            connection.CreateModule(new SQLiteModuleEnumerable<int>(
              "mod${id}", integers));

            using (SQLiteCommand command = connection.CreateCommand())
479
480
481
482
483
484
485
486

487
488
489
490
491
492
493
479
480
481
482
483
484
485

486
487
488
489
490
491
492
493







-
+







      public static class Test${id}
      {
        public static StringList GetList(params int\[\] integers)
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            SQLiteModule module = new SQLiteModuleEnumerable<int>(
                "mod${id}", integers);

            connection.CreateModule(module);
715
716
717
718
719
720
721
722

723
724
725
726
727
728
729
715
716
717
718
719
720
721

722
723
724
725
726
727
728
729







-
+







      public static class Test${id}
      {
        public static StringList GetList()
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty NoBindFunctions]"))
              "Data Source=${dataSource};[getTestProperties NoBindFunctions]"))
          {
            connection.Open();
            connection.CreateModule(new SQLiteModuleTest${id}("mod${id}"));

            try
            {
              using (SQLiteCommand command = connection.CreateCommand())
968
969
970
971
972
973
974
975

976
977
978
979
980
981
982
968
969
970
971
972
973
974

975
976
977
978
979
980
981
982







-
+







      public static class Test${id}
      {
        public static StringList GetList()
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();
            connection.CreateModule(new SQLiteModuleTest${id}("mod${id}"));

            try
            {
              using (SQLiteCommand command = connection.CreateCommand())
1137
1138
1139
1140
1141
1142
1143
1144

1145
1146
1147
1148
1149
1150
1151
1137
1138
1139
1140
1141
1142
1143

1144
1145
1146
1147
1148
1149
1150
1151







-
+







      public static class Test${id}
      {
        public static StringList GetList()
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();
            connection.CreateModule(new SQLiteModuleTest${id}("mod${id}"));

            try
            {
              using (SQLiteCommand command = connection.CreateCommand())
1314
1315
1316
1317
1318
1319
1320
1321

1322
1323
1324
1325
1326
1327
1328
1314
1315
1316
1317
1318
1319
1320

1321
1322
1323
1324
1325
1326
1327
1328







-
+







      public static class Test${id}
      {
        public static StringList GetList(params string\[\] strings)
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            SQLiteModuleTest${id} module = new SQLiteModuleTest${id}(
                "mod${id}", strings);

            connection.CreateModule(module);
1459
1460
1461
1462
1463
1464
1465
1466

1467
1468
1469
1470
1471
1472
1473
1459
1460
1461
1462
1463
1464
1465

1466
1467
1468
1469
1470
1471
1472
1473







-
+







      public static class Test${id}
      {
        public static StringList GetList(params string\[\] strings)
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            SQLiteModuleTest${id} module = new SQLiteModuleTest${id}(
                "mod${id}", strings);

            connection.CreateModule(module);
1553
1554
1555
1556
1557
1558
1559
1560

1561
1562
1563
1564
1565
1566
1567
1553
1554
1555
1556
1557
1558
1559

1560
1561
1562
1563
1564
1565
1566
1567







-
+







    namespace _Dynamic${id}
    {
      public static class Test${id}
      {
        public static object GetSum()
        {
          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            byte\[\] bytes = new byte\[1048576\];
            new Random().NextBytes(bytes);

            connection.CreateModule(new SQLiteModuleEnumerable(
1635
1636
1637
1638
1639
1640
1641
1642

1643
1644
1645
1646
1647
1648
1649
1635
1636
1637
1638
1639
1640
1641

1642
1643
1644
1645
1646
1647
1648
1649







-
+







      public static class Test${id}
      {
        public static StringList GetList(params string\[\] strings)
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            connection.CreateModule(new SQLiteModuleEnumerable(
              "mod${id}", strings));

            using (SQLiteCommand command = connection.CreateCommand())
1733
1734
1735
1736
1737
1738
1739
1740

1741
1742
1743
1744
1745
1746
1747
1733
1734
1735
1736
1737
1738
1739

1740
1741
1742
1743
1744
1745
1746
1747







-
+







      public static class Test${id}
      {
        public static StringList GetList(params string\[\] strings)
        {
          StringList result = new StringList();

          using (SQLiteConnection connection = new SQLiteConnection(
              "Data Source=${dataSource};[getFlagsProperty]"))
              "Data Source=${dataSource};[getTestProperties]"))
          {
            connection.Open();

            connection.CreateModule(new SQLiteModuleEnumerable(
              "mod${id}", strings, true));

            using (SQLiteCommand command = connection.CreateCommand())
Changes to lib/System.Data.SQLite/common.eagle.
2525
2526
2527
2528
2529
2530
2531

























2532
2533
2534
2535
2536
2537
2538
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563







+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+







        #          ["magical"] meta-flags).
        #
        return [appendArgs "Flags=" $flags \;]
      }

      return ""
    }

    proc getTestProperties { {flags ""} {quiet false} } {
      #
      # NOTE: Start with "Flags" property for the new connection, if any.
      #
      set result [getFlagsProperty $flags $quiet]

      #
      # NOTE: Add the name of the current test file, if available.  This is
      #       only used for debugging.
      #
      if {[info exists ::test_file]} then {
        append result {TestFile=${::test_file};}
      }

      #
      # NOTE: Add the name of the current test, if available.  This is only
      #       used for debugging.
      #
      if {[info exists ::eagle_tests(CurrentName)]} then {
        append result {TestName=${::eagle_tests(CurrentName)};}
      }

      return $result
    }

    proc enableSharedCache { channel enable {quiet false} } {
      if {[catch {
        object invoke -flags +NonPublic \
            System.Data.SQLite.UnsafeNativeMethods \
            sqlite3_enable_shared_cache [expr int($enable)]
      } result] == 0} then {
2656
2657
2658
2659
2660
2661
2662
















2663
2664
2665
2666
2667
2668
2669
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710







+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+







      #
      # NOTE: If our caller specified an extra payload to the connection
      #       string, append it now.
      #
      if {[string length $extra] > 0} then {
        append connection \; $extra
      }

      #
      # NOTE: Add the name of the current test file, if available.  This is
      #       only used for debugging.
      #
      if {[info exists ::test_file]} then {
        append connection {;TestFile=${::test_file}}
      }

      #
      # NOTE: Add the name of the current test, if available.  This is only
      #       used for debugging.
      #
      if {[info exists ::eagle_tests(CurrentName)]} then {
        append connection {;TestName=${::eagle_tests(CurrentName)}}
      }

      #
      # NOTE: For clarity, append a final semicolon to the connection string.
      #
      append connection \;

      #
4951
4952
4953
4954
4955
4956
4957
4958

4959
4960
4961
4962
4963
4964
4965
4992
4993
4994
4995
4996
4997
4998

4999
5000
5001
5002
5003
5004
5005
5006







-
+








        #
        # NOTE: Save the test constraints for use by threads created in this
        #       application domain.  This is necessary because all the Eagle
        #       "test context" information is per-thread.
        #
        if {![info exists ::test_constraints]} then {
          set ::test_constraints $::eagle_tests(constraints)
          set ::test_constraints $::eagle_tests(Constraints)
        }

        #
        # NOTE: Load the "after-constraints" custom per-user and/or per-host
        #       test settings now.
        #
        uplevel 1 [list loadSQLiteTestSettings $::test_channel .after]