File tree Expand file tree Collapse file tree 2 files changed +22
-0
lines changed Expand file tree Collapse file tree 2 files changed +22
-0
lines changed Original file line number Diff line number Diff line change
1
+ // Copyright © SixtyFPS GmbH <[email protected] >
2
+ // SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-Royalty-free-2.0 OR LicenseRef-Slint-Software-3.0
3
+
4
+ import { LibraryType } from "@test-lib/lib.slint" ;
5
+
6
+ import { NotFound } from "@not-found/foo.slint" ;
7
+ // ^error{Cannot find requested import "@not-found/foo.slint" in the library search path}
8
+
9
+ import { NotFound2 } from "@test-lib/lib.slint" ;
10
+ // ^error{No exported type called 'NotFound2' found in "@test-lib/lib.slint"}
11
+ import { NotFound3 } from "@test-lib/not-existing.slint" ;
12
+ // ^error{Cannot find requested import "@test-lib/not-existing.slint" in the library search path}
13
+
14
+ import { NotFound4 } from "@notexist" ;
15
+ // ^error{Cannot find requested import "@notexist" in the library search path}
16
+
Original file line number Diff line number Diff line change @@ -287,6 +287,12 @@ fn process_file_source(
287
287
let mut compiler_config = i_slint_compiler:: CompilerConfiguration :: new (
288
288
i_slint_compiler:: generator:: OutputFormat :: Interpreter ,
289
289
) ;
290
+ compiler_config. library_paths = [ (
291
+ "test-lib" . into ( ) ,
292
+ concat ! ( env!( "CARGO_MANIFEST_DIR" ) , "/tests/typeloader/library" ) . into ( ) ,
293
+ ) ]
294
+ . into_iter ( )
295
+ . collect ( ) ;
290
296
compiler_config. embed_resources = i_slint_compiler:: EmbedResourcesKind :: OnlyBuiltinResources ;
291
297
compiler_config. enable_experimental = true ;
292
298
compiler_config. style = Some ( "fluent" . into ( ) ) ;
You can’t perform that action at this time.
0 commit comments