Skip to content

Write a functional test suite #56

Open
@cdunklau

Description

@cdunklau

Work will be in PR #55, detailed test planning in this project

I was planning on doing it all in Twisted, but it turns out that twisted.words.service is more of a simple chat bridge (not a full-featured ircd), so it's missing a whole lot of necessary functionality. Rather than writing my own ircd (and certainly getting a lot wrong), I plan on just running it against freenode directly a local docker-based ircd/services rig that emulates freenode. This makes a lot more sense, since that's what infobob targets anyway. The plan:

  1. Target freenode. Don't bother with registered accounts for the time being, just use prefixed nicks for test clients (although eventually that will need to be handled in order to test the flip-to-account-ban behavior). There's no issue with registered accounts, because I can set up the ircd/services however I need.
  2. Write the test suite with Python 3 and the latest Twisted, and run infobob in a child process. This will obviate the need to later port the test suite, and as a bonus give some insight into potential challenges when porting infobob itself. That makes it harder to introspect the running bot, but that's goes against the point of black box testing anyway.
  3. Write a "manager" IRC client that reports test workflow events (suite and test start/end) by sending to the channel.
  4. Write a test client with facilities for event assertions... "i was kicked", "i was muted", "i got a pm", etc.
  5. Maaaaybe write a thing to scrape the web UI? This probably wouldn't need to be sophisticated, even just some terrible HTML regexing (I know, I know) might be workable.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions