Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(265)

Side by Side Diff: third_party/sqlite/src/ext/rtree/rtreeB.test

Issue 901033002: Import SQLite 3.8.7.4. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Chromium changes to support SQLite 3.8.7.4. Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 # 2011 March 2 1 # 2011 March 2
2 # 2 #
3 # The author disclaims copyright to this source code. In place of 3 # The author disclaims copyright to this source code. In place of
4 # a legal notice, here is a blessing: 4 # a legal notice, here is a blessing:
5 # 5 #
6 # May you do good and not evil. 6 # May you do good and not evil.
7 # May you find forgiveness for yourself and forgive others. 7 # May you find forgiveness for yourself and forgive others.
8 # May you share freely, never taking more than you give. 8 # May you share freely, never taking more than you give.
9 # 9 #
10 #*********************************************************************** 10 #***********************************************************************
11 # Make sure the rtreenode() testing function can handle entries with 11 # Make sure the rtreenode() testing function can handle entries with
12 # 64-bit rowids. 12 # 64-bit rowids.
13 # 13 #
14 14
15 if {![info exists testdir]} { 15 if {![info exists testdir]} {
16 set testdir [file join [file dirname [info script]] .. .. test] 16 set testdir [file join [file dirname [info script]] .. .. test]
17 } 17 }
18 source $testdir/tester.tcl 18 source $testdir/tester.tcl
19 ifcapable !rtree { finish_test ; return } 19 ifcapable !rtree { finish_test ; return }
20 20
21 do_test rtreeB-1.1 { 21 ifcapable rtree_int_only {
22 db eval { 22 do_test rtreeB-1.1-intonly {
23 CREATE VIRTUAL TABLE t1 USING rtree(ii, x0, y0, x1, y1); 23 db eval {
24 INSERT INTO t1 VALUES(1073741824, 0.0, 0.0, 100.0, 100.0); 24 CREATE VIRTUAL TABLE t1 USING rtree(ii, x0, y0, x1, y1);
25 INSERT INTO t1 VALUES(2147483646, 0.0, 0.0, 200.0, 200.0); 25 INSERT INTO t1 VALUES(1073741824, 0.0, 0.0, 100.0, 100.0);
26 INSERT INTO t1 VALUES(4294967296, 0.0, 0.0, 300.0, 300.0); 26 INSERT INTO t1 VALUES(2147483646, 0.0, 0.0, 200.0, 200.0);
27 INSERT INTO t1 VALUES(8589934592, 20.0, 20.0, 150.0, 150.0); 27 INSERT INTO t1 VALUES(4294967296, 0.0, 0.0, 300.0, 300.0);
28 INSERT INTO t1 VALUES(9223372036854775807, 150, 150, 400, 400); 28 INSERT INTO t1 VALUES(8589934592, 20.0, 20.0, 150.0, 150.0);
29 SELECT rtreenode(2, data) FROM t1_node; 29 INSERT INTO t1 VALUES(9223372036854775807, 150, 150, 400, 400);
30 } 30 SELECT rtreenode(2, data) FROM t1_node;
31 } {{{1073741824 0.000000 0.000000 100.000000 100.000000} {2147483646 0.000000 0. 000000 200.000000 200.000000} {4294967296 0.000000 0.000000 300.000000 300.00000 0} {8589934592 20.000000 20.000000 150.000000 150.000000} {9223372036854775807 1 50.000000 150.000000 400.000000 400.000000}}} 31 }
32 32 } {{{1073741824 0 0 100 100} {2147483646 0 0 200 200} {4294967296 0 0 300 300} {8589934592 20 20 150 150} {9223372036854775807 150 150 400 400}}}
33 } else {
34 do_test rtreeB-1.1 {
35 db eval {
36 CREATE VIRTUAL TABLE t1 USING rtree(ii, x0, y0, x1, y1);
37 INSERT INTO t1 VALUES(1073741824, 0.0, 0.0, 100.0, 100.0);
38 INSERT INTO t1 VALUES(2147483646, 0.0, 0.0, 200.0, 200.0);
39 INSERT INTO t1 VALUES(4294967296, 0.0, 0.0, 300.0, 300.0);
40 INSERT INTO t1 VALUES(8589934592, 20.0, 20.0, 150.0, 150.0);
41 INSERT INTO t1 VALUES(9223372036854775807, 150, 150, 400, 400);
42 SELECT rtreenode(2, data) FROM t1_node;
43 }
44 } {{{1073741824 0 0 100 100} {2147483646 0 0 200 200} {4294967296 0 0 300 300} {8589934592 20 20 150 150} {9223372036854775807 150 150 400 400}}}
45 }
33 46
34 finish_test 47 finish_test
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698