|
1 | | -# Testing Files Generator |
| 1 | +# Testing Files Generator - make real test files at any exact size |
2 | 2 |
|
3 | | -**Generate test files for QA, and know how the system under test should react to them.**. A free, open source tool that creates **real test files** - PDF, PNG, JPG, ZIP, DOCX, XLSX and fourteen more - at **any exact size you ask for**. It also writes down what your application should do with each one. Command line and desktop app, fully offline, on Windows, macOS and Linux. |
4 | | - |
5 | | -[](https://github.com/donislawdev/TestingFilesGenerator/releases/latest) |
6 | 3 | [](https://github.com/donislawdev/TestingFilesGenerator/actions/workflows/ci.yml) |
7 | | -[](LICENSE) |
8 | | -[](https://go.dev) |
9 | | - |
10 | | -[](https://github.com/donislawdev/TestingFilesGenerator/releases/latest) |
11 | | -[](https://github.com/donislawdev/TestingFilesGenerator/releases/latest) |
12 | | -[](https://github.com/donislawdev/TestingFilesGenerator/releases/latest) |
13 | | - |
14 | | - |
15 | | - |
16 | | -⭐ **If it saved you time, leave a star.** That is how the next tester who needs it finds out it |
17 | | -exists. |
18 | | - |
19 | | - |
| 4 | +[](https://github.com/donislawdev/TestingFilesGenerator/releases/latest) |
| 5 | +[](https://github.com/donislawdev/TestingFilesGenerator/releases) |
| 6 | +[](LICENSE) |
| 7 | + |
| 8 | + |
| 9 | + |
| 10 | + |
| 11 | +Testing Files Generator is a tool for QA engineers and developers who need real |
| 12 | +files to test against - an upload form, a parser, anything that takes a file and |
| 13 | +has an opinion about it. You pick one of its 21 formats and the size you want, |
| 14 | +and you get **exactly that**: ask for a 10 MB PDF and you get a PDF that a reader |
| 15 | +will open, at 10 MB to the byte. Every run also leaves a manifest saying **what |
| 16 | +your system should do with each file**, which is the part other generators leave |
| 17 | +to you. It runs from a desktop window or a command line built for CI, never |
| 18 | +touches the network, and works on Windows, macOS and Linux. |
| 19 | + |
| 20 | +⭐ **If it saved you time, leave a star.** That is how the next tester who |
| 21 | +needs it finds out it exists. |
| 22 | + |
| 23 | +## ⚡ What it can do |
| 24 | + |
| 25 | +- **Hit an exact size, to the byte** - ask for 10485761 bytes and get exactly |
| 26 | + that, never a silently rounded file. |
| 27 | +- **Write 21 real formats** - a generated PNG opens in an image viewer, a DOCX |
| 28 | + opens in Word, a ZIP extracts. Not padded zeros with an extension. |
| 29 | +- **Say what should happen to each file** - the manifest carries an expected |
| 30 | + outcome, so your test reads the assertion instead of you writing it out. |
| 31 | +- **Repeat itself byte for byte** - same recipe and seed, same bytes, on any |
| 32 | + machine. Commit a small recipe instead of large binary fixtures. |
| 33 | +- **Build a boundary set in one command** - one byte under a limit, the limit |
| 34 | + itself, one byte over. That is where off by one errors live. |
| 35 | +- **Produce ten thousand files at once** - one command, one manifest, and sizes |
| 36 | + drawn from the seed. |
| 37 | +- **Fill an archive for real** - a ZIP that holds 200 documents, not a stub with |
| 38 | + the right extension. |
| 39 | +- **Take settings per format** - image dimensions, JPEG quality, PDF pages, |
| 40 | + spreadsheet rows and columns. |
| 41 | +- **Fit into CI** - an exit code for every ending, machine readable output, and |
| 42 | + nothing on standard output when a run fails. |
| 43 | +- **Clean up after itself** - `verify` tells you nothing moved, `cleanup` |
| 44 | + removes exactly what it wrote and nothing else. |
| 45 | +- **Work completely offline** - no account, no cloud, no telemetry, no update |
| 46 | + check. The command line binary has no network stack compiled into it at all. |
| 47 | +- **Cost nothing and stay out of your way** - GPL-3.0, and the files you |
| 48 | + generate are yours with no strings attached. |
| 49 | + |
| 50 | + |
| 51 | + |
| 52 | + |
| 53 | + |
| 54 | +## 🧭 Table of contents |
20 | 55 |
|
21 | 56 | This README is also the manual. The short version is above the line, the full |
22 | 57 | reference is below it. |
23 | 58 |
|
| 59 | +- [What it can do](#-what-it-can-do) |
| 60 | +- [Formats it generates](#-formats-it-generates) |
| 61 | +- [The problem it solves](#-the-problem-it-solves) |
| 62 | +- [What makes it different](#-what-makes-it-different) |
| 63 | +- [Install](#-install) |
| 64 | +- [Quick start](#-quick-start) |
| 65 | +- [Reference](#reference) |
| 66 | + - [Commands](#️-commands) |
| 67 | + - [Recipes](#-recipes) |
| 68 | + - [Formats in detail](#-formats-in-detail) |
| 69 | + - [The manifest](#-the-manifest) |
| 70 | + - [Presets](#-presets) |
| 71 | + - [The desktop window](#️-the-desktop-window) |
| 72 | + - [Using it in CI](#️-using-it-in-ci) |
| 73 | + - [Questions](#-questions) |
| 74 | + - [Where this is](#-where-this-is) |
| 75 | + - [Everything inside a generated file is made up](#-everything-inside-a-generated-file-is-made-up) |
| 76 | + - [Licence](#-licence) |
| 77 | + |
24 | 78 | ## 📁 Formats it generates |
25 | 79 |
|
26 | 80 | Twenty one, and every one is a **real file of that format** - it opens in the |
@@ -104,19 +158,6 @@ And where the right answer genuinely depends on your own policy, the manifest |
104 | 158 | says `unspecified` instead of inventing one. A generator that guesses produces |
105 | 159 | false failures, and a suite that cries wolf gets switched off. |
106 | 160 |
|
107 | | -## ✨ Features |
108 | | - |
109 | | -| | | |
110 | | -|---|---| |
111 | | -| 🎯 **Exact size, to the byte** | Ask for 10485761 bytes and get exactly that. Never a silently rounded file. | |
112 | | -| 📄 **20 real formats** | Not padded zeros with an extension. A generated PNG opens in an image viewer, a DOCX opens in Word, a ZIP extracts. | |
113 | | -| 🧾 **A manifest that is a test oracle** | Path, size, SHA-256, format, seed, tool version - and what your system should do with the file. | |
114 | | -| 🔁 **Reproducible** | Same recipe and seed, same bytes, on any machine. Commit a small recipe instead of large binary fixtures. | |
115 | | -| 🖥️ **Two interfaces, one engine** | A command line built for CI, and a desktop window for exploratory testing. Neither is a cut down version of the other. | |
116 | | -| 🔌 **Completely offline** | No account, no cloud, no telemetry, no update checks. The command line binary has no network stack compiled into it at all. | |
117 | | -| 🧹 **Cleans up after itself** | `verify` tells you nothing moved, `cleanup` removes exactly what was written and nothing else. | |
118 | | -| 🆓 **Free and open source** | GPL-3.0. The files you generate are yours, with no strings attached. | |
119 | | - |
120 | 161 | ## 📦 Install |
121 | 162 |
|
122 | 163 | **Download a binary.** Take the archive for your system from the |
@@ -441,7 +482,7 @@ interrupted. One entry per file: |
441 | 482 | ```json |
442 | 483 | { |
443 | 484 | "manifest_version": "1.0", |
444 | | - "tool": { "name": "testing-files-generator", "version": "0.1.0" }, |
| 485 | + "tool": { "name": "testing-files-generator", "version": "0.2.0" }, |
445 | 486 | "run": { |
446 | 487 | "id": "run_b359aa8d94", |
447 | 488 | "seed": 0, |
@@ -619,7 +660,7 @@ a valid one of its format. |
619 | 660 |
|
620 | 661 | ### Which formats are coming next? |
621 | 662 |
|
622 | | -`7z`, `tiff`, `webp`, `mp3` and `mp4`. |
| 663 | +`7z`, `webp`, `mp3` and `mp4`. |
623 | 664 |
|
624 | 665 | ## 🚧 Where this is |
625 | 666 |
|
|
0 commit comments