import assert;
import io;

// Check that we can extract filename from file

(string output)
echo_filename(file input) "funcs" "0.0"
[ "set <<output>> [ turbine::local_file_path <<input>> ]" ];

main {
  file f = input_file("alice.txt");
  string s = echo_filename(f);
  printf("filename: %s", s);
  assertEqual(s, "alice.txt", "Filename correct");
}


import io;

(string output)
echo_filename(file input) "funcs" "0.0"
[ "set <<output>> <<input>>" ];

// SKIP-THIS-TEST: Issue #453
// Issue is filename substitution into Tcl
// This works:  [ lindex <<input>> 0 ]

main {
  file f = input_file("alice.txt");
  string s = echo_filename(f);
  printf("filename: %s", s);
}

--- 
+++ 
@@ -1,16 +1,15 @@
+import assert;
+import io;
 
-import io;
+// Check that we can extract filename from file
 
 (string output)
 echo_filename(file input) "funcs" "0.0"
-[ "set <<output>> <<input>>" ];
-
-// SKIP-THIS-TEST: Issue #453
-// Issue is filename substitution into Tcl
-// This works:  [ lindex <<input>> 0 ]
+[ "set <<output>> [ turbine::local_file_path <<input>> ]" ];
 
 main {
   file f = input_file("alice.txt");
   string s = echo_filename(f);
   printf("filename: %s", s);
+  assertEqual(s, "alice.txt", "Filename correct");
 }
Update test to be correct

git-svn-id: 47705994653588c662f4ea400dfe88107361c0e2@7596 dc4e9af1-7f46-4ead-bba6-71afc04862de
