Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[#6292] Add unit tests for AzureBlobStorage #6301

Merged
merged 2 commits into from
May 17, 2022

Conversation

ceciliaavila
Copy link
Collaborator

Addresses #6292
#minor

Description

This PR removes the existing Functional tests for the AzureBlobStorage class and replaces them with unit tests that don't require the use of the Azure Storage Emulator.

Specific Changes

  • Updates the AzureBlobStorage class, adding a new internal constructor that receives an instance of CloudBlobClient. This constructor is for the use of the tests only.
  • Replaces the existing tests in the AzureBlobStorageTests class with unit tests for each method, constructor, method validations, etc, reaching 89% of code coverage.

Testing

The following images show the new unit tests and the code coverage.
image

@ceciliaavila ceciliaavila added the Automation: No parity PR does not need to be applied to other languages. label Apr 25, 2022
@ceciliaavila ceciliaavila requested a review from a team as a code owner April 25, 2022 17:26
@coveralls
Copy link
Collaborator

coveralls commented Apr 25, 2022

Pull Request Test Coverage Report for Build 304856

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 25 unchanged lines in 2 files lost coverage.
  • Overall coverage increased (+0.2%) to 78.945%

Files with Coverage Reduction New Missed Lines %
/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Actions/ForEachElement.cs 8 90.0%
/libraries/Microsoft.Bot.Builder/BotFrameworkAdapter.cs 17 47.91%
Totals Coverage Status
Change from base Build 301524: 0.2%
Covered Lines: 25373
Relevant Lines: 32140

💛 - Coveralls

@BruceHaley
Copy link
Contributor

✔️ No Binary Compatibility issues for Microsoft.Bot.Builder.Azure.dll

@gabog gabog merged commit 3ffab3a into main May 17, 2022
@gabog gabog deleted the southworks/update/azure-blobs-storage-tests branch May 17, 2022 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Automation: No parity PR does not need to be applied to other languages.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants