Commit Graph
158 Commits
Author SHA1 Message Date
Laurent Defert d143acdd0a Add a 'copy' action to One2Many and Many2Many's set method
issue3341
review1271002
2013-11-19 11:04:33 +01:00
Cédric Krier 2b2001f1ca Force UTC as timezone
issue3444
review1411002
2013-11-15 02:26:58 +01:00
Cédric Krier 37cf65c71f Timezone must be set when running tests
review1139002
2013-10-15 17:48:25 +02:00
Cédric Krier 84d0a09711 Fix PYSON Composite test for new default value 2013-10-10 09:39:06 +02:00
Cédric Krier b9296eb070 Fix usage of context company
Default value of company should be -1 to get the right cast and an impossible
value.
Replace False by None as other value in "in" clause.

issue3394
review1119002
2013-10-09 18:24:39 +02:00
Cédric Krier 838d50b736 Add test for reading ModelSingleton rec_name via default values
review1114003
2013-10-05 18:05:45 +02:00
Cédric Krier 6f179949ed Commit cursor in timestamp unittest
cursor must be committed between each changes otherwise NOW() returns always
the same timestamp.
2013-09-23 00:00:51 +02:00
Cédric Krier 1a8c5aae1c Fix check timestamp and add unittest
review1087003
2013-09-22 14:28:46 +02:00
Nicolas Évrard c52889a1d2 Do not take into account active field when doing domain validation
review908002
2013-09-17 17:14:14 +02:00
Cédric Krier ab74123eb2 Merge test/ into tests/
review1060002
2013-09-16 11:38:11 +02:00
Cédric Krier fc6c6cfdda Migration to python-sql
* Use python-sql
* Add convert_domain method on Fields
* Add sql_format and sql_type methods on Fields
* Allow to return a full domain for Function.searcher
* Replace static backend by dynamic get method
* Replace order_field by order_<field name> method

review1001002
2013-09-06 22:32:37 +02:00
Cédric Krier 0210370575 Improve MPTT
- Remove the order on MPTT
- Make room with queries using left/right instead of ids
- Call _update_tree multiple times for small list instead of rebuild the all
  tree
- Improve test for with many roots
- Factorize the test to update MPTT

issue1892
review1007002
2013-09-03 10:26:23 +02:00
Nicolas Évrard 27ccf989a5 Add tests on fields.Binary
review1017002
2013-08-16 11:08:44 +02:00
Nicolas Évrard a293325aa6 Fix naming of fields.Selection's test 2013-08-09 18:40:02 +02:00
Cédric Krier b1e50bfaf0 Add unittest for domain validation of One2One fields
review852003
2013-05-18 19:13:56 +02:00
Ralf Peschke 7fbc4934a4 unit-test: on import_data zero values shouldn't be converted to None
import_data method converts zero values to None. As a consequence such records
don't pass the required constraint for such fields

issue3136
review779002
2013-04-13 10:29:37 +02:00
Cédric Krier f27631161a Add test for unknown fields in test_depends
review745002
2013-03-27 22:47:06 +01:00
Cédric Krier 15961b9e67 Allow to search on target of Reference field
review716002
2013-03-21 18:20:39 +01:00
Cédric Krier a95ae0dad9 Remove _inherits
review670002
2013-03-20 22:49:16 +01:00
Cédric Krier 9af0cc3039 Re-add tests of search on Reference field with tuple/list 2013-03-17 00:56:45 +01:00
Sharoon Thomas 6efc1f6a0c Improve trigger tests
review690002
2013-03-06 17:00:34 +01:00
Cédric Krier 1887c2c564 Enforce usage of None instead of False
review685002
2013-03-05 10:33:18 +01:00
Cédric Krier 5e01f5c068 Fix flake8 2013-02-27 22:50:31 +01:00
Cédric Krier d49fb4318d Add selection_change_with on Selection and Reference fields
review587002
2013-02-05 19:06:16 +01:00
Cédric Krier 289eaac537 Add test for copy of One2Many 2013-02-04 20:03:18 +01:00
Cédric Krier 1e60085854 Use a better hashing method for context
repr doesn't guarantee to have always the same string

review642002
2013-02-04 19:59:05 +01:00
Cédric Krier fd01a724f8 Add Dict fields
review501007
2013-01-26 15:18:41 +01:00
Albert Cervera i Areny 30b1403cdc Use a list of dictionaries in create().
issue2358
review266002
2013-01-06 22:18:13 +01:00
Cédric Krier 06a1e783d7 merge 2012-12-18 17:46:07 +01:00
Albert Cervera i Areny ec1761ddca Use None instead of False in ModelSingleton
issue2932
review617002
2012-12-16 23:54:41 +01:00
Albert Cervera i Areny 98164b445f Check depends of One2Many.add_remove
issue2931
review615002
2012-12-16 23:38:58 +01:00
Cédric Krier cf0636e095 Add ModelFieldAccess.get_access
review598002
2012-11-28 22:42:51 +01:00
Cédric Krier 220c31651d Fix url tests as hostname is fixed 2012-11-23 13:44:32 +01:00
Cédric Krier d7611e22e7 Remove unittest.skipIf decorator because it is only in >= 2.7 2012-10-10 09:31:53 +02:00
Nicolas Évrard 52a4ee8e56 Fix import_data for reference fields 2012-10-09 17:42:02 +02:00
Pierre-Louis Bonicoli 4e4fe87dfa Fix message when a required field is missing
issue2657
review399002
2012-10-09 11:08:56 +02:00
Cédric Krier c1d4aa7cfc Commit cursor after creation of wizard instance
Before running InstallUpgrade, the cursor must be committed to avoid
transactional dead lock.
2012-09-28 18:08:49 +02:00
Cédric Krier 529c992753 Fix comparison test on Singleton
Singleton can not be compared because the id could change meantime.
2012-09-28 18:06:27 +02:00
Cédric Krier 0fe1b93864 Active Record 2012-09-24 22:16:53 +02:00
Cédric Krier 4dc94980b1 NULL value for boolean fields should be considered like False
issue2755
review476002
2012-08-23 23:17:15 +02:00
Cédric Krier fca0e24ce0 Fix typo 2012-07-26 21:18:15 +02:00
Cédric Krier 507358c4e8 Allow to use tuple for Reference
review437001
2012-07-25 21:01:29 +02:00
Cédric Krier 5a0fd034cb Fix reading from cache in field one2many
issue2706
review419001
2012-07-19 09:55:09 +02:00
Cédric Krier 2188fc3c6c An empty string is not a valid required value
review411001
2012-06-28 15:19:21 +02:00
Cédric Krier 6858187fc8 Add dynamic size limit on the One2Many, Many2Many and Char
review396001
2012-06-20 18:12:40 +02:00
Cédric Krier 97fc27a825 Factorize the required test
issue2587
review370001
2012-06-13 23:24:47 +02:00
Cédric Krier 1aae951f92 Allow to use Reference field in One2Many & Many2Many
review378002
2012-06-08 19:27:19 +02:00
Emmanuelle Delescolle 6cd2e51aa3 Multi-level inherits search fix
Trytond now looks at the whole inherits hierarchy for fields when creating
search domain on ModelSQL objects instead of just looking at the direct parent.

issue1860
review369001
2012-05-16 15:48:00 +02:00
Cédric Krier 3ebda5c8ee Add time format validation
review342002
2012-05-16 13:04:36 +02:00
Cédric Krier ee3be37a36 Fix pep8 and pyflakes 2012-04-01 23:08:15 +02:00