Download & Extend

Update simpletest module to use drupal_static()

Project:Drupal core
Version:7.x-dev
Component:simpletest.module
Category:task
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

This is a child task for #422380: Convert all core module to use new static caching API focusing on the simpletest module.

Comments

#1

Status:active» needs review

A wrapper function as per #422362-20: convert form.inc to use new static caching API was created to reset the static var in file_test_file_scan_callback().

AttachmentSizeStatusTest resultOperations
481498-1.patch4.05 KBIdleFailed: Failed to apply patch.View details

#2

Status:needs review» needs work

The last submitted patch failed testing.

#3

Status:needs work» needs review
AttachmentSizeStatusTest resultOperations
481498-3.patch4.13 KBIdleFailed: Invalid PHP syntax in modules/simpletest/tests/file.test.View details

#4

Status:needs review» needs work

The last submitted patch failed testing.

#5

Technically this is a duplicate of: #348455: Provide a scalable way to ensure a clean testing environment for SimpleTest, but we can just prioritize this one.

#6

Please hold off on this patch though, longer standing patch with better cleanup of loading stuff #449198: SimpleTest: Clean up test loading and related API which also adds statics stuff. (just needs committing) [perhaps you want to review]

#7

Status:needs work» postponed

Postponed on account of #449198: SimpleTest: Clean up test loading and related API. Thanks for the heads up!

I'm not sure about reviewing that large patch... I've never reviewed anything before, much less a large patch of an unfamiliar module.. ^^"

#8

Status:postponed» active

Issue has been committed.

#9

Status:active» needs review

I added drupal_static() in checkPermissions(), but I am not sure where to go from there. In order to complete the process setUp() needs to take advantage of drupal_static_reset(), but I am not sure that is the scope of this particular issue.

AttachmentSizeStatusTest resultOperations
481498-simpletest-static.patch4 KBIdleFailed: Invalid PHP syntax in modules/simpletest/tests/file.test.View details

#10

Status:needs review» needs work

The last submitted patch failed testing.

#11

Status:needs work» needs review

Suppose this would be a bad idea (carried over from original) :)

<?php
function file_test_file_scan_callback($filepath == NULL) {
?>
AttachmentSizeStatusTest resultOperations
481498-simpletest-static.patch4 KBIdleFailed: 11622 passes, 2 fails, 2 exceptionsView details

#12

Status:needs review» needs work

The last submitted patch failed testing.

#13

Status:needs work» needs review

+    return files;
should be
+    return $files;

AttachmentSizeStatusTest resultOperations
481498-13.patch4.18 KBIdlePassed: 11602 passes, 0 fails, 0 exceptionsView details

#14

Status:needs review» needs work

The last submitted patch failed testing.

#15

Status:needs work» needs review

Test slave crapped.

#16

Rerolled.

AttachmentSizeStatusTest resultOperations
481498-16.patch4.18 KBIdlePassed: 11602 passes, 0 fails, 0 exceptionsView details

#17

Status:needs review» reviewed & tested by the community

Looks good.

#18

Status:reviewed & tested by the community» fixed

Small code style issue: +  } else {. Fixed that and committed to CVS HEAD.

#19

Status:fixed» closed (fixed)

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

nobody click here