aboutsummaryrefslogtreecommitdiff
path: root/sqlite3_test.go (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #549 from mjtrangoni/fix-linter-issuesmattn2018-04-171-7/+4
|\ | | | | Fix linter issues
| * fix small codespell issueMario Trangoni2018-04-171-1/+1
| |
| * fix all gosimple issuesMario Trangoni2018-04-171-6/+3
| |
* | Move RegisterAggregator implementationKenneth Shaw2017-11-051-0/+60
| | | | | | | | | | | | | | | | | | | | | | The SQLiteConn.RegisterAggregator implementation was defined in sqlite3_trace.go file, which is guarded with a build constraint. This change simply moves RegisterAggregator to the main sqlite3.go file, and moves accompanying unit tests. The rationale for this move is that it was not possible for downstream using packages to use RegisterAggregator without also specifying (and notifying the user) the 'trace' build tag.
* | Merge branch 'master' into mastermattn2017-08-301-14/+568
|\|
| * Improved TestNilAndEmptyBytesGreg Holt2017-08-211-1/+3
| | | | | | | | I forgot that bytes.Equals treats nil and []byte{} as equal.
| * Added TestNilAndEmptyBytesGreg Holt2017-08-211-0/+54
| |
| * fix testYasuhiro Matsumoto2017-08-021-34/+35
| |
| * ignore errors in teardownYasuhiro Matsumoto2017-08-021-2/+2
| |
| * fix tests on tipYasuhiro Matsumoto2017-08-021-14/+420
| |
| * Add connection option for recursive triggersRoss Light2017-07-091-0/+29
| | | | | | | | | | Similar to foreign keys, the recursive triggers PRAGMA affects the interpretation of all statements on a connection.
| * Incorporate original PR 271 from https://github.com/brokensandalsJason Abbott2017-07-031-0/+61
| |
| * Don't convert Unix times to nanoseconds when querying datetime fields. Fixes ↵deepilla2017-06-301-0/+1
| | | | | | | | #430.
* | Add support for collation sequences implemented in Go.David Anderson2017-06-081-0/+121
|/ | | | | This allows Go programs to register custom comparison functions with sqlite, and ORDER BY that comparator.
* Add _foreign_keys connection parameterRoss Light2017-04-011-0/+29
| | | | | Fixes #377 Updates #255
* not use underscoreYasuhiro Matsumoto2017-03-051-2/+2
|
* fix testYasuhiro Matsumoto2017-01-191-60/+0
|
* go vet && golintYasuhiro Matsumoto2016-11-061-21/+21
|
* separate testYasuhiro Matsumoto2016-11-041-36/+0
|
* support named paramsYasuhiro Matsumoto2016-11-041-3/+3
|
* implement go18 PingerYasuhiro Matsumoto2016-11-031-0/+16
|
* TestAggregatorRegistration may fail if trace feature is not implementedYasuhiro Matsumoto2016-09-081-1/+2
|
* Fix testing message at TestInsert and TestUpdateyoza2016-03-141-2/+2
|
* Test SQLiteRows.DeclTypes()Zac Medico2016-03-071-0/+35
|
* Clean up tempfiles in testsLars Buitinck2015-11-031-21/+21
| | | | "go test" leaves no more clutter in /tmp.
* Merge branch 'master' of https://github.com/mattn/go-sqlite3Yasuhiro Matsumoto2015-11-021-3/+23
|\
| * Store/retrieve timezones for time.Time values.Augusto Roman2015-10-091-3/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, the timezone information for a provided value was discarded and the value always stored as in UTC. However, sqlite allows specifying the timezone offsets and handles those values appropriately. This change stores the timezone information and parses it out if present, otherwise it defaults to UTC as before. One additional bugfix: Previously, a unix timestamp in seconds was parsed in the local timezone (rather than UTC), in contrast to a unix timestamp in milliseconds that was parsed in UTC. While fixing that extra bug, I cleaned up the parsing code -- no need to convert to a string and then parse it back again and risk a parse error, just to check the number of digits. The tests were extended to cover non-UTC timezones storage & retrieval, meaningful unix timestamps, and correct handling of a trailing Z.
* | fix testsYasuhiro Matsumoto2015-11-021-2/+1
| |
* | Merge branch 'pr/207'Yasuhiro Matsumoto2015-11-021-26/+50
|\ \ | |/ |/|
| * Test read-only databasesLars Buitinck2015-06-051-0/+21
| |
| * Clean up more tempfilesLars Buitinck2015-06-051-0/+1
| |
| * Get reliable tempfile names from ioutil.TempFileLars Buitinck2015-06-051-27/+28
| | | | | | | | Also makes them easier to spot (the tests tend to litter /tmp).
* | Merge pull request #229 from danderson/mastermattn2015-09-161-0/+212
|\ \ | | | | | | Implement support for calling Go functions from SQLite
| * | Implement support for aggregation functions implemented in Go.David Anderson2015-09-151-0/+59
| | |
| * | Add support for interface{} arguments in Go SQLite functions.David Anderson2015-08-211-0/+28
| | | | | | | | | | | | | | | This enabled support for functions like Foo(a interface{}) and Bar(a ...interface{}).
| * | Implement support for variadic functions.David Anderson2015-08-211-0/+13
| | | | | | | | | | | | | | | Currently, the variadic part must all be the same type, because there's no "generic" arg converter.
| * | Move argument converters to callback.go, and optimize return value handling.David Anderson2015-08-211-47/+51
| | | | | | | | | | | | | | | | | | A call now doesn't have to do any reflection, it just blindly invokes a bunch of argument and return value handlers to execute the translation, and the safety of the translation is determined at registration time.
| * | Implement support for passing Go functions as custom functions to SQLite.David Anderson2015-08-211-0/+108
| |/ | | | | | | Fixes #226.
* / Fix test. Close #216mattn2015-08-251-1/+3
|/ | | | | | When one goroutine close db that opended as :memory:, session will be lost. So another goroutine can't refer the last session. goroutine .
* Remove debug codeYasuhiro Matsumoto2015-04-151-2/+0
|
* Z suffix should be no-opYasuhiro Matsumoto2015-04-151-1/+41
|
* Merge pull request #194 from hallyn/tximm.2mattn2015-04-141-5/+39
|\ | | | | Add a txlock option when opening databases
| * Add a txlock option when opening databases (v2)Serge Hallyn2015-04-131-5/+39
| | | | | | | | | | | | | | | | | | | | | | When specified, changes the default locking at a tx.Begin. Changelog (v2): Add a testcase to ensure _txlock is properly handled. Closes #189 Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
* | Fix NULs in text.Egon Elbre2015-04-121-0/+39
|/ | | | | | NUL character is a valid symbols in UTF8. Fixes #195
* Implement number-named parameters. Close #187mattn2015-03-241-0/+36
|
* Revert a6c208564eccf3c6743f608ef88398a4ca84c5ebmattn2015-03-221-36/+0
|
* Fix buildmattn2015-03-221-3/+3
|
* Fix testmattn2015-03-221-1/+1
|
* Support $NNN-style named parameter. Close #187mattn2015-03-221-0/+36
|
* Fix testYasuhiro Matsumoto2015-03-051-3/+3
|