1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-13 22:54:25 +01:00
invoiceninja/tests/acceptance/AllPagesCept.php

95 lines
1.9 KiB
PHP
Raw Normal View History

2016-06-09 10:27:22 +02:00
<?php
2015-08-20 17:09:04 +02:00
$I = new AcceptanceTester($scenario);
2015-09-01 20:40:30 +02:00
$I->checkIfLogin($I);
2015-08-20 17:09:04 +02:00
$I->wantTo('Test all pages load');
2016-08-02 12:44:36 +02:00
// Check all language files
$count = $I->grabNumRecords('languages');
for ($i=1; $i<=$count; $i++) {
$locale = $I->grabFromDatabase('languages', 'locale', ['id' => $i]);
$I->amOnPage("/dashboard?lang={$locale}");
$I->seeElement('.navbar-brand');
}
2015-08-20 17:09:04 +02:00
// Top level navigation
2016-08-02 12:44:36 +02:00
$I->amOnPage('/dashboard?lang=en');
2015-08-20 17:09:04 +02:00
$I->see('Total Revenue');
$I->amOnPage('/clients');
$I->see('Clients', 'li');
$I->amOnPage('/clients/create');
$I->see('Clients', 'li');
$I->see('Create');
$I->amOnPage('/credits');
$I->see('Credits', 'li');
$I->amOnPage('/credits/create');
$I->see('Credits', 'li');
$I->see('Create');
$I->amOnPage('/tasks');
$I->see('Tasks', 'li');
$I->amOnPage('/tasks/create');
$I->see('Tasks', 'li');
$I->see('Create');
$I->amOnPage('/invoices');
$I->see('Invoices', 'li');
$I->amOnPage('/invoices/create');
$I->see('Invoices', 'li');
$I->see('Create');
$I->amOnPage('/quotes');
$I->see('Quotes', 'li');
$I->amOnPage('/quotes/create');
$I->see('Quotes', 'li');
$I->see('Create');
$I->amOnPage('/payments');
$I->see('Payments', 'li');
$I->amOnPage('/payments/create');
$I->see('Payments', 'li');
$I->see('Create');
// Settings pages
2015-10-14 16:15:39 +02:00
$I->amOnPage('/settings/company_details');
2015-08-20 17:09:04 +02:00
$I->see('Details');
2016-06-09 10:27:22 +02:00
//$I->amOnPage('/gateways/create');
//$I->see('Add Gateway');
2015-08-20 17:09:04 +02:00
2015-10-14 16:15:39 +02:00
$I->amOnPage('/settings/products');
2015-08-20 17:09:04 +02:00
$I->see('Product Settings');
2015-10-14 16:15:39 +02:00
$I->amOnPage('/settings/import_export');
2015-08-20 17:09:04 +02:00
$I->see('Import');
2015-10-14 16:15:39 +02:00
$I->amOnPage('/settings/invoice_settings');
2015-08-20 17:09:04 +02:00
$I->see('Invoice Fields');
2015-10-14 16:15:39 +02:00
$I->amOnPage('/settings/invoice_design');
2015-08-20 17:09:04 +02:00
$I->see('Invoice Design');
2015-10-14 16:15:39 +02:00
$I->amOnPage('/settings/templates_and_reminders');
2015-08-20 17:09:04 +02:00
$I->see('Invoice Email');
2017-01-22 11:39:40 +01:00
$I->amOnPage('/reports');
$I->see('Reports');
2015-08-20 17:09:04 +02:00
2017-03-09 16:48:21 +01:00
$I->amOnPage('/check_data');
$I->see('success');
2015-08-20 17:09:04 +02:00
//try to logout
2016-03-15 12:13:46 +01:00
//$I->click('#myAccountButton');
//$I->see('Log Out');
//$I->click('Log Out');