diff options
author | louise <louise> | 2009-08-26 16:52:14 +0000 |
---|---|---|
committer | louise <louise> | 2009-08-26 16:52:14 +0000 |
commit | 6ab35a4059158909d2560d2a8b201e2e477d3dcf (patch) | |
tree | 9dbe6c5ee62a1ca3668a9850ced3c1777bc3b94e /perllib/t/Cobrand.t | |
parent | 6cc083845e75d3b9b7967c5764401caab4e77265 (diff) |
Allowing cobrands to serve pages not in the main app
Diffstat (limited to 'perllib/t/Cobrand.t')
-rwxr-xr-x | perllib/t/Cobrand.t | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/perllib/t/Cobrand.t b/perllib/t/Cobrand.t new file mode 100755 index 000000000..36ec9fefa --- /dev/null +++ b/perllib/t/Cobrand.t @@ -0,0 +1,33 @@ +#!/usr/bin/perl -w +# +# Cobrand.t: +# Tests for the cobranding functions +# +# Copyright (c) 2009 UK Citizens Online Democracy. All rights reserved. +# Email: louise@mysociety.org; WWW: http://www.mysociety.org/ +# +# $Id: Cobrand.t,v 1.1 2009-08-26 16:52:14 louise Exp $ +# + +use strict; +use warnings; +use Test::More tests => 2; +use Test::Exception; + +use FindBin; +use lib "$FindBin::Bin"; +use lib "$FindBin::Bin/../perllib"; +use lib "$FindBin::Bin/../../perllib"; + +use Cobrand; +use MockQuery; + +sub test_cobrand_page{ + my $q = new MockQuery('mysite'); + my ($html, $params) = Cobrand::cobrand_page($q); + like($html, qr/A cobrand produced page/, 'cobrand_page returns output from cobrand module'); + return 1; +} + + +ok(test_cobrand_page() == 1, 'Ran all tests for the cobrand_page function'); |