Exemplo n.º 1
0
    def test_delete_plan(self):
        p = payjp.Plan(id="pl_delete")
        p.delete()

        self.requestor_mock.request.assert_called_with('delete',
                                                       '/v1/plans/pl_delete',
                                                       {}, None)
Exemplo n.º 2
0
    def test_update_plan(self):
        p = payjp.Plan(id="pl_update")
        p.name = "Plan Name"
        p.save()

        self.requestor_mock.request.assert_called_with('post',
                                                       '/v1/plans/pl_update', {
                                                           'name': 'Plan Name',
                                                       }, None)