adric: books icon (c) 2004 adric.net (Default)
Some notes on the cli excerpted from my work on a build doc

Some config snips, scripts, and explanation on how to use RT's cli to create queues, tickets, users, and groups by script so as to make creating the test env easy and repeatable. )

#!/usr/bin/ruby -w

## Example:
## bin/rt create -t queue set name=NewestQ description="a newer still Q than thee"

test_queues = [
{ :qname => 'External', :qdesc => 'External ticket Queue for Rt testenv' },
{ :qname => 'Helpdesk', :qdesc => 'Helpdesk ticket Queue for Rt testenv' },
{ :qname => 'Oversight', :qdesc => 'Oversight ticket Queue for Rt testenv' },
]

test_queues.each { |tq|
`bin/rt create -t queue set name=\"#{tq[:qname]}\" description=\"#{tq[:qdesc]}\"`
}


and we should easily be able to do the same for some sample users, groups. Unfortunately we can't add scrips or templates this way, yet.


2 http://www.gossamer-threads.com/lists/rt/users/61505?do=post_view_threaded
adric: books icon (c) 2004 adric.net (Default)
So, I'm a few baby steps closer to having a test environment for the work I'm doing with RT (the awesome Request Tracker software from Jesse and his bunch of misfit geniuses over at bestpractical.com) I'm not hacking on the code of RT directly, so my testing requirements aren't much aligned with those of the core developers or extension authors (who do make excellent use of the amazing variety of Perl testing frameworks and modules), so I been futzing around at it educationally and I thought it was time to share.

Exposition, explanations )

Here's what I have going so far for this:

  • mime_lite.pl : tiny Perl script using MIME:Lite from CPAN to generate full emails as text files

  • a development install of RT 3.8.6 on my workstation, configured with : ./configure --with-my-user-group --enable-layout=inplace --with-db-type=SQLite --with-devel-mode

  • which configuration1 simplifies a lot of things and enables more debug information

  • run with RT's standalone_httpd on a local high port

  • configured to send mail to /bin/cat >> mail.out instead of sendmail

  • injecting mail into RT just like a live system would, eg rt-mailgate -queue General --url http://127.0.0.1:8888 < nursemail.txt

  • using tail to watch the logs as I poke things


  • Although I've been testing and breaking software my whole life I am still quite new to the craft of software testing and the concepts behind professional QA. In particular there is no innovation (yet) in what I am doing, but the tools of Unix are proving quite helpful and I'm happy with my progress so far.

    1: That configuration script is not from the excellent but dated book RT Essentials, or the wiki, but from some of Jesse's slides from a boot camp that turned up in Google's cache.

    Profile

    adric: books icon (c) 2004 adric.net (Default)
    adric

    June 2025

    S M T W T F S
    1234567
    891011121314
    15161718192021
    22232425262728
    2930     

    Links

    Syndicate

    RSS Atom

    Most Popular Tags

    Style Credit

    Expand Cut Tags

    No cut tags
    Page generated 5 July 2025 03:51 pm
    Powered by Dreamwidth Studios