<commit_before>notifications:
  irc:
    channels:
      - "chat.freenode.net#noosfero"
      - "chat.freenode.net#noosfero-br"
    template:
      - "%{repository_slug} %{branch} %{commit} %{commit_subject} - %{result} %{build_url}"

# Ensure Container-based environment, as others can have some random failures
# specially with different Firefox versions and selenium tests.
# E.g. https://travis-ci.org/noosfero/noosfero/jobs/122918772#L1308
#
# Also container-based environments have the fatest boot times and
# are the only one with cache available for public projects.
# See https://docs.travis-ci.com/user/ci-environment/#Virtualization-environments
sudo: false
cache: bundler

language: ruby
rvm:
  - 2.3.3

services:
  - postgresql
  - elasticsearch

addons:
  apt:
    packages:
      - tango-icon-theme
      - pidgin-data
  artifacts:
    paths:
      - $(ls tmp/artifact* | tr "\n" ":")
  # same as in docker ci image
  firefox: '45.7.0'

before_install:
  # geckodriver, from http://www.columbia.edu/~njn2118/journal/2016/10/28.html
  - wget https://github.com/mozilla/geckodriver/releases/download/v0.14.0/geckodriver-v0.14.0-linux64.tar.gz
  - mkdir geckodriver
  - tar -xzf geckodriver-v0.14.0-linux64.tar.gz -C geckodriver
  - export PATH=$PATH:$PWD/geckodriver

before_script:
  - mkdir -p tmp/{pids,cache} log cache
  - script/noosfero-plugins disableall
  #- bundle exec rake makemo &>/dev/null
# database
  - cp config/database.yml.travis config/database.yml
  - psql -c 'create database myapp_test;' -U postgres
  - bundle exec rake db:schema:load
  - bundle exec rake db:migrate &>/dev/null

env:
  global:
    - LANG=en
  matrix:
    - SLICE=2/5 TASK=test:noosfero_plugins NOOSFERO_BUNDLE_OPTS=install
    # chrome hanging on travis
    #- SLICE=1/4 TASK=selenium SELENIUM_DRIVER=chrome<commit_msg>Revert "travis tmp"<commit_after>notifications:
  irc:
    channels:
      - "chat.freenode.net#noosfero"
      - "chat.freenode.net#noosfero-br"
    template:
      - "%{repository_slug} %{branch} %{commit} %{commit_subject} - %{result} %{build_url}"

# Ensure Container-based environment, as others can have some random failures
# specially with different Firefox versions and selenium tests.
# E.g. https://travis-ci.org/noosfero/noosfero/jobs/122918772#L1308
#
# Also container-based environments have the fatest boot times and
# are the only one with cache available for public projects.
# See https://docs.travis-ci.com/user/ci-environment/#Virtualization-environments
sudo: false
cache: bundler

language: ruby
rvm:
  - 2.3.3

services:
  - postgresql
  - elasticsearch

addons:
  apt:
    packages:
      - tango-icon-theme
      - pidgin-data
  artifacts:
    paths:
      - $(ls tmp/artifact* | tr "\n" ":")
  # same as in docker ci image
  firefox: '45.7.0'

before_install:
  # geckodriver, from http://www.columbia.edu/~njn2118/journal/2016/10/28.html
  - wget https://github.com/mozilla/geckodriver/releases/download/v0.14.0/geckodriver-v0.14.0-linux64.tar.gz
  - mkdir geckodriver
  - tar -xzf geckodriver-v0.14.0-linux64.tar.gz -C geckodriver
  - export PATH=$PATH:$PWD/geckodriver

before_script:
  - mkdir -p tmp/{pids,cache} log cache
  - script/noosfero-plugins disableall
  #- bundle exec rake makemo &>/dev/null
# database
  - cp config/database.yml.travis config/database.yml
  - psql -c 'create database myapp_test;' -U postgres
  - bundle exec rake db:schema:load
  - bundle exec rake db:migrate &>/dev/null

env:
  global:
    - LANG=en
  matrix:
    - TASK=test:api
    - TASK=test:units
    - TASK=test:functionals
    - TASK=test:integration
    - SLICE=1/2 TASK=cucumber
    - SLICE=2/2 TASK=cucumber
    - SLICE=1/4 TASK=selenium
    - SLICE=2/4 TASK=selenium
    - SLICE=3/4 TASK=selenium
    - SLICE=4/4 TASK=selenium
    - SLICE=1/5 TASK=test:noosfero_plugins NOOSFERO_BUNDLE_OPTS=install
    - SLICE=2/5 TASK=test:noosfero_plugins NOOSFERO_BUNDLE_OPTS=install
    - SLICE=3/5 TASK=test:noosfero_plugins NOOSFERO_BUNDLE_OPTS=install
    - SLICE=4/5 TASK=test:noosfero_plugins NOOSFERO_BUNDLE_OPTS=install
    - SLICE=5/5 TASK=test:noosfero_plugins NOOSFERO_BUNDLE_OPTS=install
    # chrome hanging on travis
    #- SLICE=1/4 TASK=selenium SELENIUM_DRIVER=chrome
{'fraction_non_alphanumeric': 0.1204362256993836, 'fraction_numerical': 0.02939781887150308, 'mean_word_length': 3.417801047120419, 'pattern_counts': {'":': 2, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 6, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7263885', 'n_tokens_mistral': 1696, 'n_tokens_neox': 1609, 'n_words': 319}