<commit_before>require 'spec_helper'
require 'tic_tac_toe/view/game'

describe TicTacToe::View::Game do

  it 'can find the mustache template' do
    gv = TicTacToe::View::Game.new(TicTacToe::Game.new_game(TicTacToe::Board.empty_board))
    expect(gv.render).to be_a(String).and start_with('<!DOCTYPE html>').and end_with("</html>\n")
  end

end<commit_msg>Add a view test for current_mark<commit_after>require 'spec_helper'
require 'tic_tac_toe/view/game'

describe TicTacToe::View::Game do

  it 'can find the mustache template' do
    gv = TicTacToe::View::Game.new(TicTacToe::Game.new_game(TicTacToe::Board.empty_board))
    expect(gv.render).to be_a(String).and start_with('<!DOCTYPE html>').and end_with("</html>\n")
  end

  it 'returns the correct value for the current mark image' do
    g = TicTacToe::Game.new_game(TicTacToe::Board.empty_board)
    gv = TicTacToe::View::Game.new(g)
    expect(gv.current_mark).to eq("ex")
    g.move(index: 0)
    expect(gv.current_mark).to eq("oh")
  end

end
{'fraction_non_alphanumeric': 0.14626865671641792, 'fraction_numerical': 0.0009950248756218905, 'mean_word_length': 5.248447204968944, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '1346455', 'n_tokens_mistral': 412, 'n_tokens_neox': 399, 'n_words': 72}