Logo Waldemar Muhl
  • Home
  • About
  • Recent Posts
  • Skills
  • Experience
  • Posts
  • Dark Theme
    Light Theme Dark Theme System Theme
Logo Inverted Logo
  • Posts
  • AI and ML
    • AI assistants as customer service agents
    • Deepseek Misconceptions
    • Is this AI?
  • Architecture
    • TOGAF
  • Coding
    • Angular Service Worker
    • Big O Notation
    • Class modifiers in C#
    • Delaying Complexity
    • Fluent Validation
    • Implicit Usings
    • Sudoku
      • Part 1
      • Part 2
      • Part 3
    • Unit Tests
      • Unit Testing in C# with FluentAssertions
      • Using Moq to complement your Unit Tests
      • Expanding on Unit Tests with GenFu and ChatGPT
  • Design Patterns
    • Introduction
    • SOLID
      • Single Responsibility
      • Open-Closed
      • Liskov's Substitution
      • Interface Segregation
      • Dependency Inversion
    • Ambassador
    • Blue-Green Deployments
    • Chain of Responsibility
    • Circuit Breaker
    • Claim Check
    • Decorator
    • Importance of Design Patterns
    • Observer
    • Observer Cat
    • Sidecar
    • Singleton
  • Miscellaneous
    • Coding Soundtrack
    • Innovation Amidst Escalating Pressures
    • Live Coding Interviews
    • My new site
    • Navigating the Data Lifecycle
    • Powershell Tips
    • PSA - Storage Sense
    • Real Agile
    • Windows Terminal with Oh My Posh
  • Tech Reviews
    • Airpods Pro 2nd Gen
    • Jetbrains' AI Assistant Review
    • NDepend Code Analysis
  • Tutorials
    • Deploying Hugo to Azure Static Site
Hero Image
Expanding on Unit Tests with GenFu and ChatGPT

In this chapter on unit testing, I’m going to discuss Moq and how it can effectively be used to ensure you are unit testing correctly without having to concern yourself (too much) with dependencies further down the chain. In this final (for now) chapter on unit testing, I’ll be showing you how to generate randomised data for our unit tests using GenFu as well as how we can use ChatGPT to write unit tests for us.

  • coding
  • computerScience
  • unitTests
Tuesday, October 31, 2023 Read
Hero Image
Using Moq to complement your Unit Tests

In this chapter on unit testing, I’m going to discuss Moq and how it can effectively be used to ensure you are unit testing correctly without having to concern yourself (too much) with dependencies further down the chain. Sample Project I’ve used the base ASP.NET Code Web API project to start things off and made a few modifications to it, all of which can be found in the repo below:

  • coding
  • computerScience
  • unitTests
Sunday, October 22, 2023 Read
Hero Image
Unit Testing in C# with FluentAssertions

Unit testing should be an essential part of your SDLC, especially when you have multiple contributors to a project. It’s a great way to ensure that your code is still returning the appropriate responses, even after someone else (who might have a different context than you) has tinkered with it. Don’t get me wrong, writing unit tests can be an exercise in tedium but it has saved my behind more times than I care to admit.

  • coding
  • computerScience
  • unitTests
Tuesday, October 10, 2023 Read
Navigation
  • About
  • Recent Posts
  • Skills
  • Experience
Contact me:
  • waltiplayer@gmail.com

Toha Theme Logo Toha
© 2024 Copyright Waldemar Muhl.
Powered by Hugo Logo