Commit graph

356 commits

Author SHA1 Message Date
Colin Kuskie
052d0ddb15 Os tests covering all possible, valid operating systems. Also has 100% test coverage 2006-10-19 17:49:51 +00:00
Colin Kuskie
b7ff72d27b tests to add 100% coverage to Privilege 2006-10-19 16:49:19 +00:00
Roy Johnson
e4d3e5839f Added 3 new tests to article for the view method, caching of the view method, and the purgeCache method. They aren't quite working right yet though... 2006-10-18 22:42:58 +00:00
Colin Kuskie
eef214ebb6 beginning of Privilege test 2006-10-18 03:32:40 +00:00
Colin Kuskie
276a2aa99d update test to work with getStatusDescription 2006-10-16 16:09:15 +00:00
Colin Kuskie
ca7110249f Extend Session::Http::getStatus so that is will also return the
description when called in list context.
Build tests to verify that behavior, and the default settings
for code and description.
2006-10-15 05:23:32 +00:00
Colin Kuskie
d6a62df50c This test is failing in the smoke-tests, but manual runs by two different
people on different OS'es are passing.  I've added some diagnostic tests
to help us figure out what's going on.
2006-10-15 01:16:57 +00:00
Colin Kuskie
eadb9ada36 Implemented the last few tests to give Session::Style 100% coverage.
There are still a few functional tests that need to be written, they're
codified as TODOs.

In Session/Style.pm, in all methods that have a send immediate option
(when sent=1), they no longer send and cache.  This prevents duplicate
heag tags from being generated if generateAdditionalHeadTags was
ever called twice.
2006-10-12 22:43:33 +00:00
Colin Kuskie
45627b37ed Full test for Output.t using tied variables as filehandles.
Test requires perl 5.8 and up since it uses PerlIO.
Test provides 100% coverage of Session::Output.pm
2006-10-12 17:32:24 +00:00
Colin Kuskie
514c2263fc Added tests to cover userStyle.
fixed a bug in userStyle where it would not process data that was false.
process will do this, so I made userStyle do it as well by adding
in a definedness check on $output.
2006-10-12 04:53:43 +00:00
Colin Kuskie
01a09cbea9 Add tests for printableStyleTemplateId.
Found a fixed an infinite loop in WebGUI::Style::process

If an asset was requested to be printed who does not have a
printableStyleTemplateId then process would recurse back up the
lineage until it does find an asset with a printableStyleTemplateId.
Eventually, if none is found, it will find the Asset Root, whose
parent is itself, and it will loop forever.

I added code to jump out of the loop if it recurses back to the
assetRoot.
2006-10-12 04:06:13 +00:00
Roy Johnson
a085db64df Added new directory in t/ for collateral tests.
fix - article.t false failure on collateral copy.

Added new test to article.t for purge method.
2006-10-11 22:51:44 +00:00
Colin Kuskie
e876e77b18 add a tests to plug a coverage holes in default subroutine arguments 2006-10-11 05:04:44 +00:00
Colin Kuskie
a86c34df84 Added 5 more tests for Style's process method, checking for meta tags
for default processing and for meta tags when cache busting is enabled.

Fixed a bug where the default meta tag Generator did not contain the
WebGUI version.

Added lots of POD to the Style module detailing how meta tags are
handled in various cases.
2006-10-11 04:15:21 +00:00
Colin Kuskie
b1bb5d0b58 Fix broken templateId in Session/Style/process when useEmptyStyle was
requested.  It used to be 6, but at somepoint in the 6.x cycle it
was changed to be PBtmpl0000000000000132 in the database.

Added tests that verify that it works correctly.
2006-10-11 00:32:42 +00:00
Colin Kuskie
6cf1afc6a7 Add more POD to Style.pm to document that sent is set to true after this method
is called.

Add tests to check personalStyleTemplate and sent inside process method.
2006-10-10 23:10:31 +00:00
Colin Kuskie
30a47092be add test for macro processing of genAddHeadTags and for handling of invalid template Id in process for Session::Style 2006-10-06 23:44:21 +00:00
Colin Kuskie
0ad99c3994 mark another TODO test 2006-10-06 05:13:04 +00:00
Colin Kuskie
4f5f5af20b correct number of tests 2006-10-05 14:46:24 +00:00
Colin Kuskie
5920a6d482 10 more tests for methods in Session/Style.pm
Refactored generateAdditionalHeadTags to remove two loops.
2006-10-05 03:40:39 +00:00
Colin Kuskie
b62247735f tests for Style/setLink and generateAdditionalHeadTags 2006-10-04 22:09:01 +00:00
Roy Johnson
518c76c6f1 A new test. It's currently failing but I'm not really sure why. It could be a bug but I think I'm testing this wrong. 2006-10-04 19:04:28 +00:00
Colin Kuskie
ff2344cdad Added comments to the POD in Var.pm that creating a Var object overwrites
the Session Id.  This is by design.

Added a check to Style.pm so that if no params are passed to setLink that
it won't die by trying to deref undef into a hashref.

First set of tests for Session/Style added.
2006-10-03 23:27:08 +00:00
Colin Kuskie
f5aaa2e996 Additional tests to cover WebGUI::Session::Scratch.
Found and fixed a but in Session/Scratch/deleteNameByValue.  It would
not delete any value that was false (0, '' or undef).  Added a defined-ness
check to make sure it will delete 0 or '', but undef is still not handled.
Added POD to say that this was the case.
2006-10-01 21:49:05 +00:00
Colin Kuskie
fc11dd64b2 add tests that check the return value of several methods. Also added tests to increase test coverage 2006-09-30 23:52:58 +00:00
Colin Kuskie
d995ff09fe Fixed a bug with WebGUI::Session::Url::page where, if preventProxyCache
was enabled a noCache param was always added to the URL.  In some
cases it would add 2 noCache params.

To fix this, I added a skipPreventProxyCache param to the gateway method,
and page just passes $pairs and $skipPreventProxyCache to gateway.

Added tests to Url.t to test gateway, page, makeAbsolute and urlize
to bring its coverage up to 100%.

Added tests to Stow.t to bring it's coverage up to 100% as well.
2006-09-30 17:23:44 +00:00
Colin Kuskie
b1a5c46fcb add 6 more tests for page and clean up the POD 2006-09-29 22:51:18 +00:00
Colin Kuskie
2d2b780ed6 More comments and POD for Session/Url.pm.
Tests for escape, unescape, extras methods.  Test code is big enough 
that I've added section delimiting comments.  This has helped make
the code a lot more readable.
2006-09-29 03:32:24 +00:00
Colin Kuskie
8174f9d2b4 More tests for WebGUI::Session::Url::getSiteUrl, which now has 100% test coverage.
Refactored getSiteUrl so it is very obvious as to how it works, replacing
code that was hard to cover.
2006-09-29 02:30:54 +00:00
Colin Kuskie
71b7032545 more Session::Url tests 2006-09-28 23:41:26 +00:00
JT Smith
f8d22359d5 Images now create revisions as you resize them, so you can roll back to a
previous size.
adjusted roy's test because it's not accurate
2006-09-27 21:19:19 +00:00
Roy Johnson
41bd19736c New test for Article Wobject 2006-09-26 18:38:31 +00:00
Colin Kuskie
86a5cb9128 Fix the same problem with form params in getRequestedUrl as in
getRefererUrl and add tests to detect it.
2006-09-25 04:47:05 +00:00
Colin Kuskie
eea7b941c9 A few more tests to kick coverage up to 100 on WebGUI::Session::Setting
Convert it to use placeholders as well.
More WebGUI::Session::Url tests, and some bug fixes:
	getRefererUrl returned parameters and accepted weird methods that
	looked like http but weren't.
2006-09-25 03:49:25 +00:00
Colin Kuskie
00e37ae971 finalized Var test with 100% coverage 2006-09-23 02:49:37 +00:00
Colin Kuskie
56e78708a4 Add a comment to WebGUI::Session::Var::start that if no userSessionId is passed
that a new userSessionId will be created and that the current sessionId (the actual
session object's id) will be set to this new id.
Add several new tests to Session/Var.t  Tried hard to exploit the change in 
sessionId and haven't found a way, yet.
2006-09-22 03:44:34 +00:00
Colin Kuskie
381ce45c1a Add 7 tests to Session/Var.t. Some of them are redundant. That will
be fixed later.
Added lots of comments to start and new subs.  Changed db methods to
use placeholders.  Changed timely data to call time once so that they
all match.
2006-09-21 03:06:04 +00:00
Colin Kuskie
a74df19091 test getIp with and without forwarding 2006-09-15 21:47:08 +00:00
Colin Kuskie
9fb805525c skeleton tests for macros to get them into the coverage report 2006-09-15 21:22:48 +00:00
Colin Kuskie
2f0d7cab57 skeleton tests for macros to get them into the coverage report 2006-09-15 21:16:15 +00:00
Colin Kuskie
65374109b1 Final test for L_loginBox, and coverage improvements for RootTitle.
Pod and documentation fixes for L_loginBox macro.
2006-09-15 21:08:04 +00:00
JT Smith
90cb569bb5 - fix: deleting workflows did not delete related instances and crons
- Added a "run" link to the scheduler and the running workflows listings to
   aid in debugging workflow errors.
 - fix: profile fields not validated by WebGUI::User
2006-09-15 06:08:30 +00:00
Colin Kuskie
a1bf6a2b21 Coverage fixes for date and last modified macros.
Refactor LastModified macro to use placeholders and remove an unused conditional.
2006-09-14 22:22:35 +00:00
Colin Kuskie
a5049f8149 fix bad test coverage 2006-09-14 20:18:12 +00:00
Colin Kuskie
66d98f371c Update some POD in Stow and PageTitle.
Fix several tests with bad coverage.
2006-09-14 15:54:54 +00:00
Colin Kuskie
d3fbe15ca7 fix test cleanup for AdSpace, add leading 0 test to Form::Text 2006-09-12 04:35:35 +00:00
Colin Kuskie
15345a0232 remove module call since it is not used 2006-09-11 16:11:04 +00:00
Colin Kuskie
adb099dcea Add test to make sure Import Node's parent is Asset Root. 2006-09-07 20:12:05 +00:00
Roy Johnson
6b2eeba271 Added test for import node constructor 2006-09-07 18:39:22 +00:00
Colin Kuskie
d95cd9b68d fix a very bad, simple text parser 2006-08-29 21:13:15 +00:00