ArnAud
34fdd8d8b3
EmType: implement select and unselect _field
9 years ago
ArnAud
886cee22df
EmType : subordinates_list and fields_list
9 years ago
Yann Weber
b6ef37752f
Supressed _fields from EmComponent and transforming the EmComponent in a standart object with standarts attributes
9 years ago
ArnAud
ee9104fd57
EmType : implement .fields()
comment selected_fields because it clashes with ._fields[]
=> we have to rethink of ._fields[] and fieldtypes
9 years ago
ArnAud
f72799af24
EmFieldgroups: fields(self, type_id=0) can now filter fields for EmType request
9 years ago
ArnAud
338bccd785
EmType: implement fieldgroups()
9 years ago
Yann Weber
6a56b31ba5
Migrating EmClass methods and EmComponent.delete according to the new Model object, changed the Model.components dict keys (and the json test file)
There is now two methods Model.name_from_emclass and emclass_from_name that allows to access the Model.components array
9 years ago
ArnAud
6f2d895462
EM: Model: store all components in one dict
9 years ago
ArnAud
71a1e852dc
EM: a canonical EM in json
9 years ago
ArnAud
e85e19c4b1
ME: basic ME for tests
9 years ago
ArnAud
55b030800f
Em: draft for fieldgroup
9 years ago
ArnAud
c73251795c
EM: first draft for a Model Class
9 years ago
Yann Weber
889abc8547
Put the database configuration asinstance attribute of EmComponent
9 years ago
Yann Weber
e757a3fb90
Doing todo
Added a dummy EmFieldType_icon
Added a test for EmType deletion with superiors
9 years ago
Roland Haroutiounian
b03958a65a
Suppression de sqlutils.getEngine au profit de sqlutils.get_engine
9 years ago
Yann Weber
49dfe9ad03
Code factorization on EmComponent.modify_rank()
Changed beahvior : when a 'non-change' is asked (like +0 -0 or set ranke to actual rank) don't raise an Error
9 years ago
Yann Weber
f41d164603
Added test for EmComponent.get_max_rank(), replacing the default value for rank by the one processed by get_max_rank
9 years ago
Yann Weber
6af0b45f3f
Code factorization on EmType select and unselect fields. Added comparison capabilities to EmComponent (and childs)
Implemented __hash__ and __eq__ for EmComponent (based on class name and uid) to test equality betwenn two instance. Allows to use "instance in instance_list" syntax
9 years ago
Yann Weber
27d178e531
Code factorization and create methods for EmComponent and childs changes
Behaviour changed for EmComponent and childs create method :
- Takes care of duplicated names at creation
- Handle all the checks in EmComponent method
Factorization of EmField.get_class_table() method
Added a @property method class_table_name to EmClass
9 years ago
Yann Weber
166dc6ad75
Added docstrings comments to tests and fixed "false hidden failure"
Added docstrings comments to tests (for fancy output with -v ).
Fixed strange hidden failure that make tests stops on non failed tests with -f option. Those false failure seems to comes from with self.subTest blocs with functions calls that does assertion.
9 years ago
Yann Weber
a3b9daf319
sqlwrapper deletion and sqlsetup enhancement
Moved the database initialisation functionnality to sqlsetup and fixed all the code to handle the sqlwrapper deletion
9 years ago
Yann Weber
4fb2f789b5
Replacing EmComponent method getDbE by db_engine
9 years ago
Yann Weber
65b10a6c5d
Added some tests to tests_types.py
Added hierarchy tests
9 years ago
Yann Weber
503ecd570b
Some tests dont pass, but most of them does
9 years ago
Yann Weber
16a962fb3f
Implemented DropColumn for sqlite
9 years ago
ArnAud
b7eb53c98a
ME test: changement de nom de fonction : new_uid
9 years ago
Roland Haroutiounian
f503dab46a
Implémentation d'un test sur le delete de type
9 years ago
Yann Weber
a042306c14
Delete implementation for EmClass and EmField
The EmField version cannot be tested yet (drop column not yet implemented for sqlite in Database.sqlalter)
9 years ago
Yann Weber
6359adc0f4
Added tests for EmField.delete() and EmClass.delete()
Also add a new function is sqlutils to execute ddl
9 years ago
Roland Haroutiounian
1d66177f8a
Suppression du rel_to_type dans le test EmField create
9 years ago
Roland Haroutiounian
61893313af
Tests EmType
9 years ago
ArnAud
96bfee8baa
test, fieldgroups: no use of subtest
9 years ago
Roland Haroutiounian
31e5448694
Ajout des tests sur la classe EmType
9 years ago
Roland Haroutiounian
1ab80e9b1c
[#11 ] Suppression de tests inutiles dans test_field
9 years ago
ArnAud
caef4dd72f
EM test EmClass: test link_type() and linked_types()
9 years ago
Roland Haroutiounian
d9c3f8e86c
[#11 ] Modification de la méthode create => passage en arguments positionnels
9 years ago
Roland Haroutiounian
62d2a978fb
[#11 ] Finalisation des tests sur Field (debuggage du process de test)
9 years ago
Roland Haroutiounian
0418bd4895
[#12 ] Modification et débuggage sur le process de création de fields
9 years ago
Roland Haroutiounian
9181acb0b2
[#12 ] Modification sur le nom de la base de test (avant passage à la classe test utils)
9 years ago
Roland Haroutiounian
e9d49533f2
[#12 ] Correctifs sur le populate et le save de EmField
9 years ago
Roland Haroutiounian
0751eb26e8
[#12 ] Modification du setup de test pour test_field
9 years ago
Roland Haroutiounian
b69b21b431
[#12 ] debug
9 years ago
Yann Weber
302382d488
Created EditorialModel tests database utilities
9 years ago
ArnAud
c8d8c34710
EM: test classes : test for EmClass.fields()
9 years ago
Roland Haroutiounian
2a9335f202
[#12 ] Déplacement des méthodes select_field et unselect_field de fields vers types
9 years ago
Roland Haroutiounian
f13b6f844d
[#12 ] Ajout de la class Em_Field_Type et du select_field
9 years ago
Yann Weber
00614d90e9
New way to specify _fields and table in EmComponent's child classes
Now _fields and table MUST be class attribute.
Its important to note that _fields now consist in a list of (name, ftype) tuples and that ftype is a EmFieldType class and NOT an EmFieldType instance
9 years ago
ArnAud
007a04ca2a
EmClass: test of types(), use uid instead of id
9 years ago
Roland Haroutiounian
e6f6720a57
[#11 ] Ajout des premiers tests sur EmField
9 years ago
Yann Weber
5340fde711
Added tests for EmComponent's delete() function
9 years ago