<commit_before># encoding: UTF-8

require "helper"
require "lint/blocking_commands"

class TestDistributedBlockingCommands < Test::Unit::TestCase

  include Helper::Distributed
  include Lint::BlockingCommands<commit_msg>Test blocking pop distribution errors<commit_after># encoding: UTF-8

require "helper"
require "lint/blocking_commands"

class TestDistributedBlockingCommands < Test::Unit::TestCase

  include Helper::Distributed
  include Lint::BlockingCommands

  def test_blpop_raises
    assert_raises(Redis::Distributed::CannotDistribute) do
      r.blpop(["foo", "bar"])
    end
  end

  def test_blpop_raises_with_old_prototype
    assert_raises(Redis::Distributed::CannotDistribute) do
      r.blpop("foo", "bar", 0)
    end
  end

  def test_brpop_raises
    assert_raises(Redis::Distributed::CannotDistribute) do
      r.brpop(["foo", "bar"])
    end
  end

  def test_brpop_raises_with_old_prototype
    assert_raises(Redis::Distributed::CannotDistribute) do
      r.brpop("foo", "bar", 0)
    end
  end

  def test_brpoplpush_raises
    assert_raises(Redis::Distributed::CannotDistribute) do
      r.brpoplpush("foo", "bar")
    end
  end

  def test_brpoplpush_raises_with_old_prototype
    assert_raises(Redis::Distributed::CannotDistribute) do
      r.brpoplpush("foo", "bar", 0)
    end
  end
{'fraction_non_alphanumeric': 0.09984756097560976, 'fraction_numerical': 0.0038109756097560975, 'mean_word_length': 4.914414414414415, 'pattern_counts': {'":': 0, '<': 5, '<?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': '5889366', 'n_tokens_mistral': 452, 'n_tokens_neox': 440, 'n_words': 82}