Index: subversion/tests/clients/cmdline/export_tests.py
===================================================================
--- subversion/tests/clients/cmdline/export_tests.py	(revision 7645)
+++ subversion/tests/clients/cmdline/export_tests.py	(working copy)
@@ -21,6 +21,7 @@
 
 # Our testing module
 import svntest
+from svntest import wc, SVNAnyOutput
 
 
 # (abbreviation)
@@ -48,7 +49,22 @@
   if not os.path.exists(export_target):
     raise svntest.Failure
 
+def export_greek_tree(sbox):
+  "export the greek tree"
+  sbox.build()
 
+  svntest.main.safe_rmtree(sbox.wc_dir)
+  export_target = sbox.wc_dir
+  expected_output = svntest.main.greek_state.copy()
+  expected_output.wc_dir = sbox.wc_dir
+  expected_output.desc[''] = wc.StateItem()
+  expected_output.tweak(contents=None, status='A ')
+
+  svntest.actions.run_and_verify_export(svntest.main.current_repo_url,
+                                        export_target,
+                                        expected_output,
+                                        svntest.main.greek_state.copy())
+
 ########################################################################
 # Run the tests
 
@@ -56,6 +72,7 @@
 # list all tests here, starting with None:
 test_list = [ None,
               export_empty_directory,
+              export_greek_tree,
              ]
 
 if __name__ == '__main__':
Index: subversion/tests/clients/cmdline/svntest/actions.py
===================================================================
--- subversion/tests/clients/cmdline/svntest/actions.py	(revision 7645)
+++ subversion/tests/clients/cmdline/svntest/actions.py	(working copy)
@@ -219,6 +219,48 @@
                       singleton_handler_b, b_baton)
 
 
+def run_and_verify_export(URL, wc_dir_name, output_tree, disk_tree,
+                          singleton_handler_a = None,
+                          a_baton = None,
+                          singleton_handler_b = None,
+                          b_baton = None):
+  """Export the URL into a new directory WC_DIR_NAME.
+
+  The subcommand output will be verified against OUTPUT_TREE,
+  and the working copy itself will be verified against DISK_TREE.
+  SINGLETON_HANDLER_A and SINGLETON_HANDLER_B will be passed to
+  tree.compare_trees - see that function's doc string for more details.
+  Returns if successful and raise on failure."""
+
+  if isinstance(output_tree, wc.State):
+    output_tree = output_tree.old_tree()
+  if isinstance(disk_tree, wc.State):
+    disk_tree = disk_tree.old_tree()
+
+  # Remove dir if it's already there.
+  main.safe_rmtree(wc_dir_name)
+
+  # Checkout and make a tree of the output, using l:foo/p:bar
+  ### todo: svn should not be prompting for auth info when using
+  ### repositories with no auth/auth requirements
+  output, errput = main.run_svn (None, 'export',
+                                 '--username', main.wc_author,
+                                 '--password', main.wc_passwd,
+                                 URL, wc_dir_name)
+  mytree = tree.build_tree_from_checkout (output)
+
+  # Verify actual output against expected output.
+  tree.compare_trees (mytree, output_tree)
+
+  # Create a tree by scanning the working copy
+  mytree = tree.build_tree_from_wc (wc_dir_name, ignore_svn=0)
+
+  # Verify expected disk against actual disk.
+  tree.compare_trees (mytree, disk_tree,
+                      singleton_handler_a, a_baton,
+                      singleton_handler_b, b_baton)
+
+
 def verify_update(actual_output, wc_dir_name,
                   output_tree, disk_tree, status_tree,
                   singleton_handler_a, a_baton,
