mirror of
https://github.com/wiremock/WireMock.Net.git
synced 2026-01-18 09:27:08 +01:00
* Fix construction of path in OpenApiParser (#1265) * Server-Sent Events (#1269) * Server Side Events * fixes * await HandleSseStringAsync(responseMessage, response, bodyData); * 1.7.5-preview-01 * IBlockingQueue * 1.7.5-preview-02 (03 April 2025) * IBlockingQueue * ... * Support OpenApi V31 (#1279) * Support OpenApi V31 * Update src/WireMock.Net.OpenApiParser/Extensions/OpenApiSchemaExtensions.cs Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * fx --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Add ProtoDefinitionHelper.FromDirectory (#1263) * Add ProtoDefinitionHelper.FromDirectory * . * unix-windows * move test * imports in the proto files indeed should use a forward slash * updates * . * private Func<IdOrTexts> ProtoDefinitionFunc() * OpenTelemetry * . * fix path utils --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
43 lines
1.2 KiB
C#
43 lines
1.2 KiB
C#
// Copyright © WireMock.Net
|
|
|
|
using System;
|
|
using Microsoft.OpenApi.Models;
|
|
using Microsoft.OpenApi.Models.Interfaces;
|
|
|
|
namespace WireMock.Net.OpenApiParser.Settings;
|
|
|
|
/// <summary>
|
|
/// A class defining the example values to use for the different types.
|
|
/// </summary>
|
|
public class WireMockOpenApiParserExampleValues : IWireMockOpenApiParserExampleValues
|
|
{
|
|
/// <inheritdoc />
|
|
public virtual bool Boolean => true;
|
|
|
|
/// <inheritdoc />
|
|
public virtual int Integer => 42;
|
|
|
|
/// <inheritdoc />
|
|
public virtual float Float => 4.2f;
|
|
|
|
/// <inheritdoc />
|
|
public virtual decimal Decimal => 4.2m;
|
|
|
|
/// <inheritdoc />
|
|
public virtual Func<DateTime> Date { get; } = () => System.DateTime.UtcNow.Date;
|
|
|
|
/// <inheritdoc />
|
|
public virtual Func<DateTime> DateTime { get; } = () => System.DateTime.UtcNow;
|
|
|
|
/// <inheritdoc />
|
|
public virtual byte[] Bytes { get; } = [48, 49, 50];
|
|
|
|
/// <inheritdoc />
|
|
public virtual object Object => "example-object";
|
|
|
|
/// <inheritdoc />
|
|
public virtual string String => "example-string";
|
|
|
|
/// <inheritdoc />
|
|
public virtual IOpenApiSchema? Schema { get; set; } = new OpenApiSchema();
|
|
} |