forked from cloudtools/troposphere
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest_sqs.py
40 lines (31 loc) · 782 Bytes
/
test_sqs.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
import unittest
from troposphere import Join
from troposphere.sqs import Queue
class TestQueue(unittest.TestCase):
def test_QueueName(self):
Queue(
"q",
FifoQueue=False,
).validate()
Queue(
"q",
FifoQueue=True,
QueueName="foobar.fifo",
).validate()
Queue(
"q",
FifoQueue=True,
QueueName=Join("foo", "bar"),
).validate()
Queue(
"q",
FifoQueue=True,
).validate()
with self.assertRaises(ValueError):
Queue(
"q",
FifoQueue=True,
QueueName="foobar",
).validate()
if __name__ == "__main__":
unittest.main()