Skip to content

Commit

Permalink
integration_tests: added breaking template static function test
Browse files Browse the repository at this point in the history
  • Loading branch information
SDAChess committed Sep 20, 2024
1 parent 48c74b6 commit 8335e53
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions integration-tests/tests/integration_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12386,6 +12386,39 @@ fn test_cpp_union_pod() {
run_test_expect_fail("", hdr, quote! {}, &[], &["CorrelationId_t_"]);
}

#[test]
fn test_cpp_static_template() {
let hdr = indoc! {"
#pragma once
template <typename T>
class Toto
{
public:
static int test()
{
return 1;
}
};
"};
run_test_ex(
"",
hdr,
quote! {},
quote! {
concrete!("Toto<int>", TotoInt)
},
None,
None,
Some(quote! {
fn run() {
ffi::TotoInt::test();
}
}),
);
}

// Yet to test:
// - Ifdef
// - Out param pointers
Expand Down

0 comments on commit 8335e53

Please sign in to comment.