YetiForceCompany/YetiForceCRM

View on GitHub
tests/App/User.php

Summary

Maintainability
A
0 mins
Test Coverage
A
100%

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

        $this->assertNull(\App\User::clearCache(), 'Cache clearance error');
Severity: Minor
Found in tests/App/User.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 'testIsExists'.
Open

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists(cached)');
Severity: Minor
Found in tests/App/User.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 'testIsExists'.
Open

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists(cached)');
Severity: Minor
Found in tests/App/User.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 'testGetUserIdByName'.
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference(cached)');
Severity: Minor
Found in tests/App/User.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 'testGetUserIdByName'.
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference');
Severity: Minor
Found in tests/App/User.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 'testIsExists'.
Open

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists');
Severity: Minor
Found in tests/App/User.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 'testIsExists'.
Open

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists');
Severity: Minor
Found in tests/App/User.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 'testGetSharingFile'.
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null(cached)');
Severity: Minor
Found in tests/App/User.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 'testInstance'.
Open

        $this->assertInstanceOf('\App\User', \App\User::getCurrentUserModel(), 'Expected User current user object');
Severity: Minor
Found in tests/App/User.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 'testGetSharingFile'.
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null');
Severity: Minor
Found in tests/App/User.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 'testInstance'.
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getCurrentUserModel()->getId(), 'Expected that user ids will be equal');
Severity: Minor
Found in tests/App/User.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 'testGetSharingFile'.
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null');
Severity: Minor
Found in tests/App/User.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 'testGetUserIdByName'.
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference');
Severity: Minor
Found in tests/App/User.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 'testGetUserIdByName'.
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference(cached)');
Severity: Minor
Found in tests/App/User.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 'testGetSharingFile'.
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null(cached)');
Severity: Minor
Found in tests/App/User.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 'testGetSharingFile'.
Open

        $this->assertNull(\App\User::getSharingFile(0), 'Sharing file should be null(User not exists)');
Severity: Minor
Found in tests/App/User.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

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

        $this->assertNull(\App\User::clearCache(), 'Cache clearance error');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertInstanceOf('\Settings_Roles_Record_Model', \App\User::getCurrentUserModel()->getRoleInstance(), 'Expected current user role object');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertTrue(\App\User::getCurrentUserModel()->isActive(), 'Expected that current user is active');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertInstanceOf('\Settings_Roles_Record_Model', \App\User::getCurrentUserModel()->getRoleInstance(), 'Expected current user role object(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertInstanceOf('\Settings_Roles_Record_Model', \App\User::getCurrentUserModel()->getRoleInstance(), 'Expected current user role object(cached)');
Severity: Critical
Found in tests/App/User.php by phan

Call to undeclared method \Tests\App\User::assertTrue
Open

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertInstanceOf('\Settings_Roles_Record_Model', \App\User::getCurrentUserModel()->getRoleInstance(), 'Expected current user role object');
Severity: Critical
Found in tests/App/User.php by phan

Call to undeclared method \Tests\App\User::assertTrue
Open

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserModel()->getRoleInstance(), \App\User::getCurrentUserModel()->get('roleInstance'), 'Role instance should be same');
Severity: Critical
Found in tests/App/User.php by phan

Call to undeclared method \Tests\App\User::assertTrue
Open

        $this->assertTrue((bool) \App\User::getCurrentUserModel()->isAdmin(), 'Expected that current user is admin');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference(cached)');
Severity: Critical
Found in tests/App/User.php by phan

Call to undeclared method \Tests\App\User::assertTrue
Open

        $this->assertTrue(\App\User::getCurrentUserModel()->isActive(), 'Expected that current user is active');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertNotEmpty(\App\User::getCurrentUserModel()->getName(), 'Expected current user name');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertNotEmpty(\App\User::getCurrentUserModel()->getName(), 'Expected current user name');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getCurrentUserModel()->getId(), 'Expected that user ids will be equal');
Severity: Critical
Found in tests/App/User.php by phan

Call to undeclared method \Tests\App\User::assertNull
Open

        $this->assertNull(\App\User::clearCache(), 'Cache clearance error');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertInstanceOf('\App\User', \App\User::getCurrentUserModel(), 'Expected User current user object');
Severity: Critical
Found in tests/App/User.php by phan

Call to undeclared method \Tests\App\User::assertNotNull
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertTrue((bool) \App\User::getCurrentUserModel()->isAdmin(), 'Expected that current user is admin');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getCurrentUserModel()->getId(), 'Expected that user ids will be equal');
Severity: Critical
Found in tests/App/User.php by phan

Call to undeclared method \Tests\App\User::assertNotNull
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertNull(\App\User::getSharingFile(0), 'Sharing file should be null(User not exists)');
Severity: Critical
Found in tests/App/User.php by phan

Call to undeclared method \Tests\App\User::assertNull
Open

        $this->assertNull(\App\User::getSharingFile(0), 'Sharing file should be null(User not exists)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserModel()->getRoleInstance(), \App\User::getCurrentUserModel()->get('roleInstance'), 'Role instance should be same');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getCurrentUserModel()->getId(), 'Expected that user ids will be equal');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists(cached)');
Severity: Critical
Found in tests/App/User.php by phan

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

        $this->assertInstanceOf('\App\User', \App\User::getCurrentUserModel(), 'Expected User current user object');
Severity: Critical
Found in tests/App/User.php by phan

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Line exceeds 120 characters; contains 122 characters
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Line exceeds 120 characters; contains 130 characters
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null(cached)');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testInstance()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertNull(\App\User::clearCache(), 'Cache clearance error');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertNotEmpty(\App\User::getCurrentUserModel()->getName(), 'Expected current user name');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertInstanceOf('\Settings_Roles_Record_Model', \App\User::getCurrentUserModel()->getRoleInstance(), 'Expected current user role object(cached)');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Line exceeds 120 characters; contains 123 characters
Open

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists(cached)');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testGet()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing function Get.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing instance creation.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testIsActive()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testIsExists()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists(cached)');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getCurrentUserModel()->getId(), 'Expected that user ids will be equal');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testGetSharingFile()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing get name.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testIsAdmin()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing if current user is active.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertInstanceOf('\App\User', \App\User::getCurrentUserModel(), 'Expected User current user object');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertInstanceOf('\Settings_Roles_Record_Model', \App\User::getCurrentUserModel()->getRoleInstance(), 'Expected current user role object');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Line exceeds 120 characters; contains 162 characters
Open

        $this->assertInstanceOf('\Settings_Roles_Record_Model', \App\User::getCurrentUserModel()->getRoleInstance(), 'Expected current user role object(cached)');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertTrue((bool) \App\User::getCurrentUserModel()->isAdmin(), 'Expected that current user is admin');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing function getUserIdByName.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testGetName()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing get role instance.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertTrue(\App\User::isExists(\App\User::getCurrentUserId()), 'Expected that current user exists');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing function isExists.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertNull(\App\User::getSharingFile(0), 'Sharing file should be null(User not exists)');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Line exceeds 120 characters; contains 154 characters
Open

        $this->assertInstanceOf('\Settings_Roles_Record_Model', \App\User::getCurrentUserModel()->getRoleInstance(), 'Expected current user role object');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Line exceeds 120 characters; contains 166 characters
Open

        $this->assertSame(\App\User::getCurrentUserModel()->getRoleInstance(), \App\User::getCurrentUserModel()->get('roleInstance'), 'Role instance should be same');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Line exceeds 120 characters; contains 190 characters
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference(cached)');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Line exceeds 120 characters; contains 140 characters
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getCurrentUserModel()->getId(), 'Expected that user ids will be equal');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing cache clearance.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertNotNull(\App\User::getSharingFile(\App\User::getCurrentUserId()), 'Sharing file should be not null(cached)');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testGetRoleInstance()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertSame(\App\User::getCurrentUserModel()->getRoleInstance(), \App\User::getCurrentUserModel()->get('roleInstance'), 'Role instance should be same');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Line exceeds 120 characters; contains 182 characters
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testClearCache()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing if current user is admin.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    {
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    public function testGetUserIdByName()
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     * Testing user sharing file loader.
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

     */
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertTrue(\App\User::getCurrentUserModel()->isActive(), 'Expected that current user is active');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    /**
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $this->assertSame(\App\User::getCurrentUserId(), \App\User::getUserIdByName(\App\User::getCurrentUserModel()->getDetail('user_name')), 'User id should be same as reference(cached)');
Severity: Minor
Found in tests/App/User.php by phpcodesniffer

There are no issues that match your filters.

Category
Status