File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -15,8 +15,8 @@ lazy_static! {
1515#[ derive( Debug ) ]
1616pub ( crate ) enum Error {
1717 InvalidPath ( PathBuf ) ,
18- NoradRead ( PathBuf , norad:: Error ) ,
19- NoradWrite ( PathBuf , norad:: Error ) ,
18+ NoradRead ( PathBuf , norad:: error :: FontLoadError ) ,
19+ NoradWrite ( PathBuf , norad:: error :: FontWriteError ) ,
2020}
2121
2222// Implementation adapted from https://www.lpalmieri.com/posts/error-handling-rust/
@@ -65,14 +65,14 @@ mod tests {
6565
6666 #[ test]
6767 fn test_ufofmterror_read ( ) {
68- let ne = norad:: Error :: MissingLayer ( "test" . to_owned ( ) ) ;
68+ let ne = norad:: error :: FontLoadError :: MissingDefaultLayer ;
6969 let ufe = Error :: NoradRead ( PathBuf :: from ( "test.ufo" ) , ne) ;
7070 assert ! ( ufe. to_string( ) . starts_with( "norad read error: " ) ) ;
7171 }
7272
7373 #[ test]
7474 fn test_ufofmterror_write ( ) {
75- let ne = norad:: Error :: MissingLayer ( "test" . to_owned ( ) ) ;
75+ let ne = norad:: error :: FontWriteError :: PreexistingPublicObjectLibsKey ;
7676 let ufe = Error :: NoradWrite ( PathBuf :: from ( "test.ufo" ) , ne) ;
7777 assert ! ( ufe. to_string( ) . starts_with( "norad write error: " ) ) ;
7878 }
You can’t perform that action at this time.
0 commit comments