Skip to content
This repository was archived by the owner on Jan 5, 2026. It is now read-only.
This repository was archived by the owner on Jan 5, 2026. It is now read-only.

DCR: As a developer, I would like to see a good example that shows me how to write effective unit tests for conversations #5347

@gabog

Description

@gabog

Issue

The BotBuilder Samples repo doesn't include any examples on how to test a bot, it would be nice to have a Test Project for the non trivial bots so developers can see a test project in action.

Proposed change

Imlement unit test project for the CoreBot

The unit tests should show case how to:

  • Use Dependency Injection to swap different components of the bot solution with mock objects
  • Create mock objects for LUIS
  • Use the testing framework and related tools for implementing tests
  • How to unit test custom dialogs and custom prompts
  • How to unit test controller code
  • How to manage State for unit tests without having to rely on CosmosDB (MemoryState)
  • Use test transcripts for review the test outcomes

Tracking Status

Samples C# (Tracked in 1560)

  • PR
  • Merged

Samples JavaScript (Tracked in 1561)

  • PR
  • Merged

Samples TypeScript (Tracked in 1629)

  • PR
  • Merged

Samples Python (Tracked in 1562)

  • PR
  • Merged

Metadata

Metadata

Assignees

Labels

Area: Testing frameworkIssues related to the bot testing frameworkP0Must Fix. Release-blocker

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions