Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
kurtbuilds committed Mar 24, 2024
1 parent 535a710 commit 2c762c2
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 9 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,4 @@ jobs:
tar xvzf checkexec-v0.2.0-x86_64-unknown-linux-musl.tar.gz checkexec
chmod +x checkexec
sudo mv checkexec /usr/local/bin
- run: just dummy_commercial
- run: cargo test
- run: just test
5 changes: 1 addition & 4 deletions Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -97,10 +97,7 @@ generate:

test *ARGS:
checkexec commercial -- just dummy_commercial
cd core && cargo test -- "$@"
cd mir && cargo test
cd mir_rust && cargo test
cd libninja && cargo test -- "$@"
cargo test
alias t := test

integration *ARGS:
Expand Down
4 changes: 2 additions & 2 deletions macro/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ pub fn function(item: TokenStream) -> TokenStream {
let Arg { name, arg_type, default } = arg;
quote! {
::mir::FnArg2::Basic {
name: #name.into(),
name: ::mir::Ident::new(#name),
ty: #arg_type,
default: #default,
}
Expand Down Expand Up @@ -83,7 +83,7 @@ pub fn rfunction(item: TokenStream) -> TokenStream {
let Arg { name, arg_type, default } = arg;
quote! {
::mir::FnArg2::Basic {
name: #name.into(),
name: ::mir::Ident::new(#name),
ty: #arg_type,
default: #default,
}
Expand Down
2 changes: 1 addition & 1 deletion macro/tests/function.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ fn test_function() {
let s: Function<String> = function!(async main() {});
assert_eq!(s.name.0, "main");
assert_eq!(s.async_, true);
assert_eq!(s.vis, Visibility::Public);
assert_eq!(s.vis, Visibility::Private);
}

#[test]
Expand Down

0 comments on commit 2c762c2

Please sign in to comment.