YetiForceCompany/YetiForceCRM

View on GitHub
tests/App/TextParser.php

Summary

Maintainability
F
3 days
Test Coverage
A
100%

File TextParser.php has 538 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php
/**
 * TextParser test file.
 *
 * @package   Tests
Severity: Major
Found in tests/App/TextParser.php - About 1 day to fix

    The class TextParser has 24 public methods. Consider refactoring TextParser to keep number of public methods under 10.
    Open

    class TextParser extends \Tests\Base
    {
        /**
         * Test record instance.
         *
    Severity: Minor
    Found in tests/App/TextParser.php by phpmd

    TooManyPublicMethods

    Since: 0.1

    A class with too many public methods is probably a good suspect for refactoring, in order to reduce its complexity and find a way to have more fine grained objects.

    By default it ignores methods starting with 'get' or 'set'.

    Example

    Source https://phpmd.org/rules/codesize.html#toomanypublicmethods

    The class TextParser has 26 non-getter- and setter-methods. Consider refactoring TextParser to keep number of methods under 25.
    Open

    class TextParser extends \Tests\Base
    {
        /**
         * Test record instance.
         *
    Severity: Minor
    Found in tests/App/TextParser.php by phpmd

    TooManyMethods

    Since: 0.1

    A class with too many methods is probably a good suspect for refactoring, in order to reduce its complexity and find a way to have more fine grained objects.

    By default it ignores methods starting with 'get' or 'set'.

    The default was changed from 10 to 25 in PHPMD 2.3.

    Example

    Source https://phpmd.org/rules/codesize.html#toomanymethods

    TextParser has 26 functions (exceeds 20 allowed). Consider refactoring.
    Open

    class TextParser extends \Tests\Base
    {
        /**
         * Test record instance.
         *
    Severity: Minor
    Found in tests/App/TextParser.php - About 3 hrs to fix

      Method testRecord has 53 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          public function testRecord()
          {
              $text = '+ $(record : NotExists)$ +';
              $this->assertSame('+  +', self::$parserClean->setContent($text)->parse()->getContent(), 'Expected empty string');
      
      
      Severity: Major
      Found in tests/App/TextParser.php - About 2 hrs to fix

        Function testGetGeneralVariable has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
        Open

            public function testGetGeneralVariable()
            {
                $arr = \App\TextParser::getInstance('IStorages')->getGeneralVariable();
                $this->assertIsArray($arr, 'Expected array type');
                $this->assertNotEmpty($arr, 'Expected any general variables data');
        Severity: Minor
        Found in tests/App/TextParser.php - About 2 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Method testEmployee has 44 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            public function testEmployee()
            {
                $currentUser = \App\User::getCurrentUserId();
                $userName = 'Employee';
                $userExistsId = (new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['user_name' => $userName])
        Severity: Minor
        Found in tests/App/TextParser.php - About 1 hr to fix

          Method testDate has 32 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              public function testDate()
              {
                  $this->assertSame('+ ' . \date('Y-m-d') . ' +', self::$parserClean
                      ->setContent('+ $(date : now)$ +')
                      ->parse()
          Severity: Minor
          Found in tests/App/TextParser.php - About 1 hr to fix

            Function testGetSourceVariable has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
            Open

                public function testGetSourceVariable()
                {
                    $this->assertFalse(\App\TextParser::getInstance('Leads')->setSourceRecord(self::$recordLeads->getId())->getSourceVariable(), 'TextParser::getSourceVariable() should return false for Leads module');
                    $arr = \App\TextParser::getInstance('Campaigns')->setSourceRecord(self::$recordLeads->getId())->getSourceVariable();
                    $this->assertIsArray($arr, 'Expected array type');
            Severity: Minor
            Found in tests/App/TextParser.php - About 1 hr to fix

            Cognitive Complexity

            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

            A method's cognitive complexity is based on a few simple rules:

            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
            • Code is considered more complex for each "break in the linear flow of the code"
            • Code is considered more complex when "flow breaking structures are nested"

            Further reading

            Method testRelatedRecordsList has 30 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                public function testRelatedRecordsList()
                {
                    $text = '$(relatedRecordsList : Accounts|lead_no,lastname,phone,description|[[["company","a","Test"]]]|All|5)$';
                    $result = \App\TextParser::getInstanceByModel(self::$recordLeads)
                        ->setContent($text)
            Severity: Minor
            Found in tests/App/TextParser.php - About 1 hr to fix

              Method testGeneral has 30 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public function testGeneral()
                  {
                      $this->assertSame('+ ' . (new \DateTimeField(null))->getDisplayDate() . ' +', self::$parserClean
                          ->setContent('+ $(general : CurrentDate)$ +')
                          ->parse()
              Severity: Minor
              Found in tests/App/TextParser.php - About 1 hr to fix

                Method testTranslate has 28 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    public function testTranslate()
                    {
                        $this->assertSame(
                            '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                            self::$parserClean->setContent('+$(general : CurrentDate)$ | $(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parseTranslations()->getContent(),
                Severity: Minor
                Found in tests/App/TextParser.php - About 1 hr to fix

                  Function testGetRelatedVariable has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                  Open

                      public function testGetRelatedVariable()
                      {
                          $arr = self::$parserCleanModule->getRelatedVariable();
                          $this->assertIsArray($arr, 'Expected array type');
                          $this->assertNotEmpty($arr, 'Expected any related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php - About 25 mins to fix

                  Cognitive Complexity

                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                  A method's cognitive complexity is based on a few simple rules:

                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                  • Code is considered more complex for each "break in the linear flow of the code"
                  • Code is considered more complex when "flow breaking structures are nested"

                  Further reading

                  Class "TextParser" has 26 methods, which is greater than 20 authorized. Split it into smaller classes.
                  Open

                  class TextParser extends \Tests\Base
                  Severity: Major
                  Found in tests/App/TextParser.php by sonar-php

                  A class that grows too much tends to aggregate too many responsibilities and inevitably becomes harder to understand and therefore to maintain. Above a specific threshold, it is strongly advised to refactor the class into smaller ones which focus on well defined topics.

                  Refactor this function to reduce its Cognitive Complexity from 16 to the 15 allowed.
                  Open

                      public function testGetGeneralVariable()
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Cognitive Complexity is a measure of how hard the control flow of a function is to understand. Functions with high Cognitive Complexity will be difficult to maintain.

                  See

                  Missing class import via use statement (line '273', column '28').
                  Open

                          $employeeExistsId = (new \App\Db\Query())
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  MissingImport

                  Since: 2.7.0

                  Importing all external classes in a file through use statements makes them clearly visible.

                  Example

                  function make() {
                      return new \stdClass();
                  }

                  Source http://phpmd.org/rules/cleancode.html#MissingImport

                  Missing class import via use statement (line '231', column '154').
                  Open

                          \App\User::setCurrentUserId((new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['status' => 'Active'])->andWhere(['not in', 'id', (new \App\Db\Query())->select(['smownerid'])->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees'])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  MissingImport

                  Since: 2.7.0

                  Importing all external classes in a file through use statements makes them clearly visible.

                  Example

                  function make() {
                      return new \stdClass();
                  }

                  Source http://phpmd.org/rules/cleancode.html#MissingImport

                  Missing class import via use statement (line '258', column '24').
                  Open

                          $userExistsId = (new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['user_name' => $userName])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  MissingImport

                  Since: 2.7.0

                  Importing all external classes in a file through use statements makes them clearly visible.

                  Example

                  function make() {
                      return new \stdClass();
                  }

                  Source http://phpmd.org/rules/cleancode.html#MissingImport

                  Missing class import via use statement (line '125', column '33').
                  Open

                          $this->assertSame('+ ' . (new \DateTimeField(null))->getDisplayDate() . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  MissingImport

                  Since: 2.7.0

                  Importing all external classes in a file through use statements makes them clearly visible.

                  Example

                  function make() {
                      return new \stdClass();
                  }

                  Source http://phpmd.org/rules/cleancode.html#MissingImport

                  Missing class import via use statement (line '231', column '36').
                  Open

                          \App\User::setCurrentUserId((new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['status' => 'Active'])->andWhere(['not in', 'id', (new \App\Db\Query())->select(['smownerid'])->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees'])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  MissingImport

                  Since: 2.7.0

                  Importing all external classes in a file through use statements makes them clearly visible.

                  Example

                  function make() {
                      return new \stdClass();
                  }

                  Source http://phpmd.org/rules/cleancode.html#MissingImport

                  Avoid using static access to class '\App\TextParser' in method 'testStaticMethods'.
                  Open

                          $this->assertSame(1, \App\TextParser::isVaribleToParse('$(TestGroup : TestVar)$'), 'string should be parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\User' in method 'testBasicField'.
                  Open

                          $tmpUser = \App\User::getCurrentUserId();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Cache' in method 'testEmployee'.
                  Open

                          \App\Cache::clear();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Tests\Base\C_RecordActions' in method 'testRelatedRecordsList'.
                  Open

                          $contactModel = \Tests\Base\C_RecordActions::createContactRecord();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Record_Model' in method 'testEmployee'.
                  Open

                          $employeeModel = $employeeExistsId ? \Vtiger_Record_Model::getInstanceById($employeeExistsId, 'OSSEmployees') : \Vtiger_Record_Model::getCleanInstance('OSSEmployees');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Tests\Base\C_RecordActions' in method 'testInstancesCreation'.
                  Open

                          self::$recordLeads = $recordModel = \Tests\Base\C_RecordActions::createLeadRecord(false);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetRelatedListVariable'.
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testInstancesCreation'.
                  Open

                          self::$parserCleanModule = \App\TextParser::getInstance('Leads');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Cache' in method 'testBasicField'.
                  Open

                          \App\Cache::clear();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\User' in method 'testEmployee'.
                  Open

                          \App\User::setCurrentUserId($currentUser);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Record_Model' in method 'testEmployee'.
                  Open

                          $employeeUser = $userExistsId ? \Vtiger_Record_Model::getInstanceById($userExistsId, 'Users') : \Vtiger_Record_Model::getCleanInstance('Users');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Tests\Base\C_RecordActions' in method 'testRelatedRecordsList'.
                  Open

                          $accountModel = \Tests\Base\C_RecordActions::createAccountRecord();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Util_Helper' in method 'createInventory'.
                  Open

                  }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Tests\Base\C_RecordActions' in method 'testRelatedRecordsList'.
                  Open

                          $result = \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createAccountRecord())->withoutTranslations(true)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Config' in method 'testGeneral'.
                  Open

                          $this->assertSame('+ ' . \App\Config::main('PORTAL_URL') . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Util_Helper' in method 'testGeneral'.
                  Open

                          $this->assertSame('+ ' . \Vtiger_Util_Helper::convertTimeIntoUsersDisplayFormat(date('H:i:s')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testInstancesCreation'.
                  Open

                          $this->assertInstanceOf('\App\TextParser', \App\TextParser::getInstanceById($recordModel->getId(), 'Leads'), 'Expected instance from lead id and module string of \App\TextParser');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\User' in method 'testEmployee'.
                  Open

                          \App\User::setCurrentUserId($employeeUser->getId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testInstancesCreation'.
                  Open

                          self::$parserClean = \App\TextParser::getInstance();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Config' in method 'testGeneral'.
                  Open

                          $this->assertSame('+ ' . \App\Config::main('site_URL') . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Config' in method 'testGeneral'.
                  Open

                              '+ ' . (empty($defaultTimeZone = date_default_timezone_get()) ? \App\Config::main('default_timezone') : $defaultTimeZone) . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\User' in method 'testGeneral'.
                  Open

                          $user = \App\User::getCurrentUserModel();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Config' in method 'testGeneral'.
                  Open

                              '+ ' . ($user->getDetail('time_zone') ?: \App\Config::main('default_timezone')) . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\User' in method 'testBasicField'.
                  Open

                          \App\User::setCurrentUserId($tmpUser);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\User' in method 'testBasicField'.
                  Open

                          \App\User::setCurrentUserId((new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['status' => 'Active'])->andWhere(['not in', 'id', (new \App\Db\Query())->select(['smownerid'])->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees'])
                              ->column(), ])
                              ->scalar());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetBaseListVariable'.
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testStaticMethods'.
                  Open

                          $this->assertSame(0, \App\TextParser::isVaribleToParse('$X(TestGroup : TestVar)$'), 'string should be not parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Record_Model' in method 'testEmployee'.
                  Open

                          $employeeUser = $userExistsId ? \Vtiger_Record_Model::getInstanceById($userExistsId, 'Users') : \Vtiger_Record_Model::getCleanInstance('Users');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Record_Model' in method 'testEmployee'.
                  Open

                          $employeeModel = $employeeExistsId ? \Vtiger_Record_Model::getInstanceById($employeeExistsId, 'OSSEmployees') : \Vtiger_Record_Model::getCleanInstance('OSSEmployees');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testInstancesCreation'.
                  Open

                          self::$parserRecord = \App\TextParser::getInstanceByModel($recordModel);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\User' in method 'testEmployee'.
                  Open

                          $currentUser = \App\User::getCurrentUserId();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Language' in method 'testTranslate'.
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetRelatedVariable'.
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetGeneralVariable'.
                  Open

                                              $this->assertSame(1, \App\TextParser::isVaribleToParse($item), 'Option: ' . $translation . ', value: ' . $item . ' should be parseable in group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Record_Model' in method 'createProduct'.
                  Open

                          self::$product = \Vtiger_Record_Model::getCleanInstance('Products');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Tests\Base\C_RecordActions' in method 'testRelatedRecord'.
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname)$+')->parse()->getContent() . ' +', 'Account name should be not empty(without module)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Tests\Base\C_RecordActions' in method 'testRelatedRecord'.
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname|Accounts)$+')->parse()->getContent() . ' +', 'Account name should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Record_Model' in method 'testRelatedRecord'.
                  Open

                          $comment = \Vtiger_Record_Model::getCleanInstance('ModComments');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Language' in method 'testTranslate'.
                  Open

                              '+' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\User' in method 'testAmountToReturn'.
                  Open

                          $correctingInvoiceModel->set('assigned_user_id', \App\User::getCurrentUserId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetRelatedVariable'.
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Config' in method 'testRecord'.
                  Open

                          $this->assertSame('+ ' . \App\Config::main('site_URL') . 'index.php?module=Leads&view=Detail&record=' . self::$recordLeads->getId() . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Language' in method 'testTranslate'.
                  Open

                              '+' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Language' in method 'testTranslate'.
                  Open

                              '+' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetRecordVariable'.
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetRecordVariable'.
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetSourceVariable'.
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_label']), 'Option: ' . $data['label'] . ', value: ' . $data['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  The method testGetGeneralVariable uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                                      } else {
                                          $placeholders = \explode(', ', $placeholder);
                                          $this->assertIsArray($placeholders, 'Expected array type  in group: ' . $groupName);
                                          $this->assertNotEmpty($placeholders, 'Expected any group data in group: ' . $groupName);
                                          foreach ($placeholders as $item) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  ElseExpression

                  Since: 1.4.0

                  An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

                  Example

                  class Foo
                  {
                      public function bar($flag)
                      {
                          if ($flag) {
                              // one branch
                          } else {
                              // another branch
                          }
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#elseexpression

                  Avoid using static access to class '\App\Config' in method 'testRecord'.
                  Open

                          $this->assertSame('+ ' . \App\Config::main('PORTAL_URL') . '/index.php?module=Leads&action=index&id=' . self::$recordLeads->getId() . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Record_Model' in method 'testAmountToReturn'.
                  Open

                          $correctingInvoiceModel = \Vtiger_Record_Model::getCleanInstance('FCorectingInvoice');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetSourceVariable'.
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_value']), 'Option: ' . $data['label'] . ', value: ' . $data['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  The method testGetSourceVariable uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                                  } else {
                                      foreach ($data as $element) {
                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  ElseExpression

                  Since: 1.4.0

                  An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

                  Example

                  class Foo
                  {
                      public function bar($flag)
                      {
                          if ($flag) {
                              // one branch
                          } else {
                              // another branch
                          }
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#elseexpression

                  Avoid using static access to class '\App\User' in method 'testAmountToReturn'.
                  Open

                          $invoiceModel->set('assigned_user_id', \App\User::getCurrentUserId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetSourceVariable'.
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Record_Model' in method 'testRecord'.
                  Open

                          $comment = \Vtiger_Record_Model::getCleanInstance('ModComments');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Language' in method 'testTranslate'.
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Language' in method 'testTranslate'.
                  Open

                              '+' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetGeneralVariable'.
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($placeholder), 'Option: ' . $translation . ', value: ' . $placeholder . ' should be parseable in group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\Vtiger_Record_Model' in method 'testAmountToReturn'.
                  Open

                          $invoiceModel = \Vtiger_Record_Model::getCleanInstance('FInvoice');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Language' in method 'testTranslate'.
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\Language' in method 'testTranslate'.
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Avoid using static access to class '\App\TextParser' in method 'testGetSourceVariable'.
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

                  Source https://phpmd.org/rules/cleancode.html#staticaccess

                  Define a constant instead of duplicating this literal " should be parseable in group: " 10 times.
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "LBL_COPY_BILLING_ADDRESS" 4 times.
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "Record instance: Translations should be equal" 3 times.
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "Clean instance: Translations should be equal" 3 times.
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "+ $(record : ChangesListChanges)$ +" 4 times.
                  Open

                          $text = '+ $(record : ChangesListChanges)$ +';
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+" 6 times.
                  Open

                              self::$parserClean->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "Accounts" 4 times.
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "Leads" 3 times.
                  Open

                          self::$parserCleanModule = \App\TextParser::getInstance('Leads');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "Expected any related variables data" 8 times.
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "ModComments" 3 times.
                  Open

                          $comment = \Vtiger_Record_Model::getCleanInstance('ModComments');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "Option: " 12 times.
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "Expected array type" 11 times.
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal ", value: " 12 times.
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "var_label" 8 times.
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "OSSEmployees" 6 times.
                  Open

                          \App\User::setCurrentUserId((new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['status' => 'Active'])->andWhere(['not in', 'id', (new \App\Db\Query())->select(['smownerid'])->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees'])
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "assigned_user_id" 3 times.
                  Open

                          $employeeModel->set('assigned_user_id', $employeeUser->getId());
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "Y-m-d" 8 times.
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d') . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "var_value" 9 times.
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "\App\TextParser" 4 times.
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserClean, 'Expected clean instance without module of \App\TextParser');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "LBL_SECONDS" 4 times.
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Define a constant instead of duplicating this literal "label" 10 times.
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by sonar-php

                  Duplicated string literals make the process of refactoring error-prone, since you must be sure to update all occurrences.

                  On the other hand, constants can be referenced from many places, but only need to be updated in a single place.

                  Noncompliant Code Example

                  With the default threshold of 3:

                  function run() {
                    prepare('action1');                              // Non-Compliant - 'action1' is duplicated 3 times
                    execute('action1');
                    release('action1');
                  }
                  

                  Compliant Solution

                  ACTION_1 = 'action1';
                  
                  function run() {
                    prepare(ACTION_1);
                    execute(ACTION_1);
                    release(ACTION_1);
                  }
                  

                  Exceptions

                  To prevent generating some false-positives, literals having less than 5 characters are excluded.

                  Avoid unused local variables such as '$key'.
                  Open

                          foreach ($arr as $key => $content) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  UnusedLocalVariable

                  Since: 0.2

                  Detects when a local variable is declared and/or assigned, but not used.

                  Example

                  class Foo {
                      public function doSomething()
                      {
                          $i = 5; // Unused
                      }
                  }

                  Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

                  Avoid unused local variables such as '$key'.
                  Open

                              foreach ($data as $key => $element) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  UnusedLocalVariable

                  Since: 0.2

                  Detects when a local variable is declared and/or assigned, but not used.

                  Example

                  class Foo {
                      public function doSomething()
                      {
                          $i = 5; // Unused
                      }
                  }

                  Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

                  Avoid unused local variables such as '$key'.
                  Open

                          foreach ($arr as $key => $content) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  UnusedLocalVariable

                  Since: 0.2

                  Detects when a local variable is declared and/or assigned, but not used.

                  Example

                  class Foo {
                      public function doSomething()
                      {
                          $i = 5; // Unused
                      }
                  }

                  Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable

                  Call to method getInstanceById from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertInstanceOf('\App\TextParser', \App\TextParser::getInstanceById($recordModel->getId(), 'Leads'), 'Expected instance from lead id and module string of \App\TextParser');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getBaseListVariable from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $arr = self::$parserClean->getBaseListVariable();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \App\Config::main('PORTAL_URL') . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserCleanModule = \App\TextParser::getInstance('Leads');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getRelatedListVariable from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $arr = self::$parserCleanModule->getRelatedListVariable();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \App\Config::main('site_URL') . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertInstanceOf
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserClean, 'Expected clean instance without module of \App\TextParser');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              self::$parserClean->setContent('+ $(general : UserTimeZone)$ +')->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . (new \DateTimeField(null))->getDisplayDate() . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \Vtiger_Util_Helper::convertTimeIntoUsersDisplayFormat(date('H:i:s')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame(0, \App\TextParser::isVaribleToParse('$X(TestGroup : TestVar)$'), 'string should be not parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertInstanceOf
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserCleanModule, 'Expected clean instance with module Leads of \App\TextParser');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(1, \App\TextParser::isVaribleToParse('$(TestGroup : TestVar)$'), 'string should be parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \App\Config::main('site_URL') . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related list data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame(1, \App\TextParser::isVaribleToParse('$(TestGroup : TestVar)$'), 'string should be parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Property \Tests\App\TextParser::$parserRecord has undeclared type \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                      private static $parserRecord;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserClean = \App\TextParser::getInstance();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Property \Tests\App\TextParser::$parserCleanModule has undeclared type \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                      private static $parserCleanModule;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(0, \App\TextParser::isVaribleToParse('$X(TestGroup : TestVar)$'), 'string should be not parseable');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Argument 1 (value) is null but \DateTimeField::__construct() takes \type defined at /code/include/fields/DateTimeField.php:31
                  Open

                          $this->assertSame('+ ' . (new \DateTimeField(null))->getDisplayDate() . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertInstanceOf
                  Open

                          $this->assertInstanceOf('\App\TextParser', \App\TextParser::getInstanceById($recordModel->getId(), 'Leads'), 'Expected instance from lead id and module string of \App\TextParser');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstanceByModel from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord = \App\TextParser::getInstanceByModel($recordModel);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              self::$parserClean->setContent('+ $(general : BaseTimeZone)$ +')->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \App\Config::main('PORTAL_URL') . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Property \Tests\App\TextParser::$parserClean has undeclared type \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                      private static $parserClean;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getCurrentUserModel from undeclared class \App\User (Did you mean class \Tests\App\User)
                  Open

                          $user = \App\User::getCurrentUserModel();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertInstanceOf
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserRecord, 'Expected instance from record model of \App\TextParser');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \Vtiger_Util_Helper::convertTimeIntoUsersDisplayFormat(date('H:i:s')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related list data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . (new \DateTimeField(null))->getDisplayDate() . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ PlaceholderNotExist +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('monday this week')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('first day of this month')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('first day of this month')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($employeeUser->getId(), 'New user id should be not empty');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setCurrentUserId from undeclared class \App\User (Did you mean class \Tests\App\User)
                  Open

                          \App\User::setCurrentUserId($currentUser);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->withoutTranslations(false);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ TestComment +', self::$parserRecord->setContent($text)
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                          $this->assertIsArray($arr, 'Expected (cached) array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('monday next week')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ test +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getCurrentUserId from undeclared class \App\User (Did you mean class \Tests\App\User)
                  Open

                          $currentUser = \App\User::getCurrentUserId();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->withoutTranslations(true);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserClean->withoutTranslations(false);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                              $this->assertNotEmpty($content, 'Expected any related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($result, 'relatedRecordsList should return not empty string if related records found');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected url is different');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertStringContainsString
                  Open

                          $this->assertStringContainsString('test', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list should should contain vat_id info');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertStringContainsString('test', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list should should contain vat_id info');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertStringContainsString('testing', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list values should be not empty');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->get('company') . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record company should be same as in db');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              self::$parserRecord->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->withoutTranslations(false);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getRecordVariable from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $arr = self::$parserCleanModule->getRecordVariable();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                                  $this->assertNotEmpty($data, 'Expected any related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ PlaceholderNotExist +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d') . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('first day of next month')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getParam from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertNull(self::$parserClean->getParam('test_var_not_exist'), 'Clean instance: key not exist, getParam should return false');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', self::$parserRecord
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstanceByModel from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $result = \App\TextParser::getInstanceByModel(self::$recordLeads)->withoutTranslations(true)
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->getId() . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected record id is different');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->withoutTranslations(false);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', self::$parserRecord->setContent($text)
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              self::$parserRecord->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getCurrentUserId from undeclared class \App\User (Did you mean class \Tests\App\User)
                  Open

                          $tmpUser = \App\User::getCurrentUserId();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setCurrentUserId from undeclared class \App\User (Did you mean class \Tests\App\User)
                  Open

                          \App\User::setCurrentUserId((new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['status' => 'Active'])->andWhere(['not in', 'id', (new \App\Db\Query())->select(['smownerid'])->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees'])
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertEmpty
                  Open

                          $this->assertEmpty($result, 'relatedRecordsList should return empty string if no related records found');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', self::$parserClean->setContent($text)->parse()->getContent(), 'Expected empty string');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('last day of this month')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \App\Db\Query::select
                  Open

                          \App\User::setCurrentUserId((new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['status' => 'Active'])->andWhere(['not in', 'id', (new \App\Db\Query())->select(['smownerid'])->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees'])
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->getId() . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected record id is different');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->getName() . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected record label is different');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_value']), 'Option: ' . $data['label'] . ', value: ' . $data['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('+1 day')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotFalse
                  Open

                          $this->assertNotFalse(strpos($result, 'records-list'), 'Record list should contain html class recordsList');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ Leads +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected module name is different');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->withoutTranslations(true);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              self::$parserClean->setContent('+$(general : CurrentDate)$ | $(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parseTranslations()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->withoutTranslations(true);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('monday this week')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ test +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \App\Db\Query::select
                  Open

                          $userExistsId = (new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['user_name' => $userName])
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($result, 'recordsList should return not empty string(CustomView not exists)');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertEmpty
                  Open

                          $this->assertEmpty($result, 'relatedRecordsList should return empty string if no related records found(CustomView not exists)');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('Mail podstawowy: test3@yetiforce.com<br>', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ $(translate : Leads|Email)$: test3@yetiforce.com<br> +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->withoutTranslations(false);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setLanguage from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              self::$parserClean->setLanguage('pl-PL')->setContent('+$(general : CurrentDate)$ | $(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parseTranslations()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                              $this->assertIsArray($data, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('+1 day')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \App\Db\Query::select
                  Open

                          $employeeExistsId = (new \App\Db\Query())
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($result, 'recordsList should return not empty string');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertStringContainsString('test', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list should should contain vat_id info');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getRecordVariable from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $arr = self::$parserCleanModule->getRecordVariable();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('first day of next month')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotFalse
                  Open

                          $this->assertNotFalse(\strpos($result, $contactModel->get('firstname')), 'relatedRecordsList should contain test record row');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('Mail podstawowy: test3@yetiforce.com<br>', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->get('company') . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record company should be same as in db');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              self::$parserClean->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($arr, 'Expected any (cached) related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d') . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('last day of this month')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getParam from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('test', self::$parserClean->getParam('test_var'), 'Clean instance: getParam should return value test');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setCurrentUserId from undeclared class \App\User (Did you mean class \Tests\App\User)
                  Open

                          \App\User::setCurrentUserId($tmpUser);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstanceByModel from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $result = \App\TextParser::getInstanceByModel(self::$recordLeads)
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \App\Config::main('site_URL') . 'index.php?module=Leads&view=Detail&record=' . self::$recordLeads->getId() . ' +',
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Reference to instance property recordModel from undeclared class \App\TextParser
                  Open

                          self::$parserRecord->recordModel->set('email', 'test3@yetiforce.com')->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ $(translate : Leads|Email)$: test3@yetiforce.com<br> +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', self::$parserRecord->setContent($text)
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                                  $this->assertIsArray($data, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('monday next week')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setParams from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserClean->setParams(['test_var' => 'test']);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setCurrentUserId from undeclared class \App\User (Did you mean class \Tests\App\User)
                  Open

                          \App\User::setCurrentUserId($employeeUser->getId());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $result = \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($result, 'relatedRecordsList should return not empty string if related records found');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', self::$parserClean->setContent($text)->parse()->getContent(), 'Expected empty string');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \App\Config::main('PORTAL_URL') . '/index.php?module=Leads&action=index&id=' . self::$recordLeads->getId() . ' +',
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertFalse(\App\TextParser::getInstance('Leads')->setSourceRecord(self::$recordLeads->getId())->getSourceVariable(), 'TextParser::getSourceVariable() should return false for Leads module');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertFalse
                  Open

                          $this->assertFalse(\App\TextParser::getInstance('Leads')->setSourceRecord(self::$recordLeads->getId())->getSourceVariable(), 'TextParser::getSourceVariable() should return false for Leads module');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $arr = \App\TextParser::getInstance('Campaigns')->setSourceRecord(self::$recordLeads->getId())->getSourceVariable();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $result = \App\TextParser::getInstance()->withoutTranslations(true)
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstanceByModel from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $result = \App\TextParser::getInstanceByModel($accountModel)->withoutTranslations(true)
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNull
                  Open

                          $this->assertNull(self::$parserClean->getParam('test_var_not_exist'), 'Clean instance: key not exist, getParam should return false');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotFalse
                  Open

                          $this->assertNotFalse(\strpos($result, $contactModel->get('firstname')), 'relatedRecordsList should contain test record row');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstanceByModel from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $result = \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createAccountRecord())->withoutTranslations(true)
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected url is different');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertStringContainsString
                  Open

                          $this->assertStringContainsString('test', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list should should contain vat_id info');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ Leads +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected module name is different');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->getName() . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected record label is different');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserRecord->withoutTranslations(true);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                              $this->assertIsArray($content, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertStringContainsString
                  Open

                          $this->assertStringContainsString('testing', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list values should be not empty');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_label']), 'Option: ' . $data['label'] . ', value: ' . $data['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              self::$parserClean->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                              $this->assertNotEmpty($data, 'Expected any related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_value']), 'Option: ' . $data['label'] . ', value: ' . $data['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(4, \substr_count($result, '<th '), 'Columns count should be equal to provided list');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ TestComment +', self::$parserRecord->setContent($text)
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method withoutTranslations from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          self::$parserClean->withoutTranslations(true);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('-1 day')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('-1 day')) . ' +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('test', self::$parserClean->getParam('test_var'), 'Clean instance: getParam should return value test');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('+  +', self::$parserRecord
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              \App\TextParser::getInstance()
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($placeholder), 'Option: ' . $translation . ', value: ' . $placeholder . ' should be parseable in group: ' . $groupName);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstanceByModel from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname|Accounts)$+')->parse()->getContent() . ' +', 'Account name should be not empty');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                                          $this->assertNotEmpty($placeholders, 'Expected any group data in group: ' . $groupName);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              '+  +', self::$parserClean->setContent('+ $(sourceRecord : description)$ +')->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotSame
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceById($comment->getId(), 'ModComments')->setContent('+ $(relatedRecord : related_to|company)$ +')->parse()->getContent() . ' +', 'Lead creator email should be not empty');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                              $this->assertIsArray($content, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstance from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $arr = \App\TextParser::getInstance('IStorages')->getGeneralVariable();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                                  $this->assertIsArray($data, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                                          $this->assertIsArray($placeholders, 'Expected array type  in group: ' . $groupName);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                              $this->assertSame(1, \App\TextParser::isVaribleToParse($item), 'Option: ' . $translation . ', value: ' . $item . ' should be parseable in group: ' . $groupName);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstanceByModel from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname)$+')->parse()->getContent() . ' +', 'Account name should be not empty(without module)');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getCurrentUserId from undeclared class \App\User (Did you mean class \Tests\App\User)
                  Open

                          $invoiceModel->set('assigned_user_id', \App\User::getCurrentUserId());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                          $this->assertIsArray($arr, 'Expected (cached) array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($placeholder), 'Option: ' . $translation . ', value: ' . $placeholder . ' should be parseable in group: ' . $groupName);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              self::$parserRecord->setContent('+$(sourceRecord : description)$+')->setSourceRecord(\Tests\Base\C_RecordActions::createLeadRecord()->getId())->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame(
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                              '+autogenerated test lead for \App\TextParser tests+', self::$parserClean->setContent('+$(sourceRecord : description)$+')->setSourceRecord(\Tests\Base\C_RecordActions::createLeadRecord()->getId())->parse()->getContent(),
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                              $this->assertIsArray($group, 'Expected array type from group: ' . $groupName);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotSame
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname|Accounts)$+')->parse()->getContent() . ' +', 'Account name should be not empty');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotSame
                  Open

                          $this->assertNotSame('+  +', '+ ' . self::$parserRecord->setContent('+$(relatedRecord : assigned_user_id|user_name|Users)$+')->parse()->getContent() . ' +', 'Lead creator user_name should be not empty');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_label']), 'Option: ' . $data['label'] . ', value: ' . $data['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                              $this->assertNotEmpty($content, 'Expected any related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotSame
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname)$+')->parse()->getContent() . ' +', 'Account name should be not empty(without module)');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method setContent from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertNotSame('+  +', '+ ' . self::$parserRecord->setContent('+$(relatedRecord : assigned_user_id|user_name|Users)$+')->parse()->getContent() . ' +', 'Lead creator user_name should be not empty');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                          $this->assertSame('-14.29 zł', \App\TextParser::getInstanceByModel($correctingInvoiceModel)->setContent('$(custom : AmountToReturn)$')->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstanceById from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceById($comment->getId(), 'ModComments')->setContent('+ $(relatedRecord : related_to|company)$ +')->parse()->getContent() . ' +', 'Lead creator email should be not empty');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getInstanceByModel from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $this->assertSame('-14.29 zł', \App\TextParser::getInstanceByModel($correctingInvoiceModel)->setContent('$(custom : AmountToReturn)$')->parse()->getContent());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertSame
                  Open

                                              $this->assertSame(1, \App\TextParser::isVaribleToParse($item), 'Option: ' . $translation . ', value: ' . $item . ' should be parseable in group: ' . $groupName);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                                  $this->assertNotEmpty($data, 'Expected any related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method isVaribleToParse from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertIsArray
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($arr, 'Expected any (cached) related variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                          $this->assertNotEmpty($arr, 'Expected any general variables data');
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to undeclared method \Tests\App\TextParser::assertNotEmpty
                  Open

                              $this->assertNotEmpty($group, 'Expected any data in group: ' . $groupName);
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getRelatedVariable from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $arr = self::$parserCleanModule->getRelatedVariable();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getRelatedVariable from undeclared class \App\TextParser (Did you mean class \Tests\App\TextParser)
                  Open

                          $arr = self::$parserCleanModule->getRelatedVariable();
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Call to method getCurrentUserId from undeclared class \App\User (Did you mean class \Tests\App\User)
                  Open

                          $correctingInvoiceModel->set('assigned_user_id', \App\User::getCurrentUserId());
                  Severity: Critical
                  Found in tests/App/TextParser.php by phan

                  Identical blocks of code found in 2 locations. Consider refactoring.
                  Open

                                      foreach ($data as $element) {
                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                                      }
                  Severity: Major
                  Found in tests/App/TextParser.php and 1 other location - About 1 hr to fix
                  tests/App/TextParser.php on lines 567..570

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 114.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Identical blocks of code found in 2 locations. Consider refactoring.
                  Open

                                  foreach ($data as $element) {
                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                                  }
                  Severity: Major
                  Found in tests/App/TextParser.php and 1 other location - About 1 hr to fix
                  tests/App/TextParser.php on lines 544..547

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 114.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                      public function testGetRelatedListVariable()
                      {
                          $arr = self::$parserCleanModule->getRelatedListVariable();
                          $this->assertIsArray($arr, 'Expected array type');
                          $this->assertNotEmpty($arr, 'Expected any related list data');
                  Severity: Minor
                  Found in tests/App/TextParser.php and 1 other location - About 50 mins to fix
                  tests/App/TextParser.php on lines 77..85

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 97.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                      public function testGetBaseListVariable()
                      {
                          $arr = self::$parserClean->getBaseListVariable();
                          $this->assertIsArray($arr, 'Expected array type');
                          $this->assertNotEmpty($arr, 'Expected any related list data');
                  Severity: Minor
                  Found in tests/App/TextParser.php and 1 other location - About 50 mins to fix
                  tests/App/TextParser.php on lines 90..98

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 97.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Avoid excessively long variable names like $correctingInvoiceModel. Keep variable name length under 20.
                  Open

                          $correctingInvoiceModel = \Vtiger_Record_Model::getCleanInstance('FCorectingInvoice');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpmd

                  LongVariable

                  Since: 0.2

                  Detects when a field, formal or local variable is declared with a long name.

                  Example

                  class Something {
                      protected $reallyLongIntName = -3; // VIOLATION - Field
                      public static function main( array $interestingArgumentsList[] ) { // VIOLATION - Formal
                          $otherReallyLongName = -5; // VIOLATION - Local
                          for ($interestingIntIndex = 0; // VIOLATION - For
                               $interestingIntIndex < 10;
                               $interestingIntIndex++ ) {
                          }
                      }
                  }

                  Source https://phpmd.org/rules/naming.html#longvariable

                  Only one argument is allowed per line in a multi-line function call
                  Open

                          self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected url is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Only one argument is allowed per line in a multi-line function call
                  Open

                          self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected url is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Only one argument is allowed per line in a multi-line function call
                  Open

                              '+  +', self::$parserClean->setContent('+ $(sourceRecord : description)$ +')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Only one argument is allowed per line in a multi-line function call
                  Open

                              '+autogenerated test lead for \App\TextParser tests+', self::$parserClean->setContent('+$(sourceRecord : description)$+')->setSourceRecord(\Tests\Base\C_RecordActions::createLeadRecord()->getId())->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       *
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      private static $parserClean;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Test record instance.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * @var \App\TextParser
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      private static $parserRecord;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * @var \App\TextParser
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Test clean instance.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       *
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserCleanModule, 'Expected clean instance with module Leads of \App\TextParser');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserRecord, 'Expected instance from record model of \App\TextParser');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(general : CurrentTime)$ should return current time');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(date : yesterday)$ should return yesterday date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * @var \App\TextParser
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: $(general : BaseTimeZone)$ should return system timezone');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              self::$parserClean->setContent('+ $(general : UserTimeZone)$ +')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(general : SiteUrl)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testDate()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(date : now)$ should return current date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('-1 day')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(date : monday next week)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(date : monday next week)$ should return next week monday date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests related module variables list.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 121 characters
                  Open

                          $this->assertSame(1, \App\TextParser::isVaribleToParse('$(TestGroup : TestVar)$'), 'string should be parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(notExist : CurrentTime)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(general : SiteUrl)$ should return site url');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(date : yesterday)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('monday this week')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       *
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          foreach ($arr as $option) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related list data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . (new \DateTimeField(null))->getDisplayDate() . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(general : CurrentDate)$ should return current date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 129 characters
                  Open

                          $this->assertSame('+ ' . \Vtiger_Util_Helper::convertTimeIntoUsersDisplayFormat(date('H:i:s')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+ ' . (empty($defaultTimeZone = date_default_timezone_get()) ? \App\Config::main('default_timezone') : $defaultTimeZone) . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('first day of this month')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /** @var \Vtiger_Record_Model Temporary Products record object. */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testGetRelatedListVariable()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $arr = self::$parserCleanModule->getRelatedListVariable();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          foreach ($arr as $option) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: unregistered function placeholder should return empty string');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing instances creation.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testGetBaseListVariable()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(general : CurrentDate)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests date placeholders replacement.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Test clean instance with module.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related list data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(general : PortalUrl)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserClean, 'Expected clean instance without module of \App\TextParser');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$recordLeads = $recordModel = \Tests\Base\C_RecordActions::createLeadRecord(false);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests empty content condition.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests static methods.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(date : tomorrow)$ should return tommorow date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('monday next week')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      private static $product;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testUnregisteredFunction()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(general : CurrentTime)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(date : tomorrow)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserClean = \App\TextParser::getInstance();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          );
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \App\Config::main('site_URL') . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(general : PortalUrl)$ should return portal url');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      private static $parserCleanModule;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /** @var \Vtiger_Record_Model Temporary Leads record object. */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testInstancesCreation()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertInstanceOf('\App\TextParser', \App\TextParser::getInstanceById($recordModel->getId(), 'Leads'), 'Expected instance from lead id and module string of \App\TextParser');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 130 characters
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserRecord, 'Expected instance from record model of \App\TextParser');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 171 characters
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 141 characters
                  Open

                              '+ ' . (empty($defaultTimeZone = date_default_timezone_get()) ? \App\Config::main('default_timezone') : $defaultTimeZone) . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 188 characters
                  Open

                          $this->assertInstanceOf('\App\TextParser', \App\TextParser::getInstanceById($recordModel->getId(), 'Leads'), 'Expected instance from lead id and module string of \App\TextParser');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testEmptyContent()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests base variables list.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 171 characters
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: $(general : UserTimeZone)$ should return user timezone'
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(date : now)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('+1 day')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: empty content should return empty result');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertSame(1, \App\TextParser::isVaribleToParse($option['key']), 'Option: ' . $option['label'] . ', value: ' . $option['key'] . ' should be parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      protected static $recordLeads;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserCleanModule = \App\TextParser::getInstance('Leads');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $arr = self::$parserClean->getBaseListVariable();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(1, \App\TextParser::isVaribleToParse('$(TestGroup : TestVar)$'), 'string should be parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(0, \App\TextParser::isVaribleToParse('$X(TestGroup : TestVar)$'), 'string should be not parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              self::$parserClean->setContent('+ $(general : BaseTimeZone)$ +')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ PlaceholderNotExist +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(general : PlaceholderNotExist)$ should return placeholder var name');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(date : monday this week)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(date : monday this week)$ should return this week monday date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 132 characters
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserClean, 'Expected clean instance without module of \App\TextParser');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 141 characters
                  Open

                          $this->assertInstanceOf('\App\TextParser', self::$parserCleanModule, 'Expected clean instance with module Leads of \App\TextParser');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests general placeholders replacement.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testGeneral()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \Vtiger_Util_Helper::convertTimeIntoUsersDisplayFormat(date('H:i:s')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+ ' . ($user->getDetail('time_zone') ?: \App\Config::main('default_timezone')) . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \App\Config::main('PORTAL_URL') . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d') . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord = \App\TextParser::getInstanceByModel($recordModel);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testStaticMethods()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 126 characters
                  Open

                          $this->assertSame(0, \App\TextParser::isVaribleToParse('$X(TestGroup : TestVar)$'), 'string should be not parseable');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests empty content condition.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $user = \App\User::getCurrentUserModel();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(general : PlaceholderNotExist)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(params : test_var_not_exist)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing Employee placeholders.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->scalar();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeModel = $employeeExistsId ? \Vtiger_Record_Model::getInstanceById($employeeExistsId, 'OSSEmployees') : \Vtiger_Record_Model::getCleanInstance('OSSEmployees');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testBasicField()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->select(['crmid'])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+ ' . \Vtiger_Record_Model::getInstanceById($employeeModel->getId(), 'OSSEmployees')->get('name') . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->scalar());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: By default employee last name should be empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser->set('is_admin', 'on');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '$(recordsList : Leads|lead_no,company,email,description|[[["company","a","Test"]]]|All|5)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($result, 'recordsList should return not empty string');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '$(relatedRecordsList : Accounts|lead_no,lastname,phone,description|[[["company","a","Test"]]]|All|5)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 122 characters
                  Open

                              ->getContent(), 'Clean instance: $(date : first day of this month)$ should return this month first day date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testParams()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testEmployee()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(employee : name)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  ->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testRecordsListPlaceholders()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotFalse(strpos($result, 'records-list'), 'Record list should contain html class recordsList');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->column(), ])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser->set('last_name', 'YetiForce');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeExistsId = (new \App\Db\Query())
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: Employee name should be same as in db'
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          );
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 122 characters
                  Open

                              ->getContent(), 'Clean instance: $(date : first day of next month)$ should return next month first day date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: Test params placeholder should return value test');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->scalar();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser->set('user_name', $userName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser->set('user_password', \Tests\Base\A_User::$defaultPassrowd);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees', 'smownerid' => $employeeUser->getId()])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $result = \App\TextParser::getInstance()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '$(recordsList : Leads|lead_no,lastname,phone,description|[[["company","a","Test"]]]|NotExist|5)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $result = \App\TextParser::getInstanceByModel(self::$recordLeads)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('last day of this month')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 277 characters
                  Open

                          \App\User::setCurrentUserId((new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['status' => 'Active'])->andWhere(['not in', 'id', (new \App\Db\Query())->select(['smownerid'])->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees'])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 130 characters
                  Open

                              ->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees', 'smownerid' => $employeeUser->getId()])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->limit(1)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(4, \substr_count($result, '<th '), 'Columns count should be equal to provided list');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $result = \App\TextParser::getInstanceByModel(self::$recordLeads)->withoutTranslations(true)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 129 characters
                  Open

                          $this->assertSame('test', self::$parserClean->getParam('test_var'), 'Clean instance: getParam should return value test');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Record instance: By default employee last name should be empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          \App\Cache::clear();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+ ' . \Vtiger_Record_Model::getInstanceById($employeeModel->getId(), 'OSSEmployees')->get('name') . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          );
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \date('Y-m-d', \strtotime('first day of next month')) . ' +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $tmpUser = \App\User::getCurrentUserId();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser->set('email1', $userName . '@yetiforce.com');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser->set('roleid', 'H2');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeModel->set('assigned_user_id', $employeeUser->getId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  ->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: Test param not exist, placeholder should return empty value');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('test', self::$parserClean->getParam('test_var'), 'Clean instance: getParam should return value test');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          \App\Cache::clear();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          \App\User::setCurrentUserId($employeeUser->getId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(date : first day of next month)$ should return next month first day date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeModel->set('name', 'Test employee');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              \App\TextParser::getInstance()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing basic field placeholder replacement.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing records list placeholders replacement.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing related records list placeholders replacement.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertEmpty($result, 'relatedRecordsList should return empty string if no related records found');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(date : first day of next month)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(date : first day of this month)$ should return this month first day date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 141 characters
                  Open

                          $this->assertNull(self::$parserClean->getParam('test_var_not_exist'), 'Clean instance: key not exist, getParam should return false');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing params functions.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ test +', self::$parserClean
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser = $userExistsId ? \Vtiger_Record_Model::getInstanceById($userExistsId, 'Users') : \Vtiger_Record_Model::getCleanInstance('Users');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          \App\User::setCurrentUserId($tmpUser);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              \App\TextParser::getInstance()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($result, 'recordsList should return not empty string(CustomView not exists)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testRelatedRecordsList()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(params : test_var)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          \App\User::setCurrentUserId((new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['status' => 'Active'])->andWhere(['not in', 'id', (new \App\Db\Query())->select(['smownerid'])->from('vtiger_crmentity')->where(['deleted' => 0, 'setype' => 'OSSEmployees'])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 152 characters
                  Open

                          $employeeUser = $userExistsId ? \Vtiger_Record_Model::getInstanceById($userExistsId, 'Users') : \Vtiger_Record_Model::getCleanInstance('Users');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($employeeUser->getId(), 'New user id should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser->set('confirm_password', \Tests\Base\A_User::$defaultPassrowd);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          \App\User::setCurrentUserId($currentUser);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeModel->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $result = \App\TextParser::getInstance()->withoutTranslations(true)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 122 characters
                  Open

                          $text = '$(relatedRecordsList : Leads|lead_no,lastname,phone,description|[[["company","a","Test"]]]|NotExist|5)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(date : last day of this month)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: $(date : last day of this month)$ should return this month last day date');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserClean->setParams(['test_var' => 'test']);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNull(self::$parserClean->getParam('test_var_not_exist'), 'Clean instance: key not exist, getParam should return false');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(employee : last_name)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', self::$parserRecord
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $currentUser = \App\User::getCurrentUserId();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $userName = 'Employee';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $userExistsId = (new \App\Db\Query())->select(['id'])->from('vtiger_users')->where(['user_name' => $userName])
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: Employee name should be same as in db(cached)'
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '$(relatedRecordsList : Leads|lead_no,lastname,phone,description|[[["company","a","Test"]]]|NotExist|5)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent('+ $(date : first day of this month)$ +')
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Clean instance: By default employee last name should be empty(cached)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $employeeUser->set('first_name', $userName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 175 characters
                  Open

                          $employeeModel = $employeeExistsId ? \Vtiger_Record_Model::getInstanceById($employeeExistsId, 'OSSEmployees') : \Vtiger_Record_Model::getCleanInstance('OSSEmployees');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 147 characters
                  Open

                          $this->assertSame('+ ' . \App\Config::main('PORTAL_URL') . '/index.php?module=Leads&action=index&id=' . self::$recordLeads->getId() . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : ChangesListChanges)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : ChangesListChanges)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ TestComment +', self::$parserRecord->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              self::$parserClean->setContent('+$(general : CurrentDate)$ | $(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parseTranslations()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $accountModel = \Tests\Base\C_RecordActions::createAccountRecord();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(custom : NotExists|NotExists)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : PortalDetailViewURL)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $contactModel = \Tests\Base\C_RecordActions::createContactRecord();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : RecordLabel)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 149 characters
                  Open

                          $this->assertSame('+ $(translate : Leads|Email)$: test3@yetiforce.com<br> +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '$(relatedRecordsList : Contacts|firstname,decision_maker,createdtime,contactstatus,verification|[[["firstname","a","Test"]]]|NotExists|5)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$recordLeads->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertStringContainsString('test', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list should should contain vat_id info');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : Comments 5|true)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'custom function with not existent Leads module parser should return empty string');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $comment->set('commentcontent', 'TestComment');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected url is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 166 characters
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ Leads +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected module name is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->getName() . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected record label is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : ChangesListChanges)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $comment->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'custom function with not existent parser should return empty string');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 139 characters
                  Open

                          $this->assertSame('+ Leads +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected module name is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 167 characters
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->getId() . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected record id is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$recordLeads->set('vat_id', 'test');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 151 characters
                  Open

                              self::$parserRecord->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 151 characters
                  Open

                              self::$parserRecord->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              foreach ($data as $key => $element) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 210 characters
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests source variables array.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_label']), 'Option: ' . $data['label'] . ', value: ' . $data['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testGetRelatedVariable()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                              $this->assertSame(1, \App\TextParser::isVaribleToParse($item), 'Option: ' . $translation . ', value: ' . $item . ' should be parseable in group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 151 characters
                  Open

                          $text = '$(relatedRecordsList : Contacts|firstname,decision_maker,createdtime,contactstatus,verification|[[["firstname","a","Test"]]]|All|5)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($result, 'relatedRecordsList should return not empty string if related records found');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($result, 'relatedRecordsList should return not empty string if related records found');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing custom placeholders.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \App\Config::main('PORTAL_URL') . '/index.php?module=Leads&action=index&id=' . self::$recordLeads->getId() . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('Mail podstawowy: test3@yetiforce.com<br>', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ $(translate : Leads|Email)$: test3@yetiforce.com<br> +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Test record comments list should be empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              self::$parserClean->setLanguage('pl-PL')->setContent('+$(general : CurrentDate)$ | $(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parseTranslations()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          foreach ($arr as $group => $data) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertIsArray($data, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertNotEmpty($data, 'Expected any related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertIsArray($content, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 214 characters
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertIsArray($group, 'Expected array type from group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              if (!empty($group)) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                      if (!\strpos($placeholder, ', ')) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 157 characters
                  Open

                          $text = '$(relatedRecordsList : Contacts|firstname,decision_maker,createdtime,contactstatus,verification|[[["firstname","a","Test"]]]|NotExists|5)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(custom : NotExists)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : NotExists)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$recordLeads->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 175 characters
                  Open

                          $this->assertStringContainsString('test', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list should should contain vat_id info');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 205 characters
                  Open

                          $this->assertFalse(\App\TextParser::getInstance('Leads')->setSourceRecord(self::$recordLeads->getId())->getSourceVariable(), 'TextParser::getSourceVariable() should return false for Leads module');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 124 characters
                  Open

                          $arr = \App\TextParser::getInstance('Campaigns')->setSourceRecord(self::$recordLeads->getId())->getSourceVariable();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          foreach ($arr as $key => $content) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  foreach ($group as $placeholder => $translation) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(custom : NotExists|Leads)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected url is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : RecordId)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 172 characters
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->getName() . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected record label is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->withoutTranslations(false);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$recordLeads->set('vat_id', 'testing');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing basic translate function.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testTranslate()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 150 characters
                  Open

                              self::$parserClean->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              self::$parserRecord->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertFalse(\App\TextParser::getInstance('Leads')->setSourceRecord(self::$recordLeads->getId())->getSourceVariable(), 'TextParser::getSourceVariable() should return false for Leads module');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $arr = \App\TextParser::getInstance('Campaigns')->setSourceRecord(self::$recordLeads->getId())->getSourceVariable();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                      foreach ($data as $element) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 134 characters
                  Open

                          $this->assertNotFalse(\strpos($result, $contactModel->get('firstname')), 'relatedRecordsList should contain test record row');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 132 characters
                  Open

                          $result = \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createAccountRecord())->withoutTranslations(true)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(custom : TableTaxSummary)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->getId() . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected record id is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '$(record : ChangesListValues)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: Only translations should be replaced');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 205 characters
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_label']), 'Option: ' . $data['label'] . ', value: ' . $data['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  } else {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  $this->assertNotEmpty($data, 'Expected any related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($arr, 'Expected any (cached) related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotFalse(\strpos($result, $contactModel->get('firstname')), 'relatedRecordsList should contain test record row');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 134 characters
                  Open

                          $this->assertNotFalse(\strpos($result, $contactModel->get('firstname')), 'relatedRecordsList should contain test record row');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->withoutTranslations(true);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertStringContainsString('test', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list should should contain vat_id info');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 175 characters
                  Open

                          $this->assertStringContainsString('test', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list should should contain vat_id info');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : company)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', self::$parserRecord->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 190 characters
                  Open

                              self::$parserClean->setContent('+$(general : CurrentDate)$ | $(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parseTranslations()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserClean->withoutTranslations(true);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests record variables array.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 218 characters
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertIsArray($content, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertNotEmpty($group, 'Expected any data in group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertEmpty($result, 'relatedRecordsList should return empty string if no related records found(CustomView not exists)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 136 characters
                  Open

                          $this->assertEmpty($result, 'relatedRecordsList should return empty string if no related records found(CustomView not exists)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->withoutTranslations(true);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->withoutTranslations(false);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->withoutTranslations(true);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : FieldNotExists)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  if (isset($data['var_value'])) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($arr, 'Expected any general variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          foreach ($arr as $groupName => $group) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 121 characters
                  Open

                          $this->assertSame('+  +', self::$parserClean->setContent($text)->parse()->getContent(), 'Expected empty string');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : ChangesListValues)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $comment->set('related_to', self::$recordLeads->getId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'Test function record when field not exists should return empty string');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              self::$parserClean->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              self::$parserRecord->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests related variables array.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $arr = self::$parserCleanModule->getRelatedVariable();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 214 characters
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertIsArray($arr, 'Expected (cached) array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                          $placeholders = \explode(', ', $placeholder);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testBasicSrcRecord()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '$(relatedRecordsList : Contacts|firstname,decision_maker,createdtime,contactstatus,verification|[[["firstname","a","Test"]]]|All|5)$';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $result = \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createAccountRecord())->withoutTranslations(true)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->recordModel->set('email', 'test3@yetiforce.com')->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : ChangesListChanges)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 166 characters
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $arr = self::$parserCleanModule->getRecordVariable();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($arr, 'Expected any related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $arr = self::$parserCleanModule->getRecordVariable();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $arr = \App\TextParser::getInstance('IStorages')->getGeneralVariable();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $contactModel->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testCustomPlaceholders()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->setContent($text)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->parse()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', self::$parserClean->setContent($text)->parse()->getContent(), 'Expected empty string');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 147 characters
                  Open

                          $this->assertSame('+ ' . \App\Config::main('site_URL') . 'index.php?module=Leads&view=Detail&record=' . self::$recordLeads->getId() . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : ModuleName)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 133 characters
                  Open

                          $this->assertSame('Mail podstawowy: test3@yetiforce.com<br>', self::$parserRecord->setContent($text)->parse()->getContent());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->withoutTranslations(false);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertStringContainsString('testing', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list values should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 171 characters
                  Open

                          $this->assertStringContainsString('testing', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record changes list values should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 186 characters
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->get('company') . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record company should be same as in db');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+$(general : CurrentDate)$ | ' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 138 characters
                  Open

                              '+' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              self::$parserClean->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 210 characters
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 218 characters
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                          $this->assertIsArray($placeholders, 'Expected array type  in group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                          foreach ($placeholders as $item) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 189 characters
                  Open

                                              $this->assertSame(1, \App\TextParser::isVaribleToParse($item), 'Option: ' . $translation . ', value: ' . $item . ' should be parseable in group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing basic source record related functions.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotFalse(\strpos($result, $contactModel->get('firstname')), 'relatedRecordsList should contain test record row');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : CrmDetailViewURL)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . \App\Config::main('site_URL') . 'index.php?module=Leads&view=Detail&record=' . self::$recordLeads->getId() . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $text = '+ $(record : ChangesListValues)$ +';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->withoutTranslations(false);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertIsArray($arr, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testGetSourceVariable()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  foreach ($data as $element) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Tests general variables array.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 199 characters
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($placeholder), 'Option: ' . $translation . ', value: ' . $placeholder . ' should be parseable in group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                          $this->assertNotEmpty($placeholders, 'Expected any group data in group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                          }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'custom function with not existent parser should return empty string');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing record vars placeholders replacement.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $comment = \Vtiger_Record_Model::getCleanInstance('ModComments');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 212 characters
                  Open

                              self::$parserClean->setLanguage('pl-PL')->setContent('+$(general : CurrentDate)$ | $(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parseTranslations()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 138 characters
                  Open

                              '+' . \App\Language::translate('LBL_SECONDS') . '==' . \App\Language::translate('LBL_COPY_BILLING_ADDRESS', 'Accounts') . '+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 205 characters
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_value']), 'Option: ' . $data['label'] . ', value: ' . $data['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          foreach ($arr as $key => $content) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              foreach ($content as $group => $data) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  $this->assertIsArray($data, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $contactModel->set('parent_id', $accountModel->getId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $result = \App\TextParser::getInstanceByModel($accountModel)->withoutTranslations(true)
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+  +', \App\TextParser::getInstance()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              ->getContent(), 'custom function with TableTaxSummary parser should return empty string');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testRecord()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('+ ' . self::$recordLeads->get('company') . ' +', self::$parserRecord->setContent($text)->parse()->getContent(), 'Test record company should be same as in db');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: Only translations should be replaced(setLanguage)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserRecord->withoutTranslations(true);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testGetRecordVariable()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertIsArray($arr, 'Expected (cached) array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotEmpty($arr, 'Expected any (cached) related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  $this->assertIsArray($data, 'Expected array type');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_label']), 'Option: ' . $element['label'] . ', value: ' . $element['var_label'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($placeholder), 'Option: ' . $translation . ', value: ' . $placeholder . ' should be parseable in group: ' . $groupName);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              foreach ($content as $group => $data) {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                  $this->assertNotEmpty($data, 'Expected any related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertNotEmpty($content, 'Expected any related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                      } else {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Testing related record placeholders.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['discountmode'] = 1;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['discountparam'] = json_encode([
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 150 characters
                  Open

                              self::$parserClean->setContent('+$(translate : LBL_SECONDS)$==$(translate : Accounts|LBL_COPY_BILLING_ADDRESS)$+')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$parserClean->withoutTranslations(false);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              $this->assertNotEmpty($content, 'Expected any related variables data');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                      $this->assertSame(1, \App\TextParser::isVaribleToParse($data['var_value']), 'Option: ' . $data['label'] . ', value: ' . $data['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testGetGeneralVariable()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testAmountToReturn(): void
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $invoiceModel->saveInventoryData();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $correctingInvoiceModel->set('assigned_user_id', \App\User::getCurrentUserId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['currency'] = \Vtiger_Util_Helper::getBaseCurrency()['id'];
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'aggregationType' => 'individual',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 178 characters
                  Open

                              self::$parserRecord->setContent('+$(sourceRecord : description)$+')->setSourceRecord(\Tests\Base\C_RecordActions::createLeadRecord()->getId())->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname|Accounts)$+')->parse()->getContent() . ' +', 'Account name should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $comment->set('commentcontent', 'TestComment');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $correctingInvoiceModel->set('subject', $subject);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Create Inventory for Amount to return test.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['taxmode'] = 0;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'globalTax' => 0,
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      private function createInventory(): array
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+  +', self::$parserClean->setContent('+ $(sourceRecord : description)$ +')->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+autogenerated test lead for \App\TextParser tests+', self::$parserClean->setContent('+$(sourceRecord : description)$+')->setSourceRecord(\Tests\Base\C_RecordActions::createLeadRecord()->getId())->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 267 characters
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname|Accounts)$+')->parse()->getContent() . ' +', 'Account name should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $invoiceModel->set('subject', $subject);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $correctingInvoiceModel = \Vtiger_Record_Model::getCleanInstance('FCorectingInvoice');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * @return array
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['qty'] = 1;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Clean instance: returned string should be empty if no source record provided');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $invoiceModel->set('assigned_user_id', \App\User::getCurrentUserId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->createProduct();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $invoiceModel->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $invoiceModel->delete();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'aggregationType' => 'individual',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          ]);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Cleaning after tests.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                                          $this->assertSame(1, \App\TextParser::isVaribleToParse($element['var_value']), 'Option: ' . $element['label'] . ', value: ' . $element['var_value'] . ' should be parseable in group: ' . $group);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $arr = self::$parserCleanModule->getRelatedVariable();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $correctingInvoiceModel->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname)$+')->parse()->getContent() . ' +', 'Account name should be not empty(without module)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['price'] = 110;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['discount'] = 26.4;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $correctingInvoiceModel->delete();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['price'] = 100;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['taxparam'] = json_encode([
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $comment->set('related_to', \Tests\Base\C_RecordActions::createLeadRecord()->getId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory = $this->createInventory();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'individualTax' => 88,
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * @return void
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$product->set('productname', 'Test');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              self::$parserRecord->setContent('+$(sourceRecord : description)$+')->setSourceRecord(\Tests\Base\C_RecordActions::createLeadRecord()->getId())->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $correctingInvoiceModel->set('finvoiceid', $invoiceModel->getId());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame('-14.29 zł', \App\TextParser::getInstanceByModel($correctingInvoiceModel)->setContent('$(custom : AmountToReturn)$')->parse()->getContent());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 168 characters
                  Open

                          $this->assertSame('-14.29 zł', \App\TextParser::getInstanceByModel($correctingInvoiceModel)->setContent('$(custom : AmountToReturn)$')->parse()->getContent());
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 232 characters
                  Open

                              '+autogenerated test lead for \App\TextParser tests+', self::$parserClean->setContent('+$(sourceRecord : description)$+')->setSourceRecord(\Tests\Base\C_RecordActions::createLeadRecord()->getId())->parse()->getContent(),
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $comment = \Vtiger_Record_Model::getCleanInstance('ModComments');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * @return void
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public function testRelatedRecord()
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 274 characters
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceByModel(\Tests\Base\C_RecordActions::createContactRecord())->setContent('+$(relatedRecord : parent_id|accountname)$+')->parse()->getContent() . ' +', 'Account name should be not empty(without module)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $invoiceModel->initInventoryData([$inventory]);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * Crete Products record.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$product->delete();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertSame(
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotSame('+  +', '+ ' . self::$parserRecord->setContent('+$(relatedRecord : assigned_user_id|user_name|Users)$+')->parse()->getContent() . ' +', 'Lead creator user_name should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 211 characters
                  Open

                          $this->assertNotSame('+  +', '+ ' . self::$parserRecord->setContent('+$(relatedRecord : assigned_user_id|user_name|Users)$+')->parse()->getContent() . ' +', 'Lead creator user_name should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['comment1'] = 'test';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          return $inventory;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      {
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$product = \Vtiger_Record_Model::getCleanInstance('Products');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $comment->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Line exceeds 120 characters; contains 242 characters
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceById($comment->getId(), 'ModComments')->setContent('+ $(relatedRecord : related_to|company)$ +')->parse()->getContent() . ' +', 'Lead creator email should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * test Amount to Return.
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       *
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      /**
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'individualDiscount' => 24,
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['name'] = self::$product->getId();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['unit'] = 'Hours';
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      }
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $this->assertNotSame('+  +', '+ ' . \App\TextParser::getInstanceById($comment->getId(), 'ModComments')->setContent('+ $(relatedRecord : related_to|company)$ +')->parse()->getContent() . ' +', 'Lead creator email should be not empty');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $subject = 'FV' . date('Y/m/d');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $correctingInvoiceModel->initInventoryData([$inventory]);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       *
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory = [];
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              'individualDiscountType' => 'percentage',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $inventory['discount'] = 24;
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      private function createProduct(): void
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       *
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       * @return void
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                      public static function tearDownAfterClass(): void
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                              '+autogenerated test lead for \App\TextParser tests+',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          $invoiceModel = \Vtiger_Record_Model::getCleanInstance('FInvoice');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       */
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          ]);
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                       *
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Spaces must be used to indent lines; tabs are not allowed
                  Open

                          self::$product->save();
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Clean instance: $(general : BaseTimeZone)$ should return system timezone');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Clean instance: $(general : BaseTimeZone)$ should return system timezone');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Clean instance: Only translations should be replaced(setLanguage)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                          self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected url is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Clean instance: Only translations should be replaced');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                          self::$parserRecord->setContent($text)->parse()->getContent(), 'Expected url is different');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Opening parenthesis of a multi-line function call must be the last content on the line
                  Open

                          $this->assertSame('+ ' . \App\Config::main('site_URL') . 'index.php?module=Leads&view=Detail&record=' . self::$recordLeads->getId() . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Clean instance: Only translations should be replaced');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Opening parenthesis of a multi-line function call must be the last content on the line
                  Open

                          $this->assertSame('+ ' . \App\Config::main('PORTAL_URL') . '/index.php?module=Leads&action=index&id=' . self::$recordLeads->getId() . ' +',
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Clean instance: Only translations should be replaced(setLanguage)');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Clean instance: returned string should be empty if no source record provided');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Closing parenthesis of a multi-line function call must be on a line by itself
                  Open

                              'Clean instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Record instance: Translations should be equal');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'Clean instance: returned string should be empty if no source record provided');
                  Severity: Minor
                  Found in tests/App/TextParser.php by phpcodesniffer

                  There are no issues that match your filters.

                  Category
                  Status