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

Fix tag on failure test #52

Merged
merged 2 commits into from
Dec 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
@@ -1,3 +1,6 @@
## 3.2.1
- Fix tag on failure test [#52](https://github.com/logstash-plugins/logstash-filter-json/pull/52)

## 3.2.0
- Feat: check target is set in ECS mode [#49](https://github.com/logstash-plugins/logstash-filter-json/pull/49)
- Refactor: logging improvements to print event details in debug mode
Expand Down
2 changes: 1 addition & 1 deletion logstash-filter-json.gemspec
@@ -1,7 +1,7 @@
Gem::Specification.new do |s|

s.name = 'logstash-filter-json'
s.version = '3.2.0'
s.version = '3.2.1'
s.licenses = ['Apache License (2.0)']
s.summary = "Parses JSON events"
s.description = "This gem is a Logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This gem is not a stand-alone program"
Expand Down
5 changes: 3 additions & 2 deletions spec/filters/json_spec.rb
Expand Up @@ -62,8 +62,9 @@
end

logstash_version = Gem::Version.create(LOGSTASH_CORE_VERSION)

if (Gem::Requirement.create('>= 7.0').satisfied_by?(logstash_version) ||

# Field Reference can handle special characters since 8.3.0
if ((Gem::Requirement.create('>= 7.0').satisfied_by?(logstash_version) && Gem::Requirement.create('< 8.3').satisfied_by?(logstash_version)) ||

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we have or can we add test cases for 8.3+ LS versions?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we have existing test for tagging json fail for 8.3+

(Gem::Requirement.create('~> 6.4').satisfied_by?(logstash_version) && LogStash::SETTINGS.get('config.field_reference.parser') == 'STRICT'))
describe "unsupported field name using `target`" do
config <<-CONFIG
Expand Down