Commit Graph

101 Commits

Author SHA1 Message Date
Sli
fee7ade1a5 Harmonize test names 2024-07-24 00:50:48 +02:00
thomas girod
3046438cb1 replace drf by django-ninja 2024-07-23 19:57:33 +02:00
thomas girod
8c69a94488 use google convention for docstrings 2024-07-21 00:57:04 +02:00
thomas girod
2ac578c3ad ruff rule DJ
Co-authored-by: Bartuccio Antoine <klmp200@users.noreply.github.com>
2024-07-08 15:37:10 +02:00
thomas girod
cfc19434d0 ruff rules UP008 and UP009 2024-07-08 15:37:09 +02:00
thomas girod
d97602e60b
Use pytest for tests (#681)
* use pytest for tests

Eh ouais, il y a que la config qui change. Pytest est implémentable par étapes. Et ça c'est beau.

* rework tests with pytest

* remove unittest custom TestRunner

* Edit doc and CI
2024-06-26 19:10:24 +02:00
thomas girod
3143d3d91a reorganize imports with ruff 2024-06-26 12:35:38 +02:00
Julien Constant
38295e591d
Fix immutable default variable in get_start_of_semester (#656)
Le serveur ne percevait pas le changement de semestre, parce
que la valeur par défaut passée à la fonction `get_start_of_semester()` était une fonction appelée une seule fois, lors du lancement du serveur. Bref, c'était ça : https://beta.ruff.rs/docs/rules/function-call-in-default-argument/

---------

Co-authored-by: imperosol <thgirod@hotmail.com>
2023-09-07 23:11:58 +02:00
thomas girod
ef968f3673
Better usage of cache for groups and clubs related operations (#634)
* Better usage of cache for group retrieval

* Cache clearing on object deletion or update

* replace signals by save and delete override

* add is_anonymous check in is_owned_by

Add in many is_owned_by(self, user) methods that user is not anonymous. Since many of those functions do db queries, this should reduce a little bit the load of the db.

* Stricter usage of User.is_in_group

Constrain the parameters that can be passed to the function to make sure only a str or an int can be used. Also force to explicitly specify if the group id or the group name is used.

* write test and correct bugs

* remove forgotten populate commands

* Correct test
2023-05-02 12:36:59 +02:00
thomas girod
96dede5077
Speed up tests (#638) 2023-05-02 11:00:23 +02:00
thomas girod
b5a40cfda9
Mise à jour de Black vers la version 23.3 (#629) 2023-04-22 15:32:31 +02:00
Julien Constant
8e7c025e47
[FIX] Broken link in readme and license fix (& update) (#591) 2023-04-04 18:39:45 +02:00
thomas girod
a73fe598ef
repair user merging tool (#498) 2023-03-04 15:01:08 +01:00
thomas girod
d726f4b1e8
Merge pull request #499 from ae-utbm/unify-account-creation
Unify account id creation
2023-01-11 13:26:00 +01:00
thomas girod
99827e005b
upgrade re_path to path (#533) 2023-01-09 22:07:03 +01:00
Thomas Girod
751c8a8bc6 unify account_id creation 2023-01-09 21:40:38 +01:00
thomas girod
5d97146d14
Merge pull request #531 from ae-utbm/remove_useless_tests
remove useless tests
2022-12-22 13:01:56 +01:00
Thomas Girod
ceb2888f82 enhance admin pages 2022-12-19 20:55:33 +01:00
Thomas Girod
22b83b0814 remove useless tests 2022-12-12 22:56:06 +01:00
Thomas Girod
fe9e5ce861 integration of 3D secure v2 for eboutic bank payment 2022-11-30 22:52:56 +01:00
thomas girod
e0ad288cf4
Suppression des appels à la db de l'ancien site (#483) 2022-10-19 16:26:30 +02:00
Théo DURR
142cb3316e
Edited deprecated code
Fixes #449

See : https://docs.djangoproject.com/en/3.2/ref/forms/api/\#notes-on-field-ordering
2022-08-26 22:33:21 +02:00
Sli
98bfc308a7 Minimal working version
* Upgrade dependencies
* Fix ugettext
* Fix bad urls
2022-08-04 00:28:09 +02:00
tleb
49a0ade315 core: create TzAwareDateTimeField to replace forms.DateTimeField 2021-09-29 15:24:06 +02:00
Francesco
1a091951e8 Added new subscription for the new CA offer 2021-09-28 01:11:23 +02:00
Francesco Witz
aaf1adaaa1 sith: Added a new subscription 2020-08-30 23:53:19 +02:00
Och
797ca0f926 settings: Added a new subscription 2020-06-18 00:23:51 +02:00
3cb306bc91
django2.2: add on_delete on migrations for ForeignKey 2019-10-08 22:46:03 +02:00
12b6f0d488
django2.2: adapt DateTimeField in forms with the new API 2019-10-08 22:46:02 +02:00
4dadb1dbc0
django2.2: add default mandatory on_delete on all ForeignKey 2019-10-08 22:46:01 +02:00
2616e8b24c
django2.2: relpace django.core.urlresolvers by django.urls 2019-10-08 22:46:01 +02:00
be855c6c90
django2.2: migrate url to re_path 2019-10-08 22:46:01 +02:00
Zar
dc9111dbcd
SUBSCRIPTIONS: 5 new discounted subscriptions for integration 2019-08-29 19:06:58 +02:00
e24eb8ce37
subscriptions: add date_of_birth for new users created in subscription form 2018-10-16 00:44:32 +02:00
cb58b00b6e
All: Apply Black coding rules 2018-10-05 21:52:55 +02:00
Soldat
cd7672f08c Change local for one day cotiz 2018-09-20 14:48:40 +02:00
Soldat
2fca548e15 Add 1 day cotiz 2018-09-20 14:30:35 +02:00
Soldat
7a1b9bd412 compute_end count day by day now (not month by month like before) to allow 6 weeks cotiz 2018-09-01 17:45:13 +02:00
e3cb6d41f9
Add subscription for 2018 Euroks 2018-07-07 00:13:31 +02:00
f1e8d55b41
Fix subscription bug for old subscribers on subscription page 2018-06-12 15:00:51 +02:00
Skia
0cc3707059 subscription/tests: remove silly print 2018-04-19 01:10:06 +02:00
Skia
e9e51d34d3 subscription: fix compute_start 2018-04-16 14:54:47 +02:00
bb47ad97a3 Search field in Subscription admin area 2017-11-17 11:48:16 +01:00
Skia
04fdb251e2 subscription: fix tests
Signed-off-by: Skia <skia@libskia.so>
2017-09-07 11:21:32 +02:00
Skia
96d0ae36be subscription: rename test
Signed-off-by: Skia <skia@libskia.so>
2017-09-07 01:27:49 +02:00
2f912a197c Allow to subscribe before subscription end 2017-09-06 19:55:14 +02:00
Skia
9f259b35bd core, counter: add preferences for counter notifications
Signed-off-by: Skia <skia@libskia.so>
2017-09-02 12:42:07 +02:00
3be64d6a8f New subscription type for jewels
New condition to consider floats in subscriptions
2017-08-31 16:37:03 +02:00
94582a2d96 Free subscription for jewels 2017-08-31 16:18:28 +02:00
Skia
9ee5c387c5 subscription: add tests
Signed-off-by: Skia <skia@libskia.so>
2017-08-29 15:07:03 +02:00