Add enum support for model property of python client

This commit is contained in:
geekerzp
2015-07-16 17:24:42 +08:00
parent 157b07e552
commit f0e09ae33a
13 changed files with 287 additions and 38 deletions

View File

@@ -0,0 +1,25 @@
# coding: utf-8
"""
Run the tests.
$ pip install nose (optional)
$ cd swagger_client-python
$ nosetests -v
"""
import os
import time
import unittest
import swagger_client
class OrderModelTests(unittest.TestCase):
def test_status(self):
order = swagger_client.Order()
order.status = "placed"
self.assertEqual("placed", order.status)
with self.assertRaises(ValueError):
order.status = "invalid"