-
Notifications
You must be signed in to change notification settings - Fork 83
Python and Java Tests with E2E testing Framework #354
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
Conversation
Language End to End Testing for PR
Function Apps for Lang E2E
* Adding Async Functions * Adding Get Http call * Added Single Event Test Function App for Dotnet * Added Dockerfile and Multi Kafka Trigger in dotnet * Updated Multi Kafka Output Binding in dotnet * Testing Http and Command Utilities * Cleaning implementation * Adding Constants and BrokerType * Adding env flag in docker commands * Correcting Dotnet Confluent Dockerfile * Removing dependence of Apptype from initialization code * Adding Test Assert * Renaming Python Test to include BrokerType * Adding Env Variables for Eventhub * Adding Python Constants and env variables * Removing FunctionsApps from Build * Fixing Build Issues * Correcting Dotnet Functions Apps * Removing Extra Python App Co-authored-by: krishna-kariya <kkariya@microsoft.com> Co-authored-by: krishna-kariya <89184055+krishna-kariya@users.noreply.github.com>
Utilities for E2E framewok
* Adding Process Manager and Cleanup Class * Making response list private * Added and Tested Python Apps * Adding Java Test Cases * Adding Env Variables to Azure Pipeline * Commenting Unit Test * Docker Build for python and java local broker test * Commenting Old Language Tests * Commenting Local Kafka Startup * Adding Http log and Powershell command * Adding additional logs for eventhub * Modifying Ubuntu Command in pipeline * Modifying Process Executor for Linux environments * Adding additional tests and correcting function app * Changing Eventhub Namespace * Adding semaphore for eventhub client access * Allowing Max threads for async operations * Correcting Dotnet Isolated Functions * Commenting old docker builds * Commenting old docker builds * Correcting Mistake in dotnet isolated csproj * Adding logs for http request response * Adding exception logging for function invocation * Code Cleanup * Correcting Azure Pipeline * Updating dotnet isolated function apps * mend * Uncommenting DotnetIsolated Confluent Test and changing Port number * Changing Typescript Eventhub app port to a random port Co-authored-by: krishna-kariya <kkariya@microsoft.com>
@jainharsh98 build is failing please fix that Could you please add the context in the description what exactly is the scope of this PR. |
@jainharsh98 Could you please add a readme file for the E2E understanding for configs setup for local |
...ns.Kafka.LangEndToEndTests/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests.csproj
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/KafkaLanguageEndToEndTests.cs
Outdated
Show resolved
Hide resolved
|
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Util/Util.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Type/AppType.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Util/Constants.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Entity/KafkaEntity.cs
Outdated
Show resolved
Hide resolved
...ft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Queue/AzureStorageQueueManager.cs
Outdated
Show resolved
Hide resolved
...Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Queue/KafkaQueueManager.cs
Outdated
Show resolved
Hide resolved
...icrosoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Entity/HttpRequestEntity.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Queue/QueueResponse.cs
Show resolved
Hide resolved
...ft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Queue/AzureStorageQueueManager.cs
Outdated
Show resolved
Hide resolved
...ft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Queue/AzureStorageQueueManager.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Queue/IQueueManager.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/TestSuitInitializer.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Command/HttpCommand.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/TestLogger.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/BaseE2E.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/BaseE2E.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/KafkaE2EFixture.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/KafkaE2EFixture.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/TestSuitInitializer.cs
Show resolved
Hide resolved
...ft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/Command/Shell/DockerRunCommand.cs
Show resolved
Hide resolved
/* Provides a static logger instance for logging throughout the framework. | ||
* This is needed as xunit framework does not support dependency injection directly. | ||
*/ | ||
internal static class TestLogger |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you intend to make this a singleton class? In that case you can create it as a singleton pattern.You can keep class as non-static.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. We are planning to have a separate work item for logging improvement.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think Logger needs to be improved with thi PR only, this logger looks incomplete and doesn't holds the guarantees of debugging the test
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Tests/JavaEventhubAppTest.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/TestSuitInitializer.cs
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/TestSuitInitializer.cs
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/TestSuitInitializer.cs
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/TestSuiteCleaner.cs
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Common/KafkaE2EFixture.cs
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Tests/PythonEventhubAppTest.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.WebJobs.Extensions.Kafka.LangEndToEndTests/Tests/PythonEventhubAppTest.cs
Outdated
Show resolved
Hide resolved
_queueType = queueType; | ||
_queueName = queueName; | ||
_queueOperation = queueOperation; | ||
if (QueueType.EventHub == queueType) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
L22-29 looks like a factory pattern approach shall we refactor this to a factory class ??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. We can take this up in the improvement task.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's a small task can be taken care in the same PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Logger functionality is not sufficient, let's fix that in the same PR
This pull request has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 7 days. It will be closed if no further activity occurs within 7 days of this comment. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
Adds a framework for testing the extension with azure functions across different languages with managed kafka offerings.
Current PR adds test cases for -
and Languages -