Problem/Motivation

As title

Proposed resolution

Remove redundant assertion messages at the same time.

Example:

-    $this->assertTrue(is_callable($controller));
+    $this->assertIsCallable($controller);

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

CommentFileSizeAuthor
#4 3131821-4.patch1.57 KBjungle

Comments

jungle created an issue. See original summary.

jungle’s picture

Title: Replace assertions involving calls to is_callable() assertIsCallable()/assertIsNotCallable() » Replace assertions involving calls to is_callable() with assertIsCallable()/assertIsNotCallable()
jungle’s picture

Issue summary: View changes
jungle’s picture

Status: Active » Needs review
StatusFileSize
new1.57 KB
longwave’s picture

Status: Needs review » Reviewed & tested by the community

Straightforward, these are the only two uses in core.

  • xjm committed a220632 on 9.1.x
    Issue #3131821 by jungle, longwave: Replace assertions involving calls...

  • xjm committed 4bd44f4 on 9.0.x
    Issue #3131821 by jungle, longwave: Replace assertions involving calls...
xjm’s picture

Title: Replace assertions involving calls to is_callable() with assertIsCallable()/assertIsNotCallable() » [backport] Replace assertions involving calls to is_callable() with assertIsCallable()/assertIsNotCallable()
Version: 9.1.x-dev » 8.8.x-dev
Status: Reviewed & tested by the community » Postponed

Confirmed. Committed to 9.1.x and 9.0.x. Thanks!

Postponing the backport on #3126787: [D8 only] Add forwards-compatibility shim for assertInternalType() replacements in phpunit 6&7.

mondrake’s picture

Status: Postponed » Needs review

Blocker is in.

mondrake’s picture

Version: 8.8.x-dev » 8.9.x-dev
Status: Needs review » Reviewed & tested by the community

#4 is passing on D8.9 now.

xjm’s picture

Status: Reviewed & tested by the community » Fixed

Nice and simple. Backport committed to 8.9.x. Thanks!

  • xjm committed 0146867 on 8.9.x
    Issue #3131821 by jungle, longwave, xjm: Replace assertions involving...
xjm’s picture

Title: [backport] Replace assertions involving calls to is_callable() with assertIsCallable()/assertIsNotCallable() » Replace assertions involving calls to is_callable() with assertIsCallable()/assertIsNotCallable()

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.