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

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

Overview
Comment:Add test for ticket [d0116ee2c3].
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | tkt-d0116ee2c3
Files: files | file ages | folders
SHA1: e7eae509f8e1eaa0d8ea89cb6c7366ad9e77bec1
User & Date: mistachkin 2014-04-10 19:24:41
Context
2014-04-10
19:25
Fix typo in test case. check-in: aacf155c6c user: mistachkin tags: tkt-d0116ee2c3
19:24
Add test for ticket [d0116ee2c3]. check-in: e7eae509f8 user: mistachkin tags: tkt-d0116ee2c3
2014-04-04
21:16
Fix build for .NET Compact Framework. Relocate the archive exclusion files. check-in: 9b72adde17 user: mistachkin tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to Setup/verify.lst.

634
635
636
637
638
639
640

641
642
643
644
645
646
647
  Tests/tkt-aba4549801.eagle
  Tests/tkt-ac47dd230a.eagle
  Tests/tkt-ae5267b863.eagle
  Tests/tkt-b4a7ddc83f.eagle
  Tests/tkt-bb4b04d457.eagle
  Tests/tkt-c010fa6584.eagle
  Tests/tkt-ccfa69fc32.eagle

  Tests/tkt-e06c4caff3.eagle
  Tests/tkt-e1b2e0f769.eagle
  Tests/tkt-e30b820248.eagle
  Tests/tkt-e47b3d8346.eagle
  Tests/tkt-ef2216192d.eagle
  Tests/tkt-f2c47a01eb.eagle
  Tests/tkt-f8dbab8baf.eagle







>







634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
  Tests/tkt-aba4549801.eagle
  Tests/tkt-ac47dd230a.eagle
  Tests/tkt-ae5267b863.eagle
  Tests/tkt-b4a7ddc83f.eagle
  Tests/tkt-bb4b04d457.eagle
  Tests/tkt-c010fa6584.eagle
  Tests/tkt-ccfa69fc32.eagle
  Tests/tkt-d0116ee2c3.eagle
  Tests/tkt-e06c4caff3.eagle
  Tests/tkt-e1b2e0f769.eagle
  Tests/tkt-e30b820248.eagle
  Tests/tkt-e47b3d8346.eagle
  Tests/tkt-ef2216192d.eagle
  Tests/tkt-f2c47a01eb.eagle
  Tests/tkt-f8dbab8baf.eagle

Added Tests/tkt-d0116ee2c3.eagle.





































































































































































>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
###############################################################################
#
# tkt-d0116ee2c3.eagle --
#
# Written by Joe Mistachkin.
# Released to the public domain, use at your own risk!
#
###############################################################################

package require Eagle
package require Eagle.Library
package require Eagle.Test

runTestPrologue

###############################################################################

package require System.Data.SQLite.Test
runSQLiteTestPrologue

###############################################################################

runTest {test tkt-d0116ee2c3-1.1 {} -setup {
  setupDb [set fileName tkt-d0116ee2c3-1.1.db]
} -body {
  sql execute $db {
    CREATE TABLE t1(x);
    INSERT INTO t1 (x) VALUES(1);
  }

  set id [object invoke Interpreter.GetActive NextId]
  set dataSource [file join [getDatabaseDirectory] $fileName]

  unset -nocomplain results errors

  set code [compileCSharpWith [subst {
    using System.Data.SQLite;

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

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

              using (SQLiteDataReader dataReader = command.ExecuteReader())
              {
                dataReader.Close();
                command.Connection = null; /* SQLiteException? */
              }
            }
          }
        }
      }
    }
  }] true true true results errors System.Data.SQLite.dll]

  list $code $results \
      [expr {[info exists errors] ? $errors : ""}] \
      [expr {$code eq "Ok" ? [catch {
        object invoke _Dynamic${id}.Test${id} Main
      } result] : [set result ""]}] $result
} -cleanup {
  cleanupDb $fileName

  unset -nocomplain result results errors code dataSource id db fileName
} -constraints {eagle monoBug28 command.sql compile.DATA SQLite\
System.Data.SQLite compileCSharp} -match regexp -result {^Ok\
System#CodeDom#Compiler#CompilerResults#\d+ \{\} 0 \{\}$}}

###############################################################################

runSQLiteTestEpilogue
runTestEpilogue