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

tests: internal: log_event_encoder: add test code #7992

Merged
merged 1 commit into from
Oct 7, 2023

Conversation

nokute78
Copy link
Collaborator

This patch is to add test code for log_event_encoder after merging #7971

Note: #7736


Enter [N/A] in the box, if an item is not applicable to your change.

Testing
Before we can approve your change; please submit the following in a comment:

  • [N/A] Example configuration file for the change
  • Debug log output from testing the change
  • Attached Valgrind output that shows no leaks or memory corruption was found

If this is a change to packaging of containers or native binaries then please confirm it works for all targets.

  • [N/A] Run local packaging test showing all targets (including any new ones) build.
  • [N/A] Set ok-package-test label to test for all targets (requires maintainer to do).

Documentation

  • [N/A] Documentation required for this feature

Backporting

  • [N/A] Backport to latest stable release.

Debug/Valgrind output

$ valgrind --leak-check=full bin/flb-it-log_event_encoder 
==17020== Memcheck, a memory error detector
==17020== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==17020== Using Valgrind-3.18.1 and LibVEX; rerun with -h for copyright info
==17020== Command: bin/flb-it-log_event_encoder
==17020== 
Test basic_format_fluent_bit_v2...              [ OK ]
==17020== Warning: invalid file descriptor -1 in syscall close()
Test basic_format_fluent_bit_v1...              [ OK ]
==17020== Warning: invalid file descriptor -1 in syscall close()
Test basic_metadata_format_fluent_bit_v2...     [ OK ]
==17020== Warning: invalid file descriptor -1 in syscall close()
Test create_destroy...                          [ OK ]
==17020== Warning: invalid file descriptor -1 in syscall close()
Test create_unsupported_format...               [ OK ]
==17020== Warning: invalid file descriptor -1 in syscall close()
Test init_destroy...                            [ OK ]
==17020== Warning: invalid file descriptor -1 in syscall close()
Test init_unsupported_format...                 [ OK ]
==17020== Warning: invalid file descriptor -1 in syscall close()
Test emit_raw_record...                         [ OK ]
==17020== Warning: invalid file descriptor -1 in syscall close()
SUCCESS: All unit tests have passed.
==17020== 
==17020== HEAP SUMMARY:
==17020==     in use at exit: 0 bytes in 0 blocks
==17020==   total heap usage: 6,785 allocs, 6,785 frees, 868,933 bytes allocated
==17020== 
==17020== All heap blocks were freed -- no leaks are possible
==17020== 
==17020== For lists of detected and suppressed errors, rerun with: -s
==17020== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)

Fluent Bit is licensed under Apache 2.0, by submitting this pull request I understand that this code will be released under the terms of that license.

@nokute78 nokute78 temporarily deployed to pr September 30, 2023 05:46 — with GitHub Actions Inactive
@nokute78 nokute78 temporarily deployed to pr September 30, 2023 05:46 — with GitHub Actions Inactive
@nokute78 nokute78 temporarily deployed to pr September 30, 2023 05:46 — with GitHub Actions Inactive
@nokute78 nokute78 temporarily deployed to pr September 30, 2023 06:13 — with GitHub Actions Inactive
@leonardo-albertovich
Copy link
Collaborator

Thank you very much @nokute78

@nokute78 nokute78 merged commit a397936 into fluent:master Oct 7, 2023
41 of 42 checks passed
@nokute78 nokute78 deleted the 3_test_log_event_encoder branch October 7, 2023 11:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants