Koha-clms/t
Tomas Cohen Arazi f2b53042bd Bug 19337: Make basic_workflow.t configurable through ENV
This patch makes the basic_workflow.t selenium tests read ENV for the
following vars:

KOHA_USER
KOHA_PASS
KOHA_INTRANET_URL
SELENIUM_ADDR
SELENIUM_PORT

to properly configure the running environment. If absent, all variables
fallback to current behaviour:

KOHA_USER // 'koha'
KOHA_PASS // 'koha'
KOHA_INTRANET_URL (unchanged)
SELENIUM_ADDR // 'localhost'
SELENIUM_PORT // 4444

[*] Selenium defaults are documented on the Selenium::Remote::Driver docs.

Prerequisites:
Make sure you have a working environment for the Selenium tests:
- Run:
  $ sudo apt update
  $ sudo apt install xvfb firefox-esr

To test:
- Run:
  $ sudo koha-shell kohadev
 k$ cd kohaclone
 k$ wget https://selenium-release.storage.googleapis.com/2.53/selenium-server-standalone-2.53.1.jar \
     -O /tmp/selenium.jar
 k$ SELENIUM_PATH=/tmp/selenium.jar
 k$ Xvfb :1 -screen 0 1024x768x24 2>&1 >/dev/null &
 k$ DISPLAY=:1 java -jar $SELENIUM_PATH &
 k$ prove t/db_dependent/selenium/basic_workflow.t
=> SUCCESS: Tests pass
- Apply this patch
- Run:
 k$ prove t/db_dependent/selenium/basic_workflow.t
=> SUCCESS: Tests pass!
- Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 5bb19808bb)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2017-10-23 16:39:18 +02:00
..
Acquisition Bug 18756 - add Unit Test 2017-07-10 12:38:17 +02:00
Biblio Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Budgets
…
Circulation Bug 17557: Koha::Patrons - Move GetAge to ->set_age (and remove SetAge) 2016-12-16 11:57:38 +00:00
External Bug 16636 [QA Followup] - Move tests to t/External 2016-06-10 18:02:14 +00:00
Koha Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Members Bug 15690: Hardcoded 16 is uncool 2016-11-14 11:28:43 +00:00
Number Bug 18900: (QA followup) Make tests conditional to locale existence 2017-09-12 16:02:02 +02:00
SIP Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Search Bug 16976 - Unit tests 2017-09-06 15:17:49 +02:00
Serials Bug 16289: Refactore code and add tests 2016-06-10 18:09:48 +00:00
db_dependent Bug 19337: Make basic_workflow.t configurable through ENV 2017-10-23 16:39:18 +02:00
edi_testfiles Bug 7736: Support Ordering via Edifact EDI messages 2016-04-01 20:03:17 +00:00
lib Bug 19003: Add a TestBuilder default for borrowers.login_attempts 2017-09-29 11:08:38 +02:00
00-checkdatabase-version.t
…
00-deprecated.t
…
00-load.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
00-merge-conflict-markers.t Bug 19335: Fix 00-merge-conflict-markers.t when dockerised 2017-10-03 09:00:59 +02:00
00-testcritic.t
…
00-valid-xml.t Bug 16608 - Add xsd extension to t/00-valid-xml.t 2016-06-10 17:40:55 +00:00
AuthUtils.t
…
Auth_with_shibboleth.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
AuthoritiesMarc_MARC21.t
…
AuthoritiesMarc_UNIMARC.t
…
Barcodes_EAN13.t
…
Barcodes_annual.t
…
Barcodes_hbyymmincr.t
…
Barcodes_incremental.t
…
Biblio.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Biblio2.t Bug 16556 - KohaToMarcMapped columns sharing same field with biblio(item)number are removed. 2016-09-15 13:42:35 +00:00
Bookseller.t
…
Boolean.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Breeding.t
…
Budgets.t
…
Cache.t Bug 16769: Uniformise calls to Koha::Cache->set_in_cache 2016-10-10 17:03:54 +00:00
Calendar.t Bug 19385: Fix random t/Calendar.t failure - clear the cache before 2017-10-03 15:59:03 +02:00
Charset.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Circulation_barcodedecode.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
ClassSortRoutine.t
…
ClassSortRoutine_Dewey.t
…
ClassSortRoutine_Generic.t
…
ClassSortRoutine_LCC.t
…
ClassSource.t
…
Context.t Bug 14751: [QA Follow-up] Unit tests for interface method 2016-03-02 04:21:26 +00:00
Contract.t
…
Creators.t Bug 16622: some tests triggered by prove t fail for unset KOHA_CONF 2016-08-05 06:09:58 +00:00
DateUtils.t Bug 17502: Throw some exceptions in output_pref 2017-04-21 07:36:25 -04:00
Debug.t
…
EdiInvoice.t Bug 7736: Support Ordering via Edifact EDI messages 2016-04-01 20:03:17 +00:00
Edifact.t Bug 7736: Support Ordering via Edifact EDI messages 2016-04-01 20:03:17 +00:00
Ediorder.t Bug 7736: Support Ordering via Edifact EDI messages 2016-04-01 20:03:17 +00:00
Ediordrsp.t Bug 7736: Support Ordering via Edifact EDI messages 2016-04-01 20:03:17 +00:00
Form_MessagingPreferences.t
…
Heading.t
…
Images.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
ImportBatch.t Bug 10407: Add two subtests to t/ImportBatch.t 2016-09-02 16:00:13 +00:00
Installer_PerlDependencies.t
…
Installer_PerlModules.t Bug 17990: Refactor Perl module versions check 2017-02-17 12:13:44 +00:00
Installer_pm.t Bug 17990: Refactor Perl module versions check 2017-02-17 12:13:44 +00:00
ItemCirculationAlertPreference.t
…
Koha.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Koha_Email.t
…
Koha_ExternalContent_OverDrive.t Bug 18243: 16034 follow-up: better handling of absence of WebService::ILS::OverDrive::Patron at testing 2017-03-20 15:28:35 +00:00
Koha_MetadataRecord.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Koha_Template_Plugin_Cache.t
…
Koha_Template_Plugin_Koha.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Koha_Util_FrameworkPlugin.t
…
Koha_Util_MARC.t
…
Labels.t
…
Labels_split_ccn.t
…
Labels_split_ddcn.t
…
Labels_split_lccn.t
…
Languages.t Bug 16675: fix breakage of t/Languages.t 2016-06-10 17:03:10 +00:00
Letters.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Log.t
…
Logger.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Makefile.t Bug 19067: Test Makefile.PL mapping 2017-09-12 16:04:16 +02:00
Matcher.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Members_AttributeTypes.t Bug 17825: (followup) Remove unused function AttributeTypeExists 2017-03-31 14:37:21 +00:00
Members_Attributes.t Bug 12267: Remove borrower_attributes.password 2016-04-22 23:08:32 +00:00
Members_Messaging.t
…
Message.t
…
NorwegianPatronDB.t
…
OpenLibrarySearch.t Bug 16649: Make OpenLibrarySearch test pass even if launches offline 2016-06-10 17:05:03 +00:00
Output.t
…
Output_JSONStream.t
…
Overdues.t
…
Patron.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Patroncards.t
…
Patroncards_Batch.t
…
Patroncards_Layout.t
…
Patroncards_Lib.t
…
Patroncards_Patroncard.t
…
Patroncards_Profile.t
…
Patroncards_Template.t
…
Prices.t Bug 13726: Make Koha::Acq::Bookseller using Koha::Object 2016-12-30 11:54:32 +00:00
Print.t
…
QueryParser.t
…
RecordProcessor.t Bug 15871: Improve PerlCritic level for t/RecordProcessor.t 2016-03-03 22:02:50 +00:00
Ris.t Bug 16668: Fix t/Ris.t tests 2016-06-10 16:59:20 +00:00
RotatingCollections.t
…
SMS.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Scheduler.t
…
Scrubber.t
…
Search.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Search_PazPar2.t
…
SimpleMARC.t
…
SocialData.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
Stats.t
…
SuggestionEngine.t
…
SuggestionEngine_AuthorityFile.t Bug 9857: Fix failing tests 2017-10-03 11:13:53 +02:00
TmplToken.t
…
Token.t Bug 18124: [Follow-up] Handle default parameters in a sub 2017-03-30 09:07:08 +00:00
XSLT.t Bug 18292: Remove return 1 statements in tests 2017-09-29 12:02:21 +02:00
dummy.t
…
perlcriticrc
…
smolder_smoke_signal
…