hkj-test

Generate fluent AssertJ assertions for Higher-Kinded-J types.

78|6|Updated Apr 4, 2025
One-click install
npx skills add https://github.com/higher-kinded-j/higher-kinded-j --skill hkj-test
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: hkj-test
Source: https://github.com/higher-kinded-j/higher-kinded-j/tree/main/.claude/skills/hkj-test
Command: npx skills add https://github.com/higher-kinded-j/higher-kinded-j --skill hkj-test

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill simplifies testing for Higher-Kinded-J (HKJ) types by providing fluent, type-safe AssertJ assertions that eliminate boilerplate and ensure test code remains readable and aligned with business logic.

Core Features & Use Cases

  • Fluent Assertions: Provides dedicated assertion classes for every HKJ type, including Either, Maybe, IO, VTask, and Monad Transformers.
  • Optic Law Harness: Includes a comprehensive suite of static assertions to verify the laws of Iso, Lens, Prism, Affine, and Traversal optics.
  • Deterministic Time: Offers a SteppableClock to control time-based logic in tests without relying on system clocks or thread sleeps.
  • Use Case: Use this to verify that your domain-specific Either-based error handling or complex optic transformations behave correctly under both success and failure conditions.

Quick Start

Use the hkj-test skill to generate AssertJ fluent assertions for the provided Higher-Kinded-J type and verify its state.

Frequently Asked Questions about hkj-test

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write fluent AssertJ assertions for Higher-Kinded-J types in Java?

You can write fluent AssertJ assertions for Higher-Kinded-J types by using dedicated assertion classes for types like Either, Maybe, and IO to ensure type-safe and readable unit testing without boilerplate.

What is the best way to test optic laws for functional programming structures in Java?

Testing optic laws for functional programming structures requires an optic law harness that provides static assertions to verify the laws of Iso, Lens, Prism, Affine, and Traversal optics within your Java applications.

How do I control time-based logic deterministically in Java unit tests without thread sleeps?

To control time-based logic deterministically in Java unit tests without thread sleeps, you can use a controlled SteppableClock implementation to manipulate time progression explicitly.

Can I validate monad transformers and complex functional structures using type-safe assertions?

Yes, you can validate monad transformers and complex functional structures using type-safe assertion helpers that facilitate the verification of these advanced functional programming components under success and failure conditions.

Does AssertJ support testing Either-based error handling out of the box?

Standard AssertJ lacks specific support for Higher-Kinded-J types, requiring dedicated fluent assertion helpers to properly verify domain-specific Either-based error handling and complex optic transformations.