[build] move spinel into src/utils (#4558)

Move spinel from src/ncp into src/utils and remove dependency on
OpenThread's core configurations.
This commit is contained in:
Yakun Xu
2020-02-19 11:45:35 -08:00
committed by GitHub
parent aa62fd8f65
commit 8546bceeab
34 changed files with 661 additions and 449 deletions
+7 -7
View File
@@ -28,22 +28,22 @@
#include "common/code_utils.hpp"
#include "common/instance.hpp"
#include "ncp/spinel_decoder.hpp"
#include "spinel/spinel_decoder.hpp"
#include "test_util.hpp"
namespace ot {
namespace Ncp {
namespace Spinel {
enum
{
kTestBufferSize = 800,
};
void TestSpinelDecoder(void)
void TestDecoder(void)
{
uint8_t buffer[kTestBufferSize];
SpinelDecoder decoder;
uint8_t buffer[kTestBufferSize];
Spinel::Decoder decoder;
spinel_ssize_t frameLen;
@@ -638,12 +638,12 @@ void TestSpinelDecoder(void)
printf(" -- PASS\n");
}
} // namespace Ncp
} // namespace Spinel
} // namespace ot
int main(void)
{
ot::Ncp::TestSpinelDecoder();
ot::Spinel::Decoder();
printf("\nAll tests passed.\n");
return 0;
}