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

[receiver/sqlquery] sqlserver integration tests, improved coverage #36922

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Grandys
Copy link
Contributor

@Grandys Grandys commented Dec 22, 2024

Description

Mainly added test for sqlserver, plus added coverage for logs (as requested in comment)

Link to tracking issue

Fixes #29695

Testing

Main changes:

  • Added metrics tests for SqlServer
  • Covered MySql, SqlServer and Oracle for logs

Improvements:

  • To avoid repetitions, changed approach to "parameterized" tests - run the same test flow for different database engines (for logs only).
  • Do not hardcode "localhost" and host port, get these values from testcontainers.
  • Replaced inserting test values into the database from running CLI commands in the container to executing SQL commands.
  • Updated Oracle init script to use otel schema instead of sys.

Important: For Oracle and SQL Server, tests are skipped (tested locally) - I expect them to fail due to #27577 (which was not fixed but closed due to inactivity).

@Grandys Grandys requested review from dmitryax, crobert-1 and a team as code owners December 22, 2024 21:42
@github-actions github-actions bot added the receiver/sqlquery SQL query receiver label Dec 22, 2024
@songy23 songy23 added the Run Windows Enable running windows test on a PR label Dec 23, 2024
Copy link

linux-foundation-easycla bot commented Dec 23, 2024

CLA Signed

The committers listed above are authorized under a signed CLA.

@Grandys Grandys force-pushed the sqlqueryreciver-improve-integration-tests branch 3 times, most recently from dc3dc6e to 1bdd23c Compare December 23, 2024 17:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
receiver/sqlquery SQL query receiver Run Windows Enable running windows test on a PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

sqlqueryreceiver lacks integration tests for mssql
3 participants