Index: tests/imagecache_create_url.test
===================================================================
--- tests/imagecache_create_url.test	(revision 666)
+++ tests/imagecache_create_url.test	(working copy)
@@ -4,7 +4,7 @@
  * Test class for testing imagecache_create_url() in several use cases with
  * the different combinations of clean URLs and private/public download method.
  */
-class ImageCacheUrlTests extends DrupalTestCase {
+class ImageCacheUrlTests extends DrupalWebTestCase {
 
   /**
    * General admin user.
@@ -31,20 +31,18 @@
    * SimpleTest core method: code run before each and every test method.
    */
   function setUp() {
-    // Always call the setUp() function from the parent class.
-    parent::setUp();
+    // Always call the setUp() function from the parent class which setups up
+    // the ImageCache module.
+    parent::setUp('imagecache');
 
-    // Make sure that the ImageCache module is enabled.
-    $this->drupalModuleEnable('imagecache');
-
     // Create admin user
     $permissions = array(
       'administer filters',
     );
-    $this->admin_user = $this->drupalCreateUserRolePerm($permissions);
+    $this->admin_user = $this->drupalCreateUser($permissions);
 
     // Log in with admin user.
-    $this->drupalLoginUser($this->admin_user);
+    $this->drupalLogin($this->admin_user);
 
     // Add an input format with PHP evaluator.
     $edit = array(
@@ -52,7 +50,7 @@
       'filters[filter/1]' => TRUE,
       'roles[2]' => TRUE,
     );
-    $this->drupalPostRequest('admin/settings/filters/add', $edit, t('Save configuration'));
+    $this->drupalPost('admin/settings/filters/add', $edit, t('Save configuration'));
     // Store the format id of the created input format.
     $this->input_format_id = db_result(db_query("SELECT format FROM {filter_formats} WHERE name = '%s'", $edit['name']));
     $this->assertTrue($this->input_format_id, t('Input format id (%s)'));
@@ -64,9 +62,9 @@
    */
   function tearDown() {
     // Remove input format.
-    $this->drupalPostRequest('admin/settings/filters/delete/'. $this->input_format_id, array(), t('Delete'));
+    $this->drupalPost('admin/settings/filters/delete/'. $this->input_format_id, array(), t('Delete'));
     // Log out admin user.
-    $this->drupalGet('logout');
+    $this->drupalLogout();
 
     // Always call the tearDown() function from the parent class.
     parent::tearDown();
@@ -136,9 +134,9 @@
    */
   private function _ImagecacheCreateUrlTest($clean_url, $file_downloads, $file_directory_path, $preset, $path, $expected) {
     // Drupal settings
-    $this->drupalVariableSet('clean_url', $clean_url);
-    $this->drupalVariableSet('file_downloads', $file_downloads);
-    $this->drupalVariableSet('file_directory_path', $file_directory_path);
+    variable_set('clean_url', $clean_url);
+    variable_set('file_downloads', $file_downloads);
+    variable_set('file_directory_path', $file_directory_path);
 
     // Build node body (php code).
     $body = "<?php
@@ -154,10 +152,10 @@
     ));
 
     // Show node.
-    $this->drupalGet(url('node/' . $node->nid, NULL, NULL, TRUE));
+    $this->drupalGet(url('node/' . $node->nid));
 
     // Check if expected url shows up
-    $this->assertWantedRaw($expected,
+    $this->assertRaw($expected,
       t('[ImageCacheUrlTests] @clean_url + @file_downloads should return "@expected"', array(
         '@clean_url' => ($clean_url ? 'Clean URLs' : 'No clean URLs'),
         '@file_downloads' => ($file_downloads == FILE_DOWNLOADS_PRIVATE ? 'private downloads' : 'public downloads'),
