From 9b9cbfe111b60afb8076d0a22d84107f7f6c642e Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 16 Jul 2015 09:20:36 +0200 Subject: [PATCH] fix for changes in justinrainbow/json-schema 1.4.4 --- composer.json | 2 +- tests/Composer/Test/Json/ComposerSchemaTest.php | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/composer.json b/composer.json index d1af27ec2..ae18931d7 100644 --- a/composer.json +++ b/composer.json @@ -23,7 +23,7 @@ }, "require": { "php": ">=5.3.2", - "justinrainbow/json-schema": "~1.4", + "justinrainbow/json-schema": "^1.4.4", "composer/spdx-licenses": "~1.0", "seld/jsonlint": "~1.0", "symfony/console": "~2.5", diff --git a/tests/Composer/Test/Json/ComposerSchemaTest.php b/tests/Composer/Test/Json/ComposerSchemaTest.php index 1b8805f48..cf44d4a84 100644 --- a/tests/Composer/Test/Json/ComposerSchemaTest.php +++ b/tests/Composer/Test/Json/ComposerSchemaTest.php @@ -23,18 +23,18 @@ class ComposerSchemaTest extends \PHPUnit_Framework_TestCase { $json = '{ }'; $this->assertEquals(array( - array('property' => '', 'message' => 'the property name is required'), - array('property' => '', 'message' => 'the property description is required'), + array('property' => 'name', 'message' => 'The property name is required'), + array('property' => 'description', 'message' => 'The property description is required'), ), $this->check($json)); $json = '{ "name": "vendor/package" }'; $this->assertEquals(array( - array('property' => '', 'message' => 'the property description is required'), + array('property' => 'description', 'message' => 'The property description is required'), ), $this->check($json)); $json = '{ "description": "generic description" }'; $this->assertEquals(array( - array('property' => '', 'message' => 'the property name is required'), + array('property' => 'name', 'message' => 'The property name is required'), ), $this->check($json)); } @@ -44,7 +44,7 @@ class ComposerSchemaTest extends \PHPUnit_Framework_TestCase $this->assertEquals(array( array( 'property' => 'minimum-stability', - 'message' => 'does not match the regex pattern ^dev|alpha|beta|rc|RC|stable$' + 'message' => 'Does not match the regex pattern ^dev|alpha|beta|rc|RC|stable$' ), ), $this->check($json), 'empty string'); @@ -52,7 +52,7 @@ class ComposerSchemaTest extends \PHPUnit_Framework_TestCase $this->assertEquals(array( array( 'property' => 'minimum-stability', - 'message' => 'does not match the regex pattern ^dev|alpha|beta|rc|RC|stable$' + 'message' => 'Does not match the regex pattern ^dev|alpha|beta|rc|RC|stable$' ), ), $this->check($json), 'dummy');