BogusLibrary 1.0.1

dotnet add package BogusLibrary --version 1.0.1
                    
NuGet\Install-Package BogusLibrary -Version 1.0.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="BogusLibrary" Version="1.0.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="BogusLibrary" Version="1.0.1" />
                    
Directory.Packages.props
<PackageReference Include="BogusLibrary" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add BogusLibrary --version 1.0.1
                    
#r "nuget: BogusLibrary, 1.0.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package BogusLibrary@1.0.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=BogusLibrary&version=1.0.1
                    
Install as a Cake Addin
#tool nuget:?package=BogusLibrary&version=1.0.1
                    
Install as a Cake Tool

About

This class project provides data generators for developers to use for learning, testing, and pre-populating data sources, such as Microsoft EF Core.

Core

Uses NuGet package Bogus to generate fake data.

Classes

  • This is a small .NET class library (target: net8.0) that provides fake/test data generators built on the Bogus library. Key folders:
    • Generators/: Generator classes that produce Models/* instances (e.g., HumanGenerator, ProductGenerator, UserGenerator).
    • Models/: Plain data models used across generators and the DataContainer singleton.
    • Classes/: helpers like DataContainer which bootstraps example datasets.
    • LanguageExtensions/: small utility/extension methods.

Typical data flow & patterns

  • Generators expose Create(int count, bool random = false) and CreateOne(bool random = false) helpers. Example: Generators/HumanGenerator.cs and Generators/ProductGenerator.cs.
  • Most generators use Bogus Faker<T> and often set Seed = new Random(338) when random == false to produce deterministic, repeatable output. Respect and preserve this seed behavior when changing APIs.
  • Some generators use StrictMode(true) on the faker to ensure all model properties are populated (see ProductGenerator).
  • Generators/JsonGenerator.cs provides GenerateJson() and typed helpers like HumansAsJson(...) — use these for quick serialized output examples.
  • Classes/DataContainer constructs sample datasets on demand using the generators — it's a useful runnable example of how pieces fit together.
Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net8.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
1.0.1 279 12/19/2025
1.0.0 273 12/16/2025

Add Vehicle generator