-
-
Notifications
You must be signed in to change notification settings - Fork 78
Open
Description
I have a proc-macro, which loads a file from a given location to generate code.
I call it this way:
#[generate_api("tests/good_source_file/mod.rs")]
impl Lifecycle for LifecycleImpl {
Using try build the given file can't be found, because "cwd" and "CARGO_TARGET_DIR" are redirected to $DIR/target/tests/trybuild.
Is there anyway I can change that?
I don't want to hardcode a full path - the macro assumes the file's location is relative to the project's root directory.
Needless to say, outside of trybuild::TestCases::new().pass("tests/ui_tests.rs"); the file loading works.
Metadata
Metadata
Assignees
Labels
No labels