From b58b40fbfa9ed0239bb03ed4971f06c613815f77 Mon Sep 17 00:00:00 2001 From: splitt3r Date: Mon, 9 Oct 2017 18:34:48 +0200 Subject: [PATCH] Apply NC => phpunit fix from new skeleton --- Makefile | 23 +++-------------------- composer.json | 14 ++++++++++++++ 2 files changed, 17 insertions(+), 20 deletions(-) create mode 100644 composer.json diff --git a/Makefile b/Makefile index 4156bb1ee..ada504fbc 100644 --- a/Makefile +++ b/Makefile @@ -151,24 +151,7 @@ appstore: --exclude="../$(app_name)/.*" \ --exclude="../$(app_name)/js/.*" \ -# Command for running JS and PHP tests. Works for package.json files in the js/ -# and root directory. If phpunit is not installed systemwide, a copy is fetched -# from the internet .PHONY: test -test: -ifneq (,$(wildcard $(CURDIR)/js/package.json)) - cd js && $(npm) run test -endif -ifneq (,$(wildcard $(CURDIR)/package.json)) - $(npm) run test -endif -ifeq (, $(shell which phpunit 2> /dev/null)) - @echo "No phpunit command available, downloading a copy from the web" - mkdir -p $(build_tools_directory) - curl -sSL https://phar.phpunit.de/phpunit.phar -o $(build_tools_directory)/phpunit.phar - php $(build_tools_directory)/phpunit.phar -c phpunit.xml - php $(build_tools_directory)/phpunit.phar -c phpunit.integration.xml -else - phpunit -c phpunit.xml --coverage-clover build/php-unit.clover - phpunit -c phpunit.integration.xml --coverage-clover build/php-unit.clover -endif +test: composer + $(CURDIR)/vendor/phpunit/phpunit/phpunit -c phpunit.xml + $(CURDIR)/vendor/phpunit/phpunit/phpunit -c phpunit.integration.xml diff --git a/composer.json b/composer.json new file mode 100644 index 000000000..6874762b7 --- /dev/null +++ b/composer.json @@ -0,0 +1,14 @@ +{ + "name": "polls", + "description": "This is a poll app, similar to doodle or dudle with the possibility for restrict access (only members, certain groups/users, hidden and public).", + "type": "project", + "license": "AGPL", + "authors": [ + { + "name": "Vinzenz Rosenkranz" + } + ], + "require-dev": { + "phpunit/phpunit": "^5.4" + } +}