From fb9400ed09bd03f83398e89ff73beea162f258c7 Mon Sep 17 00:00:00 2001 From: kraju3 Date: Thu, 30 May 2024 09:40:01 -0500 Subject: [PATCH] fixing tests and formatting --- nylas/models/folders.py | 1 - nylas/resources/folders.py | 4 +++- tests/resources/test_folders.py | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/nylas/models/folders.py b/nylas/models/folders.py index 2196034b..33ade3f5 100644 --- a/nylas/models/folders.py +++ b/nylas/models/folders.py @@ -88,4 +88,3 @@ class ListFolderQueryParams(ListQueryParams): """ parent_id: NotRequired[str] - diff --git a/nylas/resources/folders.py b/nylas/resources/folders.py index 61a3ae18..0dfccdda 100644 --- a/nylas/resources/folders.py +++ b/nylas/resources/folders.py @@ -1,3 +1,5 @@ +from typing import Optional + from nylas.config import RequestOverrides from nylas.handler.api_resources import ( ListableApiResource, @@ -31,7 +33,7 @@ class Folders( def list( self, identifier: str, - query_params: ListFolderQueryParams, + query_params: Optional[ListFolderQueryParams] = None, overrides: RequestOverrides = None, ) -> ListResponse[Folder]: """ diff --git a/tests/resources/test_folders.py b/tests/resources/test_folders.py index c1443c8c..955e3ee1 100644 --- a/tests/resources/test_folders.py +++ b/tests/resources/test_folders.py @@ -38,7 +38,7 @@ def test_folder_deserialization(self): def test_list_folders(self, http_client_list_response): folders = Folders(http_client_list_response) - folders.list(identifier="abc-123") + folders.list(identifier="abc-123",query_params=None) http_client_list_response._execute.assert_called_once_with( "GET", "/v3/grants/abc-123/folders", None, None, None, overrides=None