Skip to content
This repository has been archived by the owner on Feb 8, 2018. It is now read-only.

Commit

Permalink
Failing test for including team members in grprbn
Browse files Browse the repository at this point in the history
  • Loading branch information
chadwhitacre committed Sep 1, 2016
1 parent 35ef115 commit 139196a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gratipay/testing/billing.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ def setUp(self):
braintree_customer_id=self.obama_bt_id)
self.obama_route = ExchangeRoute.insert(self.obama, 'braintree-cc', self.obama_cc_token)
# A customer with Paypal attached.
self.homer = self.make_participant('homer', is_suspicious=False,
claimed_time='now')
self.homer = self.make_participant('homer', is_suspicious=False, verified_in='US',
claimed_time='now', email_address='[email protected]')
self.homer_route = ExchangeRoute.insert(self.homer, 'paypal', '[email protected]')


Expand Down
8 changes: 8 additions & 0 deletions tests/py/test_billing_exchanges.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,14 @@ def test_grprbn_includes_team_owners(self):
routes = get_ready_payout_routes_by_network(self.db, 'paypal')
assert [r.participant.username for r in routes] == ['picard']

def test_grprbn_includes_team_members(self):
enterprise = self.make_team(is_approved=True, available=50)
enterprise.add_member(self.homer, P('picard')) # add a member
self.obama.set_payment_instruction(enterprise, 100)
self.run_payday()
routes = get_ready_payout_routes_by_network(self.db, 'paypal')
assert [r.participant.username for r in routes] == ['homer', 'picard']

def test_grprbn_includes_1_0_payouts(self):
alice = self.make_participant('alice', balance=24, status_of_1_0_payout='pending-payout')
ExchangeRoute.insert(alice, 'paypal', '[email protected]')
Expand Down

0 comments on commit 139196a

Please sign in to comment.