Skip to content
This repository has been archived by the owner on May 13, 2024. It is now read-only.

Commit

Permalink
Merge pull request #944 from trowik/disable-stats
Browse files Browse the repository at this point in the history
chore(reports): disable project and customer statistics
  • Loading branch information
trowik authored Feb 27, 2023
2 parents 7e8dd0b + a8994c8 commit 7dbb343
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
3 changes: 3 additions & 0 deletions timed/reports/tests/test_customer_statistic.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
from timed.tracking.factories import ReportFactory


@pytest.mark.xfail(reason="Endpoint disabled")
@pytest.mark.parametrize(
"is_employed, is_customer_assignee, is_customer, expected, status_code",
[
Expand Down Expand Up @@ -71,6 +72,7 @@ def test_customer_statistic_list(
assert json["meta"]["total-time"] == "07:00:00"


@pytest.mark.xfail(reason="Endpoint disabled")
@pytest.mark.parametrize(
"filter, expected_result",
[("from_date", 5), ("customer", 3), ("cost_center", 3), ("reviewer", 3)],
Expand Down Expand Up @@ -114,6 +116,7 @@ def test_customer_statistic_filtered(auth_client, filter, expected_result):
assert json["meta"]["total-time"] == f"{expected_result:02}:00:00"


@pytest.mark.xfail(reason="Endpoint disabled")
@pytest.mark.parametrize(
"is_employed, expected, status_code",
[
Expand Down
2 changes: 2 additions & 0 deletions timed/reports/tests/test_project_statistic.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
from timed.tracking.factories import ReportFactory


@pytest.mark.xfail(reason="Endpoint disabled")
@pytest.mark.parametrize(
"is_employed, is_customer_assignee, is_customer, expected, status_code",
[
Expand Down Expand Up @@ -104,6 +105,7 @@ def test_project_statistic_list(
assert json["meta"]["total-time"] == "09:00:00"


@pytest.mark.xfail(reason="Endpoint disabled")
@pytest.mark.parametrize(
"filter, expected_result",
[("from_date", 5), ("customer", 3), ("cost_center", 3), ("reviewer", 3)],
Expand Down
4 changes: 2 additions & 2 deletions timed/reports/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
r.register(r"month-statistics", views.MonthStatisticViewSet, "month-statistic")
r.register(r"task-statistics", views.TaskStatisticViewSet, "task-statistic")
r.register(r"user-statistics", views.UserStatisticViewSet, "user-statistic")
r.register(r"customer-statistics", views.CustomerStatisticViewSet, "customer-statistic")
r.register(r"project-statistics", views.ProjectStatisticViewSet, "project-statistic")
# r.register(r"customer-statistics", views.CustomerStatisticViewSet, "customer-statistic")
# r.register(r"project-statistics", views.ProjectStatisticViewSet, "project-statistic")

urlpatterns = r.urls

0 comments on commit 7dbb343

Please sign in to comment.