switched to decimal to address python 2.6/2.7 compatibility bug

pull/1/head
Andromeda Yelton 2011-10-13 12:21:53 -04:00
parent 63203ae129
commit 3773a6dd9c
1 changed files with 2 additions and 1 deletions

View File

@ -1,3 +1,4 @@
from decimal import Decimal
from random import randint, randrange
from datetime import datetime, timedelta
@ -18,7 +19,7 @@ class Command(BaseCommand):
campaign.description = "Test Campaign"
# random campaign target between $200 and $10,000
campaign.target = float(randint(200,10000))
campaign.target = Decimal(str(randint(200,10000)))
# random deadline between 5 days from now and 180 days from now
now = datetime.now()