Skip to content

Commit

Permalink
Merge pull request #1 from zaporylie/tests
Browse files Browse the repository at this point in the history
Integration with Travis and some basic performance tests
  • Loading branch information
zaporylie authored Jul 15, 2018
2 parents 7aaf859 + a6d797e commit 27974b4
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 1 deletion.
41 changes: 41 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
language: php
dist: trusty
sudo: false

php:
- 5.6
- 7.0
- 7.1
- 7.2

env:
matrix:
- RELEASE=stable COMPOSER_CHANNEL=stable
- RELEASE=dev COMPOSER_CHANNEL=stable
- RELEASE=stable COMPOSER_CHANNEL=snapshot

matrix:
exclude:
- php: 5.6
env: RELEASE=dev COMPOSER_CHANNEL=stable
- php: 5.6
env: RELEASE=stable COMPOSER_CHANNEL=snapshot

before_install:
- if [[ $TRAVIS_PHP_VERSION = 5.6 ]]; then export COMPOSER_MEMORY_LIMIT=-1; fi;
- composer --verbose self-update --$COMPOSER_CHANNEL
- composer --version

install:
- composer --verbose validate
- composer --verbose install

script:
- cd .. && composer create-project drupal-composer/drupal-project:8.x-dev drupal-project --stability dev --no-interaction
- ls -lah . && cd drupal-project
- if [[ $RELEASE = dev ]]; then composer --verbose require --no-update --dev webflo/drupal-core-require-dev:8.6.x-dev; fi;
- if [[ $RELEASE = dev ]]; then composer --verbose require --no-update drupal/core:8.6.x-dev; fi;
- if [[ $RELEASE = dev ]]; then composer --verbose update; fi;
- composer update nothing --profile
- composer config repositories.local path "../composer-drupal-optimizations" && composer require zaporylie/composer-drupal-optimizations:@dev
- composer update nothing --profile
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
Optimize Composer for Drupal 8.5+ projects
====
[![Build Status](https://travis-ci.org/zaporylie/composer-drupal-optimizations.svg?branch=master)](https://travis-ci.org/zaporylie/composer-drupal-optimizations)
![Packagist](https://img.shields.io/packagist/v/zaporylie/composer-drupal-optimizations.svg)


# About

Expand Down
2 changes: 1 addition & 1 deletion src/Cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public function read($file)
return $content;
}

public function removeLegacyTags(array $data): array
public function removeLegacyTags(array $data)
{
foreach (self::$lowestTags as $package => $lowestVersion) {
if (!isset($data['packages'][$package][$lowestVersion])) {
Expand Down

0 comments on commit 27974b4

Please sign in to comment.