This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# frozen_string_literal: true | |
require 'uri' | |
require 'net/http' | |
require 'nokogiri' | |
# class GetSchedule, get on date schedule | |
class GetSchedule | |
HOLAMUNDO_URL = 'https://holamundo.day/' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# frozen_string_literal: false | |
gem 'minitest', '~> 5.4' | |
require 'minitest/autorun' | |
require 'minitest/pride' | |
require_relative './test0n3' | |
# class for testing | |
class HangmanTest < Minitest::Test | |
EXAMPLE_WORD = 'television' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# frozen_string_literal: false | |
# class for game Hangman | |
class Hangman | |
def initialize(original_word) | |
@original_word = original_word | |
@game_initial_data = game_preparation | |
@game_word = @game_initial_data[:game_word] | |
@missing_chars = @game_initial_data[:missing_chars] | |
@attempts = set_attempts |