Skip to content
Back to skills

Tests Windows

ASecurity

A test also runs on Windows: normalize \r\n on both sides, put #[cfg(unix)] on a Unix-only API, and name a path the way Lydite wrote it (the runner's temp folder is short, RUNNER~1).

  • 3 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added November 11, 2026
ai-agentsshellapi

Works with

  • api

Security analysis

A100/100

Scanned November 11, 2026

npx -y skills add aoricloud/lydite --skill tests-windows --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Tests Windows?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Tests Windows
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/aoricloud-tests-windows/badge)](https://www.skillsdirectory.com/skills/aoricloud-tests-windows)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: tests-windows
description: A test also runs on Windows: normalize \r\n on both sides, put #[cfg(unix)] on a Unix-only API, and name a path the way Lydite wrote it (the runner's temp folder is short, RUNNER~1).
---

## What happened
The Windows job of the CI turned red four times (pull requests 23, 24, 28 and 29), each time on something the Linux job did not show. The Windows job stops at the first failing test binary, so each fix only revealed the next failure, one whole round later. First, a test used a Unix-only API (`std::os::unix`) without `#[cfg(unix)]`, and did not compile on Windows. Then, twice, a test assumed `\n` where the batch files that stand in for the hand in the Windows tests write `\r\n`; the second time, only one side of the comparison was normalized. Last, the fake Claude of the integration tests is a batch file that rebuilt a path with PowerShell: PowerShell returns the long form of the folder, while Lydite had written its rule with the short form of the runner's temp folder (`RUNNER~1`), and at least seven tests failed.

## Why
A hand works in a Linux sandbox, so it never runs these tests on Windows. The Windows CI is the only place they run, and each failure it finds costs a wave, a CI run and a review.

## How it is checked
The Windows job of the CI plays the whole suite; a hand cannot run it in its Linux sandbox. Before you finish, read each test you touched for `\n` assumed in the output of a process or a file, a Unix-only API without `#[cfg(unix)]`, and a path compared in another form than the one Lydite wrote.

## Pitfall
Normalizing only one side passes on Linux and fails on Windows. In a batch file, `%CD%` keeps the folder as the process received it, while PowerShell's `Get-Location` expands it to the long form. A `#[cfg(unix)]` test removes its coverage from Windows: keep a Windows-friendly check of the same behaviour where the behaviour exists there too.

## Files
- src/
- tests/

## Falls when
The Windows job is removed from the CI, or the tests stop using batch files to stand in for the hand.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.