Skip to content

Commit

Permalink
Fix failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Hrishabh17 committed Jun 12, 2024
1 parent a72a622 commit a8e50f7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions tests/test_workspaces/test_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,7 @@ def test_export_to_sage300(
add_accounting_export_expenses
):
workspace_id = 1
AccountingExportSummary.objects.create(workspace_id=workspace_id)
accounting_export = AccountingExport.objects.filter(workspace_id=workspace_id).first()

advanced_settings = AdvancedSetting.objects.get(workspace_id=workspace_id)
Expand Down
4 changes: 3 additions & 1 deletion tests/test_workspaces/test_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from django.urls import reverse
from fyle_accounting_mappings.models import MappingSetting

from apps.accounting_exports.models import AccountingExport
from apps.accounting_exports.models import AccountingExport, AccountingExportSummary
from apps.workspaces.models import (
Workspace,
Sage300Credential,
Expand Down Expand Up @@ -425,6 +425,8 @@ def test_trigger_export(
"""
Test Export Trigger API
"""
workspace_id = 1
AccountingExportSummary.objects.create(workspace_id=workspace_id)

url = reverse('trigger-exports', kwargs={'workspace_id': 1})
api_client.credentials(HTTP_AUTHORIZATION='Bearer {}'.format(test_connection.access_token))
Expand Down

0 comments on commit a8e50f7

Please sign in to comment.