[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M698Z5MG65YJ810070967902":3,"skill-same:01M698Z5MG65YJ810070967902":79},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":26,"publishedAt":44,"linkOnly":45,"markdownContent":46,"markdownBody":47,"frontMatter":48,"refName":49,"commitSha":50,"skillDirectory":51,"forksCount":52,"repositoryHtmlUrl":53,"repositoryHomepageUrl":54,"ownerHtmlUrl":55,"ownerBlogUrl":56,"ownerDescription":57,"updatedAt":58,"install":59,"resources":72},"01M698Z5MG65YJ810070967902","skia-add-test",null,"Add a new test to the Skia repository. Use this skill when you need to create a new unit or integration test in the tests\u002F directory and ensure it's part of the build system.","google\u002Fskia","google","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F1342004?v=4","01M698VYEFDM0VJBZDYYJ2T83S","Google","01M698Z251PDBWCXQ35SASSY22",11032,"BSD-3-Clause","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fskia\u002Fblob\u002Fmain\u002F_agents\u002Fskills\u002Fskia-add-test\u002FSKILL.md",[18,23],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000008","测试与质量","SCENARIO","使用场景",{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000023","Skill与智能体开发",[27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43],"skia add test","test","add test","add","when","directory","you","it","unit","tests","build","use","integration test","system","repository","integration","create","2026-11-10 10:12:30",false,"---\nname: skia-add-test\ndescription: Add a new test to the Skia repository. Use this skill when you need to create a new unit or integration test in the tests\u002F directory and ensure it's part of the build system.\n---\n\n# Skia Add Test Skill\n\nThis skill guides you through adding a new test to Skia. Tests are primarily written in C++ and located in the `tests\u002F` directory.\n\n## Workflow\n\n### 1. Create the Test File\nCreate a new `.cpp` file in the `tests\u002F` directory. Use the provided template as a starting point.\n- **Template Location:** `assets\u002Ftest_template.cpp`\n\n### 2. Update the Build System\nAdd the path to your new test file to the `tests_sources` list in `gn\u002Ftests.gni`.\n- Paths in `gn\u002Ftests.gni` should be relative to the directory or use the `$_tests` variable.\n\n### 3. Build the Test\nCompile the `dm` tool, which runs the tests.\n```bash\nninja --quiet -C out\u002FDebug dm\n```\n\n### 4. Run the Test\nUse `dm` with the `--match` flag to run your specific test.\n```bash\nout\u002FDebug\u002Fdm --match [test_name]\n```\nNote: Replace `[test_name]` with the name provided to the `DEF_TEST` (or similar) macro.\n\n## Key Concepts\n\n### Macros for Defining Tests\n- `DEF_TEST(name, reporter)`: Standard CPU test.\n- `DEF_GANESH_TEST(name, reporter, options, ctsEnforcement)`: Ganesh GPU test.\n- `DEF_GRAPHITE_TEST_FOR_ALL_CONTEXTS(name, reporter, context, ctsEnforcement)`: Graphite GPU test.\n\n### CtsEnforcement\n`CtsEnforcement` is used to track tests that should be run as part of Android's Conformance Test Suite (CTS) for a specific milestone (e.g., `kApiLevel_T`) or later.\n- `CtsEnforcement::kNever`: The test is not part of CTS.\n- `CtsEnforcement::kApiLevel_U`: The test is required for Android U and later.\n\n### Reporter and Assertions\n- `REPORTER_ASSERT(reporter, condition, ...)`: Standard assertion.\n- `ERRORF(reporter, ...)`: Report a failure with a formatted message.\n- `skiatest::ReporterContext`: Use this stack-allocated object to provide additional context (like subtest names) for failure reports.\n\nExample of `ReporterContext`:\n```cpp\n{\n    skiatest::ReporterContext subtest(reporter, SkString(\"My Subtest\"));\n    REPORTER_ASSERT(reporter, condition);\n}\n```\nIf `condition` fails, the error will include \"My Subtest\".\n","# Skia Add Test Skill\n\nThis skill guides you through adding a new test to Skia. Tests are primarily written in C++ and located in the `tests\u002F` directory.\n\n## Workflow\n\n### 1. Create the Test File\nCreate a new `.cpp` file in the `tests\u002F` directory. Use the provided template as a starting point.\n- **Template Location:** `assets\u002Ftest_template.cpp`\n\n### 2. Update the Build System\nAdd the path to your new test file to the `tests_sources` list in `gn\u002Ftests.gni`.\n- Paths in `gn\u002Ftests.gni` should be relative to the directory or use the `$_tests` variable.\n\n### 3. Build the Test\nCompile the `dm` tool, which runs the tests.\n```bash\nninja --quiet -C out\u002FDebug dm\n```\n\n### 4. Run the Test\nUse `dm` with the `--match` flag to run your specific test.\n```bash\nout\u002FDebug\u002Fdm --match [test_name]\n```\nNote: Replace `[test_name]` with the name provided to the `DEF_TEST` (or similar) macro.\n\n## Key Concepts\n\n### Macros for Defining Tests\n- `DEF_TEST(name, reporter)`: Standard CPU test.\n- `DEF_GANESH_TEST(name, reporter, options, ctsEnforcement)`: Ganesh GPU test.\n- `DEF_GRAPHITE_TEST_FOR_ALL_CONTEXTS(name, reporter, context, ctsEnforcement)`: Graphite GPU test.\n\n### CtsEnforcement\n`CtsEnforcement` is used to track tests that should be run as part of Android's Conformance Test Suite (CTS) for a specific milestone (e.g., `kApiLevel_T`) or later.\n- `CtsEnforcement::kNever`: The test is not part of CTS.\n- `CtsEnforcement::kApiLevel_U`: The test is required for Android U and later.\n\n### Reporter and Assertions\n- `REPORTER_ASSERT(reporter, condition, ...)`: Standard assertion.\n- `ERRORF(reporter, ...)`: Report a failure with a formatted message.\n- `skiatest::ReporterContext`: Use this stack-allocated object to provide additional context (like subtest names) for failure reports.\n\nExample of `ReporterContext`:\n```cpp\n{\n    skiatest::ReporterContext subtest(reporter, SkString(\"My Subtest\"));\n    REPORTER_ASSERT(reporter, condition);\n}\n```\nIf `condition` fails, the error will include \"My Subtest\".\n",{"name":5,"description":7},"main","607de4b035dcf7fdbaafb66c6cc04f22009ff4d4","_agents\u002Fskills\u002Fskia-add-test",1795,"https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fskia","https:\u002F\u002Fskia.org","https:\u002F\u002Fgithub.com\u002Fgoogle","https:\u002F\u002Fopensource.google\u002F","Google ❤️ Open Source","2026-11-14 21:53:49",{"source":8,"skillName":5,"commands":60,"prompt":70,"zipAvailable":71},[61,64,67],{"tool":62,"command":63},"npx","npx skills add google\u002Fskia --skill skia-add-test",{"tool":65,"command":66},"bunx","bunx skills add google\u002Fskia --skill skia-add-test",{"tool":68,"command":69},"pnpm","pnpm dlx skills add google\u002Fskia --skill skia-add-test","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fskia\u002Fblob\u002Fmain\u002F_agents\u002Fskills\u002Fskia-add-test\u002FSKILL.md",true,[73],{"path":74,"resourceType":75,"resourceTypeDesc":76,"sizeBytes":77,"sourceHtmlUrl":78},"assets\u002Ftest_template.cpp","ASSET","资产文件",1066,"https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fskia\u002Fblob\u002Fmain\u002F_agents\u002Fskills\u002Fskia-add-test\u002Fassets\u002Ftest_template.cpp",[80,106],{"skillNo":81,"name":82,"nameZh":6,"description":83,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":84,"categories":85,"keywords":87,"publishedAt":44},"01M698Z9BRHT49CDX1V3Y9YH3G","skia-style-check","Checks that changed code on the current git branch matches Skia's style and formatting requirements defined in site\u002Fdocs\u002Fdev\u002Fcontrib\u002Fstyle.md. Use this skill when verifying, auditing, or reviewing code changes on the active branch for style compliance before committing or submitting. Do not use for compiler errors or build workflows.","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fskia\u002Fblob\u002Fmain\u002F_agents\u002Fskills\u002Fskia-style-check\u002FSKILL.md",[86],{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},[88,89,90,91,31,92,93,38,37,94,95,96,97,98,99,100,101,102,103,104,105],"check","skia style check","style","compiler","compliance","branch","do","requirements","reviewing code","errors","for","changes","contrib","dev","git branch","code","workflows","docs",{"skillNo":107,"name":108,"nameZh":6,"description":109,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":110,"categories":111,"keywords":113,"publishedAt":44},"01M698Z74AMD0234MTMAS8RQ76","skia-gn-workflow","MANDATORY: Use this skill for ANY and ALL tasks involving building Skia with GN, Ninja, or compiling any Skia tool. It is the authoritative source for Skia's build workflows and MUST be used whenever compilation is required.","https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fskia\u002Fblob\u002Fmain\u002F_agents\u002Fskills\u002Fskia-gn-workflow\u002FSKILL.md",[112],{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},[114,115,116,98,117,34,37,38,118,119,120,104],"workflow","skia gn workflow","source","with","tool","compiling","tasks"]