transfer from private server/git server
This commit is contained in:
30
docs/evidence/coverage_output.txt
Normal file
30
docs/evidence/coverage_output.txt
Normal file
@@ -0,0 +1,30 @@
|
||||
.................................. [100%]
|
||||
|
||||
---------- coverage: platform linux, python 3.11.15-final-0 ----------
|
||||
Name Stmts Miss Cover Missing
|
||||
-------------------------------------------------------------
|
||||
app.py 48 13 73% 58-60, 64-66, 70-73, 77-79, 85
|
||||
db.py 41 4 90% 61-64
|
||||
models/__init__.py 0 0 100%
|
||||
models/annonce_model.py 20 0 100%
|
||||
models/audit_model.py 6 2 67% 13-17
|
||||
models/block_model.py 23 17 26% 13-15, 25-30, 34-39, 49-52, 56-59
|
||||
models/evenement_model.py 14 10 29% 5-9, 13-17, 21-25, 29-32
|
||||
models/fichier_model.py 14 6 57% 13-17, 29-32
|
||||
routes/__init__.py 0 0 100%
|
||||
routes/annonces.py 42 6 86% 47-50, 60-61
|
||||
routes/auth.py 38 20 47% 47-51, 55-65, 69-74, 84-86
|
||||
routes/dashboard.py 35 12 66% 12, 19, 29, 35-36, 42-46, 52-55
|
||||
routes/evenements.py 29 8 72% 18, 33, 39-44
|
||||
routes/fichiers.py 41 18 56% 18, 31, 37-46, 52-59
|
||||
services/__init__.py 0 0 100%
|
||||
services/annonce_service.py 33 1 97% 23
|
||||
services/audit_service.py 5 1 80% 11
|
||||
services/auth_service.py 36 1 97% 82
|
||||
services/block_service.py 14 9 36% 7, 11-15, 20-21, 25
|
||||
services/evenement_service.py 29 13 55% 16-17, 21, 26, 31-33, 37-42
|
||||
services/fichier_service.py 84 15 82% 70, 72, 129, 141, 150-160
|
||||
-------------------------------------------------------------
|
||||
TOTAL 552 156 72%
|
||||
|
||||
34 passed in 0.92s
|
||||
1
docs/evidence/flake8_output.txt
Normal file
1
docs/evidence/flake8_output.txt
Normal file
@@ -0,0 +1 @@
|
||||
flake8: 0 lignes (0 = aucune violation)
|
||||
43
docs/evidence/pytest_output.txt
Normal file
43
docs/evidence/pytest_output.txt
Normal file
@@ -0,0 +1,43 @@
|
||||
============================= test session starts ==============================
|
||||
platform linux -- Python 3.11.15, pytest-8.3.3, pluggy-1.6.0 -- /home/claude/work/venv/bin/python
|
||||
cachedir: .pytest_cache
|
||||
rootdir: /home/claude/work/gesthub-v2/web
|
||||
plugins: cov-5.0.0
|
||||
collecting ... collected 34 items
|
||||
|
||||
tests/test_integration_routes.py::test_it01_annonces_sans_auth_401 PASSED [ 2%]
|
||||
tests/test_integration_routes.py::test_it02_annonces_avec_auth_200 PASSED [ 5%]
|
||||
tests/test_integration_routes.py::test_it03_creer_annonce_non_admin_403 PASSED [ 8%]
|
||||
tests/test_integration_routes.py::test_it04_creer_annonce_admin_201_puis_visible PASSED [ 11%]
|
||||
tests/test_integration_routes.py::test_it05_modifier_annonce_admin_200 PASSED [ 14%]
|
||||
tests/test_integration_routes.py::test_it06_supprimer_annonce_admin_200 PASSED [ 17%]
|
||||
tests/test_integration_routes.py::test_it07_is_admin_reflete_groupes PASSED [ 20%]
|
||||
tests/test_integration_routes.py::test_it08_upload_sans_fichier_400 PASSED [ 23%]
|
||||
tests/test_integration_routes.py::test_it09_evenement_dates_invalides_400 PASSED [ 26%]
|
||||
tests/test_integration_routes.py::test_it10_accueil_sans_session_redirige_login PASSED [ 29%]
|
||||
tests/test_integration_routes.py::test_it04b_creer_annonce_titre_manquant_400 PASSED [ 32%]
|
||||
tests/test_security.py::test_ts01_injection_sql_dans_titre_est_neutralisee PASSED [ 35%]
|
||||
tests/test_security.py::test_ts02_acces_sans_token_refuse PASSED [ 38%]
|
||||
tests/test_security.py::test_ts03_cookie_session_falsifie_refuse PASSED [ 41%]
|
||||
tests/test_security.py::test_ts04_contenu_avec_script_est_echappe_au_rendu PASSED [ 44%]
|
||||
tests/test_security.py::test_ts05_telechargement_fichier_dautrui_refuse PASSED [ 47%]
|
||||
tests/test_security.py::test_ts06_seul_caddy_expose_des_ports_publics PASSED [ 50%]
|
||||
tests/test_unit_annonce_service.py::test_ut01_create_annonce_valide PASSED [ 52%]
|
||||
tests/test_unit_annonce_service.py::test_ut02_create_annonce_titre_vide PASSED [ 55%]
|
||||
tests/test_unit_annonce_service.py::test_ut03_create_annonce_contenu_vide PASSED [ 58%]
|
||||
tests/test_unit_annonce_service.py::test_ut04_update_annonce_existante PASSED [ 61%]
|
||||
tests/test_unit_annonce_service.py::test_ut05_update_annonce_inexistante PASSED [ 64%]
|
||||
tests/test_unit_annonce_service.py::test_ut05b_delete_annonce_inexistante PASSED [ 67%]
|
||||
tests/test_unit_auth_service.py::test_ut09_is_admin_avec_groupe_admin PASSED [ 70%]
|
||||
tests/test_unit_auth_service.py::test_ut10_is_admin_sans_groupe_admin PASSED [ 73%]
|
||||
tests/test_unit_auth_service.py::test_ut11_is_admin_utilisateur_none PASSED [ 76%]
|
||||
tests/test_unit_auth_service.py::test_ut12_is_admin_sans_champ_groups PASSED [ 79%]
|
||||
tests/test_unit_fichier_service.py::test_ut06_fichier_trop_grand PASSED [ 82%]
|
||||
tests/test_unit_fichier_service.py::test_ut06b_fichier_vide PASSED [ 85%]
|
||||
tests/test_unit_fichier_service.py::test_ut07_extension_interdite PASSED [ 88%]
|
||||
tests/test_unit_fichier_service.py::test_ut07b_extension_autorisee PASSED [ 91%]
|
||||
tests/test_unit_fichier_service.py::test_ut08_nom_genere_est_unique PASSED [ 94%]
|
||||
tests/test_unit_fichier_service.py::test_ut08b_presence_fichier_absent PASSED [ 97%]
|
||||
tests/test_unit_fichier_service.py::test_upload_complet_end_to_end PASSED [100%]
|
||||
|
||||
============================== 34 passed in 0.54s ==============================
|
||||
113
docs/evidence/radon_cc_output.txt
Normal file
113
docs/evidence/radon_cc_output.txt
Normal file
@@ -0,0 +1,113 @@
|
||||
models/annonce_model.py
|
||||
F 19:0 insert - A (1)
|
||||
F 27:0 fetch_all - A (1)
|
||||
F 35:0 get - A (1)
|
||||
F 43:0 update - A (1)
|
||||
F 53:0 delete - A (1)
|
||||
C 10:0 AnnonceNotFoundError - A (1)
|
||||
models/audit_model.py
|
||||
F 4:0 insert - A (1)
|
||||
F 12:0 fetch_recent - A (1)
|
||||
models/evenement_model.py
|
||||
F 4:0 insert - A (1)
|
||||
F 12:0 fetch_all - A (1)
|
||||
F 20:0 get - A (1)
|
||||
F 28:0 delete - A (1)
|
||||
models/block_model.py
|
||||
F 12:0 _row_to_dict - A (3)
|
||||
F 24:0 fetch_all - A (2)
|
||||
F 33:0 insert - A (1)
|
||||
F 48:0 update_position - A (1)
|
||||
F 55:0 delete - A (1)
|
||||
models/fichier_model.py
|
||||
F 4:0 insert - A (1)
|
||||
F 12:0 fetch_all - A (1)
|
||||
F 20:0 get - A (1)
|
||||
F 28:0 delete - A (1)
|
||||
services/annonce_service.py
|
||||
F 19:0 _validate - B (6)
|
||||
F 39:0 update_annonce - A (2)
|
||||
F 49:0 delete_annonce - A (2)
|
||||
F 28:0 list_annonces - A (1)
|
||||
F 32:0 create_annonce - A (1)
|
||||
C 12:0 ValidationError - A (1)
|
||||
services/auth_service.py
|
||||
F 30:0 is_admin - A (3)
|
||||
F 78:0 client_ip - A (2)
|
||||
F 18:0 current_user - A (1)
|
||||
F 23:0 is_authenticated - A (1)
|
||||
F 45:0 require_login - A (1)
|
||||
F 57:0 require_admin - A (1)
|
||||
services/audit_service.py
|
||||
F 6:0 log - A (1)
|
||||
F 10:0 recent - A (1)
|
||||
services/fichier_service.py
|
||||
F 63:0 step3_check_mime - A (5)
|
||||
F 149:0 delete_fichier - A (5)
|
||||
F 48:0 step2_check_size - A (4)
|
||||
F 77:0 step4_check_extension - A (4)
|
||||
F 132:0 prepare_download - A (4)
|
||||
F 41:0 step1_check_presence - A (3)
|
||||
F 91:0 step6_save_to_disk - A (2)
|
||||
F 86:0 step5_generate_safe_name - A (1)
|
||||
F 105:0 step7_persist_metadata - A (1)
|
||||
F 109:0 step8_log_audit - A (1)
|
||||
F 113:0 handle_upload - A (1)
|
||||
F 128:0 list_fichiers - A (1)
|
||||
C 36:0 FileValidationError - A (1)
|
||||
services/block_service.py
|
||||
F 10:0 add_block - A (3)
|
||||
F 18:0 save_layout - A (2)
|
||||
F 6:0 list_blocks - A (1)
|
||||
F 24:0 delete_block - A (1)
|
||||
services/evenement_service.py
|
||||
F 24:0 create_evenement - A (4)
|
||||
F 13:0 _parse - A (2)
|
||||
F 36:0 delete_evenement - A (2)
|
||||
F 20:0 list_evenements - A (1)
|
||||
C 9:0 ValidationError - A (1)
|
||||
routes/fichiers.py
|
||||
F 36:0 download - A (3)
|
||||
F 51:0 delete - A (3)
|
||||
F 23:0 upload - A (2)
|
||||
F 11:0 _db - A (1)
|
||||
F 17:0 list_fichiers - A (1)
|
||||
routes/auth.py
|
||||
F 24:0 register_oauth - A (1)
|
||||
F 35:0 init_auth_routes - A (1)
|
||||
F 83:0 _get_db - A (1)
|
||||
routes/annonces.py
|
||||
F 39:0 update_annonce - A (4)
|
||||
F 24:0 create_annonce - A (3)
|
||||
F 56:0 delete_annonce - A (2)
|
||||
F 12:0 _db - A (1)
|
||||
F 18:0 list_annonces - A (1)
|
||||
routes/dashboard.py
|
||||
F 16:0 index - A (2)
|
||||
F 34:0 save_layout - A (2)
|
||||
F 41:0 add_block - A (2)
|
||||
F 51:0 delete_block - A (2)
|
||||
F 11:0 _db - A (1)
|
||||
F 23:0 api_is_admin - A (1)
|
||||
F 28:0 get_layout - A (1)
|
||||
routes/evenements.py
|
||||
F 23:0 create_evenement - A (3)
|
||||
F 38:0 delete_evenement - A (2)
|
||||
F 11:0 _db - A (1)
|
||||
F 17:0 list_evenements - A (1)
|
||||
app.py
|
||||
F 20:0 create_app - A (1)
|
||||
F 51:0 register_error_handlers - A (1)
|
||||
F 76:0 _wants_json - A (1)
|
||||
db.py
|
||||
C 25:0 Database - A (3)
|
||||
M 48:4 Database.cursor - A (3)
|
||||
M 68:4 Database.fetch_all - A (2)
|
||||
M 73:4 Database.fetch_one - A (2)
|
||||
M 78:4 Database.execute - A (2)
|
||||
F 85:0 init_db - A (1)
|
||||
M 28:4 Database.__init__ - A (1)
|
||||
M 35:4 Database._connect - A (1)
|
||||
|
||||
92 blocks (classes, functions, methods) analyzed.
|
||||
Average complexity: A (1.7173913043478262)
|
||||
264
docs/evidence/radon_raw_output.txt
Normal file
264
docs/evidence/radon_raw_output.txt
Normal file
@@ -0,0 +1,264 @@
|
||||
models/annonce_model.py
|
||||
LOC: 57
|
||||
LLOC: 22
|
||||
SLOC: 32
|
||||
Comments: 0
|
||||
Single comments: 0
|
||||
Multi: 11
|
||||
Blank: 14
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 19%
|
||||
models/audit_model.py
|
||||
LOC: 17
|
||||
LLOC: 7
|
||||
SLOC: 12
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 4
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
models/__init__.py
|
||||
LOC: 13
|
||||
LLOC: 1
|
||||
SLOC: 0
|
||||
Comments: 0
|
||||
Single comments: 0
|
||||
Multi: 11
|
||||
Blank: 2
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 85%
|
||||
models/evenement_model.py
|
||||
LOC: 32
|
||||
LLOC: 15
|
||||
SLOC: 23
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 8
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
models/block_model.py
|
||||
LOC: 59
|
||||
LLOC: 26
|
||||
SLOC: 41
|
||||
Comments: 0
|
||||
Single comments: 0
|
||||
Multi: 6
|
||||
Blank: 12
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 10%
|
||||
models/fichier_model.py
|
||||
LOC: 32
|
||||
LLOC: 15
|
||||
SLOC: 23
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 8
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
services/annonce_service.py
|
||||
LOC: 55
|
||||
LLOC: 35
|
||||
SLOC: 33
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 5
|
||||
Blank: 16
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 9%
|
||||
services/auth_service.py
|
||||
LOC: 83
|
||||
LLOC: 45
|
||||
SLOC: 36
|
||||
Comments: 0
|
||||
Single comments: 3
|
||||
Multi: 20
|
||||
Blank: 24
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 24%
|
||||
services/audit_service.py
|
||||
LOC: 11
|
||||
LLOC: 6
|
||||
SLOC: 5
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 5
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
services/__init__.py
|
||||
LOC: 1
|
||||
LLOC: 1
|
||||
SLOC: 0
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 0
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
services/fichier_service.py
|
||||
LOC: 160
|
||||
LLOC: 91
|
||||
SLOC: 91
|
||||
Comments: 15
|
||||
Single comments: 14
|
||||
Multi: 21
|
||||
Blank: 34
|
||||
- Comment Stats
|
||||
(C % L): 9%
|
||||
(C % S): 16%
|
||||
(C + M % L): 22%
|
||||
services/block_service.py
|
||||
LOC: 25
|
||||
LLOC: 16
|
||||
SLOC: 14
|
||||
Comments: 0
|
||||
Single comments: 2
|
||||
Multi: 0
|
||||
Blank: 9
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
services/evenement_service.py
|
||||
LOC: 42
|
||||
LLOC: 30
|
||||
SLOC: 29
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 12
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
routes/fichiers.py
|
||||
LOC: 59
|
||||
LLOC: 49
|
||||
SLOC: 45
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 13
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
routes/auth.py
|
||||
LOC: 86
|
||||
LLOC: 41
|
||||
SLOC: 48
|
||||
Comments: 10
|
||||
Single comments: 11
|
||||
Multi: 12
|
||||
Blank: 15
|
||||
- Comment Stats
|
||||
(C % L): 12%
|
||||
(C % S): 21%
|
||||
(C + M % L): 26%
|
||||
routes/annonces.py
|
||||
LOC: 62
|
||||
LLOC: 50
|
||||
SLOC: 48
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 13
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
routes/__init__.py
|
||||
LOC: 6
|
||||
LLOC: 1
|
||||
SLOC: 0
|
||||
Comments: 0
|
||||
Single comments: 0
|
||||
Multi: 5
|
||||
Blank: 1
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 83%
|
||||
routes/dashboard.py
|
||||
LOC: 55
|
||||
LLOC: 40
|
||||
SLOC: 37
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 17
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
routes/evenements.py
|
||||
LOC: 44
|
||||
LLOC: 34
|
||||
SLOC: 32
|
||||
Comments: 0
|
||||
Single comments: 1
|
||||
Multi: 0
|
||||
Blank: 11
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 0%
|
||||
app.py
|
||||
LOC: 85
|
||||
LLOC: 53
|
||||
SLOC: 48
|
||||
Comments: 3
|
||||
Single comments: 3
|
||||
Multi: 11
|
||||
Blank: 23
|
||||
- Comment Stats
|
||||
(C % L): 4%
|
||||
(C % S): 6%
|
||||
(C + M % L): 16%
|
||||
db.py
|
||||
LOC: 93
|
||||
LLOC: 47
|
||||
SLOC: 57
|
||||
Comments: 0
|
||||
Single comments: 3
|
||||
Multi: 17
|
||||
Blank: 16
|
||||
- Comment Stats
|
||||
(C % L): 0%
|
||||
(C % S): 0%
|
||||
(C + M % L): 18%
|
||||
** Total **
|
||||
LOC: 1077
|
||||
LLOC: 625
|
||||
SLOC: 654
|
||||
Comments: 28
|
||||
Single comments: 47
|
||||
Multi: 119
|
||||
Blank: 257
|
||||
- Comment Stats
|
||||
(C % L): 3%
|
||||
(C % S): 4%
|
||||
(C + M % L): 14%
|
||||
BIN
docs/evidence/schema_couches_logiques.png
Normal file
BIN
docs/evidence/schema_couches_logiques.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 88 KiB |
BIN
docs/evidence/schema_infrastructure.png
Normal file
BIN
docs/evidence/schema_infrastructure.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 105 KiB |
BIN
docs/evidence/screenshot_404.png
Normal file
BIN
docs/evidence/screenshot_404.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 17 KiB |
BIN
docs/evidence/screenshot_dashboard_admin.png
Normal file
BIN
docs/evidence/screenshot_dashboard_admin.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 30 KiB |
BIN
docs/evidence/screenshot_dashboard_membre.png
Normal file
BIN
docs/evidence/screenshot_dashboard_membre.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 30 KiB |
Reference in New Issue
Block a user