From 51e3a8f7b61ce9377aea024b7214d87213d132d0 Mon Sep 17 00:00:00 2001 From: David Stenglein Date: Thu, 4 Feb 2016 08:08:53 -0500 Subject: [PATCH] gh-124 Fix for original PR, unit tests had flaw that hid non-working code for copying board. --- test/test_board.py | 2 +- trello/trelloclient.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/test_board.py b/test/test_board.py index b90d9bb4..7400307b 100644 --- a/test/test_board.py +++ b/test/test_board.py @@ -117,7 +117,7 @@ def test110_copy_board(self): listed_boards = self._trello.list_boards(board_filter="open") copied_board = next(iter([x for x in listed_boards if x.name == "copied_board"]), None) self.assertIsNotNone(copied_board) - open_lists = source_board.open_lists() + open_lists = copied_board.open_lists() self.assertEqual(len(open_lists), 4) # default lists plus mine test_list = open_lists[0] self.assertEqual(len(test_list.list_cards()), 1) diff --git a/trello/trelloclient.py b/trello/trelloclient.py index ccf46417..c5d42675 100644 --- a/trello/trelloclient.py +++ b/trello/trelloclient.py @@ -131,7 +131,7 @@ def add_board(self, board_name, source_board=None): post_args['idBoardSource'] = source_board.id obj = self.fetch_json('/boards', http_method='POST', - post_args={'name': board_name}) + post_args=post_args) return Board.from_json(self, json_obj=obj) def get_member(self, member_id):