File: bayesian_memory_test.rb

package info (click to toggle)
ruby-classifier-reborn 2.2.0-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 1,424 kB
  • sloc: ruby: 2,021; makefile: 7
file content (18 lines) | stat: -rwxr-xr-x 464 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# encoding: utf-8

require File.dirname(__FILE__) + '/../test_helper'
require_relative './bayesian_common_tests'

class BayesianMemoryTest < Minitest::Test
  include BayesianCommonTests

  def setup
    @alternate_backend = ClassifierReborn::BayesMemoryBackend.new
    @classifier = ClassifierReborn::Bayes.new 'Interesting', 'Uninteresting'
    @old_stopwords = Hasher::STOPWORDS['en']
  end

  def teardown
    Hasher::STOPWORDS['en'] = @old_stopwords
  end
end