R004

Official

Finds test cases that don’t assert

Authoropenharmonyinsight
Version1.0.0
Installs0

System Documentation

What problem does it solve?

It detects invalid unit/integration test cases where an it() block contains no assertion, preventing the test from actually verifying behavior.

Core Features & Use Cases

  • Assertion Presence Verification: Flags it() blocks in .ets, .ts, and .js files that lack any effective assertion.
  • Indirect Assertion Tracing: Recursively checks local and imported helper functions to determine whether assertions exist through call chains.
  • try-catch Branch Guarding: Ensures assertions exist appropriately within try and catch branches, including detection of missing assertions and gaps in helper functions.

Quick Start

Use the R004 skill to scan your ArkTS/TypeScript/JavaScript test files and report which it() test cases are missing effective assertions.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: R004
Download link: https://github.com/openharmonyinsight/openharmony-skills/archive/main.zip#r004

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.