Enhance Skill Scoring and Profile Functionality
Deploy Development / deploy (push) Successful in 43s
Test Suite / pytest-backend (push) Successful in 42s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 13s
Test Suite / k6 /health Baseline (push) Successful in 33s
Test Suite / playwright-tests (push) Successful in 1m15s
Deploy Development / deploy (push) Successful in 43s
Test Suite / pytest-backend (push) Successful in 42s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 13s
Test Suite / k6 /health Baseline (push) Successful in 33s
Test Suite / playwright-tests (push) Successful in 1m15s
- Introduced a new function to calculate club-specific skill percentages, ensuring values are capped at 100%. - Updated skill profile calculations to include indicators for the best club performance per skill. - Enhanced frontend components to display club best indicators and improved layout for skill profiles. - Refactored CSS styles for skill profile components, ensuring a more cohesive and user-friendly interface. - Updated tests to validate new functionality and ensure accurate representation of skill metrics.
This commit is contained in:
1 parent
78c6c51520
commit
9a0cf7f823
9 files changed
+312
-189
No files matched your search
@@ -3,6 +3,7 @@ from skill_scoring import (
|
||||
ExerciseOccurrence,
|
||||
compute_skill_profile,
|
||||
match_score_for_skill_ids,
|
||||
_club_universal_percent,
|
||||
_level_range_multiplier,
|
||||
_skill_link_multiplier,
|
||||
)
|
||||
@@ -97,8 +98,15 @@ def test_universal_percent_against_corpus_max():
|
||||
)
|
||||
assert profile["has_reference_scale"] is True
|
||||
assert profile["skills"][0]["universal_percent"] == 50.0
|
||||
top = profile["by_main_category"][0]["categories"][0]["top_skill"]
|
||||
assert top["universal_percent"] == 50.0
|
||||
assert profile["skills"][0]["is_club_best_for_skill"] is False
|
||||
|
||||
|
||||
def test_club_universal_percent_capped_at_100():
|
||||
pct, is_best = _club_universal_percent(150.0, 100.0)
|
||||
assert pct == 100.0
|
||||
assert is_best is True
|
||||
pct2, _ = _club_universal_percent(72.6, 100.0)
|
||||
assert pct2 == 72.6
|
||||
|
||||
|
||||
def test_match_score_for_skill_ids():
|
||||
|
||||
Reference in new issue
Block a user