diff --git a/UNITTESTS/stubs/EventQueue_stub.h b/UNITTESTS/stubs/EventQueue_stub.h deleted file mode 100644 index 12fb4d5..0000000 --- a/UNITTESTS/stubs/EventQueue_stub.h +++ /dev/null @@ -1,24 +0,0 @@ -/* - * Copyright (c) , Arm Limited and affiliates. - * SPDX-License-Identifier: Apache-2.0 - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#include - -namespace EventQueue_stub { -extern int int_value; -extern unsigned unsigned_value; -} - diff --git a/UNITTESTS/stubs/equeue_stub.h b/UNITTESTS/stubs/equeue_stub.h deleted file mode 100644 index 648d920..0000000 --- a/UNITTESTS/stubs/equeue_stub.h +++ /dev/null @@ -1,26 +0,0 @@ -/* - * Copyright (c) , Arm Limited and affiliates. - * SPDX-License-Identifier: Apache-2.0 - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#include "stdint.h" -#include "stdbool.h" - -typedef struct { - void *void_ptr; - bool call_cb_immediately; -} equeue_stub_def; - -extern equeue_stub_def equeue_stub; diff --git a/events/tests/UNITTESTS/doubles/CMakeLists.txt b/events/tests/UNITTESTS/doubles/CMakeLists.txt index 34608dd..8d249c0 100644 --- a/events/tests/UNITTESTS/doubles/CMakeLists.txt +++ b/events/tests/UNITTESTS/doubles/CMakeLists.txt @@ -23,6 +23,11 @@ mbed_shared_queues_stub.cpp ) +target_include_directories(mbed-stubs-events + PUBLIC + . +) + target_link_libraries(mbed-stubs-events PRIVATE mbed-headers diff --git a/events/tests/UNITTESTS/doubles/EventQueue_stub.h b/events/tests/UNITTESTS/doubles/EventQueue_stub.h new file mode 100644 index 0000000..12fb4d5 --- /dev/null +++ b/events/tests/UNITTESTS/doubles/EventQueue_stub.h @@ -0,0 +1,24 @@ +/* + * Copyright (c) , Arm Limited and affiliates. + * SPDX-License-Identifier: Apache-2.0 + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +namespace EventQueue_stub { +extern int int_value; +extern unsigned unsigned_value; +} + diff --git a/events/tests/UNITTESTS/doubles/equeue_stub.h b/events/tests/UNITTESTS/doubles/equeue_stub.h new file mode 100644 index 0000000..648d920 --- /dev/null +++ b/events/tests/UNITTESTS/doubles/equeue_stub.h @@ -0,0 +1,26 @@ +/* + * Copyright (c) , Arm Limited and affiliates. + * SPDX-License-Identifier: Apache-2.0 + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "stdint.h" +#include "stdbool.h" + +typedef struct { + void *void_ptr; + bool call_cb_immediately; +} equeue_stub_def; + +extern equeue_stub_def equeue_stub;