.gitlab-ci.yml 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746
  1. image: registry.znuny.com/docker/zammad-application:latest
  2. # Global variables added to the ENV of each job
  3. variables:
  4. # for faster translation loading
  5. Z_LOCALES: "en-us:de-de"
  6. # Browser tests and variables
  7. RAILS_SERVE_STATIC_FILES: "true"
  8. REMOTE_URL: "http://selenium:24444/wd/hub"
  9. TZ: "Europe/London"
  10. # docker elgalu/selenium variables for parallel browser instance creation
  11. MAX_INSTANCES: "50"
  12. MAX_SESSIONS: "50"
  13. # docker-imap-devel variables required for browser tests
  14. MAILNAME: "mail.test.dc.zammad.com"
  15. MAILBOX_INIT: "zammad@mail.test.dc.zammad.com:zammad"
  16. MAIL_ADDRESS: "zammad@mail.test.dc.zammad.com"
  17. MAIL_PASS: "zammad"
  18. # Artifacts are stored for failed jobs for 2 days
  19. .artifacts_error_template: &artifacts_error
  20. artifacts:
  21. expire_in: 2 days
  22. when: on_failure
  23. paths:
  24. - tmp/screenshot*
  25. - tmp/screenshots/*
  26. - log/*.log
  27. # Workaround to enable usage of mixed SSH and Docker GitLab CI runners
  28. .docker_env_template: &docker_env
  29. tags:
  30. - docker
  31. .base_env_template: &base_env
  32. <<: *docker_env
  33. <<: *artifacts_error
  34. # General required Docker services for different DB envs
  35. .services_mysql_template: &services_mysql
  36. services:
  37. - name: registry.znuny.com/docker/zammad-mysql:latest
  38. alias: mysql
  39. .services_postgresql_template: &services_postgresql
  40. services:
  41. - name: registry.znuny.com/docker/zammad-postgresql:latest
  42. alias: postgresql
  43. # Initialize env
  44. before_script:
  45. - test ${CI_JOB_STAGE} != 'pre' && bundle install -j $(nproc)
  46. - test ${CI_JOB_STAGE} != 'pre' && ruby script/build/database_config.rb
  47. stages:
  48. - pre
  49. - test
  50. - browser-core
  51. - browser-integration
  52. # pre stage
  53. # Workaround to enable usage of mixed SSH and Docker GitLab CI runners
  54. .pre_stage_template: &pre_stage
  55. <<: *docker_env
  56. stage: pre
  57. pre:rubocop:
  58. <<: *pre_stage
  59. script:
  60. - bundle install -j $(nproc)
  61. - bundle exec rubocop
  62. pre:coffeelint:
  63. <<: *pre_stage
  64. script:
  65. - coffeelint app/
  66. pre:bundle-audit:
  67. <<: *pre_stage
  68. script:
  69. - gem install bundler-audit
  70. - bundle-audit update
  71. - bundle-audit
  72. pre:github:
  73. <<: *pre_stage
  74. tags:
  75. - deploy
  76. script:
  77. - script/build/sync_repo.sh git@github.com:zammad/zammad.git
  78. # test stage
  79. ## RSpec
  80. .script_rspec_template: &script_rspec_definition
  81. <<: *base_env
  82. variables:
  83. RAILS_ENV: "test"
  84. script:
  85. - rake zammad:db:init
  86. - bundle exec rspec -t ~type:system
  87. test:rspec:mysql:
  88. stage: test
  89. <<: *services_mysql
  90. <<: *script_rspec_definition
  91. test:rspec:postgresql:
  92. stage: test
  93. <<: *services_postgresql
  94. <<: *script_rspec_definition
  95. ## Unit and Controller tests
  96. .script_unit_template: &script_unit_definition
  97. <<: *base_env
  98. variables:
  99. RAILS_ENV: "test"
  100. script:
  101. - rake zammad:db:init
  102. - rake test:units
  103. - ruby -I test/ test/integration/object_manager_test.rb
  104. - ruby -I test/ test/integration/package_test.rb
  105. test:unit:mysql:
  106. stage: test
  107. <<: *services_mysql
  108. <<: *script_unit_definition
  109. test:unit:postgresql:
  110. stage: test
  111. <<: *services_postgresql
  112. <<: *script_unit_definition
  113. ## Integration tests
  114. .test_integration_template: &test_integration_definition
  115. <<: *base_env
  116. <<: *services_postgresql
  117. stage: test
  118. variables:
  119. RAILS_ENV: "test"
  120. test:integration:email_helper_deliver:
  121. <<: *test_integration_definition
  122. script:
  123. - rake zammad:db:unseeded
  124. - ruby -I test/ test/integration/email_helper_test.rb
  125. - ruby -I test/ test/integration/email_deliver_test.rb
  126. - ruby -I test/ test/integration/email_keep_on_server_test.rb
  127. test:integration:facebook:
  128. <<: *test_integration_definition
  129. script:
  130. - rake zammad:db:init
  131. - ruby -I test/ test/integration/facebook_test.rb
  132. allow_failure: true
  133. test:integration:geo:
  134. <<: *test_integration_definition
  135. script:
  136. - rake zammad:db:unseeded
  137. - ruby -I test/ test/integration/geo_calendar_test.rb
  138. - ruby -I test/ test/integration/geo_location_test.rb
  139. - ruby -I test/ test/integration/geo_ip_test.rb
  140. test:integration:user_agent:
  141. <<: *test_integration_definition
  142. script:
  143. - rake zammad:db:unseeded
  144. - ruby -I test/ test/integration/user_agent_test.rb
  145. - export ZAMMAD_PROXY_TEST=true
  146. - ruby -I test/ test/integration/user_agent_test.rb
  147. allow_failure: true
  148. test:integration:slack:
  149. <<: *test_integration_definition
  150. script:
  151. - rake zammad:db:unseeded
  152. - echo "gem 'slack-api'" >> Gemfile.local
  153. - bundle install -j $(nproc)
  154. - ruby -I test test/integration/slack_test.rb
  155. test:integration:clearbit:
  156. <<: *test_integration_definition
  157. script:
  158. - rake zammad:db:unseeded
  159. - ruby -I test test/integration/clearbit_test.rb
  160. allow_failure: true
  161. ### Elasticsearch
  162. .script_elasticsearch_template: &script_elasticsearch_definition
  163. <<: *base_env
  164. stage: test
  165. variables:
  166. RAILS_ENV: "test"
  167. ES_INDEX_RAND: "true"
  168. ES_URL: "http://elasticsearch:9200"
  169. script:
  170. - rake zammad:db:unseeded
  171. - ruby -I test/ test/integration/elasticsearch_active_test.rb
  172. - ruby -I test/ test/integration/elasticsearch_test.rb
  173. - ruby -I test/ test/integration/report_test.rb
  174. - bundle exec rspec --tag searchindex
  175. test:integration:es_mysql:
  176. <<: *script_elasticsearch_definition
  177. services:
  178. - name: registry.znuny.com/docker/zammad-mysql:latest
  179. alias: mysql
  180. - name: registry.znuny.com/docker/zammad-elasticsearch:latest
  181. alias: elasticsearch
  182. test:integration:es_postgresql:
  183. <<: *script_elasticsearch_definition
  184. services:
  185. - name: registry.znuny.com/docker/zammad-postgresql:latest
  186. alias: postgresql
  187. - name: registry.znuny.com/docker/zammad-elasticsearch:latest
  188. alias: elasticsearch
  189. ### Zendesk
  190. .script_integration_zendesk_template: &script_integration_zendesk_definition
  191. <<: *base_env
  192. <<: *services_postgresql
  193. stage: test
  194. variables:
  195. RAILS_ENV: "test"
  196. script:
  197. - rake zammad:db:unseeded
  198. - ruby -I test/ test/integration/zendesk_import_test.rb
  199. allow_failure: true
  200. test:integration:zendesk_mysql:
  201. <<: *services_mysql
  202. <<: *script_integration_zendesk_definition
  203. test:integration:zendesk_postgresql:
  204. <<: *services_postgresql
  205. <<: *script_integration_zendesk_definition
  206. ### OTRS
  207. .script_integration_otrs_template: &script_integration_otrs_definition
  208. <<: *base_env
  209. stage: test
  210. script:
  211. - rake zammad:db:unseeded
  212. - ruby -I test/ test/integration/otrs_import_test.rb
  213. .variables_integration_otrs_6_template: &variables_integration_otrs_6_definition
  214. variables:
  215. RAILS_ENV: "test"
  216. IMPORT_OTRS_ENDPOINT: "https://vz1185.test.znuny.com/otrs/public.pl?Action=ZammadMigrator"
  217. test:integration:otrs_6_mysql:
  218. <<: *services_mysql
  219. <<: *script_integration_otrs_definition
  220. <<: *variables_integration_otrs_6_definition
  221. test:integration:otrs_6_postgresql:
  222. <<: *services_postgresql
  223. <<: *script_integration_otrs_definition
  224. <<: *variables_integration_otrs_6_definition
  225. test:integration:otrs_5:
  226. <<: *services_postgresql
  227. variables:
  228. RAILS_ENV: "test"
  229. IMPORT_OTRS_ENDPOINT: "http://vz1109.demo.znuny.com/otrs/public.pl?Action=ZammadMigrator"
  230. <<: *script_integration_otrs_definition
  231. test:integration:otrs_4:
  232. <<: *services_postgresql
  233. variables:
  234. RAILS_ENV: "test"
  235. IMPORT_OTRS_ENDPOINT: "http://vz383.demo.znuny.com/otrs/public.pl?Action=ZammadMigrator"
  236. <<: *script_integration_otrs_definition
  237. test:integration:otrs_33:
  238. <<: *services_postgresql
  239. variables:
  240. RAILS_ENV: "test"
  241. IMPORT_OTRS_ENDPOINT: "http://vz305.demo.znuny.com/otrs/public.pl?Action=ZammadMigrator"
  242. <<: *script_integration_otrs_definition
  243. test:integration:otrs_32:
  244. <<: *services_postgresql
  245. variables:
  246. RAILS_ENV: "test"
  247. IMPORT_OTRS_ENDPOINT: "http://vz382.demo.znuny.com/otrs/public.pl?Action=ZammadMigrator"
  248. <<: *script_integration_otrs_definition
  249. test:integration:otrs_31:
  250. <<: *services_postgresql
  251. variables:
  252. RAILS_ENV: "test"
  253. IMPORT_OTRS_ENDPOINT: "http://vz381.demo.znuny.com/otrs/public.pl?Action=ZammadMigrator"
  254. <<: *script_integration_otrs_definition
  255. # Browser tests
  256. ## preparation (asset precompile)
  257. browser:build:
  258. <<: *base_env
  259. <<: *services_postgresql
  260. stage: test
  261. variables:
  262. RAILS_ENV: "production"
  263. script:
  264. - rake zammad:db:unseeded
  265. - rake assets:precompile
  266. artifacts:
  267. expire_in: 1 week
  268. paths:
  269. - public/assets/.sprockets-manifest*
  270. - public/assets/application-*
  271. - public/assets/print-*
  272. .services_browser_postgresql_template: &services_browser_postgresql_definition
  273. services:
  274. - name: registry.znuny.com/docker/zammad-postgresql:latest
  275. alias: postgresql
  276. - name: registry.znuny.com/docker/zammad-elasticsearch:latest
  277. alias: elasticsearch
  278. - name: docker.io/elgalu/selenium:latest
  279. alias: selenium
  280. - name: registry.znuny.com/docker/docker-imap-devel:latest
  281. alias: mail
  282. .services_browser_mysql_template: &services_browser_mysql_definition
  283. services:
  284. - name: registry.znuny.com/docker/zammad-mysql:latest
  285. alias: mysql
  286. - name: registry.znuny.com/docker/zammad-elasticsearch:latest
  287. alias: elasticsearch
  288. - name: docker.io/elgalu/selenium:latest
  289. alias: selenium
  290. - name: registry.znuny.com/docker/docker-imap-devel:latest
  291. alias: mail
  292. ## Capybara
  293. .test_capybara_template: &test_capybara_definition
  294. <<: *base_env
  295. stage: browser-core
  296. script:
  297. - rake zammad:ci:test:prepare[with_elasticsearch]
  298. - bundle exec rspec --fail-fast -t type:system
  299. .variables_capybara_chrome_template: &variables_capybara_chrome_definition
  300. <<: *test_capybara_definition
  301. variables:
  302. RAILS_ENV: "test"
  303. NO_RESET_BEFORE_SUITE: "true"
  304. BROWSER: "chrome"
  305. .variables_capybara_ff_template: &variables_capybara_ff_definition
  306. <<: *test_capybara_definition
  307. variables:
  308. RAILS_ENV: "test"
  309. NO_RESET_BEFORE_SUITE: "true"
  310. BROWSER: "firefox"
  311. test:browser:core:capybara_chrome_postgresql:
  312. <<: *variables_capybara_chrome_definition
  313. <<: *services_browser_postgresql_definition
  314. test:browser:core:capybara_chrome_mysql:
  315. <<: *variables_capybara_chrome_definition
  316. <<: *services_browser_mysql_definition
  317. test:browser:core:capybara_ff_postgresql:
  318. <<: *variables_capybara_ff_definition
  319. <<: *services_browser_postgresql_definition
  320. test:browser:core:capybara_ff_mysql:
  321. <<: *variables_capybara_ff_definition
  322. <<: *services_browser_mysql_definition
  323. ## Browser core tests
  324. .variables_browser_template: &variables_browser_definition
  325. RAILS_ENV: "production"
  326. APP_RESTART_CMD: "rake zammad:ci:app:restart"
  327. .test_browser_core_template: &test_browser_core_definition
  328. <<: *base_env
  329. stage: browser-core
  330. dependencies:
  331. - browser:build
  332. ### API clients
  333. test:browser:integration:api_client_ruby:
  334. <<: *test_browser_core_definition
  335. <<: *services_postgresql
  336. variables:
  337. <<: *variables_browser_definition
  338. script:
  339. - RAILS_ENV=test rake db:create
  340. - cp contrib/auto_wizard_test.json auto_wizard.json
  341. - rake zammad:ci:test:start
  342. - git clone https://github.com/zammad/zammad-api-client-ruby.git
  343. - cd zammad-api-client-ruby
  344. - bundle install -j $(nproc)
  345. - bundle exec rspec
  346. test:browser:integration:api_client_php:
  347. <<: *test_browser_core_definition
  348. <<: *services_postgresql
  349. variables:
  350. <<: *variables_browser_definition
  351. ZAMMAD_PHP_API_CLIENT_UNIT_TESTS_URL: "http://localhost:3000"
  352. ZAMMAD_PHP_API_CLIENT_UNIT_TESTS_USERNAME: "master@example.com"
  353. ZAMMAD_PHP_API_CLIENT_UNIT_TESTS_PASSWORD: "test"
  354. script:
  355. - RAILS_ENV=test rake db:create
  356. - rake zammad:ci:test:start zammad:setup:auto_wizard
  357. - git clone https://github.com/zammad/zammad-api-client-php.git
  358. - php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
  359. - php composer-setup.php --install-dir=/usr/local/bin
  360. - ln -s /usr/local/bin/composer.phar /usr/local/bin/composer
  361. - cd zammad-api-client-php
  362. - composer install
  363. - vendor/bin/phpunit
  364. ### Browser test slices
  365. #### Templates
  366. .script_browser_slice_template: &script_browser_slice_definition
  367. script:
  368. # temporary workaround to check Yahoo! mailbox only in test:browser:core:ff_3_* tests
  369. - if [[ $CI_JOB_NAME != test:browser:core:ff_3_* ]]; then unset MAILBOX_AUTO1 ; fi
  370. - if [[ $CI_JOB_NAME != test:browser:core:ff_3_* ]]; then unset MAILBOX_AUTO2 ; fi
  371. - if [[ $CI_JOB_NAME != test:browser:core:ff_3_* ]]; then unset MAILBOX_MANUAL1 ; fi
  372. - if [[ $CI_JOB_NAME != test:browser:core:ff_3_* ]]; then unset MAILBOX_MANUAL2 ; fi
  373. - env
  374. - script/build/test_slice_tests.sh $TEST_SLICE
  375. - RAILS_ENV=test rake db:create
  376. - rake zammad:ci:test:start[with_elasticsearch]
  377. - rake test:browser
  378. .test_browser_core_postgresql_template: &test_browser_core_postgresql_definition
  379. <<: *test_browser_core_definition
  380. <<: *script_browser_slice_definition
  381. <<: *services_browser_postgresql_definition
  382. .test_browser_core_mysql_template: &test_browser_core_mysql_definition
  383. <<: *test_browser_core_definition
  384. <<: *script_browser_slice_definition
  385. <<: *services_browser_mysql_definition
  386. #### Firefox
  387. test:browser:core:ff_1_mysql:
  388. <<: *test_browser_core_mysql_definition
  389. variables:
  390. <<: *variables_browser_definition
  391. BROWSER: "firefox"
  392. TEST_SLICE: "1"
  393. test:browser:core:ff_2_mysql:
  394. <<: *test_browser_core_mysql_definition
  395. variables:
  396. <<: *variables_browser_definition
  397. BROWSER: "firefox"
  398. TEST_SLICE: "2"
  399. test:browser:core:ff_3_mysql:
  400. <<: *test_browser_core_mysql_definition
  401. variables:
  402. <<: *variables_browser_definition
  403. BROWSER: "firefox"
  404. TEST_SLICE: "3"
  405. test:browser:core:ff_4_mysql:
  406. <<: *test_browser_core_mysql_definition
  407. variables:
  408. <<: *variables_browser_definition
  409. BROWSER: "firefox"
  410. TEST_SLICE: "4"
  411. test:browser:core:ff_5_mysql:
  412. <<: *test_browser_core_mysql_definition
  413. variables:
  414. <<: *variables_browser_definition
  415. BROWSER: "firefox"
  416. TEST_SLICE: "5"
  417. test:browser:core:ff_6_mysql:
  418. <<: *test_browser_core_mysql_definition
  419. variables:
  420. <<: *variables_browser_definition
  421. BROWSER: "firefox"
  422. TEST_SLICE: "6"
  423. test:browser:core:ff_1_postgresql:
  424. <<: *test_browser_core_postgresql_definition
  425. variables:
  426. <<: *variables_browser_definition
  427. BROWSER: "firefox"
  428. TEST_SLICE: "1"
  429. test:browser:core:ff_2_postgresql:
  430. <<: *test_browser_core_postgresql_definition
  431. variables:
  432. <<: *variables_browser_definition
  433. BROWSER: "firefox"
  434. TEST_SLICE: "2"
  435. test:browser:core:ff_3_postgresql:
  436. <<: *test_browser_core_postgresql_definition
  437. variables:
  438. <<: *variables_browser_definition
  439. BROWSER: "firefox"
  440. TEST_SLICE: "3"
  441. test:browser:core:ff_4_postgresql:
  442. <<: *test_browser_core_postgresql_definition
  443. variables:
  444. <<: *variables_browser_definition
  445. BROWSER: "firefox"
  446. TEST_SLICE: "4"
  447. test:browser:core:ff_5_postgresql:
  448. <<: *test_browser_core_postgresql_definition
  449. variables:
  450. <<: *variables_browser_definition
  451. BROWSER: "firefox"
  452. TEST_SLICE: "5"
  453. test:browser:core:ff_6_postgresql:
  454. <<: *test_browser_core_postgresql_definition
  455. variables:
  456. <<: *variables_browser_definition
  457. BROWSER: "firefox"
  458. TEST_SLICE: "6"
  459. ### Chrome
  460. test:browser:core:chrome_1_mysql:
  461. <<: *test_browser_core_mysql_definition
  462. variables:
  463. <<: *variables_browser_definition
  464. BROWSER: "chrome"
  465. TEST_SLICE: "1"
  466. test:browser:core:chrome_2_mysql:
  467. <<: *test_browser_core_mysql_definition
  468. variables:
  469. <<: *variables_browser_definition
  470. BROWSER: "chrome"
  471. TEST_SLICE: "2"
  472. test:browser:core:chrome_3_mysql:
  473. <<: *test_browser_core_mysql_definition
  474. variables:
  475. <<: *variables_browser_definition
  476. BROWSER: "chrome"
  477. TEST_SLICE: "3"
  478. test:browser:core:chrome_4_mysql:
  479. <<: *test_browser_core_mysql_definition
  480. variables:
  481. <<: *variables_browser_definition
  482. BROWSER: "chrome"
  483. TEST_SLICE: "4"
  484. test:browser:core:chrome_5_mysql:
  485. <<: *test_browser_core_mysql_definition
  486. variables:
  487. <<: *variables_browser_definition
  488. BROWSER: "chrome"
  489. TEST_SLICE: "5"
  490. test:browser:core:chrome_6_mysql:
  491. <<: *test_browser_core_mysql_definition
  492. variables:
  493. <<: *variables_browser_definition
  494. BROWSER: "chrome"
  495. TEST_SLICE: "6"
  496. test:browser:core:chrome_1_postgresql:
  497. <<: *test_browser_core_postgresql_definition
  498. variables:
  499. <<: *variables_browser_definition
  500. BROWSER: "chrome"
  501. TEST_SLICE: "1"
  502. test:browser:core:chrome_2_postgresql:
  503. <<: *test_browser_core_postgresql_definition
  504. variables:
  505. <<: *variables_browser_definition
  506. BROWSER: "chrome"
  507. TEST_SLICE: "2"
  508. test:browser:core:chrome_3_postgresql:
  509. <<: *test_browser_core_postgresql_definition
  510. variables:
  511. <<: *variables_browser_definition
  512. BROWSER: "chrome"
  513. TEST_SLICE: "3"
  514. test:browser:core:chrome_4_postgresql:
  515. <<: *test_browser_core_postgresql_definition
  516. variables:
  517. <<: *variables_browser_definition
  518. BROWSER: "chrome"
  519. TEST_SLICE: "4"
  520. test:browser:core:chrome_5_postgresql:
  521. <<: *test_browser_core_postgresql_definition
  522. variables:
  523. <<: *variables_browser_definition
  524. BROWSER: "chrome"
  525. TEST_SLICE: "5"
  526. test:browser:core:chrome_6_postgresql:
  527. <<: *test_browser_core_postgresql_definition
  528. variables:
  529. <<: *variables_browser_definition
  530. BROWSER: "chrome"
  531. TEST_SLICE: "6"
  532. ### Auto wizard
  533. .auto_wizard_services_template: &auto_wizard_services
  534. services:
  535. - name: registry.znuny.com/docker/zammad-postgresql:latest
  536. alias: postgresql
  537. - name: docker.io/elgalu/selenium:latest
  538. alias: selenium
  539. .test_browser_integration_template: &test_browser_integration_definition
  540. <<: *base_env
  541. <<: *auto_wizard_services
  542. stage: browser-integration
  543. dependencies:
  544. - browser:build
  545. .script_integration_auto_wizard_template: &script_integration_auto_wizard_definition
  546. script:
  547. - RAILS_ENV=test rake db:create
  548. - cp $AUTO_WIZARD_FILE auto_wizard.json
  549. - rake zammad:ci:test:start
  550. - ruby -I test/ $TEST_FILE
  551. .browser_core_auto_wizard_template: &browser_core_auto_wizard_definition
  552. <<: *test_browser_core_definition
  553. <<: *auto_wizard_services
  554. <<: *script_integration_auto_wizard_definition
  555. test:browser:autowizard_chrome:
  556. <<: *browser_core_auto_wizard_definition
  557. variables:
  558. <<: *variables_browser_definition
  559. BROWSER: "chrome"
  560. AUTO_WIZARD_FILE: "contrib/auto_wizard_example.json"
  561. TEST_FILE: "test/integration/auto_wizard_browser_test.rb"
  562. test:browser:autowizard_ff:
  563. <<: *browser_core_auto_wizard_definition
  564. variables:
  565. <<: *variables_browser_definition
  566. BROWSER: "firefox"
  567. AUTO_WIZARD_FILE: "contrib/auto_wizard_example.json"
  568. TEST_FILE: "test/integration/auto_wizard_browser_test.rb"
  569. ### Browser integration tests
  570. .browser_integration_auto_wizard_template: &browser_integration_auto_wizard_definition
  571. <<: *test_browser_integration_definition
  572. <<: *script_integration_auto_wizard_definition
  573. test:browser:integration:twitter_chrome:
  574. <<: *browser_integration_auto_wizard_definition
  575. variables:
  576. <<: *variables_browser_definition
  577. BROWSER: "chrome"
  578. AUTO_WIZARD_FILE: "contrib/auto_wizard_test.json"
  579. TEST_FILE: "test/integration/twitter_browser_test.rb"
  580. test:browser:integration:twitter_ff:
  581. <<: *browser_integration_auto_wizard_definition
  582. variables:
  583. <<: *variables_browser_definition
  584. BROWSER: "firefox"
  585. AUTO_WIZARD_FILE: "contrib/auto_wizard_test.json"
  586. TEST_FILE: "test/integration/twitter_browser_test.rb"
  587. test:browser:integration:facebook_chrome:
  588. <<: *browser_integration_auto_wizard_definition
  589. variables:
  590. <<: *variables_browser_definition
  591. BROWSER: "chrome"
  592. AUTO_WIZARD_FILE: "contrib/auto_wizard_test.json"
  593. TEST_FILE: "test/integration/facebook_browser_test.rb"
  594. test:browser:integration:facebook_ff:
  595. <<: *browser_integration_auto_wizard_definition
  596. variables:
  597. <<: *variables_browser_definition
  598. BROWSER: "firefox"
  599. AUTO_WIZARD_FILE: "contrib/auto_wizard_test.json"
  600. TEST_FILE: "test/integration/facebook_browser_test.rb"
  601. test:browser:integration:idoit_chrome:
  602. <<: *browser_integration_auto_wizard_definition
  603. variables:
  604. <<: *variables_browser_definition
  605. BROWSER: "chrome"
  606. AUTO_WIZARD_FILE: "contrib/auto_wizard_test.json"
  607. TEST_FILE: "test/integration/idoit_browser_test.rb"
  608. ### Browser integration tests
  609. .variables_browser_import_template: &variables_browser_import_definition
  610. BROWSER: "chrome"
  611. RAILS_SERVE_STATIC_FILES: "true"
  612. RAILS_ENV: "production"
  613. .browser_integration_import_template: &browser_integration_import_definition
  614. <<: *test_browser_integration_definition
  615. script:
  616. - RAILS_ENV=test rake db:create
  617. - rake zammad:ci:test:start
  618. - ruby -I test/ $TEST_FILE
  619. test:browser:integration:otrs_chrome:
  620. <<: *browser_integration_import_definition
  621. variables:
  622. <<: *variables_browser_import_definition
  623. TEST_FILE: "test/integration/otrs_import_browser_test.rb"
  624. test:browser:integration:zendesk_chrome:
  625. <<: *browser_integration_import_definition
  626. variables:
  627. <<: *variables_browser_import_definition
  628. TEST_FILE: "test/integration/zendesk_import_browser_test.rb"