19 lines
416 B
Python
19 lines
416 B
Python
|
import main
|
||
|
import random
|
||
|
import secrets
|
||
|
|
||
|
import lorem
|
||
|
|
||
|
for i in range(0, 100):
|
||
|
|
||
|
|
||
|
t = lorem.get_word(count=random.randint(1,16))
|
||
|
|
||
|
a = main.Article()
|
||
|
a.name = 'testpop-' + t.lower().replace(' ', '-')[:254]
|
||
|
a.title = t.title()[:254]
|
||
|
a.teaser = lorem.get_paragraph(count=1)
|
||
|
a.text = lorem.get_paragraph(count=random.randint(2,8), sep='\n\n')
|
||
|
a.published = True
|
||
|
a.save(force_insert=True)
|