Skip to content

test: add trace-exec testing and fix trace-exec mock stability - #104

Open
yuKing123-king wants to merge 1 commit into
DKapture:mainfrom
yuKing123-king:test/trace-exec
Open

test: add trace-exec testing and fix trace-exec mock stability#104
yuKing123-king wants to merge 1 commit into
DKapture:mainfrom
yuKing123-king:test/trace-exec

Conversation

@yuKing123-king

@yuKing123-king yuKing123-king commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

本次修改集中在 test 目录,修改内容如下

  1. 添加了 trace-exec 的 BUILTIN 单测。测试内容围绕工具实际功能补充了较完整的回归验证,覆盖了以下几类行为:

    • 简单功能测试
    • 测试-u能否过滤成功
    • 测试-t能否过滤成功
    • 测试-d能否过滤成功
    • 测试-d,-u能否组合过滤成功
    • 测试-u -1 异常数值能否被正确阻止,正确的uid正常被过滤
    • 测试-u 12abc 异常数值能否被正确阻止,正确的uid正常被过滤
    • 测试-d -1 异常数值能否被正确阻止,正确的depth正常起作用
    • 测试-d 0 异常数值能否被正确阻止,正确的depth正常起作用
    • 测试-d 12a 异常数值能否被正确阻止,正确的depth正常起作用
    • 测试-u 超大数值能否被正确阻止,正确的uid正常起作用
  2. 在test/Makefile 中补齐测试目标的链接依赖;

  3. 在test/mock.cpp 中修正 skeleton 对象在全局容器中的分配、指针回填和销毁逻辑,避免因扩容和错索引导致的崩溃;

@yuKing123-king
yuKing123-king force-pushed the test/trace-exec branch 3 times, most recently from 10cd9bf to 61aa848 Compare July 21, 2026 07:49
Signed-off-by: Wang Yu <wangyu6@uniontech.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant