<commit_before>require 'cucumber/core/filter'
require 'rbconfig'

# Filter out tests which don't run on Windows
WindowsFilter = Cucumber::Core::Filter.new do
    def test_case(test_case)
        is_not_windows = !(RbConfig::CONFIG['host_os'] =~ /mswin|mingw|cygwin/i)
        is_not_tagged = !test_case.match_tags?("@notwindows")

        if is_not_windows || is_not_tagged then
            test_case.describe_to(receiver)
        end
    end
end

AfterConfiguration do |config|
  config.filters << WindowsFilter.new
end<commit_msg>Add filter for @onlywindows<commit_after>require 'cucumber/core/filter'
require 'rbconfig'

# Filter out tests which don't run on Windows
WindowsFilter = Cucumber::Core::Filter.new do
    def test_case(test_case)
        is_not_windows_platform = !(RbConfig::CONFIG['host_os'] =~ /mswin|mingw|cygwin/i)
        is_not_windows_test = !test_case.match_tags?("@notwindows")
        is_windows_only_test = test_case.match_tags?("@onlywindows")

        if is_not_windows_platform && is_windows_only_test then
            # 
        elsif is_not_windows_platform || is_not_windows_test then
            test_case.describe_to(receiver)
        end
    end
end

AfterConfiguration do |config|
  config.filters << WindowsFilter.new
end
{'fraction_non_alphanumeric': 0.09690230341540905, 'fraction_numerical': 0.0, 'mean_word_length': 3.864864864864865, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6687986', 'n_tokens_mistral': 415, 'n_tokens_neox': 405, 'n_words': 80}