<commit_before>require 'spec_helper'

describe Deck do
  describe 'creation' do
    describe 'defaults' do
      before(:all) do
        make_deck
      end

      it 'should create a deck with 52 cards' do
        @deck.size.should == 52
      end

      it 'should have every single combination of card suit and value' do
        found_cards = []
        @deck.cards.each do |card|
          Card.all_cards do |value, suit|
            @match = ((card.suit == suit) && (card.value == value))
            if @match
              break
            end
          end
          if @match
            found_cards << true
            next
          else
            found_cards << false
          end
        end
      end
    end

    describe 'custom' do
      it 'should create a specific deck size' do
        custom_size = 6
        @deck = Deck.new(custom_size)
        @deck.size.should == custom_size * 52
      end
    end
  end

  describe 'operation' do
    describe 'shuffling' do
      pending("can't be tested?")
    end
<commit_msg>Fix broken test<commit_after>require 'spec_helper'

describe Deck do
  describe 'creation' do
    describe 'defaults' do
      before(:all) do
        make_deck
      end

      it 'should create a deck with 52 cards' do
        @deck.size.should == 52
      end

      it 'should have every single combination of card suit and value' do
        found_cards = []
        @deck.cards.each do |card|
          Card.all_cards do |value, suit|
            @match = ((card.suit == suit) && (card.value == value))
            if @match
              break
            end
          end
          if @match
            found_cards << true
            next
          end
        end
        found_cards.all?.should == true
        found_cards.count.should == 52
      end
    end

    describe 'custom' do
      it 'should create a specific deck size' do
        custom_size = 6
        @deck = Deck.new(custom_size)
        @deck.size.should == custom_size * 52
      end
    end
  end

  describe 'operation' do
    describe 'shuffling' do
      pending("can't be tested?")
    end

{'fraction_non_alphanumeric': 0.07975460122699386, 'fraction_numerical': 0.0075507314771118455, 'mean_word_length': 1.5634824667472793, 'pattern_counts': {'":': 0, '<': 9, '<?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': '4091091', 'n_tokens_mistral': 619, 'n_tokens_neox': 586, 'n_words': 203}