QaaS.Mocker
2.0.0
See the version list below for details.
dotnet add package QaaS.Mocker --version 2.0.0
NuGet\Install-Package QaaS.Mocker -Version 2.0.0
<PackageReference Include="QaaS.Mocker" Version="2.0.0" />
<PackageVersion Include="QaaS.Mocker" Version="2.0.0" />
<PackageReference Include="QaaS.Mocker" />
paket add QaaS.Mocker --version 2.0.0
#r "nuget: QaaS.Mocker, 2.0.0"
#:package QaaS.Mocker@2.0.0
#addin nuget:?package=QaaS.Mocker&version=2.0.0
#tool nuget:?package=QaaS.Mocker&version=2.0.0
QaaS.Mocker
Configurable mock runtime for QaaS protocol workloads.
Contents
- Overview
- Packages
- Functionalities
- Protocol Support
- Quick Start
- Run the Example
- Build and Test
- Documentation
Overview
This repository contains one solution: QaaS.Mocker.sln.
QaaS.Mocker is published as a single NuGet package and composes internal runtime modules for stubs, protocol servers, and optional Redis controller operations.
Packages
| Package | Latest Version | Total Downloads |
|---|---|---|
| QaaS.Mocker |
Functionalities
QaaS.Mocker
- Parses CLI options and loads YAML configuration with overwrite files/arguments and optional environment resolution.
- Builds and validates execution context, data sources, stubs, one or more server runtimes, and optional controller runtime.
- Supports execution modes:
Run,Lint, andTemplate.
QaaS.Mocker.Stubs
- Builds transaction stubs from configured processors and data source bindings.
- Executes request/response transformation through configurable serializer/deserializer pairs.
- Includes default status-code stubs for not-found and internal-error flows.
QaaS.Mocker.Servers
- Hosts protocol runtimes for
HTTP/HTTPS,gRPC/gRPCs, andSocket. - Routes actions/RPC methods to transaction stubs through state objects.
- Caches input/output payloads for controller consume operations.
QaaS.Mocker.Controller
- Initializes optional Redis-backed runtime controller when configured.
- Handles
PingandCommandchannels. - Supports runtime commands such as action-to-stub switch, trigger, and consume.
QaaS.Mocker.Example
- Provides runnable multi-server and transport-specific mocker configurations, sample processors, protobuf schema, and sample data assets.
Protocol Support
Supported protocol/runtime families in QaaS.Mocker:
| Family | Implementations |
|---|---|
| HTTP / RPC | HTTP, HTTPS, gRPC, gRPCs |
| Streaming / Socket | Socket (broadcast and collect modes) |
| Runtime Control | Redis-backed controller channels (ping and command) |
Quick Start
Install package:
dotnet add package QaaS.Mocker
Upgrade package:
dotnet add package QaaS.Mocker --version <target-version>
dotnet restore
Run the Example
The example uses relative paths for certificates, sample data, and socket payloads, so run it from QaaS.Mocker.Example. The example entry point also disables environment-variable overrides by default so IDE terminal variables do not rewrite the sample configuration.
- Open a terminal in the example directory.
Set-Location .\QaaS.Mocker.Example
- Create the development certificate expected by the sample HTTPS and gRPC configs.
dotnet dev-certs https -ep .\Certificates\devcert.pfx -p qaas-dev-cert
- Start the combined example. It boots HTTPS, gRPC with TLS, and a TCP socket collect endpoint from the same process.
dotnet run -- run mocker.qaas.yaml
- In a second terminal, call the HTTPS health endpoint.
curl.exe -k https://127.0.0.1:8443/health
- Call the gRPC endpoint from Git Bash, WSL, or another POSIX-style shell if you have
grpcurlinstalled.
grpcurl -insecure -import-path Protos -proto echo.proto -d '{"message":"hello"}' 127.0.0.1:50051 qaas.mocker.example.EchoService/Echo
- Send a payload to the socket collect endpoint. The socket endpoint does not reply; success is a clean connect and write plus a collect log entry in the server terminal.
$client = [System.Net.Sockets.TcpClient]::new()
$client.Connect('127.0.0.1', 7001)
$stream = $client.GetStream()
$payload = [System.Text.Encoding]::UTF8.GetBytes('socket-check')
$stream.Write($payload, 0, $payload.Length)
$stream.Flush()
$stream.Dispose()
$client.Dispose()
- Generate the effective combined configuration without using
--mode.
dotnet run -- template mocker.qaas.yaml
- If you still want the dedicated gRPC-only sample, it remains available.
dotnet run -- run mocker.grpc.qaas.yaml
Build and Test
dotnet restore QaaS.Mocker.sln
dotnet build QaaS.Mocker.sln -c Release --no-restore
dotnet test QaaS.Mocker.sln -c Release --no-build
Documentation
- Official docs: thesmoketeam.github.io/qaas-docs
- CI workflow:
.github/workflows/ci.yml - NuGet package: QaaS.Mocker on NuGet
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- CommandLineParser (>= 2.9.1)
- QaaS.Framework.Executions (>= 1.2.1)
- QaaS.Mocker.Controller (>= 2.0.0)
- QaaS.Mocker.Servers (>= 2.0.0)
- System.IO.Abstractions (>= 22.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 2.1.1 | 103 | 3/28/2026 |
| 2.1.0 | 69 | 3/25/2026 |
| 2.0.6 | 99 | 3/23/2026 |
| 2.0.6-alpha.1 | 35 | 3/22/2026 |
| 2.0.5 | 130 | 3/21/2026 |
| 2.0.5-alpha.4 | 33 | 3/22/2026 |
| 2.0.5-alpha.3 | 36 | 3/21/2026 |
| 2.0.5-alpha.1 | 37 | 3/21/2026 |
| 2.0.4 | 85 | 3/21/2026 |
| 2.0.3 | 80 | 3/17/2026 |
| 2.0.2 | 74 | 3/17/2026 |
| 2.0.1 | 85 | 3/16/2026 |
| 2.0.0 | 82 | 3/16/2026 |
| 2.0.0-alpha.12 | 40 | 3/15/2026 |
| 2.0.0-alpha.11 | 39 | 3/15/2026 |
| 2.0.0-alpha.7 | 45 | 3/11/2026 |
| 2.0.0-alpha.6 | 37 | 3/6/2026 |
| 2.0.0-alpha.5 | 36 | 3/5/2026 |
| 2.0.0-alpha.4 | 36 | 3/5/2026 |
| 2.0.0-alpha.3 | 35 | 3/5/2026 |