diff --git a/lib/spack/spack/package.py b/lib/spack/spack/package.py
index 049d193eefea07c4fd5f7eed8170fc47b92e65a8..d9f76b411e0ed2c676753ede320e67c61ba120e8 100644
--- a/lib/spack/spack/package.py
+++ b/lib/spack/spack/package.py
@@ -247,17 +247,16 @@ class SomePackage(Package):
     """
 
     #
-    # These variables are per-package metadata will be defined by subclasses.
+    # These variables are defaults for the various relations defined on
+    # packages.  Subclasses will have their own versions of these.
     #
-    """By default a package has no dependencies."""
+    """Specs of dependency packages, keyed by name."""
     dependencies = {}
 
-    """List of specs of virtual packages provided by this package."""
+    """Specs of virtual packages provided by this package, keyed by name."""
     provided = {}
 
-    """List of specs of conflicting packages.
-       TODO: implement conflicts.
-    """
+    """Specs of conflicting packages, keyed by name. """
     conflicted = {}
 
     #
@@ -272,6 +271,7 @@ class SomePackage(Package):
     """Controls whether install and uninstall check deps before running."""
     ignore_dependencies = False
 
+
     def __init__(self, spec):
         # These attributes are required for all packages.
         attr_required(self, 'homepage')
@@ -292,18 +292,17 @@ def __init__(self, spec):
         validate.url(self.url)
 
         # Set up version
+        # TODO: get rid of version attr and use spec
+        # TODO: roll this into available_versions
         if not hasattr(self, 'version'):
             try:
                 self.version = url.parse_version(self.url)
             except UndetectableVersionError:
                 tty.die("Couldn't extract a default version from %s. You " +
                         "must specify it explicitly in the package." % self.url)
-        elif type(self.version) == string:
+        elif type(self.version) != Version:
             self.version = Version(self.version)
 
-        # Empty at first; only compute dependent packages if necessary
-        self._dependents = None
-
         # This is set by scraping a web page.
         self._available_versions = None
 
@@ -312,6 +311,9 @@ def __init__(self, spec):
         if self.versions and type(self.versions) != VersionList:
             self.versions = VersionList(self.versions)
 
+        # Empty at first; only compute dependent packages if necessary
+        self._dependents = None
+
         # stage used to build this package.
         # TODO: hash the concrete spec and use that as the stage name.
         self.stage = Stage(self.url, "%s-%s" % (self.name, self.version))
@@ -390,6 +392,7 @@ def dependents(self):
 
 
     def preorder_traversal(self, visited=None):
+        """This does a preorder traversal of the package's dependence DAG."""
         if visited is None:
             visited = set()
 
diff --git a/lib/spack/spack/test/stage.py b/lib/spack/spack/test/stage.py
index 19c0ed2fb312dc52add362a59544ef31b3ab8044..4fa9ce2f4d9de825783ecf0da5f874447be26b92 100644
--- a/lib/spack/spack/test/stage.py
+++ b/lib/spack/spack/test/stage.py
@@ -118,15 +118,19 @@ def check_setup(self, stage, stage_name):
 
     def check_fetch(self, stage, stage_name):
         stage_path = self.get_stage_path(stage, stage_name)
-        self.assertTrue(archive_name in os.listdir(stage_path))
+        self.assertIn(archive_name, os.listdir(stage_path))
         self.assertEqual(new_path(stage_path, archive_name),
                          stage.archive_file)
 
 
     def check_expand_archive(self, stage, stage_name):
         stage_path = self.get_stage_path(stage, stage_name)
-        self.assertTrue(archive_name in os.listdir(stage_path))
-        self.assertTrue(archive_dir in os.listdir(stage_path))
+        self.assertIn(archive_name, os.listdir(stage_path))
+        self.assertIn(archive_dir, os.listdir(stage_path))
+
+        self.assertEqual(
+            new_path(stage_path, archive_dir),
+            stage.expanded_archive_path)
 
         readme = new_path(stage_path, archive_dir, readme_name)
         self.assertTrue(os.path.isfile(readme))
@@ -226,7 +230,7 @@ def test_expand_archive(self):
         self.check_destroy(stage, stage_name)
 
 
-    def test_zexpand_archive(self):
+    def test_expand_archive(self):
         stage = Stage(archive_url, stage_name)
 
         stage.fetch()
@@ -240,3 +244,31 @@ def test_zexpand_archive(self):
 
         stage.destroy()
         self.check_destroy(stage, stage_name)
+
+
+    def test_restage(self):
+        stage = Stage(archive_url, stage_name)
+
+        stage.fetch()
+        stage.expand_archive()
+        stage.chdir_to_archive()
+        self.check_expand_archive(stage, stage_name)
+        self.check_chdir_to_archive(stage, stage_name)
+
+        # Try to make a file in the old archive dir
+        with closing(open('foobar', 'w')) as file:
+            file.write("this file is to be destroyed.")
+
+        self.assertIn('foobar', os.listdir(stage.expanded_archive_path))
+
+        # Make sure the file is not there after restage.
+        stage.restage()
+        self.check_chdir(stage, stage_name)
+        self.check_fetch(stage, stage_name)
+
+        stage.chdir_to_archive()
+        self.check_chdir_to_archive(stage, stage_name)
+        self.assertNotIn('foobar', os.listdir(stage.expanded_archive_path))
+
+        stage.destroy()
+        self.check_destroy(stage, stage_name)