@@ -208,8 +208,6 @@ fn minimize_rpaths(rpaths: &[Path]) -> ~[Path] {
208208
209209#[ cfg( unix) ]
210210mod test {
211- #[ legacy_exports] ;
212-
213211 use core:: prelude:: * ;
214212
215213 use back:: rpath:: { get_absolute_rpath, get_install_prefix_rpath} ;
@@ -221,14 +219,14 @@ mod test {
221219 use core:: str;
222220
223221 #[ test]
224- fn test_rpaths_to_flags ( ) {
222+ pub fn test_rpaths_to_flags ( ) {
225223 let flags = rpaths_to_flags ( ~[ Path ( "path1" ) ,
226224 Path ( "path2" ) ] ) ;
227225 assert flags == ~[ ~"-Wl , -rpath, path1", ~"-Wl , -rpath, path2"] ;
228226 }
229227
230228 #[ test]
231- fn test_prefix_rpath ( ) {
229+ pub fn test_prefix_rpath ( ) {
232230 let res = get_install_prefix_rpath ( "triple" ) ;
233231 let d = Path ( env ! ( "CFG_PREFIX" ) )
234232 . push_rel ( & Path ( "lib/rustc/triple/lib" ) ) ;
@@ -239,21 +237,21 @@ mod test {
239237 }
240238
241239 #[ test]
242- fn test_prefix_rpath_abs ( ) {
240+ pub fn test_prefix_rpath_abs ( ) {
243241 let res = get_install_prefix_rpath ( "triple" ) ;
244242 assert res. is_absolute ;
245243 }
246244
247245 #[ test]
248- fn test_minimize1 ( ) {
246+ pub fn test_minimize1 ( ) {
249247 let res = minimize_rpaths ( [ Path ( "rpath1" ) ,
250248 Path ( "rpath2" ) ,
251249 Path ( "rpath1" ) ] ) ;
252250 assert res == ~[ Path ( "rpath1" ) , Path ( "rpath2" ) ] ;
253251 }
254252
255253 #[ test]
256- fn test_minimize2 ( ) {
254+ pub fn test_minimize2 ( ) {
257255 let res = minimize_rpaths ( ~[ Path ( "1a" ) , Path ( "2" ) , Path ( "2" ) ,
258256 Path ( "1a" ) , Path ( "4a" ) , Path ( "1a" ) ,
259257 Path ( "2" ) , Path ( "3" ) , Path ( "4a" ) ,
@@ -262,63 +260,63 @@ mod test {
262260 }
263261
264262 #[ test]
265- fn test_relative_to1 ( ) {
263+ pub fn test_relative_to1 ( ) {
266264 let p1 = Path ( "/usr/bin/rustc" ) ;
267265 let p2 = Path ( "/usr/lib/mylib" ) ;
268266 let res = get_relative_to ( & p1, & p2) ;
269267 assert res == Path ( "../lib" ) ;
270268 }
271269
272270 #[ test]
273- fn test_relative_to2 ( ) {
271+ pub fn test_relative_to2 ( ) {
274272 let p1 = Path ( "/usr/bin/rustc" ) ;
275273 let p2 = Path ( "/usr/bin/../lib/mylib" ) ;
276274 let res = get_relative_to ( & p1, & p2) ;
277275 assert res == Path ( "../lib" ) ;
278276 }
279277
280278 #[ test]
281- fn test_relative_to3 ( ) {
279+ pub fn test_relative_to3 ( ) {
282280 let p1 = Path ( "/usr/bin/whatever/rustc" ) ;
283281 let p2 = Path ( "/usr/lib/whatever/mylib" ) ;
284282 let res = get_relative_to ( & p1, & p2) ;
285283 assert res == Path ( "../../lib/whatever" ) ;
286284 }
287285
288286 #[ test]
289- fn test_relative_to4 ( ) {
287+ pub fn test_relative_to4 ( ) {
290288 let p1 = Path ( "/usr/bin/whatever/../rustc" ) ;
291289 let p2 = Path ( "/usr/lib/whatever/mylib" ) ;
292290 let res = get_relative_to ( & p1, & p2) ;
293291 assert res == Path ( "../lib/whatever" ) ;
294292 }
295293
296294 #[ test]
297- fn test_relative_to5 ( ) {
295+ pub fn test_relative_to5 ( ) {
298296 let p1 = Path ( "/usr/bin/whatever/../rustc" ) ;
299297 let p2 = Path ( "/usr/lib/whatever/../mylib" ) ;
300298 let res = get_relative_to ( & p1, & p2) ;
301299 assert res == Path ( "../lib" ) ;
302300 }
303301
304302 #[ test]
305- fn test_relative_to6 ( ) {
303+ pub fn test_relative_to6 ( ) {
306304 let p1 = Path ( "/1" ) ;
307305 let p2 = Path ( "/2/3" ) ;
308306 let res = get_relative_to ( & p1, & p2) ;
309307 assert res == Path ( "2" ) ;
310308 }
311309
312310 #[ test]
313- fn test_relative_to7 ( ) {
311+ pub fn test_relative_to7 ( ) {
314312 let p1 = Path ( "/1/2" ) ;
315313 let p2 = Path ( "/3" ) ;
316314 let res = get_relative_to ( & p1, & p2) ;
317315 assert res == Path ( ".." ) ;
318316 }
319317
320318 #[ test]
321- fn test_relative_to8 ( ) {
319+ pub fn test_relative_to8 ( ) {
322320 let p1 = Path ( "/home/brian/Dev/rust/build/" ) . push_rel (
323321 & Path ( "stage2/lib/rustc/i686-unknown-linux-gnu/lib/librustc.so" ) ) ;
324322 let p2 = Path ( "/home/brian/Dev/rust/build/stage2/bin/.." ) . push_rel (
@@ -333,7 +331,7 @@ mod test {
333331 #[ test]
334332 #[ cfg( target_os = "linux" ) ]
335333 #[ cfg( target_os = "andorid" ) ]
336- fn test_rpath_relative ( ) {
334+ pub fn test_rpath_relative ( ) {
337335 let o = session:: os_linux;
338336 let res = get_rpath_relative_to_output ( o,
339337 & Path ( "bin/rustc" ) , & Path ( "lib/libstd.so" ) ) ;
@@ -342,7 +340,7 @@ mod test {
342340
343341 #[ test]
344342 #[ cfg( target_os = "freebsd" ) ]
345- fn test_rpath_relative ( ) {
343+ pub fn test_rpath_relative ( ) {
346344 let o = session:: os_freebsd;
347345 let res = get_rpath_relative_to_output ( o,
348346 & Path ( "bin/rustc" ) , & Path ( "lib/libstd.so" ) ) ;
@@ -351,7 +349,7 @@ mod test {
351349
352350 #[ test]
353351 #[ cfg( target_os = "macos" ) ]
354- fn test_rpath_relative ( ) {
352+ pub fn test_rpath_relative ( ) {
355353 // this is why refinements would be nice
356354 let o = session:: os_macos;
357355 let res = get_rpath_relative_to_output ( o,
@@ -361,7 +359,7 @@ mod test {
361359 }
362360
363361 #[ test]
364- fn test_get_absolute_rpath ( ) {
362+ pub fn test_get_absolute_rpath ( ) {
365363 let res = get_absolute_rpath ( & Path ( "lib/libstd.so" ) ) ;
366364 debug ! ( "test_get_absolute_rpath: %s vs. %s" ,
367365 res. to_str( ) ,
0 commit comments