diff options
author | Tomasz Zielinski <tomasz.zielinski@pyconsultant.eu> | 2012-01-14 00:01:43 +0100 |
---|---|---|
committer | Tomasz Zielinski <tomasz.zielinski@pyconsultant.eu> | 2012-01-14 00:01:43 +0100 |
commit | 849464ff7b3e754055a0e16617edb427dab9729b (patch) | |
tree | 3b20e70e1b58be2cffaad70a221fae4bcc25aca9 | |
parent | d71964cfc70b351015922d7f0e04e53d337459bb (diff) | |
parent | b6ba1415689a034c320aa1ad3952878ad42d3f93 (diff) | |
download | askbot-849464ff7b3e754055a0e16617edb427dab9729b.tar.gz askbot-849464ff7b3e754055a0e16617edb427dab9729b.tar.bz2 askbot-849464ff7b3e754055a0e16617edb427dab9729b.zip |
Merge remote-tracking branch 'askbot/wikipost' into wikipost
-rw-r--r-- | askbot/management/commands/askbot_add_test_content.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/askbot/management/commands/askbot_add_test_content.py b/askbot/management/commands/askbot_add_test_content.py index 7295e1de..6b14df59 100644 --- a/askbot/management/commands/askbot_add_test_content.py +++ b/askbot/management/commands/askbot_add_test_content.py @@ -76,7 +76,8 @@ class Command(NoArgsCommand): active_question = None last_vote = False # Each user posts a question - for user in users[:NUM_QUESTIONS]: + for i in range(NUM_QUESTIONS): + user = users[i] # Downvote/upvote the questions - It's reproducible, yet # gives good randomized data if not active_question is None: @@ -94,6 +95,8 @@ class Command(NoArgsCommand): # len(TAGS_TEMPLATE) tags per question - each tag is different tags = " ".join([t%user.id for t in TAGS_TEMPLATE]) + if i < NUM_QUESTIONS/2: + tags += ' one-tag' active_question = user.post_question( title = TITLE_TEMPLATE % user.id, body_text = CONTENT_TEMPLATE, |