From b9ef55c21fb7ee48ca2f8e010441411cc1478598 Mon Sep 17 00:00:00 2001 From: weryques Date: Tue, 12 Dec 2017 12:01:41 -0200 Subject: [PATCH] Remove translations --- tests/factories/class-tainacan-entity-factory.php | 9 ++++----- tests/factories/class-tainacan-field-factory.php | 2 +- tests/factories/class-tainacan-filter-factory.php | 2 +- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/tests/factories/class-tainacan-entity-factory.php b/tests/factories/class-tainacan-entity-factory.php index 6b2d6caa0..fec0a3caa 100644 --- a/tests/factories/class-tainacan-entity-factory.php +++ b/tests/factories/class-tainacan-entity-factory.php @@ -34,7 +34,7 @@ class Entity_Factory { try { if(empty($type)){ - throw new \InvalidArgumentException(__('The type can\'t be empty', 'tainacan')); + throw new \InvalidArgumentException('The type can\'t be empty'); } elseif(!strrchr($type, '_')){ $type = ucfirst(strtolower($type)); } else { @@ -75,7 +75,7 @@ class Entity_Factory { if ($this->entity->validate()) { $this->entity = $this->repository->insert($this->entity); } else { - throw new \ErrorException( __( 'The entity wasn\'t validated.', 'tainacan' ) ); + throw new \ErrorException('The entity wasn\'t validated.'); } } elseif (!empty($args) && !$is_validated_and_in_db){ @@ -112,12 +112,11 @@ class Entity_Factory { if ($this->entity->validate()) { $this->entity = $this->repository->insert( $this->entity ); } else { - throw new \ErrorException( __( 'The entity wasn\'t validated.', 'tainacan').print_r( $this->entity->get_errors(), true ) ); // TODO show this in a better way - throw new \ErrorException( __( 'The entity wasn\'t validated.', 'tainacan' ) ); + throw new \ErrorException('The entity wasn\'t validated.' . print_r( $this->entity->get_errors(), true)); } } else { - throw new \InvalidArgumentException( __( 'One or more arguments are invalid.', 'tainacan' ) ); + throw new \InvalidArgumentException('One or more arguments are invalid.'); } } catch (\Error $exception){ echo "\n" . $exception->getMessage() . "\n"; diff --git a/tests/factories/class-tainacan-field-factory.php b/tests/factories/class-tainacan-field-factory.php index 2557b3946..777f3e058 100644 --- a/tests/factories/class-tainacan-field-factory.php +++ b/tests/factories/class-tainacan-field-factory.php @@ -8,7 +8,7 @@ class Field_Factory { public function create_field($type, $primitive_type = []){ if(empty($type)){ - throw new \InvalidArgumentException(__('The type can\'t be empty', 'tainacan')); + throw new \InvalidArgumentException('The type can\'t be empty'); } elseif(!strrchr($type, '_')){ $type = ucfirst(strtolower($type)); } else { diff --git a/tests/factories/class-tainacan-filter-factory.php b/tests/factories/class-tainacan-filter-factory.php index 3e1845913..d78e8162c 100644 --- a/tests/factories/class-tainacan-filter-factory.php +++ b/tests/factories/class-tainacan-filter-factory.php @@ -8,7 +8,7 @@ class Filter_Factory { public function create_filter($type, $supported_types = []){ if(empty($type)){ - throw new \InvalidArgumentException(__('The type can\'t be empty', 'tainacan')); + throw new \InvalidArgumentException('The type can\'t be empty'); } elseif(!strrchr($type, '_')){ $type = ucfirst(strtolower($type)); } else {