Esempio n. 1
0
 def test_20_translipsum_generator_ukrainian_cyrillic(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Ukrainian Cyrillic.
     """
     g_uk = TranslipsumGenerator(language_code='uk')
     res = g_uk.generate_sentence()
     assert res
     return res
Esempio n. 2
0
 def __test_19_translipsum_generator_hebrew(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Hebrew.
     """
     g_he = TranslipsumGenerator(language_code='he')
     res = g_he.generate_sentence()
     assert res
     return res
Esempio n. 3
0
 def test_20_translipsum_generator_cyrillic(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Cyrillic.
     """
     g_ru = TranslipsumGenerator(language_code='ru')
     res = g_ru.generate_sentence()
     assert res
     return res
Esempio n. 4
0
 def test_17_translipsum_generator_georgian(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Georgian.
     """
     g_ge = TranslipsumGenerator(language_code='ka')
     res = g_ge.generate_sentence()
     assert res
     return res
Esempio n. 5
0
 def test_18_translipsum_generator_greek(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Greek.
     """
     g_el = TranslipsumGenerator(language_code='el')
     res = g_el.generate_sentence()
     assert res
     return res
 def test_20_translipsum_generator_ukrainian_cyrillic(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Ukrainian Cyrillic.
     """
     g_uk = TranslipsumGenerator(language_code='uk')
     res = g_uk.generate_sentence()
     assert res
     return res
 def test_20_translipsum_generator_bulgarian_cyrillic(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Bulgarian Cyrillic.
     """
     g_bg = TranslipsumGenerator(language_code='bg')
     res = g_bg.generate_sentence()
     assert res
     return res
 def test_20_translipsum_generator_bulgarian_cyrillic(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Bulgarian Cyrillic.
     """
     g_bg = TranslipsumGenerator(language_code='bg')
     res = g_bg.generate_sentence()
     assert res
     return res
 def __test_19_translipsum_generator_hebrew(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Hebrew.
     """
     g_he = TranslipsumGenerator(language_code='he')
     res = g_he.generate_sentence()
     assert res
     return res
 def test_20_translipsum_generator_cyrillic(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Cyrillic.
     """
     g_ru = TranslipsumGenerator(language_code='ru')
     res = g_ru.generate_sentence()
     assert res
     return res
 def test_18_translipsum_generator_greek(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Greek.
     """
     g_el = TranslipsumGenerator(language_code='el')
     res = g_el.generate_sentence()
     assert res
     return res
 def test_17_translipsum_generator_georgian(self):
     """
     Testing the translipsum generator. Generating lorem ipsum sentence in Georgian.
     """
     g_ge = TranslipsumGenerator(language_code='ka')
     res = g_ge.generate_sentence()
     assert res
     return res
Esempio n. 13
0
print get_available_language_codes()

print '\nTransliteration to Example\n---------------------------------------'
print translit(text, 'example')

print '\nTransliterated lorem ipsum generator \n---------------------------------------'
from transliterate.contrib.apps.translipsum import TranslipsumGenerator
g_am = TranslipsumGenerator(language_code='hy')

print 'Generating paragraphs'
print g_am.generate_paragraph()

g_ru = TranslipsumGenerator(language_code='ru')

print '\nGenerating sentenses'
print g_ru.generate_sentence()

print '\nLanguage detection\n---------------------------------------'
from transliterate.utils import detect_language

print detect_language(u'Լօրեմ իպսում դօլօր սիտ ամետ')

print detect_language(u'Лорем ипсум долор сит амет')

print '\nSlugify\n---------------------------------------'
from transliterate.utils import slugify

print slugify(u'Լօրեմ իպսում դօլօր սիտ ամետ')

print slugify(u'Лорем ипсум долор сит амет')
        )
        browser.visit(
            url +
            '/islandora/object/islandora%3Asp_basic_image_collection/manage/overview/ingest'
        )

        print('\tclicking Next to start submission')
        button = browser.find_by_id('edit-next')
        button.click()

        # Filling out the form.
        print('\tfilling out form')
        browser.fill(
            'titleInfo[title]',
            str(time.strftime("%m/%d/%Y %H:%M:%S")) + ' ' +
            lorem.generate_sentence())
        browser.fill(
            'titleInfo[subTitle]',
            str(time.strftime("%m/%d/%Y %H:%M:%S")) + ' ' +
            lorem.generate_sentence())
        browser.fill('name[0][namePart]', random.choice(name_of_person))
        browser.fill('name[0][role]', random.choice(person_role))
        browser.find_option_by_text(random.choice(type_of_resource)).click()
        browser.fill('genre', random.choice(genre))
        browser.fill('originInfo[dateIssued]', '2018')
        browser.fill('originInfo[publisher]', random.choice(publishers))
        browser.fill('originInfo[country]', random.choice(countries))
        browser.fill('originInfo[place]', random.choice(places))
        browser.fill('language', random.choice(languages))

        browser.fill('abstract', lorem.generate_paragraph())
Esempio n. 15
0
print get_available_language_codes()

print '\nTransliteration to Example\n---------------------------------------'
print translit(text, 'example')

print '\nTransliterated lorem ipsum generator \n---------------------------------------'
from transliterate.contrib.apps.translipsum import TranslipsumGenerator
g_am = TranslipsumGenerator(language_code='hy')

print 'Generating paragraphs'
print g_am.generate_paragraph()

g_ru = TranslipsumGenerator(language_code='ru')

print '\nGenerating sentenses'
print g_ru.generate_sentence()

print '\nLanguage detection\n---------------------------------------'
from transliterate.utils import detect_language

print detect_language(u'Լօրեմ իպսում դօլօր սիտ ամետ')

print detect_language(u'Лорем ипсум долор сит амет')

print '\nSlugify\n---------------------------------------'
from transliterate.utils import slugify

print slugify(u'Լօրեմ իպսում դօլօր սիտ ամետ')

print slugify(u'Лорем ипсум долор сит амет')
Esempio n. 16
0
        print ('\n \t<-------------- ' + str(how_many_submissions_to_submit-counter) + ' -------------->')
        print ('\t' + str(user) + ' is logging in at ' + str(url))
        browser.fill('name', user)
        browser.fill('pass', user)

        # find the search button on the page and click it.
        button = browser.find_by_id('edit-submit')
        button.click()

        # From Profile Page click the collection to submit to.
        print ('\tclicking Submit to Grad Thes')
        browser.click_link_by_text('Submit Graduate Theses and Dissertations')

        # Filling out the form.
        print ('\tfilling out form')
        browser.fill('titleInfo[title]', random.choice(special_chars) + ' ' + str(time.strftime("%m/%d/%Y %H:%M:%S")) + ' ' + lorem.generate_sentence())
        browser.fill('name[namePartGiven]', random.choice(first_names))
        browser.fill('name[namePartFamily]', random.choice(last_names))
        browser.fill('name[namePartTermsofAddress]', random.choice(name_suffix))
        browser.fill('name[valueURI]', '1234-1234-1234-1234')
        browser.find_option_by_text(random.choice(date_of_Award)).first.click()
        browser.find_option_by_text(random.choice(degree_Type)).first.click()
        browser.find_option_by_text(random.choice(department_name)).first.click()
        browser.find_option_by_text(random.choice(discipline)).first.click()

        # Thesis advisor
        browser.fill('advisor[0][namePartGiven]', random.choice(name_of_person))
        browser.fill('advisor[0][namePartFamily]', random.choice(name_of_person))

        # Committee Member
        browser.fill('committee[0][namePartGiven]', random.choice(name_of_person))