Skip to content

Self test case 13 fails - star at beginning of pattern #7

@jrwarwick

Description

@jrwarwick

Running python setup.py test results in many tests passed, but test 13 fails with this message:

FAIL: test13_star (test.test_kernel.TestKernel)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/tmp/pyaiml_test/aiml/test/test_kernel.py", line 106, in test13_star
    self._testTag('star test #1', 'You should test star begin', ['Begin star matched: You should'])
  File "/tmp/pyaiml_test/aiml/test/test_kernel.py", line 33, in _testTag
    self.assertIn( response, outputList, msg="input=%s"%input_ )
AssertionError: '' not found in ['Begin star matched: You should'] : input=You should test star begin

After a little tiny bit of fiddling, it looks like somehow the return of self.k.respond is blank. A little further with my limited pdb skills:

...
> /tmp/pyaiml_test/aiml/aiml/Kernel.py(390)respond()
-> response = self._respond(s, sessionID)
(Pdb) p s
'You should test star begin'
(Pdb) n
WARNING: No match found for input: You should test star begin
...

I invoked self._brain.dump() and captured to a file, which I will attempt to attach. I'm not confident in my ability to interpret, but it does look like that rule was added in, but (perhaps) strangely each word is in a separate array element instead of a single string.
braindump.txt

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions