Compare commits

..

75 Commits

Author SHA1 Message Date
(no author)
7665fa8325 This commit was manufactured by cvs2svn to create tag 'commit'.
git-svn-id: svn://10.0.0.236/tags/commit@177985 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 19:53:03 +00:00
(no author)
e3556ede22 This commit was manufactured by cvs2svn to create branch
'FIREFOX_1_5b1_MINIBRANCH'.

git-svn-id: svn://10.0.0.236/branches/FIREFOX_1_5b1_MINIBRANCH@177984 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 19:53:02 +00:00
bsmedberg%covad.net
bfa01a746d From bug 304476 - version.txt entries need mozilla/ in front
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177983 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 19:53:01 +00:00
aaronleventhal%moonset.net
d9d36fadeb Bug 304488. Accesibility issues with frames and iframes. r=timeless, sr=dmose, a=cbeard
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177980 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 19:07:52 +00:00
cmp%mozilla.org
d5c5d13cb6 Swap sl and sk to ensure they are built in the correct order by the build
systems.  Bug 304992, attachment 192973.  r+a=chase@mozilla.org


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177979 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 18:38:25 +00:00
smfr%smfr.org
10a9a7be6b Fix bug 259903: allow the user to show file extensions when saving web pages, and correctly fix up the file extension when they swap formats.
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177977 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 18:33:50 +00:00
bzbarsky%mit.edu
67308f41f3 Make sure to set base tag info on the leaf forms we create when HTML is
misnested. Bug 73818, r=mrbkap, sr=jst, a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177975 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 18:22:50 +00:00
bryner%brianryner.com
b656f7998b Don't duplicate entries in MOZCONFIG_MODULES (bug 304504). r+a=bsmedberg.
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177971 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 18:09:56 +00:00
bsmedberg%covad.net
5a0b4fc01e Part of bug 299992 - intl makefiles are defining __STDC__ for no good reason, r=jshin+cls a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177969 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 17:51:38 +00:00
scott%scott-macgregor.org
4b48602c14 Bug #304898 --> View Certificates, Manage CRLs and Device Manager dialog should be resizable window
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177968 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 17:50:31 +00:00
aaronleventhal%moonset.net
1b076301c4 Bug 304484. Expose alerts, prompts and message boxes as ROLE_ALERT so screen readers have a cue to speak the entire dialog when it appears. r=mconnor, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177965 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 17:24:38 +00:00
aaronleventhal%moonset.net
752c0788be Bug 304871. Hitting enter with screen reader active will not open new window links. r=timeless, sr=jst, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177963 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 17:22:55 +00:00
aaronleventhal%moonset.net
49ba9d91a8 Bug 303404. Crash when hitting escape in context menu for a menu item. r=dbaron, sr=neil, a=cbeard
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177961 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 17:18:25 +00:00
bsmedberg%covad.net
b43a21ee0d Bug 304476 and 304478 - remove app.extensions.version from default prefs - r=chase a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177960 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 17:17:17 +00:00
bienvenu%nventure.com
405489c150 fix 303948, rebuild group sort by date when date changes, sr=mscott a= asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177959 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 17:03:44 +00:00
jst%mozilla.jstenback.com
569f47cfda Fixing bug 301476. Make XPCNativeWrapper's checkAccess hook always forward to the wrapper's checkAccess hook, if it's got one. r=shaver@mozilla.org, sr=brendan@mozilla.org, a=asa@mozilla.org
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177955 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 16:51:01 +00:00
bsmedberg%covad.net
2294affeb4 Bug 302136 - Two clicks on "Install Now" button are necessary to install an extension - r+a=beng
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177953 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 16:40:43 +00:00
gavin%gavinsharp.com
c530b44444 Bug 303644 : Remove livemark autodiscovery's handrolled wrapper, patch by Phil Ringnalda <bugzilla@philringnalda.com>, r=vlad, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177952 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 16:37:42 +00:00
cbiesinger%web.de
17c0db36bf bug 301004 make native gtk2 filepicker modal to its parent
patch by Christian Persch <chpe@gnome.org> r=caillon sr=roc a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177945 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 13:42:42 +00:00
cbiesinger%web.de
2d76924659 bug 277587 nsSecureBrowserUIImpl's nsUIContext interface requestor doesn't give
access to the dom window
patch by Christian Persch <chpe@gnome.org> r=jgmyers sr=roc a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177944 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 13:39:30 +00:00
axel%pike.org
3e3e48fba4 adding mk to thunderbird 1.5, l10n only, per request of damjan
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177942 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 11:46:03 +00:00
timeless%mozdev.org
050a74b34b Bug 299825 Search plugins in App directory are updated into Profile directory (resulting in double Search Bar entries)
patch by torisugari@gmail.com r=timeless sr=neil a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177938 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 09:26:09 +00:00
timeless%mozdev.org
ffdbfd0beb Bug 304237 Enable xpcom under windows debuggers to filter assertions the way it does without a debugger
to enable this feature, set XPCOM_DEBUG_DLG=1, or if you're already in the debugger, just poke the static to 2.
r=dougt a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177933 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 07:49:30 +00:00
jshin%mailaps.org
b44c107d84 bug 304277: add further TLDs to IDN whitelist : patch by gerv, rs=jshin, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177923 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-17 01:31:00 +00:00
jwalden%mit.edu
227b358e20 Bug 299976 - Remove identical items from glossary/index datasources and make them platform-specific. p=steffen, r=me, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177909 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 22:40:16 +00:00
cbiesinger%web.de
198e275f18 bug 283606 make nsOSHelperAppService::GetApplicationDescription get
a friendly description
r=darin sr=bz a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177902 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 22:01:35 +00:00
cbiesinger%web.de
b711722a0e bug 297388 make nsIWebBrowserStream implement ReadSegments correctly (by
just forwarding to the underlying pipe)
r=caillon sr=darin a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177899 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 21:53:18 +00:00
mrbkap%gmail.com
634e4913d2 bug 289933: functions, RegExps, and Script objects should all be of type "function" for compatibility with older SpiderMonkeys and to more closely imitate ECMA. r+a=brendan
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177897 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 21:43:54 +00:00
roc+%cs.cmu.edu
3ccd8d696b Bug 303484. Limit the nesting of modal event loops so we avoid overflowing the C++ stack. r+sr=brendan,a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177889 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 21:03:12 +00:00
jst%mozilla.jstenback.com
0c1074dda7 Fixing frame crasher from bug 296639. Wrap frames in the scope of the frame's outer window. r=mrbkap@gmail.com, sr=shaver@mozilla.org, a=asa@mozilla.org
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177883 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 20:17:57 +00:00
myk%mozilla.org
2de5835b34 Bug 304362: makes feedview parse W3C-DTF dates correctly; also, fixes several regressions from the checkin for bug 303848, specifically: uncomments call to Feed.init() so feeds get initialized (and dates show up and refresh works); calls the refresh function appropriately so refresh works; disables refresh by default; adds back menu display and refresh prefs; makes refresh pref refer to minutes rather than seconds; and looks for prefs in DOM by correct name (all lowercase, since XSLT forces them to that) so the menu shows up and refresh works. r=mconnor, sr=beng, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177877 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 19:47:06 +00:00
aaronleventhal%moonset.net
68e7466914 Bug 258285. Findbar coming up when it shouldn't (textareas/textfields). r=mats, sr=bryner, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177875 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 19:33:48 +00:00
smfr%smfr.org
dfff2b57ba Fix bug 295737: use Core Graphics to do image tiling, because it's much faster than doing it ourselves. r=jhpedemonte, sr=bryner, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177859 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 18:10:18 +00:00
mrbkap%gmail.com
941e888ae2 bug 303267: Back/forward with bfcache on break javascript. We now store the entire inner window in the cache instead of just random properties from it. r=bryner sr=jst a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177856 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 17:59:44 +00:00
aaronleventhal%moonset.net
4a5d8941ec Backing out. Doh! I have approval but I only wanted to check this into the trunk at first, for testing.
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177854 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 17:52:43 +00:00
scott%scott-macgregor.org
22f98faaad Bug #303786 --> "Delete Message" filter action missing for IMAP and Newsgroups
sr=bienvenu
a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177852 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 17:42:07 +00:00
scott%scott-macgregor.org
aca80bdc15 Bug #304466 --> SSL Icon for IMAP Accounts no longer shows up
sr=bienvenu
a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177851 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 17:39:36 +00:00
aaronleventhal%moonset.net
c595157e1c Bug 258285. Find As You Type coming up when it shouldn't (textareas/textfields). r=mats, sr=bryner
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177850 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 17:36:46 +00:00
timeless%mozdev.org
a1fac68280 Bug 303654 InstallTrigger.install(null) crashes [@ JS_Enumerate]
patch by shutdown@flashmail.com r=dveditz sr=dveditz a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177848 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 16:32:53 +00:00
mozilla.mano%sent.com
c444e0172b Bug 304748 - 'Bookmark This Tab' command doesn't work if the context element is the tabbar itself. r=mconnor, a=asa.
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177841 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 14:28:31 +00:00
mozilla.mano%sent.com
e7fe612941 Bug 299239 - BiDi: Caret is stuck when reaching a single LTR character in RTL text. patch from Eyal Rozenberg <eyalroz@technion.ac.il>, r+sr=roc, a=asa.
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177839 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 14:22:51 +00:00
bzbarsky%mit.edu
f9db98fa3d Use a valid MIME type for the "display" stuff in mailnews. Bug 303336, r=bienvenu,
sr=mscott, a=asa.


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177838 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 14:20:17 +00:00
gavin%gavinsharp.com
a03c8b171a Bug 243324: Download manager fails to close with files that download very quickly (small files / cached files), patch by Ben Basson <cusser.bugs@cusser.net>, r=mconnor, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177832 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 12:10:38 +00:00
bugzilla%arlen.demon.co.uk
c5314a600c Bug 304137 Junk/scam header pane remains after selection of an empty folder (i.e. no message selection)
p=me r=neil.parkwaycc.co.uk sr=bienvenu a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177830 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 12:00:25 +00:00
neil%parkwaycc.co.uk
f73483ce99 Ability to navigate the search folderpicker when closed b=302120 sr=mscott a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177827 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 08:18:12 +00:00
neil%parkwaycc.co.uk
c550c37397 Bug 304053 Don't draw canvas focus on editor/midas frames r+sr=roc a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177825 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 08:14:06 +00:00
neil%parkwaycc.co.uk
2017890d24 Fix typo (Enter key is VK_RETURN, not VK_ENTER ?!) b=304500 sr=bienvenu a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177823 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 08:08:17 +00:00
gavin%gavinsharp.com
dd1e3c2efd Bug 304469 : Add -new-tab option to auto-remote, r=benjamin, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177813 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 05:18:43 +00:00
smfr%smfr.org
cccdbcb886 Fix bug 304565: bookmark descriptions all getting the same value. Make sure we make a copy of [NSTextView string] before setting the bookmark description, and clean up other minor NSString usage.
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177812 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 04:51:10 +00:00
myk%mozilla.org
217d024ced Bug 304734: update Mozilla Store bookmark to point to store.mozilla.org; r=mconnor, a=cbeard
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177802 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 01:17:28 +00:00
relyea%netscape.com
af70ef05e8 Bug 225034 Certificate Manager Crashes Mozilla [@ nsCertTree::CmpByCrit]
sr=brendan r=wtc a=dbaron
The issue is the use of the PL_DHash* functions. It's possible that a given call to PL_DHashOperate which adds a new entry may cause the hash table to expand, and all the existing entries to be reallocated. PL_DHash does this by allocating new memory, then copying the entries. getCacheEntry() returns one of these hash entries. CmpBy() makes two consecutive calls to getCacheEntry, then uses the returned entries for it's comparisons. If the second entry call causes a new entry to be added to the table, and causes the hash table to expand, the pointer to the first entry we retrieved will point to freed memory. The fix is to make the usable entry a pointer in the hashtable entry, and return that pointer. When the hashtable rebuilds it's entries, the pointer will be copied to the new entry and not be disturbed.


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177796 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-16 00:23:42 +00:00
scott%scott-macgregor.org
a40c90f749 Bug #269483 --> the check for updates menu item needs to be iconic so we the animated throbber shows
up when downloading an update.


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177779 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 21:16:00 +00:00
scott%scott-macgregor.org
f004b39561 Porting the changes for Bug #302269 to Thunderbird. Fixes some Thunderbird padding issues with the software update wizard.
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177778 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 21:07:23 +00:00
scott%scott-macgregor.org
86781c7a2f Bug #269483 --> remove some obsolete auto update UI
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177777 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 20:59:07 +00:00
mozilla.mano%sent.com
3492c1517e bug 304436 - [mac] RSS button is displayed empty. patch from Kevin Gerich (on bug 303848). a=asa.
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177773 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 19:08:11 +00:00
doronr%us.ibm.com
feb4a7d3ee Bug 303058 - Missing plugin bar no longer appears. r/a=mconnor
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177757 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 17:31:22 +00:00
aaronleventhal%moonset.net
1accd323b1 Bug 304457. Can't tab out of location bar (regression). r=mconnor, a=dbaron
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177743 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 03:04:34 +00:00
bzbarsky%mit.edu
2d7f2d7ca1 Removing unused code. Bug 303102, r+sr=jst, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177742 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 02:50:31 +00:00
bzbarsky%mit.edu
6faa2cc5f3 Don't leak radio visitors through shutdown. Bug 302706, r+sr=jst, a=asa.
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177740 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 02:46:46 +00:00
bzbarsky%mit.edu
e55bd192e6 Make the one-arg version of scrollIntoView scriptable in IDL. Bug 296965,
r+sr=jst, a=asa.


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177737 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 02:37:48 +00:00
bzbarsky%mit.edu
0cc47592c8 Make table.rows["rowid"] work like it should. Bug 295561, r+sr=jst, a=asa
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177735 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-15 02:35:42 +00:00
steffen.wilberg%web.de
c0400f0495 Bug 222654: global/scrollbars.css for native scrollbars different on Mac (many Firefox themes break scrollbars on Mac). Use nativescrollbars.css and xulscrollbars.css and ship both files on all platforms. r=neil, kevin, sr=bz, a=bsmedberg
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177731 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-14 16:28:42 +00:00
gavin%gavinsharp.com
99aca96354 Bug 304233: fix "preference has no properties" error in advanced JS Options, patch by Ronny Perinke <ronny.perinke@gmx.de>, r+a=mconnor
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177723 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 22:54:24 +00:00
gavin%gavinsharp.com
6dac3d3e80 Bug 303743: fix typo in richlistbox.xml, patch by Adam Guthrie <ispiked@gmail.com>, r+a=mconnor
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177721 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 22:37:52 +00:00
dbaron%dbaron.org
0ef723541e Make nsIChannel implementations follow the rules that prevent them from leaking due to cycles with their notification callbacks. b=303043 r=biesi sr=darin a=cbeard
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177716 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 19:34:01 +00:00
mnyromyr%tprac.de
85cb92260e Bug 299581: Mac application menu still named Mozilla; r=pinkerton, sr=sfraser, a=cbeard
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177715 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 19:33:25 +00:00
dbaron%dbaron.org
0458974e37 Add tools/update-packaging to all pull. b=304377 r=chase a=chase
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177714 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 19:32:16 +00:00
gavin%gavinsharp.com
082ba176b6 Bug 304418 : Fix a couple of regressions from the checkin for bug 284868, r+a=mconnor
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177708 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 17:41:28 +00:00
bugzilla%arlen.demon.co.uk
d375b2fd63 Bug 301737 Support multiple selection for xul:listbox - Revised xpfe version of patch v2.1
p=me r=cbiesinger sr=neil.parkwaycc.co.uk a=asa


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177698 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 13:42:03 +00:00
cbiesinger%web.de
0abc04d831 Bug 297238 incorrect parameter specification for signal open-uri of gtkembedmoz
patch by chpe@gnome.org r=mpgritti sr=roc


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177694 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 12:11:23 +00:00
cbiesinger%web.de
996effeff6 bug 97580 back out the original patch for this bug, since it's not necessary
anymore and breaks plugins
patch by chpe@gnome.org r=blizzard sr=roc a=cbeard


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177693 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 12:00:34 +00:00
cbiesinger%web.de
c98e01adcb bug 292998
- move textZoom storage to the prescontext from the documentviewer
- copy the textZoom between document viewers for fastback
r=bryner sr=dbaron a=cbeard


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177691 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 11:55:32 +00:00
cbiesinger%web.de
463d2d8489 bug 250375 allow necko consumers to append to the Cookie header
r+sr=darin a=cbeard


git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177689 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-13 11:51:55 +00:00
cltbld
bd3cab6a8e Update client.mk to pull from the MOZILLA_1_8_BRANCH tag. (chase)
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177657 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-12 20:32:24 +00:00
(no author)
f7df88887e This commit was manufactured by cvs2svn to create branch
'MOZILLA_1_8_BRANCH'.

git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@177651 18797224-902f-48f8-a5cc-f745e15eee43
2005-08-12 19:01:32 +00:00
894 changed files with 816 additions and 118185 deletions

816
mozilla/client.mk Normal file
View File

@@ -0,0 +1,816 @@
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corporation.
# Portions created by the Initial Developer are Copyright (C) 1998
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
# Stephen Lamm
# Benjamin Smedberg <bsmedberg@covad.net>
# Chase Phillips <chase@mozilla.org>
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
# Build a mozilla application.
#
# To checkout and build a tree,
# 1. cvs co mozilla/client.mk
# 2. cd mozilla
# 3. create your .mozconfig file with
# mk_add_options MOZ_CO_PROJECT=suite,browser,mail,minimo,xulrunner
# 4. gmake -f client.mk
#
# This script will pick up the CVSROOT from the CVS/Root file. If you wish
# to use a different CVSROOT, you must set CVSROOT in your environment:
#
# export CVSROOT=:pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot
# export CVSROOT=:pserver:username%somedomain.org@cvs.mozilla.org:/cvsroot
#
# You must specify which products/modules you wish to checkout, with
# MOZ_CO_PROJECT, MOZ_CO_MODULE, and BUILD_MODULES variables.
#
# MOZ_CO_PROJECT possibilities include the following:
# suite (Seamonkey suite)
# browser (aka Firefox)
# mail (aka Thunderbird)
# minimo (small browser for devices)
# composer (standalone composer, aka NVU)
# calendar (aka Sunbird, use this to build the calendar extensions also)
# xulrunner
# macbrowser (aka Camino)
#
# Other common MOZ_CO_MODULE options include the following:
# mozilla/other-licenses/libart_lgpl
# mozilla/other-licenses/bsdiff
# mozilla/tools/codesighs
#
# Other targets (gmake -f client.mk [targets...]),
# checkout
# build
# clean (realclean is now the same as clean)
# distclean
#
# See http://www.mozilla.org/build/ for more information.
#
# Options:
# MOZ_OBJDIR - Destination object directory
# MOZ_CO_DATE - Date tag to use for checkout (default: none)
# MOZ_CO_MODULE - Module to checkout
# MOZ_CVS_FLAGS - Flags to pass cvs (default: -q -z3)
# MOZ_CO_FLAGS - Flags to pass after 'cvs co' (default: -P)
# MOZ_MAKE_FLAGS - Flags to pass to $(MAKE)
# MOZ_CO_LOCALES - localizations to pull (MOZ_CO_LOCALES="de-DE,pt-BR")
# MOZ_LOCALE_DIRS - directories which contain localizations
# LOCALES_CVSROOT - CVSROOT to use to pull localizations
#
AVAILABLE_PROJECTS = \
all \
suite \
toolkit \
browser \
mail \
minimo \
composer \
calendar \
xulrunner \
macbrowser \
$(NULL)
MODULES_core := \
SeaMonkeyAll \
mozilla/browser/config/version.txt \
mozilla/mail/config/version.txt \
mozilla/ipc/ipcd \
mozilla/modules/libpr0n \
mozilla/modules/libmar \
mozilla/modules/libbz2 \
mozilla/accessible \
mozilla/security/manager \
mozilla/toolkit \
mozilla/storage \
mozilla/db/sqlite3 \
$(NULL)
LOCALES_core := \
netwerk \
dom \
$(NULL)
MODULES_toolkit := \
$(MODULES_core) \
mozilla/chrome \
$(NULL)
LOCALES_toolkit := \
$(LOCALES_core) \
toolkit \
security/manager \
$(NULL)
MODULES_suite := \
$(MODULES_core) \
mozilla/suite \
$(NULL)
LOCALES_suite := \
$(LOCALES_core) \
$(NULL)
MODULES_browser := \
$(MODULES_toolkit) \
mozilla/browser \
mozilla/other-licenses/branding/firefox \
mozilla/other-licenses/7zstub/firefox \
$(NULL)
LOCALES_browser := \
$(LOCALES_toolkit) \
browser \
other-licenses/branding/firefox \
$(NULL)
BOOTSTRAP_browser := mozilla/browser/config/mozconfig
MODULES_minimo := \
$(MODULES_toolkit) \
mozilla/minimo \
$(NULL)
MODULES_mail := \
$(MODULES_toolkit) \
mozilla/mail \
mozilla/other-licenses/branding/thunderbird \
mozilla/other-licenses/7zstub/thunderbird \
$(NULL)
LOCALES_mail := \
$(LOCALES_toolkit) \
mail \
other-licenses/branding/thunderbird \
editor/ui \
$(NULL)
BOOTSTRAP_mail := mozilla/mail/config/mozconfig
MODULES_composer := \
$(MODULES_toolkit) \
mozilla/composer \
$(NULL)
MODULES_calendar := \
$(MODULES_toolkit) \
mozilla/storage \
mozilla/db/sqlite3 \
mozilla/calendar \
$(NULL)
BOOTSTRAP_calendar := mozilla/calendar/sunbird/config/mozconfig
MODULES_xulrunner := \
$(MODULES_toolkit) \
mozilla/xulrunner \
$(NULL)
LOCALES_xulrunner := \
$(LOCALES_toolkit) \
$(NULL)
BOOTSTRAP_xulrunner := mozilla/xulrunner/config/mozconfig
MODULES_macbrowser := \
$(MODULES_core) \
mozilla/camino \
$(NULL)
BOOTSTRAP_macbrowser := mozilla/camino/config/mozconfig
MODULES_all := \
mozilla/other-licenses/bsdiff \
mozilla/other-licenses/libart_lgpl \
mozilla/tools/trace-malloc \
mozilla/tools/jprof \
mozilla/tools/codesighs \
mozilla/tools/update-packaging \
mozilla/other-licenses/branding \
mozilla/other-licenses/7zstub \
$(NULL)
#######################################################################
# Checkout Tags
#
# For branches, uncomment the MOZ_CO_TAG line with the proper tag,
# and commit this file on that tag.
MOZ_CO_TAG = MOZILLA_1_8_BRANCH
NSPR_CO_TAG = MOZILLA_1_8_BRANCH
NSS_CO_TAG = MOZILLA_1_8_BRANCH
LDAPCSDK_CO_TAG = MOZILLA_1_8_BRANCH
LOCALES_CO_TAG = MOZILLA_1_8_BRANCH
BUILD_MODULES = all
#######################################################################
# Defines
#
CVS = cvs
comma := ,
CWD := $(shell pwd)
ifeq "$(CWD)" "/"
CWD := /.
endif
ifneq (, $(wildcard client.mk))
# Ran from mozilla directory
ROOTDIR := $(shell dirname $(CWD))
TOPSRCDIR := $(CWD)
else
# Ran from mozilla/.. directory (?)
ROOTDIR := $(CWD)
TOPSRCDIR := $(CWD)/mozilla
endif
# on os2, TOPSRCDIR may have two forward slashes in a row, which doesn't
# work; replace first instance with one forward slash
TOPSRCDIR := $(shell echo "$(TOPSRCDIR)" | sed -e 's%//%/%')
ifndef TOPSRCDIR_MOZ
TOPSRCDIR_MOZ=$(TOPSRCDIR)
endif
# if ROOTDIR equals only drive letter (i.e. "C:"), set to "/"
DIRNAME := $(shell echo "$(ROOTDIR)" | sed -e 's/^.://')
ifeq ($(DIRNAME),)
ROOTDIR := /.
endif
AUTOCONF := autoconf
MKDIR := mkdir
SH := /bin/sh
ifndef MAKE
MAKE := gmake
endif
CONFIG_GUESS_SCRIPT := $(wildcard $(TOPSRCDIR)/build/autoconf/config.guess)
ifdef CONFIG_GUESS_SCRIPT
CONFIG_GUESS = $(shell $(CONFIG_GUESS_SCRIPT))
else
_IS_FIRST_CHECKOUT := 1
endif
####################################
# CVS
# Add the CVS root to CVS_FLAGS if needed
CVS_ROOT_IN_TREE := $(shell cat $(TOPSRCDIR)/CVS/Root 2>/dev/null)
ifneq ($(CVS_ROOT_IN_TREE),)
ifneq ($(CVS_ROOT_IN_TREE),$(CVSROOT))
CVS_FLAGS := -d $(CVS_ROOT_IN_TREE)
endif
endif
CVS_CO_DATE_FLAGS = $(if $(MOZ_CO_DATE),-D "$(MOZ_CO_DATE)")
CVSCO = $(CVS) $(CVS_FLAGS) co $(MOZ_CO_FLAGS) $(if $(MOZ_CO_TAG),-r $(MOZ_CO_TAG)) $(CVS_CO_DATE_FLAGS)
CVSCO_LOGFILE := $(ROOTDIR)/cvsco.log
CVSCO_LOGFILE := $(shell echo $(CVSCO_LOGFILE) | sed s%//%/%)
# if LOCALES_CVSROOT is not specified, set it here
# (and let mozconfig override it)
LOCALES_CVSROOT ?= :pserver:anonymous@cvs-mirror.mozilla.org:/l10n
####################################
# Load mozconfig Options
# See build pages, http://www.mozilla.org/build/ for how to set up mozconfig.
MOZCONFIG_LOADER := mozilla/build/autoconf/mozconfig2client-mk
MOZCONFIG_FINDER := mozilla/build/autoconf/mozconfig-find
MOZCONFIG_MODULES := mozilla/build/unix/modules.mk mozilla/build/unix/uniq.pl
run_for_side_effects := \
$(shell cd $(ROOTDIR); \
if test "$(_IS_FIRST_CHECKOUT)"; then \
$(CVSCO) $(MOZCONFIG_FINDER) $(MOZCONFIG_LOADER) $(MOZCONFIG_MODULES); \
else true; \
fi; \
$(MOZCONFIG_LOADER) $(TOPSRCDIR) mozilla/.mozconfig.mk > mozilla/.mozconfig.out)
include $(TOPSRCDIR)/.mozconfig.mk
include $(TOPSRCDIR)/build/unix/modules.mk
####################################
# Options that may come from mozconfig
MOZ_PROJECT_LIST := $(subst $(comma), ,$(MOZ_CO_PROJECT))
ifneq (,$(filter-out $(AVAILABLE_PROJECTS),$(MOZ_PROJECT_LIST)))
$(error MOZ_CO_PROJECT contains an unrecognized project.)
endif
ifeq (all,$(filter all,$(MOZ_PROJECT_LIST)))
MOZ_PROJECT_LIST := $(AVAILABLE_PROJECTS)
endif
MOZ_MODULE_LIST := $(subst $(comma), ,$(MOZ_CO_MODULE)) $(foreach project,$(MOZ_PROJECT_LIST),$(MODULES_$(project)))
LOCALE_DIRS := $(MOZ_LOCALE_DIRS) $(foreach project,$(MOZ_PROJECT_LIST),$(LOCALES_$(project)))
MOZCONFIG_MODULES += $(foreach project,$(MOZ_PROJECT_LIST),$(BOOTSTRAP_$(project)))
# Using $(sort) here because it also removes duplicate entries.
MOZ_MODULE_LIST := $(sort $(MOZ_MODULE_LIST))
LOCALE_DIRS := $(sort $(LOCALE_DIRS))
MOZCONFIG_MODULES := $(sort $(MOZCONFIG_MODULES))
# Change CVS flags if anonymous root is requested
ifdef MOZ_CO_USE_MIRROR
CVS_FLAGS := -d :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot
endif
# MOZ_CVS_FLAGS - Basic CVS flags
ifeq "$(origin MOZ_CVS_FLAGS)" "undefined"
CVS_FLAGS := $(CVS_FLAGS) -q -z 3
else
CVS_FLAGS := $(MOZ_CVS_FLAGS)
endif
ifdef MOZ_OBJDIR
OBJDIR := $(MOZ_OBJDIR)
MOZ_MAKE := $(MAKE) $(MOZ_MAKE_FLAGS) -C $(OBJDIR)
else
OBJDIR := $(TOPSRCDIR)
MOZ_MAKE := $(MAKE) $(MOZ_MAKE_FLAGS)
endif
####################################
# CVS defines for NSS
#
NSS_CO_MODULE = \
mozilla/security/nss \
mozilla/security/coreconf \
$(NULL)
NSS_CO_FLAGS := -P
ifdef MOZ_CO_FLAGS
NSS_CO_FLAGS := $(MOZ_CO_FLAGS)
endif
NSS_CO_FLAGS := $(NSS_CO_FLAGS) $(if $(NSS_CO_TAG),-r $(NSS_CO_TAG),-A)
# Cannot pull static tags by date
ifeq ($(NSS_CO_TAG),NSS_CLIENT_TAG)
CVSCO_NSS = $(CVS) $(CVS_FLAGS) co $(NSS_CO_FLAGS) $(NSS_CO_MODULE)
else
CVSCO_NSS = $(CVS) $(CVS_FLAGS) co $(NSS_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(NSS_CO_MODULE)
endif
####################################
# CVS defines for NSPR
#
NSPR_CO_MODULE = mozilla/nsprpub
NSPR_CO_FLAGS := -P
ifdef MOZ_CO_FLAGS
NSPR_CO_FLAGS := $(MOZ_CO_FLAGS)
endif
NSPR_CO_FLAGS := $(NSPR_CO_FLAGS) $(if $(NSPR_CO_TAG),-r $(NSPR_CO_TAG),-A)
# Cannot pull static tags by date
ifeq ($(NSPR_CO_TAG),NSPRPUB_CLIENT_TAG)
CVSCO_NSPR = $(CVS) $(CVS_FLAGS) co $(NSPR_CO_FLAGS) $(NSPR_CO_MODULE)
else
CVSCO_NSPR = $(CVS) $(CVS_FLAGS) co $(NSPR_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(NSPR_CO_MODULE)
endif
####################################
# CVS defines for the C LDAP SDK
#
LDAPCSDK_CO_MODULE = mozilla/directory/c-sdk
LDAPCSDK_CO_FLAGS := -P
ifdef MOZ_CO_FLAGS
LDAPCSDK_CO_FLAGS := $(MOZ_CO_FLAGS)
endif
LDAPCSDK_CO_FLAGS := $(LDAPCSDK_CO_FLAGS) $(if $(LDAPCSDK_CO_TAG),-r $(LDAPCSDK_CO_TAG),-A)
CVSCO_LDAPCSDK = $(CVS) $(CVS_FLAGS) co $(LDAPCSDK_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(LDAPCSDK_CO_MODULE)
####################################
# CVS defines for standalone modules
#
ifeq ($(BUILD_MODULES),all)
CHECKOUT_STANDALONE := true
CHECKOUT_STANDALONE_NOSUBDIRS := true
else
STANDALONE_CO_MODULE := $(filter-out $(NSPRPUB_DIR) security directory/c-sdk, $(BUILD_MODULE_CVS))
STANDALONE_CO_MODULE += allmakefiles.sh client.mk aclocal.m4 configure configure.in
STANDALONE_CO_MODULE += Makefile.in
MOZ_MODULE_LIST += $(addprefix mozilla/,$(STANDALONE_CO_MODULE))
NOSUBDIRS_MODULE := $(addprefix mozilla/,$(BUILD_MODULE_CVS_NS))
ifeq (,$(filter $(NSPRPUB_DIR), $(BUILD_MODULE_CVS))$(MOZ_CO_PROJECT))
CVSCO_NSPR :=
endif
ifeq (,$(filter security security/manager, $(BUILD_MODULE_CVS))$(MOZ_CO_PROJECT))
CVSCO_NSS :=
endif
ifeq (,$(filter directory/c-sdk, $(BUILD_MODULE_CVS))$(MOZ_CO_PROJECT))
CVSCO_LDAPCSDK :=
endif
endif
####################################
# Error on obsolete variables.
#
ifdef MOZ_MAPINFO
$(warning MOZ_MAPINFO is obsolete, use MOZ_CO_MODULE=mozilla/tools/codesighs instead.)
MOZ_MODULE_LIST += mozilla/tools/codesighs
endif
ifdef MOZ_INTERNAL_LIBART_LGPL
$(error MOZ_INTERNAL_LIBART_LGPL is obsolete, use MOZ_CO_MODULE=mozilla/other-licenses/libart_lgpl instead.)
endif
ifdef MOZ_PHOENIX
$(warning MOZ_PHOENIX is obsolete.)
MOZ_MODULE_LIST += $(MODULES_browser)
# $(error MOZ_PHOENIX is obsolete, use MOZ_CO_PROJECT=browser and --enable-application=browser)
endif
ifdef MOZ_THUNDERBIRD
$(warning MOZ_THUNDERBIRD is obsolete.)
MOZ_MODULE_LIST += $(MODULES_mail)
# $(error MOZ_THUNDERBIRD is obsolete, use MOZ_CO_PROJECT=mail and --enable-application=mail)
endif
###################################
# Checkout main modules
#
# sort is used to remove duplicates. SeaMonkeyAll is special-cased to
# checkout last, because if you check it out first, there is a sticky
# tag left over from checking out the LDAP SDK, which causes files in
# the root directory to be missed.
MOZ_MODULE_LIST := $(sort $(filter-out SeaMonkeyAll,$(MOZ_MODULE_LIST))) $(firstword $(filter SeaMonkeyAll,$(MOZ_MODULE_LIST)))
MODULES_CO_FLAGS := -P
ifdef MOZ_CO_FLAGS
MODULES_CO_FLAGS := $(MOZ_CO_FLAGS)
endif
MODULES_CO_FLAGS := $(MODULES_CO_FLAGS) $(if $(MOZ_CO_TAG),-r $(MOZ_CO_TAG),-A)
CVSCO_MODULES_NS = $(CVS) $(CVS_FLAGS) co $(MODULES_CO_FLAGS) $(CVS_CO_DATE_FLAGS) -l $(NOSUBDIRS_MODULE)
ifeq (,$(strip $(MOZ_MODULE_LIST)))
FASTUPDATE_MODULES = $(error No modules or projects were specified. Use MOZ_CO_PROJECT to specify a project for checkout.)
CHECKOUT_MODULES = $(error No modules or projects were specified. Use MOZ_CO_PROJECT to specify a project for checkout.)
else
FASTUPDATE_MODULES := fast_update $(CVS) $(CVS_FLAGS) co $(MODULES_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(MOZ_MODULE_LIST)
CHECKOUT_MODULES := $(foreach module,$(MOZ_MODULE_LIST),cvs_co $(CVS) $(CVS_FLAGS) co $(MODULES_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(module);)
endif
ifeq (,$(NOSUBDIRS_MODULE))
FASTUPDATE_MODULES_NS := true
CHECKOUT_MODULES_NS := true
else
FASTUPDATE_MODULES_NS := fast_update $(CVSCO_MODULES_NS)
CHECKOUT_MODULES_NS := cvs_co $(CVSCO_MODULES_NS)
endif
###################################
# CVS defines for locales
#
LOCALES_CO_FLAGS := -P
ifdef MOZ_CO_FLAGS
LOCALES_CO_FLAGS := $(MOZ_CO_FLAGS)
endif
LOCALES_CO_FLAGS := $(LOCALES_CO_FLAGS) $(if $(LOCALES_CO_TAG),-r $(LOCALES_CO_TAG),-A)
ifndef MOZ_CO_LOCALES
FASTUPDATE_LOCALES := true
CHECKOUT_LOCALES := true
else
override MOZ_CO_LOCALES := $(subst $(comma), ,$(MOZ_CO_LOCALES))
ifeq (all,$(MOZ_CO_LOCALES))
MOZCONFIG_MODULES += $(foreach project,$(MOZ_PROJECT_LIST),mozilla/$(project)/locales/all-locales)
LOCALE_CO_DIRS := $(sort $(foreach project,$(MOZ_PROJECT_LIST),$(foreach locale,$(shell cat mozilla/$(project)/locales/all-locales),$(foreach dir,$(LOCALES_$(project)),l10n/$(locale)/$(dir)))))
else # MOZ_CO_LOCALES != all
LOCALE_CO_DIRS = $(sort $(foreach locale,$(MOZ_CO_LOCALES),$(foreach dir,$(LOCALE_DIRS),l10n/$(locale)/$(dir))))
endif
CVSCO_LOCALES := $(CVS) $(CVS_FLAGS) -d $(LOCALES_CVSROOT) co $(LOCALES_CO_FLAGS) $(LOCALE_CO_DIRS)
FASTUPDATE_LOCALES := fast_update $(CVSCO_LOCALES)
CHECKOUT_LOCALES := cvs_co $(CVSCO_LOCALES)
endif #MOZ_CO_LOCALES
#######################################################################
# Rules
#
# Print out any options loaded from mozconfig.
all build checkout clean depend distclean export libs install realclean::
@if test -f .mozconfig.out; then \
cat .mozconfig.out; \
rm -f .mozconfig.out; \
else true; \
fi
ifdef _IS_FIRST_CHECKOUT
all:: checkout build
else
all:: checkout alldep
endif
# Windows equivalents
pull_all: checkout
build_all: build
build_all_dep: alldep
build_all_depend: alldep
clobber clobber_all: clean
pull_and_build_all: checkout alldep
# Do everything from scratch
everything: checkout clean build
####################################
# CVS checkout
#
checkout::
# @: Backup the last checkout log.
@if test -f $(CVSCO_LOGFILE) ; then \
mv $(CVSCO_LOGFILE) $(CVSCO_LOGFILE).old; \
else true; \
fi
ifdef RUN_AUTOCONF_LOCALLY
@echo "Removing local configures" ; \
cd $(ROOTDIR) && \
$(RM) -f mozilla/configure mozilla/nsprpub/configure \
mozilla/directory/c-sdk/configure
endif
@echo "checkout start: "`date` | tee $(CVSCO_LOGFILE)
@echo '$(CVSCO) $(CVS_CO_DATE_FLAGS) mozilla/client.mk $(MOZCONFIG_MODULES)'; \
cd $(ROOTDIR) && \
$(CVSCO) $(CVS_CO_DATE_FLAGS) mozilla/client.mk $(MOZCONFIG_MODULES)
@cd $(ROOTDIR) && $(MAKE) -f mozilla/client.mk real_checkout
# Start the checkout. Split the output to the tty and a log file.
real_checkout:
@set -e; \
cvs_co() { set -e; echo "$$@" ; \
"$$@" 2>&1 | tee -a $(CVSCO_LOGFILE); }; \
cvs_co $(CVSCO_NSPR); \
cvs_co $(CVSCO_NSS); \
cvs_co $(CVSCO_LDAPCSDK); \
$(CHECKOUT_MODULES) \
$(CHECKOUT_MODULES_NS); \
$(CHECKOUT_LOCALES);
@echo "checkout finish: "`date` | tee -a $(CVSCO_LOGFILE)
# update the NSS checkout timestamp
@if test `egrep -c '^(U|C) mozilla/security/(nss|coreconf)' $(CVSCO_LOGFILE) 2>/dev/null` != 0; then \
touch $(TOPSRCDIR)/security/manager/.nss.checkout; \
fi
# @: Check the log for conflicts. ;
@conflicts=`egrep "^C " $(CVSCO_LOGFILE)` ;\
if test "$$conflicts" ; then \
echo "$(MAKE): *** Conflicts during checkout." ;\
echo "$$conflicts" ;\
echo "$(MAKE): Refer to $(CVSCO_LOGFILE) for full log." ;\
false; \
else true; \
fi
ifdef RUN_AUTOCONF_LOCALLY
@echo Generating configures using $(AUTOCONF) ; \
cd $(TOPSRCDIR) && $(AUTOCONF) && \
cd $(TOPSRCDIR)/nsprpub && $(AUTOCONF) && \
cd $(TOPSRCDIR)/directory/c-sdk && $(AUTOCONF)
endif
fast-update:
# @: Backup the last checkout log.
@if test -f $(CVSCO_LOGFILE) ; then \
mv $(CVSCO_LOGFILE) $(CVSCO_LOGFILE).old; \
else true; \
fi
ifdef RUN_AUTOCONF_LOCALLY
@echo "Removing local configures" ; \
cd $(ROOTDIR) && \
$(RM) -f mozilla/configure mozilla/nsprpub/configure \
mozilla/directory/c-sdk/configure
endif
@echo "checkout start: "`date` | tee $(CVSCO_LOGFILE)
@echo '$(CVSCO) mozilla/client.mk $(MOZCONFIG_MODULES)'; \
cd $(ROOTDIR) && \
$(CVSCO) mozilla/client.mk $(MOZCONFIG_MODULES)
@cd $(TOPSRCDIR) && \
$(MAKE) -f client.mk real_fast-update
# Start the update. Split the output to the tty and a log file.
real_fast-update:
@set -e; \
fast_update() { set -e; config/cvsco-fast-update.pl $$@ 2>&1 | tee -a $(CVSCO_LOGFILE); }; \
cvs_co() { set -e; echo "$$@" ; \
"$$@" 2>&1 | tee -a $(CVSCO_LOGFILE); }; \
fast_update $(CVSCO_NSPR); \
cd $(ROOTDIR); \
cvs_co $(CVSCO_NSS); \
cd mozilla; \
fast_update $(CVSCO_LDAPCSDK); \
$(FASTUPDATE_MODULES); \
$(FASTUPDATE_MODULES_NS); \
$(FASTUPDATE_LOCALES);
@echo "fast_update finish: "`date` | tee -a $(CVSCO_LOGFILE)
# update the NSS checkout timestamp
@if test `egrep -c '^(U|C) mozilla/security/(nss|coreconf)' $(CVSCO_LOGFILE) 2>/dev/null` != 0; then \
touch $(TOPSRCDIR)/security/manager/.nss.checkout; \
fi
# @: Check the log for conflicts. ;
@conflicts=`egrep "^C " $(CVSCO_LOGFILE)` ;\
if test "$$conflicts" ; then \
echo "$(MAKE): *** Conflicts during fast-update." ;\
echo "$$conflicts" ;\
echo "$(MAKE): Refer to $(CVSCO_LOGFILE) for full log." ;\
false; \
else true; \
fi
ifdef RUN_AUTOCONF_LOCALLY
@echo Generating configures using $(AUTOCONF) ; \
cd $(TOPSRCDIR) && $(AUTOCONF) && \
cd $(TOPSRCDIR)/nsprpub && $(AUTOCONF) && \
cd $(TOPSRCDIR)/directory/c-sdk && $(AUTOCONF)
endif
####################################
# Web configure
WEBCONFIG_FILE := $(HOME)/.mozconfig
MOZCONFIG2CONFIGURATOR := build/autoconf/mozconfig2configurator
webconfig:
@cd $(TOPSRCDIR); \
url=`$(MOZCONFIG2CONFIGURATOR) $(TOPSRCDIR)`; \
echo Running mozilla with the following url: ;\
echo ;\
echo $$url ;\
mozilla -remote "openURL($$url)" || \
netscape -remote "openURL($$url)" || \
mozilla $$url || \
netscape $$url ;\
echo ;\
echo 1. Fill out the form on the browser. ;\
echo 2. Save the results to $(WEBCONFIG_FILE)
#####################################################
# First Checkout
ifdef _IS_FIRST_CHECKOUT
# First time, do build target in a new process to pick up new files.
build::
$(MAKE) -f $(TOPSRCDIR)/client.mk build
else
#####################################################
# After First Checkout
####################################
# Configure
CONFIG_STATUS := $(wildcard $(OBJDIR)/config.status)
CONFIG_CACHE := $(wildcard $(OBJDIR)/config.cache)
ifdef RUN_AUTOCONF_LOCALLY
EXTRA_CONFIG_DEPS := \
$(TOPSRCDIR)/aclocal.m4 \
$(wildcard $(TOPSRCDIR)/build/autoconf/*.m4) \
$(NULL)
$(TOPSRCDIR)/configure: $(TOPSRCDIR)/configure.in $(EXTRA_CONFIG_DEPS)
@echo Generating $@ using autoconf
cd $(TOPSRCDIR); $(AUTOCONF)
endif
CONFIG_STATUS_DEPS := \
$(TOPSRCDIR)/configure \
$(TOPSRCDIR)/allmakefiles.sh \
$(TOPSRCDIR)/.mozconfig.mk \
$(wildcard $(TOPSRCDIR)/nsprpub/configure) \
$(wildcard $(TOPSRCDIR)/directory/c-sdk/configure) \
$(wildcard $(TOPSRCDIR)/mailnews/makefiles) \
$(wildcard $(TOPSRCDIR)/themes/makefiles) \
$(wildcard $(TOPSRCDIR)/config/milestone.txt) \
$(wildcard $(TOPSRCDIR)/config/chrome-versions.sh) \
$(NULL)
# configure uses the program name to determine @srcdir@. Calling it without
# $(TOPSRCDIR) will set @srcdir@ to "."; otherwise, it is set to the full
# path of $(TOPSRCDIR).
ifeq ($(TOPSRCDIR),$(OBJDIR))
CONFIGURE := ./configure
else
CONFIGURE := $(TOPSRCDIR)/configure
endif
ifdef MOZ_TOOLS
CONFIGURE := $(TOPSRCDIR)/configure
endif
configure:
@if test ! -d $(OBJDIR); then $(MKDIR) $(OBJDIR); else true; fi
@echo cd $(OBJDIR);
@echo $(CONFIGURE) $(CONFIGURE_ARGS)
@cd $(OBJDIR) && $(CONFIGURE_ENV_ARGS) $(CONFIGURE) $(CONFIGURE_ARGS) \
|| ( echo "*** Fix above errors and then restart with\
\"$(MAKE) -f client.mk build\"" && exit 1 )
@touch $(OBJDIR)/Makefile
$(OBJDIR)/Makefile $(OBJDIR)/config.status: $(CONFIG_STATUS_DEPS)
@$(MAKE) -f $(TOPSRCDIR)/client.mk configure
ifdef CONFIG_STATUS
$(OBJDIR)/config/autoconf.mk: $(TOPSRCDIR)/config/autoconf.mk.in
cd $(OBJDIR); \
CONFIG_FILES=config/autoconf.mk ./config.status
endif
####################################
# Depend
depend:: $(OBJDIR)/Makefile $(OBJDIR)/config.status
$(MOZ_MAKE) export && $(MOZ_MAKE) depend
####################################
# Build it
build:: $(OBJDIR)/Makefile $(OBJDIR)/config.status
$(MOZ_MAKE)
####################################
# Profile-feedback build (gcc only)
# To use this, you should set the following variables in your mozconfig
# mk_add_options PROFILE_GEN_SCRIPT=/path/to/profile-script
#
# The profile script should exercise the functionality to be included
# in the profile feedback.
profiledbuild:: $(OBJDIR)/Makefile $(OBJDIR)/config.status
$(MOZ_MAKE) MOZ_PROFILE_GENERATE=1
OBJDIR=${OBJDIR} $(PROFILE_GEN_SCRIPT)
$(MOZ_MAKE) clobber_all
$(MOZ_MAKE) MOZ_PROFILE_USE=1
find $(OBJDIR) -name "*.da" -exec rm {} \;
####################################
# Other targets
# Pass these target onto the real build system
install export libs clean realclean distclean alldep:: $(OBJDIR)/Makefile $(OBJDIR)/config.status
$(MOZ_MAKE) $@
cleansrcdir:
@cd $(TOPSRCDIR); \
if [ -f webshell/embed/gtk/Makefile ]; then \
$(MAKE) -C webshell/embed/gtk distclean; \
fi; \
if [ -f Makefile ]; then \
$(MAKE) distclean ; \
else \
echo "Removing object files from srcdir..."; \
rm -fr `find . -type d \( -name .deps -print -o -name CVS \
-o -exec test ! -d {}/CVS \; \) -prune \
-o \( -name '*.[ao]' -o -name '*.so' \) -type f -print`; \
build/autoconf/clean-config.sh; \
fi;
# (! IS_FIRST_CHECKOUT)
endif
echo_objdir:
@echo $(OBJDIR)
.PHONY: checkout real_checkout depend build export libs alldep install clean realclean distclean cleansrcdir pull_all build_all clobber clobber_all pull_and_build_all everything configure

View File

@@ -1,17 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>testopia-1.0</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.epic.perleditor.perlbuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.epic.perleditor.perlnature</nature>
</natures>
</projectDescription>

View File

@@ -1,392 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Large portions lifted uncerimoniously from Bugzilla::Attachment.pm
# and bugzilla's attachment.cgi
# Which are copyrighted by their respective copyright holders:
# Terry Weissman <terry@mozilla.org>
# Myk Melez <myk@mozilla.org>
# Daniel Raichle <draichle@gmx.net>
# Dave Miller <justdave@syndicomm.com>
# Alexander J. Vincent <ajvincent@juno.com>
# Max Kanat-Alexander <mkanat@bugzilla.org>
# Greg Hendricks <ghendricks@novell.com>
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
=head1 NAME
Bugzilla::Testopia::Attachment - Attachment object for Testopia
=head1 DESCRIPTION
This module provides support for attachments to Test Cases and Test
Plans in Testopia.
=head1 SYNOPSIS
$attachment = Bugzilla::Testopia::Attachment->new($attachment_id);
$attachment = Bugzilla::Testopia::Attachment->new(\%attachment_hash);
=cut
package Bugzilla::Testopia::Attachment;
use strict;
use Bugzilla::Util;
use Bugzilla::Config;
use base qw(Exporter);
###############################
#### Initialization ####
###############################
=head1 FIELDS
attachment_id
plan_id
case_id
submitter_id
description
filename
creation_ts
mime_type
=cut
use constant DB_COLUMNS => qw(
test_attachments.attachment_id
test_attachments.plan_id
test_attachments.case_id
test_attachments.submitter_id
test_attachments.description
test_attachments.filename
test_attachments.creation_ts
test_attachments.mime_type
);
our $columns = join(", ", DB_COLUMNS);
###############################
#### Methods ####
###############################
=head1 METHODS
=head2 new
Instantiates a new Attachment object
=cut
sub new {
my $invocant = shift;
my $class = ref($invocant) || $invocant;
my $self = {};
bless($self, $class);
return $self->_init(@_);
}
=head2 _init
Private constructor for attachment class
=cut
sub _init {
my $self = shift;
my ($param) = (@_);
my $dbh = Bugzilla->dbh;
my $id = $param unless (ref $param eq 'HASH');
my $obj;
if (defined $id && detaint_natural($id)) {
$obj = $dbh->selectrow_hashref(qq{
SELECT $columns FROM test_attachments
WHERE attachment_id = ?}, undef, $id);
} elsif (ref $param eq 'HASH'){
$obj = $param;
} else {
ThrowCodeError('bad_arg',
{argument => 'param',
function => 'Testopia::Attachment::_init'});
}
return undef unless (defined $obj);
foreach my $field (keys %$obj) {
$self->{$field} = $obj->{$field};
}
return $self;
}
=head2 store
Serializes this attachment to the database
=cut
sub store {
my ($self) = @_;
if (!$self->{'case_id'} && !$self->{'plan_id'}){
ThrowUserError("testopia-missing-attachment-key");
}
$self->_validate_data;
$self->{'filename'} = $self->strip_path($self->{'filename'});
my $dbh = Bugzilla->dbh;
my ($timestamp) = Bugzilla::Testopia::Util::get_time_stamp();
$dbh->do("INSERT INTO test_attachments ($columns)
VALUES (?,?,?,?,?,?,?,?)",
undef, "NULL", $self->{'plan_id'}, $self->{'case_id'},
$self->{'submitter_id'}, $self->{'description'},
$self->{'filename'}, $timestamp, $self->{'mime_type'});
my $key = $dbh->bz_last_key( 'test_attachments', 'attachment_id' );
$dbh->do("INSERT INTO test_attachment_data VALUES(?,?)",
undef, $key, $self->{'contents'});
return $key;
}
=head2 _validate_data
Private method for validating attachment data. Checks that size
limit is not exceeded and converts uncompressed BMP to PNG
=cut
sub _validate_data {
my $self = shift;
my $maxsize = Param('maxattachmentsize');
$maxsize *= 1024; # Convert from K
# Make sure the attachment does not exceed the maximum permitted size
my $len = $self->{'contents'} ? length($self->{'contents'}) : 0;
if ($maxsize && $len > $maxsize) {
my $vars = { filesize => sprintf("%.0f", $len/1024) };
ThrowUserError("file_too_large", $vars);
}
trick_taint($self->{'contents'});
}
=head2 strip_path
Strips the path from a filename, everything up to the last / or \.
Note: this was copied directly from bugzilla.
=cut
sub strip_path {
my $self = shift;
my ($filename) = @_;
# Remove path info (if any) from the file name. The browser should do this
# for us, but some are buggy. This may not work on Mac file names and could
# mess up file names with slashes in them, but them's the breaks. We only
# use this as a hint to users downloading attachments anyway, so it's not
# a big deal if it munges incorrectly occasionally.
$filename =~ s/^.*[\/\\]//;
# Truncate the filename to 100 characters, counting from the end of the string
# to make sure we keep the filename extension.
$filename = substr($filename, -100, 100);
trick_taint($filename);
return $filename;
}
=head2 isViewable
Returns true if the content type (mime-type) is viewable in a browser
text/* and img for the most part are viewable, All others are not.
=cut
# Returns 1 if the parameter is a content-type viewable in this browser
# Note that we don't use $cgi->Accept()'s ability to check if a content-type
# matches, because this will return a value even if it's matched by the generic
# */* which most browsers add to the end of their Accept: headers.
sub isViewable
{
my $self = shift;
my $cgi = shift;
my $contenttype = $self->mime_type;
# We assume we can view all text and image types
if ($contenttype =~ /^(text|image)\//) {
return 1;
}
# Mozilla can view XUL. Note the trailing slash on the Gecko detection to
# avoid sending XUL to Safari.
if (($contenttype =~ /^application\/vnd\.mozilla\./) &&
($cgi->user_agent() =~ /Gecko\//))
{
return 1;
}
# If it's not one of the above types, we check the Accept: header for any
# types mentioned explicitly.
my $accept = join(",", $cgi->Accept());
if ($accept =~ /^(.*,)?\Q$contenttype\E(,.*)?$/) {
return 1;
}
return 0;
}
=head2 update
Updates an existing attachment object in the database.
Takes a reference to a hash, the keys of which must match
the fields of an attachment and the values representing the
new data.
=cut
sub update {
my $self = shift;
my ($newvalues) = @_;
my $dbh = Bugzilla->dbh;
my $timestamp = Bugzilla::Testopia::Util::get_time_stamp();
$dbh->bz_lock_tables('test_attachments WRITE');
foreach my $field (keys %{$newvalues}){
if ($self->{$field} ne $newvalues->{$field}){
trick_taint($newvalues->{$field});
$dbh->do("UPDATE test_attachments
SET $field = ? WHERE attachment_id = ?",
undef, $newvalues->{$field}, $self->{'attachment_id'});
}
}
$dbh->bz_unlock_tables();
}
=head2 obliterate
Completely removes an attachment from the database. This is the only
safe way to do this.
=cut
sub obliterate {
my $self = shift;
my $dbh = Bugzilla->dbh;
$dbh->do("DELETE FROM test_attachment_data
WHERE attachment_id = ?", undef, $self->{'attachment_id'});
$dbh->do("DELETE FROM test_attachments
WHERE attachment_id = ?", undef, $self->{'attachment_id'});
}
=head2 canview
Returns true if the logged in user has rights to view this attachment
=cut
sub canview {
}
=head2 canedit
Returns true if the logged in user has rights to edit this attachment
=cut
sub canedit {
}
=head2 candelete
Returns true if the logged in user has rights to delete this attachment
=cut
sub candelete {
}
###############################
#### Accessors ####
###############################
sub id { return $_[0]->{'attachment_id'}; }
sub plan_id { return $_[0]->{'plan_id'}; }
sub case_id { return $_[0]->{'case_id'}; }
sub submitter { return Bugzilla::User->new($_[0]->{'submitter_id'}); }
sub description { return $_[0]->{'description'}; }
sub filename { return $_[0]->{'filename'}; }
sub creation_ts { return $_[0]->{'creation_ts'}; }
sub mime_type { return $_[0]->{'mime_type'}; }
=head2 contents
Returns the attachment data
=cut
sub contents {
my ($self) = @_;
my $dbh = Bugzilla->dbh;
return $self->{'contents'} if exists $self->{'contents'};
my ($contents) = $dbh->selectrow_array("SELECT contents
FROM test_attachment_data
WHERE attachment_id = ?",
undef, $self->{'attachment_id'});
$self->{'contents'} = $contents;
return $self->{'contents'};
}
=head2 datasize
Returns the size of the attachment data
=cut
sub datasize {
my ($self) = @_;
my $dbh = Bugzilla->dbh;
return $self->{'datasize'} if exists $self->{'datasize'};
my ($datasize) = $dbh->selectrow_array("SELECT LENGTH(contents)
FROM test_attachment_data
WHERE attachment_id = ?",
undef, $self->{'attachment_id'});
$self->{'datasize'} = $datasize;
return $self->{'datasize'};
}
=head1 SEE ALSO
Bugzilla::Attachment
=head1 AUTHOR
Greg Hendricks <ghendricks@novell.com>
=cut
1;

View File

@@ -1,272 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
=head1 NAME
Bugzilla::Testopia::Build - An object representing a Testopia build number
=head1 DESCRIPTION
Builds are used to classify test runs. A build represents the results of
a period of work.
=head1 SYNOPSIS
$build = Bugzilla::Testopia::Build->new($build_id);
$build = Bugzilla::Testopia::Build->new(\%build_hash);
=cut
package Bugzilla::Testopia::Build;
use strict;
use Bugzilla::Util;
use Bugzilla::Error;
use Bugzilla::Testopia::TestPlan;
use Bugzilla::Testopia::TestCase;
use base qw(Exporter);
###############################
#### Initialization ####
###############################
=head1 FIELDS
build_id
product_id
name
description
milestone
=cut
use constant DB_COLUMNS => qw(
test_builds.build_id
test_builds.product_id
test_builds.name
test_builds.description
test_builds.milestone
);
our $columns = join(", ", DB_COLUMNS);
###############################
#### Methods ####
###############################
=head1 METHODS
=head2 new
Instantiates a new Build object
=cut
sub new {
my $invocant = shift;
my $class = ref($invocant) || $invocant;
my $self = {};
bless($self, $class);
return $self->_init(@_);
}
=head2 _init
Private constructor for build class
=cut
sub _init {
my $self = shift;
my ($param) = (@_);
my $dbh = Bugzilla->dbh;
my $id = $param unless (ref $param eq 'HASH');
my $obj;
if (defined $id && detaint_natural($id)) {
$obj = $dbh->selectrow_hashref(qq{
SELECT $columns FROM test_builds
WHERE build_id = ?}, undef, $id);
} elsif (ref $param eq 'HASH'){
$obj = $param;
}
return undef unless (defined $obj);
foreach my $field (keys %$obj) {
$self->{$field} = $obj->{$field};
}
return $self;
}
=head2 store
Serializes this build to the database
=cut
sub store {
my $self = shift;
my $dbh = Bugzilla->dbh;
$dbh->do("INSERT INTO test_builds ($columns)
VALUES (?,?,?,?,?)",
undef, "NULL", $self->{'product_id'}, $self->{'name'},
$self->{'description'}, $self->{'milestone'});
my $key = $dbh->bz_last_key( 'test_builds', 'build_id' );
return $key;
}
=head2 remove
Removes this build from the specified product
=cut
sub remove {
my $self = shift;
my ($plan) = @_;
ThrowUserError("testopia-incorrect-plan") if ($self->{'product_id'} != $plan->product_id);
ThrowUserError("testopia-non-zero-case-run-count") if ($self->{'case_run_count'});
ThrowUserError("testopia-non-zero-run-count", {'object' => 'Build'}) if ($self->{'run_count'});
my $dbh = Bugzilla->dbh;
$dbh->do("DELETE FROM test_builds
WHERE build_id = ?", undef,
$self->{'build_id'});
}
=head2 check_name
Returns true if a build of the specified name exists in the database
for a product.
=cut
sub check_name {
my $self = shift;
my ($name) = @_;
my $dbh = Bugzilla->dbh;
my $is = $dbh->selectrow_array(
"SELECT 1 FROM test_builds
WHERE name = ? AND product_id = ?",
undef, $name, $self->{'product_id'});
return $is;
}
=head2 update
Updates an existing build object in the database.
Takes the new name, description, and milestone.
=cut
sub update {
my $self = shift;
my ($name, $desc, $milestone) = @_;
my $dbh = Bugzilla->dbh;
$dbh->do("UPDATE test_builds
SET name = ?, description = ?, milestone = ?
WHERE build_id = ?", undef,
($name, $desc, $milestone, $self->{'build_id'}));
}
###############################
#### Accessors ####
###############################
=head2 id
Returns the ID of this object
=head2 product_id
Returns the product_id of this object
=head2 name
Returns the name of this object
=head2 description
Returns the description of this object
=head2 milestone
Returns the Bugzilla taget milestone associated with this build
=cut
sub id { return $_[0]->{'build_id'}; }
sub product_id { return $_[0]->{'product_id'}; }
sub name { return $_[0]->{'name'}; }
sub description { return $_[0]->{'description'};}
sub milestone { return $_[0]->{'milestone'};}
=head2 run_count
Returns the number of test runs using this build
=cut
sub run_count {
my ($self) = @_;
my $dbh = Bugzilla->dbh;
return $self->{'run_count'} if exists $self->{'run_count'};
$self->{'run_count'} = $dbh->selectrow_array(
"SELECT COUNT(run_id) FROM test_runs
WHERE build_id = ?", undef, $self->{'build_id'});
return $self->{'run_count'};
}
=head2 case_run_count
Returns the number of test case runs against this build
=cut
sub case_run_count {
my ($self) = @_;
my $dbh = Bugzilla->dbh;
return $self->{'case_run_count'} if exists $self->{'case_run_count'};
$self->{'case_run_count'} = $dbh->selectrow_array(
"SELECT COUNT(case_run_id) FROM test_case_runs
WHERE build_id = ?", undef, $self->{'build_id'});
return $self->{'case_run_count'};
}
=head1 SEE ALSO
TestPlan TestRun TestCaseRun
=head1 AUTHOR
Greg Hendricks <ghendricks@novell.com>
=cut
1;

View File

@@ -1,275 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
=head1 NAME
Bugzilla::Testopia::Category - An object representing a test case category
=head1 DESCRIPTION
Categories are used to classify test cases. Each test case must
belong to one category.
=head1 SYNOPSIS
$category = Bugzilla::Testopia::Category->new($category_id);
$category = Bugzilla::Testopia::Category->new(\%category_hash);
=cut
package Bugzilla::Testopia::Category;
use strict;
use Bugzilla::Util;
use Bugzilla::Error;
use Bugzilla::Testopia::TestPlan;
use Bugzilla::Testopia::TestCase;
use base qw(Exporter);
###############################
#### Initialization ####
###############################
=head1 FILEDS
category_id
product_id
name
description
=cut
use constant DB_COLUMNS => qw(
test_case_categories.category_id
test_case_categories.product_id
test_case_categories.name
test_case_categories.description
);
our $columns = join(", ", DB_COLUMNS);
###############################
#### Methods ####
###############################
=head1 METHODS
=head2 new
Instantiates a new Category object
=cut
sub new {
my $invocant = shift;
my $class = ref($invocant) || $invocant;
my $self = {};
bless($self, $class);
return $self->_init(@_);
}
=head2 _init
Private constructor for category class
=cut
sub _init {
my $self = shift;
my ($param) = (@_);
my $dbh = Bugzilla->dbh;
my $id = $param unless (ref $param eq 'HASH');
my $obj;
if (defined $id && detaint_natural($id)) {
$obj = $dbh->selectrow_hashref(qq{
SELECT $columns FROM test_case_categories
WHERE category_id = ?}, undef, $id);
} elsif (ref $param eq 'HASH'){
$obj = $param;
} else {
ThrowCodeError('bad_arg',
{argument => 'param',
function => 'Testopia::Category::_init'});
}
return undef unless (defined $obj);
foreach my $field (keys %$obj) {
$self->{$field} = $obj->{$field};
}
return $self;
}
=head2 store
Serializes this category to the database
=cut
sub store {
my $self = shift;
my $dbh = Bugzilla->dbh;
$dbh->do("INSERT INTO test_case_categories ($columns)
VALUES (?,?,?,?)",
undef, "NULL", $self->{'product_id'}, $self->{'name'},
$self->{'description'});
my $key = $dbh->bz_last_key( 'test_case_categories', 'category_id' );
return $key;
}
=head2 remove
Removes this category from the specified product
=cut
sub remove {
my $self = shift;
my ($plan) = @_;
ThrowUserError("testopia-incorrect-plan") if ($self->{'product_id'} != $plan->product_id);
ThrowUserError("testopia-non-zero-case-count") if ($self->{'case_count'});
my $dbh = Bugzilla->dbh;
$dbh->do("DELETE FROM test_case_categories
WHERE category_id = ?", undef,
$self->{'category_id'});
}
=head2 check_name
Returns true if a category of the specified name exists in the
database for a product.
=cut
sub check_name {
my $self = shift;
my ($name) = @_;
my $dbh = Bugzilla->dbh;
my $is = $dbh->selectrow_array(
"SELECT 1 FROM test_case_categories
WHERE name = ? AND product_id = ?",
undef, $name, $self->{'product_id'});
return $is;
}
=head2 update
Updates an existing category object in the database.
Takes the new name, and description.
=cut
sub update {
my $self = shift;
my ($name, $desc) = @_;
my $dbh = Bugzilla->dbh;
$dbh->do("UPDATE test_case_categories
SET name = ?, description = ?
WHERE category_id = ?", undef,
($name, $desc, $self->{'category_id'}));
}
###############################
#### Accessors ####
###############################
=head2 id
Returns the ID of this object
=head2 product_id
Returns the product_id of this object
=head2 name
Returns the name of this object
=head2 description
Returns the description of this object
=cut
sub id { return $_[0]->{'category_id'}; }
sub product_id { return $_[0]->{'product_id'}; }
sub name { return $_[0]->{'name'}; }
sub description { return $_[0]->{'description'}; }
=head2 case_count
Returns the number of test cases in this category
=cut
sub case_count {
my ($self) = @_;
my $dbh = Bugzilla->dbh;
return $self->{'case_count'} if exists $self->{'case_count'};
my ($count) = $dbh->selectrow_array(
"SELECT COUNT(case_id)
FROM test_cases
WHERE category_id = ?",
undef, $self->{'category_id'});
$self->{'case_count'} = $count;
return $self->{'case_count'};
}
=head2 case_ids
Returns a reference to a list of case_ids in this category
=cut
sub case_ids {
my ($self) = @_;
my $dbh = Bugzilla->dbh;
return $self->{'case_ids'} if exists $self->{'case_ids'};
$self->{'case_ids'} = $dbh->selectcol_arrayref(
"SELECT case_id
FROM test_cases
WHERE category_id = ?",
undef, $self->{'category_id'});
return $self->{'case_ids'};
}
=head1 SEE ALSO
TestCase
=head1 AUTHOR
Greg Hendricks <ghendricks@novell.com>
=cut
1;

View File

@@ -1,125 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
package Bugzilla::Testopia::Constants;
use strict;
use base qw(Exporter);
@Bugzilla::Testopia::Constants::EXPORT = qw(
PROPOSED
CONFIRMED
DISABLED
IDLE
PASSED
FAILED
RUNNING
PAUSED
BLOCKED
UNIT
INTEGRATION
FUNCTION
SYSTEM
ACCEPTANCE
INSTALLATION
PERFORMANCE
REL_AUTHOR
REL_EDITOR
REL_TESTER
REL_TEST_CC
RELATIONSHIPS
);
@Bugzilla::Constants::EXPORT_OK = qw(contenttypes);
# Test Case Status
use constant PROPOSED => 1;
use constant CONFIRMED => 2;
use constant DISABLED => 3;
# Test case Run Status
use constant IDLE => 1;
use constant PASSED => 2;
use constant FAILED => 3;
use constant RUNNING => 4;
use constant PAUSED => 5;
use constant BLOCKED => 6;
# Test Plan Types
use constant UNIT => 1;
use constant INTEGRATION => 2;
use constant SYSTEM => 3;
use constant PERFORMANCE => 4;
use constant REL_AUTHOR => 0;
use constant REL_EDITOR => 1;
use constant REL_TESTER => 2;
use constant REL_TEST_CC => 3;
use constant RELATIONSHIPS => REL_AUTHOR, REL_EDITOR, REL_TESTER, REL_TEST_CC;
# Used for global events like EVT_FLAG_REQUESTED
use constant REL_ANY => 100;
# There are two sorts of event - positive and negative. Positive events are
# those for which the user says "I want mail if this happens." Negative events
# are those for which the user says "I don't want mail if this happens."
#
# Exactly when each event fires is defined in wants_bug_mail() in User.pm; I'm
# not commenting them here in case the comments and the code get out of sync.
use constant EVT_OTHER => 0;
use constant EVT_ADDED_REMOVED => 1;
use constant EVT_COMMENT => 2;
use constant EVT_ATTACHMENT => 3;
use constant EVT_ATTACHMENT_DATA => 4;
use constant EVT_PROJ_MANAGEMENT => 5;
use constant EVT_OPENED_CLOSED => 6;
use constant EVT_KEYWORD => 7;
use constant EVT_CC => 8;
use constant POS_EVENTS => EVT_OTHER, EVT_ADDED_REMOVED, EVT_COMMENT,
EVT_ATTACHMENT, EVT_ATTACHMENT_DATA,
EVT_PROJ_MANAGEMENT, EVT_OPENED_CLOSED, EVT_KEYWORD,
EVT_CC;
use constant EVT_UNCONFIRMED => 50;
use constant EVT_CHANGED_BY_ME => 51;
use constant NEG_EVENTS => EVT_UNCONFIRMED, EVT_CHANGED_BY_ME;
# These are the "global" flags, which aren't tied to a particular relationship.
# and so use REL_ANY.
use constant EVT_FLAG_REQUESTED => 100; # Flag has been requested of me
use constant EVT_REQUESTED_FLAG => 101; # I have requested a flag
use constant GLOBAL_EVENTS => EVT_FLAG_REQUESTED, EVT_REQUESTED_FLAG;
# Number of bugs to return in a buglist when performing
# a fulltext search.
use constant FULLTEXT_BUGLIST_LIMIT => 200;
# Path to sendmail.exe (Windows only)
use constant SENDMAIL_EXE => '/usr/lib/sendmail.exe';
1;

View File

@@ -1,398 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
=head1 NAME
Bugzilla::Testopia::Environment - A test environment
=head1 DESCRIPTION
Environments are a set of parameters dictating what conditions
a test was conducted in. Each test run must have an environment.
Environments can be very simple or very complex. Since there is
no easy way of defining a limit for an environment, the bulk of
the information is captured as an XML document. At the very least
however, and environment consists of the OS and platform from
Bugzilla.
=head1 SYNOPSIS
$env = Bugzilla::Testopia::Environment->new($env_id);
$env = Bugzilla::Testopia::Environment->new(\%env_hash);
=cut
package Bugzilla::Testopia::Environment;
use strict;
use Bugzilla::Util;
use Bugzilla::Error;
use Bugzilla::User;
###############################
#### Initialization ####
###############################
=head1 FIELDS
environment_id
op_sys_id
rep_platform_id
name
xml
=cut
use constant DB_COLUMNS => qw(
test_environments.environment_id
test_environments.op_sys_id
test_environments.rep_platform_id
test_environments.name
test_environments.xml
);
our $columns = join(", ", DB_COLUMNS);
###############################
#### Methods ####
###############################
=head1 METHODS
=head2 new
Instantiates a new Environment object
=cut
sub new {
my $invocant = shift;
my $class = ref($invocant) || $invocant;
my $self = {};
bless($self, $class);
return $self->_init(@_);
}
=head2 _init
Private constructor for the environment class
=cut
sub _init {
my $self = shift;
my ($param) = (@_);
my $dbh = Bugzilla->dbh;
my $id = $param unless (ref $param eq 'HASH');
my $obj;
if (defined $id && detaint_natural($id)) {
$obj = $dbh->selectrow_hashref(qq{
SELECT $columns FROM test_environments
WHERE environment_id = ?}, undef, $id);
} elsif (ref $param eq 'HASH'){
$obj = $param;
}
return undef unless (defined $obj);
foreach my $field (keys %$obj) {
$self->{$field} = $obj->{$field};
}
return $self;
}
=head2 get_op_sys_list
Returns the list of bugzilla op_sys entries
=cut
sub get_op_sys_list{
my $self = shift;
my $dbh = Bugzilla->dbh;
my $ref = $dbh->selectall_arrayref(
"SELECT id, value AS name
FROM op_sys
ORDER BY sortkey", {'Slice'=>{}});
return $ref;
}
=head2 get_rep_platform_list
Returns the list of rep_platforms from bugzilla
=cut
sub get_rep_platform_list{
my $self = shift;
my $dbh = Bugzilla->dbh;
my $ref = $dbh->selectall_arrayref(
"SELECT id, value AS name
FROM rep_platform
ORDER BY sortkey", {'Slice'=>{}});
return $ref;
}
=head2 store
Serializes this environment to the database
=cut
sub store {
my $self = shift;
my $timestamp = Bugzilla::Testopia::Util::get_time_stamp();
# Verify name is available
return 0 if $self->check_name($self->{'name'});
my $dbh = Bugzilla->dbh;
$dbh->do("INSERT INTO test_environments ($columns)
VALUES (?,?,?,?,?)",
undef, (undef, $self->{'op_sys_id'},
$self->{'rep_platform_id'}, $self->{'name'},
$self->{'xml'}));
my $key = $dbh->bz_last_key( 'test_plans', 'plan_id' );
return $key;
}
=head2 update
Updates this environment object in the database.
Takes a reference to a hash whose keys match the fields of
an environment.
=cut
sub update {
my $self = shift;
my ($newvalues) = @_;
my $dbh = Bugzilla->dbh;
$dbh->bz_lock_tables('test_environments WRITE');
foreach my $field (keys %{$newvalues}){
if ($self->{$field} ne $newvalues->{$field}){
# If the new name is already in use, return.
if ($field eq 'name' && $self->check_name($newvalues->{'name'})) {
$dbh->bz_unlock_tables;
return 0;
}
trick_taint($newvalues->{$field});
$dbh->do("UPDATE test_environments
SET $field = ? WHERE environment_id = ?",
undef, $newvalues->{$field}, $self->{'environment_id'});
$self->{$field} = $newvalues->{$field};
}
}
$dbh->bz_unlock_tables;
return 1;
}
=head2 obliterate
Completely removes this environment from the database.
=cut
sub obliterate {
my $self = shift;
my $dbh = Bugzilla->dbh;
$dbh->bz_lock_tables('test_runs READ', 'test_environments WRITE');
my $used = $dbh->selectrow_array("SELECT 1 FROM test_runs
WHERE environment_id = ?",
undef, $self->{'environment_id'});
if ($used) {
$dbh->bz_unlock_tables;
ThrowUserError("testopia-non-zero-run-count", {'object' => 'Environment'});
}
$dbh->do("DELETE FROM test_environments
WHERE environment_id = ?", undef, $self->{'environment_id'});
$dbh->bz_unlock_tables;
}
=head2 get_run_list
Returns a list of run ids associated with this environment.
=cut
sub get_run_list {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $ref = $dbh->selectcol_arrayref("SELECT run_id FROM test_runs
WHERE environment_id = ?",
undef, $self->{'environment_id'});
return join(",", @{$ref});
}
=head2 get_run_count
Returns a count of the runs associated with this environment
=cut
sub get_run_count {
my $self = shift;
my $dbh = Bugzilla->dbh;
my ($count) = $dbh->selectrow_array("SELECT COUNT(run_id) FROM test_runs
WHERE environment_id = ?",
undef, $self->{'environment_id'});
return $count;
}
=head2 check_name
Returns true if an environment of the specified name exists
in the database.
=cut
sub check_name {
my $self = shift;
my ($name) = @_;
my $dbh = Bugzilla->dbh;
my ($used) = $dbh->selectrow_array("SELECT 1
FROM test_environments
WHERE name = ?",
undef, $name);
return $used;
}
=head2 canedit
Returns true if the logged in user has rights to edit this environment.
=cut
sub canedit {
my $self = shift;
return UserInGroup('managetestplans')
|| UserInGroup('edittestcases')
|| UserInGroup('runtests');
}
=head2 canview
Returns true if the logged in user has rights to view this environment.
=cut
sub canview {
my $self = shift;
return UserInGroup('managetestplans')
|| UserInGroup('edittestcases')
|| UserInGroup('runtests');
}
=head2 candelete
Returns true if the logged in user has rights to delete this environment.
=cut
sub candelete {
my $self = shift;
return (UserInGroup('managetestplans')
|| UserInGroup('edittestcases'))
&& Param('allow-test-deletion');
}
###############################
#### Accessors ####
###############################
=head2 id
Returns the ID of this object
=head2 name
Returns the name of this object
=head2 xml
Returnst the xml associated with this environment
=cut
sub id { return $_[0]->{'environment_id'}; }
sub name { return $_[0]->{'name'}; }
sub xml { return $_[0]->{'xml'}; }
=head2 op_sys
Returns the bugzilla op_sys value
=cut
sub op_sys {
my $self = shift;
my $dbh = Bugzilla->dbh;
return $self->{'op_sys'} if exists $self->{'op_sys'};
my ($res) = $dbh->selectrow_array("SELECT value
FROM op_sys
WHERE id = ?",
undef, $self->{'op_sys_id'});
$self->{'op_sys'} = $res;
return $self->{'op_sys'};
}
=head2 rep_platform
Returns the bugzilla rep_platform value
=cut
sub rep_platform {
my $self = shift;
my $dbh = Bugzilla->dbh;
return $self->{'rep_platform'} if exists $self->{'rep_platform'};
my ($res) = $dbh->selectrow_array("SELECT value
FROM rep_platform
WHERE id = ?",
undef, $self->{'rep_platform_id'});
$self->{'rep_platform'} = $res;
return $self->{'rep_platform'};
}
=head1 TODO
Use Bugzilla methods for op_sys and rep_platforms in 2.22
=head1 SEE ALSO
TestRun
=head1 AUTHOR
Greg Hendricks <ghendricks@novell.com>
=cut
1;

View File

@@ -1,65 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
package Bugzilla::Testopia::Product;
use strict;
# Extends Bugzilla::Product;
use base "Bugzilla::Product";
use Bugzilla;
use Bugzilla::Testopia::Environment;
sub environments {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $ref = $dbh->selectcol_arrayref("SELECT environment_id
FROM test_environments
WHERE product_id = ?",
undef, $self->{'id'});
my @objs;
foreach my $id (@{$ref}){
push @objs, Bugzilla::Testopia::Environment->new($id);
}
$self->{'environments'} = \@objs;
return $self->{'environmets'};
}
sub builds {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $ref = $dbh->selectcol_arrayref(
"SELECT build_id
FROM test_builds tb
JOIN test_plans tp ON tb.plan_id = tp.plan_id
WHERE tp.product_id = ?",
undef, $self->{'id'});
my @objs;
foreach my $id (@{$ref}){
push @objs, Bugzilla::Testopia::Build->new($id);
}
$self->{'build'} = \@objs;
return $self->{'build'};
}
1;

View File

@@ -1,489 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Justin C. De Vries <judevries@novell.com>
package Bugzilla::Testopia::Schema;
use base qw(Bugzilla::DB::Schema);
use strict;
use Bugzilla::Error;
use Bugzilla::Util;
use Carp;
use Safe;
# Historical, needed for SCHEMA_VERSION = '1.00'
use Storable qw(dclone freeze thaw);
#New SCHEMA_Version (2.00) use this
use Data::Dumper;
use constant SCHEMA_VERSION => '2.00';
use constant ABSTRACT_SCHEMA => {
#Note: Most of types will need to be defined in a MySQL specific file some where.
test_category_templates => {
FIELDS => [
# Note: UNSMALLSERIAL might need to be added to the MySQL.pm file. Its
# definition is UNSIGNED SMALLINT AUTO_INCREMENT.
category_template_id => {TYPE => 'UNSMALLSERIAL', NOTNULL => 1},
name => {TYPE => 'varchar(255)', NOTNULL => 1},
description => {TYPE => 'MEDIUMTEXT'},
],
INDEXES => [
category_template_name_idx => ['name'],
],
},
test_attachments => {
FIELDS => [
# Note: Serial is a MySQL specific type. This will need to
# be written or modified to be database generic.
attachment_id => {TYPE => 'SERIAL'},
# Note: UNBIGINT need to be added to the MySQL.pm file. Its
# definition is UNSIGNED BIGINT.
plan_id => {TYPE => 'UNBIGINT'},
case_id => {TYPE => 'UNBIGINT'},
submitter_id => {TYPE => 'INT3', NOTNULL => 1},
description => {TYPE => 'MEDIUMTEXT'},
filename => {TYPE => 'MEDIUMTEXT'},
creation_ts => {TYPE => 'DATETIME'},
mime_type => {TYPE => 'varchar(100)', NOTNULL => 1},
],
INDEXES => [
attachment_plan_idx => ['plan_id'],
attachment_case_idx => ['case_id'],
],
},
test_case_categories => {
FIELDS => [
category_id => {TYPE => 'UNSMALLSERIAL', NOTNULL => 1},
product_id => {TYPE => 'INT2', NOTNULL => 1},
name => {TYPE => 'varchar(240)', NOTNULL => 1},
description => {TYPE => 'MEDIUMTEXT'},
],
INDEXES => [
category_name_idx => ['name'],
],
},
test_cases => {
FIELDS => [
case_id => {TYPE => 'SERIAL'},
case_status_id => {TYPE => 'INT1', NOTNULL => 1},
# Note: UNINT2 need to be added to the MySQL.pm file. Its
# definition is UNSIGNED SMALLINT.
category_id => {TYPE => 'UNINT2', NOTNULL => 1},
priority_id => {TYPE => 'INT2'},
author_id => {TYPE => 'INT3', NOTNULL => 1},
creation_date => {TYPE => 'DATETIME', NOTNULL => 1},
isautomated => {TYPE => 'BOOLEAN', NOTNULL => 1, DEFAULT => '0'},
sortkey => {TYPE => 'INT4'},
script => {TYPE => 'MEDIUMTEXT'},
arguments => {TYPE => 'MEDIUMTEXT'},
summary => {TYPE => 'varchar(255)'},
requirement => {TYPE => 'varchar(255)'},
alias => {TYPE => 'varchar(255)'},
],
INDEXES => [
test_case_category_idx => ['category_id'],
test_case_author_idx => ['author_id'],
test_case_creation_date_idx => ['creation_date'],
test_case_sortkey_idx => ['sortkey'],
test_case_requirement_idx => ['requirement'],
test_case_shortname_idx => ['alias'],
],
},
test_case_bugs => {
FIELDS => [
bug_id => {TYPE => 'INT3', NOTNUTLL => 1},
case_run_id => {TYPE => 'UNBIGINT'},
],
INDEXES => [
case_run_id_idx => [qw(case_run_id bug_id)],
case_run_bug_id_idx => ['bug_id'],
],
},
test_case_runs => {
FIELDS => [
case_run_id => {TYPE => 'SERIAL'},
run_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
case_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
assignee => {TYPE => 'INT3'},
testedby => {TYPE => 'INT3'},
case_run_status_id => {TYPE => 'UNINT1', NOTNULL => 1},
case_text_version => {TYPE => 'UNINT3', NOTNULL => 1},
build_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
close_date => {TYPE => 'DATETIME'},
notes => {TYPE => 'TEXT'},
iscurrent => {TYPE => 'BOOLEAN', DEFAULT => '0'},
sortkey => {TYPE => 'INT4'},
],
INDEXES => [
case_run_run_id_idx => ['run_id'],
case_run_case_id_idx => ['case_id'],
case_run_assignee_idx => ['assignee'],
case_run_testedby_idx => ['testedby'],
case_run_close_date_idx => ['close_date'],
case_run_shortkey_idx => ['sortkey'],
],
},
test_case_texts => {
FIELDS => [
case_id => {TYPE => 'UNBIGINT', NOTNULL =>1},
case_text_version => {TYPE => 'INT3', NOTNULL =>1},
who => {TYPE => 'INT3', NOTNULL =>1},
creation_ts => {TYPE => 'DATETIME', NOTNULL =>1},
action => {TYPE => 'MEDIUMTEXT'},
effect => {TYPE => 'MEDIUMTEXT'},
],
INDEXES => [
case_versions_idx => {FIELDS => [qw(case_id case_text_version)],
TYPE => 'UNIQUE'},
case_versions_who_idx => ['who'],
case_versions_creation_ts_idx => ['creation_ts'],
],
},
test_case_tags => {
FIELDS => [
tag_id => {TYPE => 'UNINT4', NOTNULL => 1},
case_id => {TYPE => 'UNBIGINT'},
],
INDEXES => [
case_tags_case_id_idx => [qw(case_id tag_id)],
case_tags_tag_id_idx => [qw(tag_id case_id)],
test_tag_name_indx => ['tag_name'],
],
},
test_plan_testers => {
FIELDS => [
tester_id => {TYPE => 'INT3', NOTNULL => 1},
product_id => {TYPE => 'INT2'},
read_only => {TYPE => 'BOOLEAN', DEFAULT => '1'},
],
},
test_tags => {
FIELDS => [
# Note: UNINT4SERIAL need to be added to the MySQL.pm file. Its
# definition is UNSIGNED INTEGER AUTO_INCREMENT.
tag_id => {TYPE => 'UNINT4SERIAL', NOTNULL => 1},
tag_name => {TYPE => 'varchar(255)', NOTNULL => 1},
],
},
test_plans => {
FIELDS => [
plan_id => {TYPE => 'SERIAL'},
product_id => {TYPE => 'INT2', NOTNULL => 1},
author_id => {TYPE => 'INT3', NOTNULL => 1},
editor_id => {TYPE => 'INT3', NOTNULL => 1},
type_id => {TYPE => 'UNINT1', NOTNULL => 1},
default_product_version => {TYPE => 'MEDIUMTEXT', NOTNULL => 1},
name => {TYPE => 'varchar(255)', NOTNULL => 1},
creation_date => {TYPE => 'DATETIME', NOTNULL => 1},
isactive => {TYPE => 'BOOLEAN', NOTNULL =>, DEFAULT => '1'},
],
INDEXES => [
plan_product_plan_id_idx => [qw(product_id plan_id)],
plan_author_idx => ['author_id'],
plan_type_idx => ['type_id'],
plan_editor_idx => ['editor_id'],
plan_isactive_idx => ['isactive'],
],
},
text_plan_text => {
FIELDS => [
plan_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
plan_text_version => {TYPE => 'INT4', NOTNULL => 1},
who => {TYPE => 'INT3', NOTNULL => 1},
creation_ts => {TYPE => 'DATETIME', NOTNULL => 1},
# Note: LONGTEXT needs to be added to the MySQL.pm file. Its
# definition is LONGTEXT.
plan_text => {TYPE => 'LONGTEXT'},
],
INDEXES => [
test_plan_text_version_idx => [qw(plan_id plan_text_version)],
test_plan_text_who_idx => ['who'],
],
},
test_plan_types => {
FIELDS => [
# Note: UNTINYINTSERIAL needs to be added to the MySQL.pm file. Its
# definition is UNSIGNED TINYINT AUTO_INCREMENT.
type_id => {TYPE => 'UNTINYSERIAL', NOTNULL => 1},
name => {TYPE => 'varchar(64)', NOTNULL => 1},
],
INDEXES => [
plan_type_name_idx => ['name'],
],
},
test_runs => {
FIELDS => [
run_id => {TYPE => 'SERIAL'},
plan_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
environment_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
product_version => {TYPE => 'MEDIUMTEXT'},
build_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
plan_text_version => {TYPE => 'INT4', NOTNULL => 1},
manager_id => {TYPE => 'INT3', NOTNULL => 1},
default_tester_id => {TYPE => 'INT3'},
start_date => {TYPE => 'DATETIME'},
stop_date => {TYPE => 'DATETIME'},
summary => {TYPE => 'TINYTEXT', NOTNULL => 1},
notes => {TYPE => 'MEDIUMTEXT'},
],
INDEXES => [
test_run_plan_id_run_id_idx => [qw(plan_id run_id)],
test_run_manager_idx => ['manager_id'],
test_run_start_date_idx => ['start_date'],
],
},
test_case_plans => {
FIELDS => [
plan_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
case_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
],
INDEXES => [
case_plans_plan_id_idx => ['plan_id'],
case_plans_case_id_idx => ['plan_id'],
],
},
test_case_activity => {
FIELDS => [
case_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
fieldid => {TYPE => 'UNINT2', NOTNULL => 1},
who => {TYPE => 'INT3', NOTNULL => 1},
changed => {TYPE => 'DATETIME', NOTNULL => 1},
oldvalue => {TYPE => 'MEDUIMTEXT'},
newvalue => {TYPE => 'MEDUIMTEXT'},
],
INDEXES => [
case_activity_case_id_idx => ['case_id'],
case_activity_who_idx => ['who'],
case_activity_when_idx => ['changed'],
case_activity_field_idx => ['fieldid'],
],
},
test_fielddefs => {
FIELDS => [
fieldid => {TYPE => 'UNSMALLSERIAL', NOTNULL => 1},
name => {TPYE => 'varchar(100)', NOTNULL => 1},
description => {TYPE => 'MEDIUMTEXT'},
table_name => {TYPE => 'varchar(100)', NOTNULL => 1},
],
INDEXES => [
fielddefs_name_idx => ['name'],
],
},
test_plan_activity => {
FIELDS => [
plan_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
fieldid => {TYPE => 'UNINT2', NOTNULL => 1},
who => {TYPE => 'INT3', NOTNULL => 1},
changed => {TYPE => 'DATETIME', NOTNULL => 1},
oldvalue => {TYPE => 'MEDIUMTEXT'},
newvalue => {TYPE => 'MEDIUMTEXT'},
],
INDEXES => [
plan_activity_who_idx => ['who'],
],
},
test_case_components => {
FIELDS => [
case_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
component_id => {TYPE => 'INT2', NOTNULL => 1},
],
INDEXES => [
case_components_case_id_idx => ['case_id'],
case_commponents_component_id_idx => ['case_id'],
],
},
test_run_activity => {
FIELDS => [
run_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
fieldid => {TYPE => 'UNINT2', NOTNULL => 1},
who => {TYPE => 'INT3', NOTNULL => 1},
changed => {TYPE => 'DATETIME', NOTNULL => 1},
oldvalue => {TYPE => 'MEDIUMTEXT'},
newvalue => {TYPE => 'MEDIUMTEXT'},
],
INDEXES => [
run_activity_run_id_idx => ['run_id'],
run_activity_who_idx => ['who'],
run_activity_when_idx => ['changed'],
],
},
test_run_cc => {
FIELDS => [
run_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
who => {TYPE => 'INT3', NOTNULL => 1},
],
INDEXES => [
run_cc_run_id_who_idx => [qw(run_id who)],
],
},
test_email_settings => {
FIELDS => [
userid => {TYPE => 'INT3', NOTNULL => 1},
eventid => {TYPE => 'UNINT1', NOTNULL => 1},
relationship_id => {TYPE => 'UNINT1', NOTNULL => 1},
],
INDEXES => [
test_event_user_event_idx => [qw(userid eventid)],
test_event_user_relationship_idx => [qw(userid relationship_id)],
],
},
test_events => {
FIELDS => [
eventid => {TYPE => 'UNIN1', NOTNULL => 1},
name => {TYPE => 'varchar(50)'},
],
INDEXES => [
test_event_name_idx => ['name'],
],
},
test_relationships => {
FIELDS => [
relationship_id => {TYPE => 'UNINT1', NOTNULL => 1},
name => {TYPE => 'varchar(50)'},
],
},
test_case_run_status => {
FIELDS => [
case_run_status_id => {TYPE => 'UNTINYSERIAL', NOTNULL => 1},
name => {TYPE => 'varchar(20)'},
sortkey => {TYPE => 'INT4'},
],
INDEXES => [
case_run_status_name_idx => ['name'],
case_run_status_sortkey_idx => ['sortkey'],
],
},
test_case_status => {
FIELDS => [
case_status_id => {TYPE => 'UNTINYSERIAL', NOTNULL => 1},
name => {TYPE => 'varchar(255)'},
],
INDEXES => [
test_case_status_name_idx => ['name'],
],
},
test_case_dependencies => {
FIELDS => [
dependson => {TYPE => 'UNBIGINT', NOTNULL => 1},
blocks => {TYPE => 'UNBIGINT'},
],
},
test_case_group_map => {
FIELDS => [
case_id => {TYPE => 'UNBIGINT', NOTNULL =>1},
group_id => {TYPE => 'INT3'},
],
},
test_environments => {
FIELDS => [
environment_id => {TYPE => 'SERIAL', NOTNULL => 1},
op_sys_id => {TYPE => 'INT4'},
rep_platform_id => {TYPE => 'INT4'},
name => {TYPE => 'varchar(255)'},
xml => {TYPE => 'MEDIUMTEXT'},
],
INDEXES => [
environment_op_sys_idx => ['op_sys_id'],
environment_platform_idx => ['rep_platform_id'],
environment_name_idx => ['name'],
],
},
test_run_tags => {
FIELDS => [
tag_id => {TYPE => 'UNINT4', NOTNULL => 1},
run_id => {TYPE => 'UNBIGINT'},
],
INDEXES => [
run_tags_idx => ['qw(tag_id, run_id'],
],
},
test_plan_tags => {
FIELDS => [
tag_id => {TYPE => 'UNINT4', NOTNULL => 1},
plan_id => {TYPE => 'UNBIGINT'},
],
INDEXES => [
plan_tags_idx => ['qw(tag_id, plan_id'],
],
},
test_build => {
FIELDS => [
build_id => {TYPE => 'SERIAL', NOTNULL => 1},
product_id => {TYPE => 'INT2', NOTNULL => 1},
name => {TYPE => 'varchar(255)'},
description => {TYPE => 'TEXT'},
],
},
test_attachment_data => {
FIELDS => [
attachment_id => {TYPE => 'UNBIGINT', NOTNULL => 1},
contents => {TYPE => 'LONGBLOB'},
],
},
test_named_queries => {
FIELDS => [
userid => {TYPE => 'INT3', NOTNULL => 1},
name => {TYPE => 'varchar(64)', NOTNULL => 1},
isvisible => {TYEP => 'BOOLEAN', NOTNULL => 1, DEFAULT => 1},
query => {TYPE => 'MEDIUMTEXT', NOTNULL => 1},
],
INDEXES => [
test_namedquery_name_idx => ['name'],
],
},
};
1;

View File

@@ -1,828 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
# Large portions lifted uncerimoniously from Bugzilla::Search.pm
# Which is copyrighted by its respective copyright holders
# Many thanks to the geniouses that contributed to that work of art:
# Gervase Markham <gerv@gerv.net>
# Terry Weissman <terry@mozilla.org>
# Dan Mosedale <dmose@mozilla.org>
# Stephan Niemz <st.n@gmx.net>
# Andreas Franke <afranke@mathweb.org>
# Myk Melez <myk@mozilla.org>
# Michael Schindler <michael@compressconsult.com>
# Max Kanat-Alexander <mkanat@bugzilla.org>
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
=head1 NAME
Bugzilla::Testopia::Search - A module to support searches in Testopis
=head1 DESCRIPTION
Testopia::Search is based heavilly on Bugzilla::Search. It takes a
CGI instance and parses its parameters to generate an SQL query that
can be used to get a result set from the database. The query is
usually passed to Table.pm to execute and display the results.
Search.pm supports searching for all major objects in the Testopia
database, Cases, Plans, Runs and Case-runs. It supports sorting
on one column at a time in ascending order.
=head1 SYNOPSIS
$search = Bugzilla::Testopia::Search($cgi);
=cut
package Bugzilla::Testopia::Search;
use strict;
use Bugzilla::Util;
use Bugzilla::Config;
use Bugzilla::Error;
use Bugzilla::Testopia::Util;
use Bugzilla::Testopia::TestCase;
sub new {
my $invocant = shift;
my $class = ref($invocant) || $invocant;
my $self = {};
bless($self, $class);
$self->init(@_);
return $self;
}
sub init {
my $self = shift;
my $cgi = shift;
my $user = $self->{'user'} || Bugzilla->user;
$self->{'cgi'} = $cgi;
my $debug = $cgi->param('debug') || 0;
my $dbh = Bugzilla->dbh;
if ($debug){
use Data::Dumper;
print Dumper($cgi);
print "<br><br>";
}
my $page = $cgi->param('page') || 0;
detaint_natural($page) if $page;
$page = undef if ($cgi->param('viewall'));
my $pagesize = 25;
my @specialchart;
my @supptables;
my @wherepart;
my @having;
my @groupby;
my @andlist;
my @orderby;
my @inputorder;
my @fields;
my %specialorderjoin;
my %chartfields;
# $chartid is the number of the current chart whose SQL we're constructing
# $row is the current row of the current chart
# names for table aliases are constructed using $chartid and $row
# SELECT blah FROM $table "$table_$chartid_$row" WHERE ....
# $f = field of table in bug db (e.g. bug_id, reporter, etc)
# $ff = qualified field name (field name prefixed by table)
# e.g. bugs_activity.bug_id
# $t = type of query. e.g. "equal to", "changed after", case sensitive substr"
# $v = value - value the user typed in to the form
# $q = sanitized version of user input (SqlQuote($v))
# @supptables = Tables and/or table aliases used in query
# %suppseen = A hash used to store all the tables in supptables to weed
# out duplicates.
# @supplist = A list used to accumulate all the JOIN clauses for each
# chart to merge the ON sections of each.
# $suppstring = String which is pasted into query containing all table names
my $chartid;
my $sequence = 0;
my $f;
my $ff;
my $t;
my $q;
my $v;
my $term;
my %funcsbykey;
my $type;
my $obj = trim($cgi->param('current_tab')) || ThrowUserError('testopia-missing-parameter', {'param' => 'current_tab'});
ThrowUserError('unknown-tab') if $obj !~ '^(case|plan|run|case_run)$';
trick_taint($obj);
my $order = $cgi->param('order') || '';
if ($order eq 'author') {
push @supptables, "INNER JOIN profiles as map_author ON map_author.userid = test_". $obj ."s.author_id";
push @orderby, 'map_author.login_name';
}
elsif ($order eq 'manager') {
push @supptables, "INNER JOIN profiles as map_manager ON map_manager.userid = test_". $obj ."s.manager_id";
push @orderby, 'map_manager.login_name';
}
elsif ($order eq 'assignee') {
push @supptables, "LEFT JOIN profiles as map_assignee ON map_assignee.userid = test_". $obj ."s.assignee";
push @orderby, 'map_assignee.login_name';
}
elsif ($order eq 'testedby') {
push @supptables, "LEFT JOIN profiles as map_testedby ON map_testedby.userid = test_". $obj ."s.testedby";
push @orderby, 'map_testedby.login_name';
}
elsif ($order eq 'tester') {
push @supptables, "LEFT JOIN profiles as map_tester ON map_tester.userid = test_". $obj ."s.default_tester_id";
push @orderby, 'map_tester.login_name';
}
elsif ($order eq 'product') {
push @supptables, "INNER JOIN products ON products.id = test_". $obj ."s.product_id";
push @orderby, 'products.name';
}
elsif ($order eq 'build') {
push @supptables, "INNER JOIN test_builds AS build ON build.build_id = test_". $obj ."s.build_id";
push @orderby, 'build.name';
}
elsif ($order eq 'environment') {
push @supptables, "INNER JOIN test_environments AS env ON env.environment_id = test_". $obj ."s.environment_id";
push @orderby, 'env.name';
}
elsif ($order eq 'plan_type') {
push @supptables, "INNER JOIN test_plan_types AS ptype ON ptype.type_id = test_plans.type_id";
push @orderby, 'ptype.name';
}
elsif ($order eq 'plan_prodver') {
push @supptables, "INNER JOIN versions ON versions.value = test_plans.default_product_version";
push @orderby, 'versions.value';
}
elsif ($order eq 'priority') {
push @supptables, "INNER JOIN priority ON priority.id = test_cases.priority_id";
push @orderby, 'test_cases.priority_id';
}
elsif ($order eq 'build') {
push @supptables, "INNER JOIN test_builds ON test_builds.build_id = test_case_runs.build_id";
push @orderby, 'test_builds.name';
}
elsif ($order eq 'case_run_status') {
push @supptables, "INNER JOIN test_case_run_status as case_run_status ON case_run_status.case_run_status_id = test_case_runs.case_run_status_id";
push @orderby, 'case_run_status.sortkey';
}
elsif ($order eq 'category') {
if ($obj eq 'case_run'){
push @supptables, "INNER JOIN test_cases ON test_cases.case_id = test_case_runs.case_id";
}
push @supptables, "INNER JOIN test_case_categories AS categories ON test_cases.category_id = categories.category_id";
push @orderby, 'categories.name';
}
elsif ($order eq 'case_status') {
push @supptables, "INNER JOIN test_case_status AS case_status ON test_cases.case_status_id = case_status.case_status_id";
push @orderby, 'case_status.name';
}
elsif ($order eq 'summary') {
push @orderby, 'test_'. $obj .'s.summary';
}
elsif ($order eq 'created') {
push @orderby, 'test_'. $obj .'s.creation_date';
}
elsif ($order eq 'name') {
push @orderby, 'test_'. $obj .'s.name';
}
else{
if ($order){
trick_taint($order) if ($order);
push @orderby, 'test_'. $obj .'s.' . $order;
}
}
my @funcdefs =
(
"^category," => sub {
if ($obj eq 'case_run'){
push(@supptables,
"INNER JOIN test_cases " .
"ON test_case_runs.case_id = test_cases.case_id");
}
push(@supptables,
"INNER JOIN test_case_categories AS categories " .
"ON test_cases.category_id = categories.category_id");
$f = "categories.name";
},
"^build," => sub {
my $str = '';
$str = 'case_' if ($obj eq 'case_run');
push(@supptables,
"INNER JOIN test_builds AS builds " .
"ON test_". $str ."runs.build_id = builds.build_id");
$f = "builds.name";
},
"^(tcaction|tceffect)," => sub {
push(@supptables,
"LEFT JOIN test_case_texts AS case_texts " .
"ON test_cases.case_id = case_texts.case_id");
my $fid = ($1 eq 'tcaction' ? 'action' : 'effect');
$f = "case_texts.$fid";
},
"^plan_text," => sub {
push(@supptables,
"LEFT JOIN test_plan_texts AS plan_texts " .
"ON test_plans.plan_id = plan_texts.plan_id");
$f = "plan_texts.plan_text";
},
"^environment," => sub {
push(@supptables,
"LEFT JOIN test_environments AS env " .
"ON test_runs.environment_id = env.environment_id");
$f = "env.xml";
},
"^component," => sub {
push(@supptables,
"INNER JOIN test_case_components AS tc_components " .
"ON test_cases.case_id = tc_components.case_id");
push(@supptables,
"INNER JOIN components ".
"ON components.id = tc_components.component_id");
$f = "components.name";
},
"^milestone," => sub {
push(@supptables,
"INNER JOIN test_builds AS builds " .
"ON test_runs.build_id = builds.build_id");
push(@supptables,
"INNER JOIN milestones ".
"ON milestones.value = builds.milestone");
$f = "milestones.value";
},
"^bug," => sub {
push(@supptables,
"INNER JOIN test_case_bugs AS case_bugs " .
"ON test_case_runs.case_run_id = case_bugs.case_run_id");
push(@supptables,
"INNER JOIN bugs ".
"ON case_bugs.bug_id = bugs.bug_id");
$f = "bugs.bug_id";
},
"^tags," => sub {
push(@supptables,
"INNER JOIN test_". $obj ."_tags AS ". $obj ."_tags " .
"ON test_". $obj ."s.". $obj ."_id = ". $obj ."_tags.". $obj ."_id");
push(@supptables,
"INNER JOIN test_tags " .
"ON ". $obj ."_tags.tag_id = test_tags.tag_id");
$f = "test_tags.tag_name";
},
"^case_plan_id," => sub {
push(@supptables,
"INNER JOIN test_case_plans AS case_plans " .
"ON test_cases.case_id = case_plans.case_id");
push(@supptables,
"INNER JOIN test_plans " .
"ON case_plans.plan_id = test_plans.plan_id");
$f = "test_plans.plan_id";
},
"^run_plan_id," => sub {
$f = "test_runs.plan_id";
},
"^case_prod," => sub {
push(@supptables,
"INNER JOIN test_case_plans AS case_plans " .
"ON test_cases.case_id = case_plans.case_id");
push(@supptables,
"INNER JOIN test_plans " .
"ON case_plans.plan_id = test_plans.plan_id");
push(@supptables,
"INNER JOIN products " .
"ON test_plans.product_id = products.id");
$f = "test_plans.product_id";
},
"^run_prod," => sub {
push(@supptables,
"INNER JOIN test_plans " .
"ON test_runs.plan_id = test_plans.plan_id");
push(@supptables,
"INNER JOIN products " .
"ON test_plans.product_id = products.id");
$f = "test_plans.product_id";
},
"^(author|editor|manager|default_tester)," => sub {
push(@supptables,
"INNER JOIN profiles AS map_$1 " .
"ON test_". $obj ."s.". $1 ."_id = map_$1.userid");
$f = "map_$1.login_name";
},
"^(assignee|testedby)," => sub {
push(@supptables,
"INNER JOIN profiles AS map_$1 " .
"ON test_". $obj ."s.". $1 ." = map_$1.userid");
$f = "map_$1.login_name";
},
",isnotnull" => sub {
$term = "$ff is not null";
},
",isnull" => sub {
$term = "$ff is null";
},
",equals" => sub {
$term = "$ff = $q";
},
",notequals" => sub {
$term = "$ff != $q";
},
",casesubstring" => sub {
$term = $dbh->sql_position($q, $ff) . " > 0";
},
",substring" => sub {
$term = $dbh->sql_position(lc($q), "LOWER($ff)") . " > 0";
},
",substr" => sub {
$funcsbykey{",substring"}->();
},
",notsubstring" => sub {
$term = $dbh->sql_position(lc($q), "LOWER($ff)") . " = 0";
},
",regexp" => sub {
$term = "$ff " . $dbh->sql_regexp() . " $q";
},
",notregexp" => sub {
$term = "$ff " . $dbh->sql_not_regexp() . " $q";
},
",lessthan" => sub {
$term = "$ff < $q";
},
",greaterthan" => sub {
$term = "$ff > $q";
},
",anyexact" => sub {
my @list;
foreach my $w (split(/,/, $v)) {
push(@list, $dbh->quote($w));
}
if (@list) {
$term = "$ff IN (" . join (',', @list) . ")";
}
},
",anywordssubstr" => sub {
$term = join(" OR ", @{GetByWordListSubstr($ff, $v)});
},
",allwordssubstr" => sub {
$term = join(" AND ", @{GetByWordListSubstr($ff, $v)});
},
",nowordssubstr" => sub {
my @list = @{GetByWordListSubstr($ff, $v)};
if (@list) {
$term = "NOT (" . join(" OR ", @list) . ")";
}
},
",anywords" => sub {
$term = join(" OR ", @{GetByWordList($ff, $v)});
},
",allwords" => sub {
$term = join(" AND ", @{GetByWordList($ff, $v)});
},
",nowords" => sub {
my @list = @{GetByWordList($ff, $v)};
if (@list) {
$term = "NOT (" . join(" OR ", @list) . ")";
}
},
);
if ($cgi->param('case_id')) {
my $type = "anyexact";
if ($cgi->param('caseidtype') && $cgi->param('caseidtype') eq 'exclude') {
$type = "nowords";
}
push(@specialchart, ["case_id", $type, join(',', $cgi->param('case_id'))]);
}
if ($cgi->param('run_id')) {
my $type = "anyexact";
if ($cgi->param('runidtype') && $cgi->param('runidtype') eq 'exclude') {
$type = "nowords";
}
push(@specialchart, ["run_id", $type, join(',', $cgi->param('run_id'))]);
}
if ($cgi->param('plan_id')) {
my $type = "anyexact";
if ($cgi->param('planidtype') && $cgi->param('planidtype') eq 'exclude') {
$type = "nowords";
}
if ($obj eq 'case'){
push(@specialchart, ["case_plan_id", $type, join(',', $cgi->param('plan_id'))]);
if ($cgi->param('exclude')){
my @exclusions = split(/,/, $cgi->param('exclude'));
foreach (@exclusions){
detaint_natural($_);
}
push @wherepart, 'test_cases.case_id NOT IN ('. join(',', @exclusions) .')';
}
}
elsif ($obj eq 'run'){
push(@specialchart, ["run_plan_id", $type, join(',', $cgi->param('plan_id'))]);
}
else{
push(@specialchart, ["plan_id", $type, join(',', $cgi->param('plan_id'))]);
}
}
if ($cgi->param('bug_id')) {
my $type = "anyexact";
if ($cgi->param('bugidtype') && $cgi->param('bugidtype') eq 'exclude') {
$type = "nowords";
}
push(@specialchart, ["bug", $type, join(',', $cgi->param('bug_id'))]);
}
if ($cgi->param("product_id")){
my $type = "anyexact";
if ($cgi->param('prodidtype') && $cgi->param('prodidtype') eq 'exclude') {
$type = "nowords";
}
if ($obj eq 'run'){
push(@specialchart, ["run_prod", $type, join(',', $cgi->param('product_id'))]);
}
elsif ($obj eq 'case'){
push(@specialchart, ["case_prod", $type, join(',', $cgi->param('product_id'))]);
}
else{
push(@specialchart, ["product_id", $type, join(',', $cgi->param('product_id'))]);
}
}
# Check the Multi select fields and add them to the chart
my @legal_fields = ("case_status_id", "category", "priority_id",
"component", "isautomated", "case_run_status_id",
"default_product_version", "type_id",
"build", "environment_id", "milestone");
foreach my $field ($cgi->param()) {
if (lsearch(\@legal_fields, $field) != -1) {
push(@specialchart, [$field, "anyexact",
join(',', $cgi->param($field))]);
}
}
if (defined $cgi->param('run_status')){
my @sta = $cgi->param('run_status');
unless (scalar @sta > 1){
if ($cgi->param('run_status') == 1){
push(@specialchart, ['stop_date', 'isnotnull', 'null']);
}
else {
push(@specialchart, ['stop_date', 'isnull', 'null']);
}
}
}
if (defined $cgi->param('close_date')){
my @sta = $cgi->param('close_date');
unless (scalar @sta > 1){
if ($cgi->param('close_date') == 1){
push(@specialchart, ['close_date', 'isnotnull', 'null']);
}
else {
push(@specialchart, ['close_date', 'isnull', 'null']);
}
}
}
# Check the tags and add them to the chart
if ($cgi->param('tags')) {
my $t = $cgi->param('tags_type');
if (!$t || $t eq "or") {
$t = "anywords";
}
push(@specialchart, ["tags", $t, $cgi->param('tags')]);
}
# Check for author
my @clist;
foreach my $profile ("author", "editor", "manager", "default_tester",
"assignee", "testedby"){
$t = $cgi->param($profile . "_type") || '';
if ($t eq "exact") {
$t = "anyexact";
foreach my $name (split(',', $cgi->param($profile))) {
$name = trim($name);
if ($name) {
&::DBNameToIdAndCheck($name);
}
}
}
if ($cgi->param($profile)){
if ($cgi->param('andor')){
push(@specialchart, [$profile, $t, trim($cgi->param($profile))]);
}
else{
push(@clist, $profile, $t, trim($cgi->param($profile)));
}
}
}
if (@clist) {
push(@specialchart, \@clist);
}
# check static text fields
foreach my $f ("summary", "tcaction", "tceffect", "script",
"requirement", "name", "plan_text", "environment",
"notes") {
if (defined $cgi->param($f)) {
my $s = trim($cgi->param($f));
if ($s ne "") {
trick_taint($s);
my $type = $cgi->param($f . "_type");
push(@specialchart, [$f, $type, $s]);
}
}
}
if ($obj eq 'plan'){
unless ($cgi->param('isactive')){
push @wherepart, 'test_plans.isactive = 1';
}
}
if ($obj eq 'case_run'){
unless ($cgi->param('isactive')){
push @wherepart, 'test_case_runs.iscurrent = 1';
}
}
my @funcnames;
while (@funcdefs) {
my $key = shift(@funcdefs);
my $value = shift(@funcdefs);
if ($key =~ /^[^,]*$/) {
die "All defs in %funcs must have a comma in their name: $key";
}
if (exists $funcsbykey{$key}) {
die "Duplicate key in %funcs: $key";
}
$funcsbykey{$key} = $value;
push(@funcnames, $key);
}
# first we delete any sign of "Chart #-1" from the HTML form hash
# since we want to guarantee the user didn't hide something here
my @badcharts = grep /^(field|type|value)-1-/, $cgi->param();
foreach my $field (@badcharts) {
$cgi->delete($field);
}
# now we take our special chart and stuff it into the form hash
my $chart = -1;
my $row = 0;
foreach my $ref (@specialchart) {
my $col = 0;
while (@$ref) {
$cgi->param("field$chart-$row-$col", shift(@$ref));
$cgi->param("type$chart-$row-$col", shift(@$ref));
$cgi->param("value$chart-$row-$col", shift(@$ref));
if ($debug) {
print qq{<p>$cgi->param("field$chart-$row-$col") | $cgi->param("type$chart-$row-$col") | $cgi->param("value$chart-$row-$col")*</p>\n};
}
$col++;
}
$row++;
}
# get a list of field names to verify the user-submitted chart fields against
my $ref = $dbh->selectall_arrayref("SELECT name, fieldid FROM test_fielddefs");
foreach my $list (@{$ref}) {
my ($name, $id) = @{$list};
$chartfields{$name} = $id;
}
$row = 0;
for ($chart=-1 ;
$chart < 0 || $cgi->param("field$chart-0-0") ;
$chart++) {
$chartid = $chart >= 0 ? $chart : "";
my @chartandlist = ();
for ($row = 0 ;
$cgi->param("field$chart-$row-0") ;
$row++) {
my @orlist;
for (my $col = 0 ;
$cgi->param("field$chart-$row-$col") ;
$col++) {
$f = $cgi->param("field$chart-$row-$col") || "noop";
$t = $cgi->param("type$chart-$row-$col") || "noop";
$v = $cgi->param("value$chart-$row-$col");
$v = "" if !defined $v;
$v = trim($v);
if ($f eq "noop" || $t eq "noop" || $v eq "") {
next;
}
# chart -1 is generated by other code above, not from the user-
# submitted form, so we'll blindly accept any values in chart -1
if ((!$chartfields{$f}) && ($chart != -1)) {
ThrowCodeError("invalid_field_name", {field => $f});
}
# This is either from the internal chart (in which case we
# already know about it), or it was in %chartfields, so it is
# a valid field name, which means that it's ok.
trick_taint($f);
$q = $dbh->quote($v);
my $rhs = $v;
$rhs =~ tr/,//;
my $func;
$term = undef;
foreach my $key (@funcnames) {
if ("$f,$t,$rhs" =~ m/$key/) {
my $ref = $funcsbykey{$key};
if ($debug) {
print "<p>$key ($f , $t , $rhs ) => ";
}
$ff = $f;
if ($f !~ /\./) {
$ff = "test_". $obj ."s.$f";
}
&$ref;
if ($debug) {
print "$f , $t , $v , $term</p>";
}
if ($term) {
last;
}
}
}
if ($term) {
push(@orlist, $term);
}
else {
# This field and this type don't work together.
ThrowCodeError("field_type_mismatch",
{ field => $cgi->param("field$chart-$row-$col"),
type => $cgi->param("type$chart-$row-$col"),
});
}
}
if (@orlist) {
@orlist = map("($_)", @orlist) if (scalar(@orlist) > 1);
push(@chartandlist, "(" . join(" OR ", @orlist) . ")");
}
}
if (@chartandlist) {
if ($cgi->param("negate$chart")) {
push(@andlist, "NOT(" . join(" AND ", @chartandlist) . ")");
} else {
push(@andlist, "(" . join(" AND ", @chartandlist) . ")");
}
}
}
# The ORDER BY clause goes last, but can require modifications
# to other parts of the query, so we want to create it before we
# write the FROM clause.
foreach my $orderitem (@inputorder) {
# Some fields have 'AS' aliases. The aliases go in the ORDER BY,
# not the whole fields.
# XXX - Ideally, we would get just the aliases in @inputorder,
# and we'd never have to deal with this.
if ($orderitem =~ /\s+AS\s+(.+)$/i) {
$orderitem = $1;
}
BuildOrderBy($orderitem, \@orderby);
}
# Now JOIN the correct tables in the FROM clause.
# This is done separately from the above because it's
# cleaner to do it this way.
foreach my $orderitem (@inputorder) {
# Grab the part without ASC or DESC.
my @splitfield = split(/\s+/, $orderitem);
if ($specialorderjoin{$splitfield[0]}) {
push(@supptables, $specialorderjoin{$splitfield[0]});
}
}
my %suppseen = ("test_". $obj ."s" => 1);
my $suppstring = "test_". $obj ."s";
my @supplist = (" ");
foreach my $str (@supptables) {
if (!$suppseen{$str}) {
if ($str =~ /^(LEFT|INNER|RIGHT)\s+JOIN/i) {
$str =~ /^(.*?)\s+ON\s+(.*)$/i;
my ($leftside, $rightside) = ($1, $2);
if ($suppseen{$leftside}) {
$supplist[$suppseen{$leftside}] .= " AND ($rightside)";
} else {
$suppseen{$leftside} = scalar @supplist;
push @supplist, " $leftside ON ($rightside)";
}
} else {
# Do not accept implicit joins using comma operator
# as they are not DB agnostic
# ThrowCodeError("comma_operator_deprecated");
$suppstring .= ", $str";
$suppseen{$str} = 1;
}
}
}
$suppstring .= join('', @supplist);
# Make sure we create a legal SQL query.
@andlist = ("1 = 1") if !@andlist;
my $query = "SELECT test_". $obj ."s.". $obj. "_id" .
" FROM $suppstring";
$query .= " WHERE " . join(' AND ', (@wherepart, @andlist));
foreach my $field (@fields, @orderby) {
next if ($field =~ /(AVG|SUM|COUNT|MAX|MIN|VARIANCE)\s*\(/i ||
$field =~ /^\d+$/ || $field eq "bugs.bug_id" ||
$field =~ /^relevance/);
if ($field =~ /.*AS\s+(\w+)$/i) {
push(@groupby, $1) if !grep($_ eq $1, @groupby);
} else {
push(@groupby, $field) if !grep($_ eq $field, @groupby);
}
}
$query .= " " . $dbh->sql_group_by("test_". $obj ."s.". $obj ."_id", join(', ', @groupby));
if (@having) {
$query .= " HAVING " . join(" AND ", @having);
}
if (@orderby) {
$query .= " ORDER BY " . join(',', @orderby);
}
if (defined $page){
$query .= " LIMIT $pagesize OFFSET ". $page*$pagesize;
}
if ($debug) {
print "<p><code>" . value_quote($query) . "</code></p>\n";
exit;
}
$self->{'sql'} = $query;
}
sub query {
my $self = shift;
return $self->{'sql'};
}
sub GetByWordList {
my ($field, $strs) = (@_);
my @list;
my $dbh = Bugzilla->dbh;
foreach my $w (split(/[\s,]+/, $strs)) {
my $word = $w;
if ($word ne "") {
$word =~ tr/A-Z/a-z/;
$word = $dbh->quote(quotemeta($word));
trick_taint($word);
$word =~ s/^'//;
$word =~ s/'$//;
$word = '(^|[^a-z0-9])' . $word . '($|[^a-z0-9])';
push(@list, "$field " . $dbh->sql_regexp() . " '$word'");
}
}
return \@list;
}
# Support for "any/all/nowordssubstr" comparison type ("words as substrings")
sub GetByWordListSubstr {
my ($field, $strs) = (@_);
my @list;
my $dbh = Bugzilla->dbh;
foreach my $word (split(/[\s,]+/, $strs)) {
trick_taint($word);
if ($word ne "") {
push(@list, $dbh->sql_position(lc($dbh->quote($word)),
"LOWER($field)") . " > 0");
}
}
return \@list;
}
=head1 SEE ALSO
Testopia::Table Bugzilla::Search
=head1 AUTHOR
Greg Hendricks <ghendricks@novell.com>
=cut
1;

View File

@@ -1,455 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
=head1 NAME
Bugzilla::Testopia::Table - Produces display tables for Testopia lists
=head1 DESCRIPTION
A table is generated as a result of a query. This module returns
a list of Testopia objects that were queried for. It supports
pagination of data as well as sorting. It takes the following
arguments:
=over
=item type - one of 'case', 'plan', 'run', or 'caserun'
=item url - the cgi file that is calling this
=item cgi - a CGI object
=item list - A reference to a list
=item query - An SQL query string, usually generated by Search.pm
=back
=head1 SYNOPSIS
$table = Bugzilla::Testopia::Table->new($type, $url, $cgi, $list, $query);
=cut
package Bugzilla::Testopia::Table;
use strict;
use Bugzilla;
use Bugzilla::Util;
use Bugzilla::Error;
use Bugzilla::Testopia::Util;
use Bugzilla::Testopia::TestCase;
use Bugzilla::Testopia::TestPlan;
use Bugzilla::Testopia::TestRun;
use Bugzilla::Testopia::TestCaseRun;
###############################
#### Initialization ####
###############################
# For use in sorting functions which do not allow arguments
our $field;
our $reverse;
=head1 METHODS
=head2 new
Instantiates a new table object
=cut
sub new {
my $invocant = shift;
my $class = ref($invocant) || $invocant;
my $self = {};
bless($self, $class);
$self->init(@_);
return $self;
}
=head2 init
Private constructor for this class
=cut
sub init {
my $self = shift;
my ($type, $url, $cgi, $list, $query) = @_;
my $dbh = Bugzilla->dbh;
$self->{'user'} = Bugzilla->user;
$self->{'type'} = $type || ThrowCodeError('bad_arg',
{argument => 'type',
function => 'Testopia::Table::_init'});
$self->{'url_loc'} = $url;
$self->{'cgi'} = $cgi;
my $debug = $cgi->param('debug') if $cgi;
my @list;
if ($query){
print "$query" if $debug;
# For paging we need to know the total number of items
# but Search.pm returns a query with a subset
my $countquery = $query;
$countquery =~ s/ LIMIT.*$//;
print "<br> $countquery" if $debug;
my $count_res = $dbh->selectcol_arrayref($countquery);
my $count = scalar @$count_res;
print "<br> total rows: $count" if $debug;
$self->{'list_count'} = $count;
my @ids;
my $list = $dbh->selectcol_arrayref($query);
foreach my $id (@$list){
my $o;
if ($type eq 'case'){
$o = Bugzilla::Testopia::TestCase->new($id);
}
elsif ($type eq 'plan'){
$o = Bugzilla::Testopia::TestPlan->new($id);
}
elsif ($type eq 'run'){
$o = Bugzilla::Testopia::TestRun->new($id);
}
elsif ($type eq 'case_run'){
$o = Bugzilla::Testopia::TestCaseRun->new($id);
}
push (@ids, $id);
push (@list, $o);
}
$self->{'list'} = \@list;
$self->{'id_list'} = join(",", @$count_res);
}
if ($cgi){
$self->{'viewall'} = $cgi->param('viewall');
$self->{'page'} = $cgi->param('page') || 0;
}
# elsif (!$query && !$list){
# my @list;
# foreach my $id (split(",", $self->get_saved_list())){
# if ($self->{'type'} eq 'case'){
# my $o = Bugzilla::Testopia::TestCase->new($id);
# push @list, $o;
# $o->category;
# $o->status;
# $o->priority;
# }
# elsif ($self->{'type'} eq 'plan'){
# my $o = Bugzilla::Testopia::TestPlan->new($id);
# push @list, $o;
# $o->test_case_count;
# $o->test_run_count;
# }
# elsif ($self->{'type'} eq 'run'){
# my $o = Bugzilla::Testopia::TestCase->new($id);
# push @list, $o;
## $o->category;
## $o->status;
## $o->priority;
# }
# elsif ($self->{'type'} eq 'caserun'){
# my $o = Bugzilla::Testopia::TestCase->new($id);
# push @list, $o;
## $o->category;
## $o->status;
## $o->priority;
# }
# elsif ($self->{'type'} eq 'attachment'){
# my $o = Bugzilla::Testopia::TestCase->new($id);
# push @list, $o;
## $o->category;
## $o->status;
## $o->priority;
# }
# else {
# ThrowUserError('unknown-type');
# }
# }
# $self->{'list'} = \@list;
# }
# else {
# $self->{'list'} = $list;
# }
# my @params = split(":", $cgi->cookie('TESTORDER'));
# $self->{'last_sort'} = shift @params || undef;
# $self->{'reverse_sort'} = shift @params || undef;
#
# #### SORT ####
# # This is very inefficient. It would be much better to have
# # the database do this.
# my $order = $cgi->param('order');
# if ($order){
# $self->sort_fields($order);
# $self->{'reverse_sort'} = ($self->{'reverse_sort'} ? 1 : 0);
# }
#
#### SAVE ####
# Save the list of testcases for use in paginating and sorting
$self->save_list;
#
# #### SPLICE ####
# # If we are using a paged view of the data we split it up here
# $self->get_page($self->{'page'});
}
###############################
#### Methods ####
###############################
=head2 save_list
Saves the last list to the database as a hidden saved search
Used only in list context
=cut
sub save_list {
my $self = shift;
return if ($self->{'user'}->id == 0);
# my @ids;
# foreach my $i (@{$self->{'list'}}){
# push @ids, $i->id;
# }
# my $list = join(",", @ids);
my $dbh = Bugzilla->dbh;
if ($self->{'id_list'}){
$dbh->bz_lock_tables('test_named_queries WRITE');
my ($is) = $dbh->selectrow_array(
"SELECT 1 FROM test_named_queries
WHERE userid = ? AND name = ?", undef,
($self->{'user'}->id, "__". $self->{'type'} ."__"));
if ($is) {
$dbh->do("UPDATE test_named_queries SET query = ?
WHERE userid = ? AND name = ?", undef,
(join(",", $self->{'id_list'}), $self->{'user'}->id, "__". $self->{'type'} ."__"));
}
else {
$dbh->do("INSERT INTO test_named_queries VALUES(?,?,?,?)", undef,
($self->{'user'}->id, "__". $self->{'type'} ."__", 0, join(",", $self->{'id_list'})));
}
$dbh->bz_unlock_tables();
}
# $self->{'list_count'} = scalar @ids unless $self->{'query'};
}
=head2 get_saved_list
Retrieves a saved list from the database
Used only in list context
=cut
sub get_saved_list {
my $self = shift;
return undef if ($self->{'user'}->id == 0);
my $type = shift || $self->{'type'};
my $dbh = Bugzilla->dbh;
my ($list) = $dbh->selectrow_array(
"SELECT query FROM test_named_queries
WHERE userid = ? AND name = ?", undef,
($self->{'user'}->id, "__". $type ."__"));
my @list = split(',', $list);
return \@list;
}
# used by the sort function to check which field to sort on
# we turn off warnings to supress the nonnumeric vs numeric junk
sub sort_fields {
no warnings;
if ($field eq 'category'){
if ($reverse){
$a->category->name cmp $b->category->name;
}
else {
$b->category->name cmp $a->category->name;
}
}
elsif ($field eq 'plans'){
if ($reverse){
scalar @{$a->plans} <=> scalar @{$b->plans};
}
else {
scalar @{$b->plans} <=> scalar @{$a->plans};
}
}
else{
if ($reverse){
$a->{$field} cmp $b->{$field};
}
else {
$b->{$field} cmp $a->{$field};
}
}
use warnings;
}
sub sort_list {
my $self = shift;
$field = shift;
$reverse = $self->{'reverse_sort'};
my @list = sort sort_fields @{$self->{'list'}};
$self->{'list'} = \@list;
return $self->{'list'};
}
sub get_page {
my $self = shift;
if ($self->{'viewall'}){
return $self->{'list'};
}
my $pagenum = shift || $self->{'page'};
$self->{'page'} = $pagenum;
my $offset = $pagenum * $self->page_size;
my @list = @{$self->{'list'}};
@list = splice(@list, $offset, $self->page_size);
$self->{'list'} = \@list;
return $self->{'list'};
}
sub get_next{
my $self = shift;
my ($curr) = @_;
my $list = $self->get_list;
my $ref = lsearch($curr, $list);
return undef if $ref == -1;
return $list->[$ref];
}
###############################
#### Accessors ####
###############################
sub list { return $_[0]->{'list'}; }
sub list_count { return $_[0]->{'list_count'}; }
sub page { return $_[0]->{'page'}; }
=head2 page_size
Returns an ineger representing how many items should appear on a page
=cut
sub page_size {
my $self = shift;
my $cgi = $self->{'cgi'};
return $cgi->param('pagesize') if $cgi->param('pagesize');
return 25; #TODO: make this a user setting
}
=head2 get_order_url
Returns a URL query string from a CGI object which is used by
column headers to produce a sort order
=cut
sub get_order_url {
my $self = shift;
return $self->get_url('(page|order)');
}
=head2 get_page_url
Retrns a URL query string from a CGI object which is used by
the page navigation links to move from page to page.
=cut
sub get_page_url {
my $self = shift;
return $self->get_url('page');
}
sub get_url {
my $self = shift;
my $regxp = shift;
my $cgi = $self->{'cgi'};
my @keys = $cgi->param;
my $qstring;
foreach my $key (@keys){
if ($key =~ /$regxp/){
next;
}
my @vals = $cgi->param($key);
foreach my $val (@vals){
$qstring .= $key ."=". $val ."&";
}
}
chop $qstring;
$qstring = $self->{'url_loc'} ."?". $qstring;
$self->{'url'} = $qstring;
return $self->{'url'};
}
=head2 page_count
Returns a total count of the number of pages returned by a query.
Determined in part by page_size
=cut
sub page_count {
my $self = shift;
if ($self->list_count % $self->page_size){
use integer;
return ($self->list_count / $self->page_size) + 1;
}
return $self->list_count/$self->page_size;
}
sub reverse_sort {
my $self = shift;
return $self->{'reverse_sort'};
}
sub ajax {
my $self = shift;
return $self->{'ajax'} ? 1 : 0;
}
sub arrow {
my $self = shift;
if ($self->{'reverse_sort'}) {
$self->{'arrow'} = '<img src="images/arrow_desc.png" border="0">';
}
else {
$self->{'arrow'} = '<img src="images/arrow_asc.png" border="0">';
}
return $self->{'arrow'};
}
=head1 SEE ALSO
Testopia::Search
=head1 AUTHOR
Greg Hendricks <ghendricks@novell.com>
=cut
1;

File diff suppressed because it is too large Load Diff

View File

@@ -1,833 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
=head1 NAME
Bugzilla::Testopia::TestCaseRun - Testopia Test Case Run object
=head1 DESCRIPTION
This module represents a test case run in Testopia.
A test case run is a record in the test_case_runs table which joins
test cases to test runs. Basically, for each test run a selction of
test cases is made to be included in that run. As a test run
progresses, testers set statuses on each of the cases in the run.
If the build is changed on a case-run with a status, a clone of that
case-run is made in the table for historical purposes.
=head1 SYNOPSIS
use Bugzilla::Testopia::TestCaseRun;
$caserun = Bugzilla::Testopia::TestCaseRun->new($caserun_id);
$caserun = Bugzilla::Testopia::TestCaseRun->new(\%caserun_hash);
=cut
package Bugzilla::Testopia::TestCaseRun;
use strict;
use Bugzilla::Util;
use Bugzilla::Error;
use Bugzilla::User;
use Bugzilla::Config;
use Bugzilla::Testopia::Util;
use Bugzilla::Testopia::Constants;
###############################
#### Initialization ####
###############################
=head1 FIELDS
case_run_id
run_id
case_id
assignee
testedby
case_run_status_id
case_text_version
build_id
notes
close_date
iscurrent
sortkey
=cut
use constant DB_COLUMNS => qw(
test_case_runs.case_run_id
test_case_runs.run_id
test_case_runs.case_id
test_case_runs.assignee
test_case_runs.testedby
test_case_runs.case_run_status_id
test_case_runs.case_text_version
test_case_runs.build_id
test_case_runs.notes
test_case_runs.close_date
test_case_runs.iscurrent
test_case_runs.sortkey
);
our $columns = join(", ", DB_COLUMNS);
###############################
#### Methods ####
###############################
=head1 METHODS
=head2 new
Instantiate a new case run. This takes a single argument
either a test case ID or a reference to a hash containing keys
identical to a test case-run's fields and desired values.
=cut
sub new {
my $invocant = shift;
my $class = ref($invocant) || $invocant;
my $self = {};
bless($self, $class);
return $self->_init(@_);
}
=head2 _init
Private constructor for this object
=cut
sub _init {
my $self = shift;
my ($param) = (@_);
my $dbh = Bugzilla->dbh;
my $id = $param unless (ref $param eq 'HASH');
my $obj;
if (defined $id && detaint_natural($id)) {
$obj = $dbh->selectrow_hashref(qq{
SELECT $columns FROM test_case_runs
WHERE case_run_id = ?}, undef, $id);
} elsif (ref $param eq 'HASH'){
$obj = $param;
} else {
Bugzilla::Error::ThrowCodeError('bad_arg',
{argument => 'param',
function => 'Testopia::TestCaseRun::_init'});
}
return undef unless (defined $obj);
foreach my $field (keys %$obj) {
$self->{$field} = $obj->{$field};
}
return $self;
}
=head2 store
Stores a test case run object in the database. This method is used
to store a newly created test case run. It returns the new id.
=cut
sub store {
my $self = shift;
my $dbh = Bugzilla->dbh;
$dbh->do("INSERT INTO test_case_runs ($columns)
VALUES (?,?,?,?,?,?,?,?,?,?,?,?)", undef,
(undef, $self->{'run_id'}, $self->{'case_id'}, $self->{'assignee'},
undef, IDLE, $self->{'case_text_version'},
$self->{'build_id'}, $self->{'notes'}, undef, 1, 0));
my $key = $dbh->bz_last_key( 'test_case_runs', 'case_run_id' );
return $key;
}
=head2 clone
Creates a copy of this caserun and sets it as the current record
=cut
sub clone {
my $self = shift;
my ($fields) = @_;
my $dbh = Bugzilla->dbh;
$self->{'build_id'} = $fields->{'build_id'};
my $entry = $self->store;
$self->set_as_current($entry);
return $entry;
}
=head2 check_exists
Checks for an existing entry with the same build for this case and run
and returns the id if it is found
=cut
sub check_exists {
my $self = shift;
my ($run_id, $case_id, $build_id) = @_;
$run_id ||= $self->{'run_id'};
$case_id ||= $self->{'case_id'};
$build_id ||= $self->{'build_id'};
my $dbh = Bugzilla->dbh;
my ($is) = $dbh->selectrow_array(
"SELECT case_run_id
FROM test_case_runs
WHERE run_id = ? AND case_id = ? AND build_id = ?",
undef, ($run_id, $case_id, $build_id));
return $is;
}
=head2 update
Update this case-run in the database. This method checks which
fields have been changed and either creates a clone of the case-run
or updates the existing one.
=cut
sub update {
my $self = shift;
my ($fields) = @_;
my $dbh = Bugzilla->dbh;
if ($self->is_closed_status($fields->{'case_run_status_id'})){
$fields->{'close_date'} = Bugzilla::Testopia::Util::get_time_stamp();
}
my ($is) = $self->check_exists($self->run_id, $self->case_id, $fields->{'build_id'});
if ($fields->{'build_id'} != $self->{'build_id'}){
if ($is){
return $is;
}
if ($self->{'case_run_status_id'} != IDLE){
return $self->clone($fields);
}
}
return $self->_update_fields($fields);
}
=head2 _update_fields
Update this case-run in the database if a change is made to an
updatable field.
=cut
sub _update_fields{
my $self = shift;
my ($newvalues) = @_;
my $dbh = Bugzilla->dbh;
if ($newvalues->{'case_run_status_id'} && $newvalues->{'case_run_status_id'} == FAILED){
$self->_update_deps(BLOCKED);
}
elsif ($newvalues->{'case_run_status_id'} && $newvalues->{'case_run_status_id'} == PASSED){
$self->_update_deps(IDLE);
}
$dbh->bz_lock_tables('test_case_runs WRITE');
foreach my $field (keys %{$newvalues}){
$dbh->do("UPDATE test_case_runs
SET $field = ? WHERE case_run_id = ?",
undef, $newvalues->{$field}, $self->{'case_run_id'});
}
$dbh->bz_unlock_tables();
return $self->{'case_run_id'};
}
=head2 set_as_current
Sets this case-run as the current or active one in the history
list of case-runs of this build and case_id
=cut
sub set_as_current {
my $self = shift;
my ($caserun) = @_;
$caserun = $self->{'case_run_id'} unless defined $caserun;
my $dbh = Bugzilla->dbh;
my $list = $self->get_case_run_list;
$dbh->bz_lock_tables('test_case_runs WRITE');
foreach my $c (@{$list}){
$dbh->do("UPDATE test_case_runs
SET iscurrent = 0
WHERE case_run_id = ?",
undef, $c);
}
$dbh->do("UPDATE test_case_runs
SET iscurrent = 1
WHERE case_run_id = ?",
undef, $caserun);
$dbh->bz_unlock_tables();
}
=head2 set_build
Sets the build on a case-run
=cut
sub set_build {
my $self = shift;
my ($build_id) = @_;
$self->_update_fields({'build_id' => $build_id});
$self->{'build_id'} = $build_id;
}
=head2 set_status
Sets the status on a case-run and updates the close_date and testedby
if the status is a closed status.
=cut
sub set_status {
my $self = shift;
my ($status_id) = @_;
$self->_update_fields({'case_run_status_id' => $status_id});
if ($status_id == IDLE){
$self->_update_fields({'close_date' => undef});
$self->_update_fields({'testedby' => undef});
$self->{'close_date'} = undef;
$self->{'testedby'} = undef;
}
elsif ($status_id == RUNNING || $status_id == PAUSED){
$self->_update_fields({'close_date' => undef});
$self->{'close_date'} = undef;
}
else {
my $timestamp = Bugzilla::Testopia::Util::get_time_stamp();
$self->_update_fields({'close_date' => $timestamp});
$self->_update_fields({'testedby' => Bugzilla->user->id});
$self->{'close_date'} = $timestamp;
$self->{'testedby'} = Bugzilla->user->id;
}
$self->{'case_run_status_id'} = $status_id;
$self->{'status'} = undef;
}
=head2 set_assignee
Sets the assigned tester for the case-run
=cut
sub set_assignee {
my $self = shift;
my ($user_id) = @_;
$self->_update_fields({'assignee' => $user_id});
}
=head2 set_note
Updates the notes field for the case-run
=cut
sub set_note {
my $self = shift;
my ($note, $append) = @_;
if ($append){
my $note = $self->notes . "\n" . $note;
}
$self->_update_fields({'notes' => $note});
$self->{'notes'} = $note;
}
=head2 _update_deps
Private method for updating blocked test cases. If the pre-requisite
case fails, the blocked test cases in a run get a status of BLOCKED
if it passes they are set back to IDLE. This only happens to the
current case run and only if it doesn't already have a closed status.
=cut
sub _update_deps {
my $self = shift;
my ($status) = @_;
my $deplist = $self->case->get_dep_tree;
return unless $deplist;
my $dbh = Bugzilla->dbh;
$dbh->bz_lock_tables("test_case_runs WRITE");
my $caseruns = $dbh->selectcol_arrayref(
"SELECT case_run_id
FROM test_case_runs
WHERE iscurrent = 1
AND run_id = ?
AND case_run_status_id IN(". join(',', (IDLE,RUNNING,PAUSED,BLOCKED)) .")
AND case_id IN (". join(',', @$deplist) .")",
undef, $self->{'run_id'});
my $sth = $dbh->prepare_cached(
"UPDATE test_case_runs
SET case_run_status_id = ?
WHERE case_run_id = ?");
foreach my $id (@$caseruns){
$sth->execute($status, $id);
}
$dbh->bz_unlock_tables;
$self->{'updated_deps'} = $caseruns;
}
=head2 get_case_run_list
Returns a reference to a list of case-runs for the given case and run
=cut
sub get_case_run_list {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $ref = $dbh->selectcol_arrayref(
"SELECT case_run_id FROM test_case_runs
WHERE case_id = ? AND run_id = ?", undef,
($self->{'case_id'}, $self->{'run_id'}));
return $ref;
}
=head2 get_status_list
Returns a list reference of the legal statuses for a test case-run
=cut
sub get_status_list {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $ref = $dbh->selectall_arrayref(
"SELECT case_run_status_id AS id, name
FROM test_case_run_status
ORDER BY sortkey", {'Slice' =>{}});
return $ref
}
=head2 attach_bug
Attaches the specified bug to this test case-run
=cut
sub attach_bug {
my $self = shift;
my ($bug, $caserun_id) = @_;
$caserun_id ||= $self->{'case_run_id'};
my $dbh = Bugzilla->dbh;
$dbh->bz_lock_tables('test_case_bugs WRITE');
my ($is) = $dbh->selectrow_array(
"SELECT bug_id
FROM test_case_bugs
WHERE case_run_id=?
AND bug_id=?",
undef, ($caserun_id, $bug));
if ($is) {
$dbh->bz_unlock_tables();
return;
}
$dbh->do("INSERT INTO test_case_bugs (bug_id, case_run_id)
VALUES(?,?)", undef, ($bug, $self->{'case_run_id'}));
$dbh->bz_unlock_tables();
}
=head2 detach_bug
Removes the association of the specified bug from this test case-run
=cut
sub detach_bug {
my $self = shift;
my ($bug) = @_;
my $dbh = Bugzilla->dbh;
$dbh->do("DELETE FROM test_case_bugs
WHERE bug_id = ?
AND case_run_id = ?",
undef, ($bug, $self->{'case_run_id'}));
}
=head2 get_buglist
Returns a comma separated string off bug ids associated with
this case-run
=cut
sub get_buglist {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $bugids = $dbh->selectcol_arrayref("SELECT bug_id
FROM test_case_bugs
WHERE case_run_id=?",
undef, $self->{'case_run_id'});
return join(',', @{$bugids});
}
###############################
#### Accessors ####
###############################
=head1 ACCESSOR METHODS
=head2 id
Returns the ID of the object
=head2 testedby
Returns a Bugzilla::User object representing the user that closed
this case-run.
=head2 assignee
Returns a Bugzilla::User object representing the user assigned to
update this case-run.
=head2 case_text_version
Returns the version of the test case document that this case-run
was run against.
=head2 notes
Returns the notes of the object
=head2 close_date
Returns the time stamp of when this case-run was closed
=head2 iscurrent
Returns true if this is the current case-run in the history list
=head2 status_id
Returns the status id of the object
=head2 sortkey
Returns the sortkey of the object
=head2 isprivate
Returns the true if this case-run is private.
=cut
=head2 updated_deps
Returns a reference to a list of dependent caseruns that were updated
=cut
sub id { return $_[0]->{'case_run_id'}; }
sub case_id { return $_[0]->{'case_id'}; }
sub run_id { return $_[0]->{'run_id'}; }
sub testedby { return Bugzilla::User->new($_[0]->{'testedby'}); }
sub assignee { return Bugzilla::User->new($_[0]->{'assignee'}); }
sub case_text_version { return $_[0]->{'case_text_version'}; }
sub notes { return $_[0]->{'notes'}; }
sub close_date { return $_[0]->{'close_date'}; }
sub iscurrent { return $_[0]->{'iscurrent'}; }
sub status_id { return $_[0]->{'case_run_status_id'}; }
sub sortkey { return $_[0]->{'sortkey'}; }
sub isprivate { return $_[0]->{'isprivate'}; }
sub updated_deps { return $_[0]->{'updated_deps'}; }
=head2 run
Returns the TestRun object that this case-run is associated with
=cut
# The potential exists for creating a circular reference here.
sub run {
my $self = shift;
return $self->{'run'} if exists $self->{'run'};
$self->{'run'} = Bugzilla::Testopia::TestRun->new($self->{'run_id'});
return $self->{'run'};
}
=head2 case
Returns the TestCase object that this case-run is associated with
=cut
# The potential exists for creating a circular reference here.
sub case {
my $self = shift;
return $self->{'case'} if exists $self->{'case'};
$self->{'case'} = Bugzilla::Testopia::TestCase->new($self->{'case_id'});
return $self->{'case'};
}
=head2 build
Returns the Build object that this case-run is associated with
=cut
sub build {
my $self = shift;
return $self->{'build'} if exists $self->{'build'};
$self->{'build'} = Bugzilla::Testopia::Build->new($self->{'build_id'});
return $self->{'build'};
}
=head2 status
Looks up the status name of the associated status_id for this object
=cut
sub status {
my $self = shift;
my $dbh = Bugzilla->dbh;
($self->{'status'}) = $dbh->selectrow_array(
"SELECT name FROM test_case_run_status
WHERE case_run_status_id=?", undef,
$self->{'case_run_status_id'});
return $self->{'status'};
}
=head2 bugs
Returns a list of Bugzilla::Bug objects associated with this case-run
=cut
sub bugs {
my $self = shift;
#return $self->{'bug'} if exists $self->{'bug'};
my $dbh = Bugzilla->dbh;
my @bugs;
my $bugids = $dbh->selectcol_arrayref("SELECT bug_id
FROM test_case_bugs
WHERE case_run_id=?",
undef, $self->{'case_run_id'});
#TODO: Check that user can see bug
foreach my $bugid (@{$bugids}){
push @bugs, Bugzilla::Bug->new($bugid, Bugzilla->user->id);
}
$self->{'bugs'} = \@bugs; #join(",", @$bugids);
return $self->{'bugs'};
}
=head2 bug_list
Returns a comma separated list of bug ids associated with this case-run
=cut
sub bug_list {
my $self = shift;
#return $self->{'bug'} if exists $self->{'bug'};
my $dbh = Bugzilla->dbh;
my @bugs;
my $bugids = $dbh->selectcol_arrayref("SELECT bug_id
FROM test_case_bugs
WHERE case_run_id=?",
undef, $self->{'case_run_id'});
#TODO: Check that user can see bug
foreach my $bugid (@{$bugids}){
push @bugs, Bugzilla::Bug->new($bugid, Bugzilla->user->id);
}
$self->{'bug_list'} = join(",", @$bugids);
return $self->{'bug_list'};
}
=head2 bug_count
Retuns a count of the bugs associated with this case-run
=cut
sub bug_count{
my $self = shift;
return $self->{'bug_count'} if exists $self->{'bug_count'};
my $dbh = Bugzilla->dbh;
$self->{'bug_count'} = $dbh->selectrow_array("SELECT COUNT(bug_id)
FROM test_case_bugs
WHERE case_run_id=?",
undef, $self->{'case_run_id'});
return $self->{'bug_count'};
}
=head2 is_open_status
Returns true if the status of this case-run is an open status
=cut
sub is_open_status {
my $self = shift;
my $status = shift;
my @open_status_list = (IDLE, RUNNING, PAUSED);
return 1 if lsearch(\@open_status_list, $status) > -1;
}
=head2 is_closed_status
Returns true if the status of this case-run is a closed status
=cut
sub is_closed_status {
my $self = shift;
my $status = shift;
my @closed_status_list = (PASSED, FAILED, BLOCKED);
return 1 if lsearch(\@closed_status_list, $status) > -1;
}
=head2 canview
Returns true if the logged in user has rights to view this case-run.
=cut
sub canview {
my $self = shift;
# return $self->{'canview'} if exists $self->{'canview'};
# my ($case_log_id, $run_id, $plan_id, $current_user_id) = @_;
#
# my $dbh = Bugzilla->dbh;
# my $canview = 0;
# my $current_user_id = Bugzilla->user->id;
# my ($plan_id) = $dbh->selectrow_array("SELECT plan_id FROM test_runs
# WHERE run_id=?",
# undef, $self->{'test_run_id'});
#
# if (0 == &Bugzilla::Param('private-cases-log')) {
# $canview = 1;
# } else {
#
# if (0 == $self->{'isprivate'}) {
# # if !isprivate, then everybody can run it and should be able to see
# # the current status
# $canview = 1;
# } else {
# # check is the current user is a tester:
# if (defined $current_user_id) {
#
# SendSQL("select 1 from test_case_run_testers ".
# "where case_log_id=". $self->{'id'} ." and userid=$current_user_id");
#
# if (FetchOneColumn()) {
# # current user is a tester
# $canview = 1;
# } else {
# # check editors
# SendSQL("select 1 from test_plans where plan_id=$plan_id and editor=$current_user_id");
#
# if (FetchOneColumn()) {
# $canview = 1;
# } else {
# # check watchers
# SendSQL("select 1 from test_plans_watchers where plan_id=$plan_id and userid=$current_user_id");
# if (FetchOneColumn()) {
# $canview = 1;
# } else {
# #check test run manager
# SendSQL("select 1 from test_runs where test_run_id=". $self->{'test_run_id'} ." and manager=$current_user_id");
# $canview = FetchOneColumn()? 1 : 0;
#
# if (0 == $canview) {
# if (UserInGroup('admin')) {
# $canview = 1;
# }
# }
# }
# }
# }
# }
# }
# }
$self->{'canview'} = 1;
return $self->{'canview'};
}
=head2 canedit
Returns true if the logged in user has rights to edit this case-run.
=cut
sub canedit {
my $self = shift;
return !$self->run->stop_date && $self->canview
&& (UserInGroup('managetestplans')
|| UserInGroup('edittestcases')
|| UserInGroup('runtests'));
}
=head2 candelete
Returns true if the logged in user has rights to delete this case-run.
=cut
sub candelete {
my $self = shift;
return $self->canedit && Param('allow-test-deletion');
}
=head1 SEE ALSO
TestCase TestRun
=head1 AUTHOR
Greg Hendricks <ghendricks@novell.com>
=cut
1;

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,330 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
=head1 NAME
Bugzilla::Testopia::TestTag - A Testopia tag
=head1 DESCRIPTION
Tags in Testopia are used to classify objects in an intuitive manner.
Tags are user defined strings that can be attached to Test Plans, test
Cases, and Test Runs. They are similar to keywords in Bugzilla but do
not require administrator privileges to create.
=head1 SYNOPSIS
use Bugzilla::Testopia::TestTag;
$tag = Bugzilla::Testopia::TestTag->new($tag_id);
$tag = Bugzilla::Testopia::TestTag->new($tag_hash);
=cut
package Bugzilla::Testopia::TestTag;
use strict;
use Bugzilla::Util;
use Bugzilla::Error;
###############################
#### Initialization ####
###############################
=head1 FIELDS
tag_id
tag_name
=cut
use constant DB_COLUMNS => qw(
test_tags.tag_id
test_tags.tag_name
);
our $columns = join(", ", DB_COLUMNS);
###############################
#### Methods ####
###############################
=head1 METHODS
=head2 new
Instantiates a new TestTag
=cut
sub new {
my $invocant = shift;
my $class = ref($invocant) || $invocant;
my $self = {};
bless($self, $class);
return $self->_init(@_);
}
=head2 _init
Private constructor
=cut
sub _init {
my $self = shift;
my ($param) = (@_);
my $dbh = Bugzilla->dbh;
my $id = $param unless (ref $param eq 'HASH');
my $name = $param unless (ref $param eq 'HASH');
my $obj;
if (defined $id && detaint_natural($id)) {
$obj = $dbh->selectrow_hashref(qq{
SELECT $columns FROM test_tags
WHERE tag_id = ?}, undef, $id);
} elsif (ref $param eq 'HASH'){
$obj = $param;
} else {
ThrowCodeError('bad_arg',
{argument => 'param',
function => 'Testopia::TestTag::_init'});
}
return undef unless (defined $obj);
foreach my $field (keys %$obj) {
$self->{$field} = $obj->{$field};
}
$self->case_count;
$self->plan_count;
$self->run_count;
return $self;
}
=head2 check_name
Checks the supplied name to see if a tag of that name exists.
If it does it returns a TestTag object. Otherwise it returns
undef.
=cut
sub check_name {
my $self = shift;
my ($name) = @_;
my $dbh = Bugzilla->dbh;
my ($id) = $dbh->selectrow_array(
"SELECT tag_id FROM test_tags
WHERE tag_name = ?",
undef, lc($name));
if ($id){
return Bugzilla::Testopia::TestTag->new($id);
}
else{
return undef;
}
}
=head2 store
Checks if the given tag exists in the database. If so, it returns
that ID. Otherwise it submits the tag to the database and returns
the newly created ID.
=cut
sub store {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $key;
$dbh->bz_lock_tables('test_tags WRITE');
($key) = $dbh->selectrow_array("SELECT tag_id FROM test_tags
WHERE LOWER(tag_name) = ?",
undef, lc($self->{'tag_name'}));
if ($key) {
$dbh->bz_unlock_tables();
return $key;
}
$dbh->do("INSERT INTO test_tags ($columns)
VALUES (?,?)",
undef, (undef, $self->{'tag_name'}));
$key = $dbh->bz_last_key( 'test_tags', 'tag_id' );
$dbh->bz_unlock_tables();
return $key;
}
=head2 obliterate
Completely removes a tag from the database. This is the only safe
way to do this.
=cut
sub obliterate {
my $self = shift;
my $dbh = Bugzilla->dbh;
$dbh->do("DELETE FROM test_case_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
$dbh->do("DELETE FROM test_plan_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
$dbh->do("DELETE FROM test_run_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
$dbh->do("DELETE FROM test_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
}
=head2 case_list
Returns a comma separated list of case ids associated with this tag
=cut
sub case_list {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $list = $dbh->selectcol_arrayref(
"SELECT case_id FROM test_case_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
return join(",", @{$list});
}
=head2 plan_list
Returns a comma separated list of plan ids associated with this tag
=cut
sub plan_list {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $list = $dbh->selectcol_arrayref(
"SELECT plan_id FROM test_plan_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
return join(",", @{$list});
}
=head2 run_list
Returns a comma separated list of run ids associated with this tag
=cut
sub run_list {
my $self = shift;
my $dbh = Bugzilla->dbh;
my $list = $dbh->selectcol_arrayref(
"SELECT run_id FROM test_run_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
return join(",", @{$list});
}
###############################
#### Accessors ####
###############################
=head1 ACCCESSOR METHODS
=head2 id
Returns the tag ID
=head2 name
Returns the tag name
=cut
sub id { return $_[0]->{'tag_id'}; }
sub name { return $_[0]->{'tag_name'}; }
=head2 case_count
Returns a count of the test cases associated with this tag
=cut
sub case_count {
my $self = shift;
return $self->{'case_count'} if exists $self->{'case_count'};
my $dbh = Bugzilla->dbh;
my ($count) = $dbh->selectrow_array(
"SELECT COUNT(tag_id)
FROM test_case_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
$self->{'case_count'} = $count;
return $self->{'case_count'};
}
=head2 plan_count
Returns a count of the test plans associated with this tag
=cut
sub plan_count {
my $self = shift;
return $self->{'plan_count'} if exists $self->{'plan_count'};
my $dbh = Bugzilla->dbh;
my ($count) = $dbh->selectrow_array(
"SELECT COUNT(tag_id)
FROM test_plan_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
$self->{'plan_count'} = $count;
return $self->{'plan_count'};
}
=head2 run_count
Returns a count of the test runs associated with this tag
=cut
sub run_count {
my $self = shift;
return $self->{'run_count'} if exists $self->{'run_count'};
my $dbh = Bugzilla->dbh;
my ($count) = $dbh->selectrow_array(
"SELECT COUNT(tag_id)
FROM test_run_tags
WHERE tag_id = ?", undef, $self->{'tag_id'});
$self->{'run_count'} = $count;
return $self->{'run_count'}
}
=head1 SEE ALSO
TestPlan TestRun TestCase
=head1 AUTHOR
Greg Hendricks <ghendricks@novell.com>
=cut
1;

View File

@@ -1,247 +0,0 @@
# -*- Mode: perl; indent-tabs-mode: nil -*-
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Maciej Maczynski <macmac@xdsnet.pl>
# Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
=head1 NAME
Bugzilla::Testopia::Util
=head1 DESCRIPTION
This module contains miscillaneous functions used by Testopia.
It exports all of these functions using Exporter.
=cut
package Bugzilla::Testopia::Util;
use strict;
use base qw(Exporter);
@Bugzilla::Testopia::Util::EXPORT = qw(get_product_plans get_product_components
can_view_product GetProducts
get_field_id get_time_stamp
validate_test_id validate_selection
validate_version);
use Bugzilla;
use Bugzilla::Config;
use Bugzilla::Error;
use Bugzilla::Constants;
use Bugzilla::Util;
use Bugzilla::Testopia::TestPlan;
### Methods ###
sub get_product_plans {
my ($product_id) = @_;
my $dbh = Bugzilla->dbh;
my @testplans;
my $col = $dbh->selectcol_arrayref("SELECT plan_id
FROM test_plans
WHERE product_id=?",
undef,$product_id);
foreach my $plan_id (@{$col}){
push @testplans, Bugzilla::Testopia::TestPlan->new($plan_id);
}
return \@testplans;
}
sub get_product_components {
my ($product_id) = @_;
my $dbh = Bugzilla->dbh;
my $components = $dbh->selectcol_arrayref("SELECT name FROM components
WHERE product_id=?", undef, $product_id);
return $components;
}
=head2 can_view_product
Returns true if the logged in user has rights to edit bugs and
by extension, test plans in a prodcut.
=cut
# Code adapted from GetSelectableProducts:
sub can_view_product {
my $dbh = Bugzilla->dbh;
my ($product_id) = @_;
my $query = "SELECT 1 " .
"FROM products " .
"LEFT JOIN group_control_map " .
"ON group_control_map.product_id = products.id ";
if (Param('useentrygroupdefault')) {
$query .= "AND group_control_map.entry != 0 ";
} else {
$query .= "AND group_control_map.membercontrol = " .
CONTROLMAPMANDATORY . " ";
}
if (%{Bugzilla->user->groups}) {
$query .= "AND group_id NOT IN(" .
join(',', values(%{Bugzilla->user->groups})) . ") ";
}
$query .= "WHERE group_id IS NULL AND products.id= ?";
my ($canedit) = $dbh->selectrow_array($query,undef,$product_id);
return $canedit;
}
=head2 get_field_id
Takes a field name and table and returns the fieldid from the
test_fielddefs table.
=cut
sub get_field_id {
my ($field, $table) = @_;
my $dbh = Bugzilla->dbh;
my ($field_id) = $dbh->selectrow_array(
"SELECT fieldid
FROM test_fielddefs
WHERE name = ? AND table_name = ?",
undef, $field, $table);
return $field_id;
}
=head2 get_time_stamp
Returns an SQL timestamp
=cut
sub get_time_stamp {
my $dbh = Bugzilla->dbh;
my ($timestamp) = $dbh->selectrow_array("SELECT NOW()");
return $timestamp;
}
=head2 tc_alias_to_id
Takes a test case alias and returns the corresponding ID
=cut
sub tc_alias_to_id {
my ($alias) = @_;
my $dbh = Bugzilla->dbh;
trick_taint($alias);
return $dbh->selectrow_array(
"SELECT case_id FROM test_cases WHERE alias = ?", undef, $alias);
}
=head2 validate_test_id
Takes an ID and a Testopia type and validates it against the database.
In the case of cases it will validate and return an ID from an alias.
Much of this was taken from Bugzilla. This function assumes all tables
in the database are named test_<object>s
=cut
sub validate_test_id {
my $dbh = Bugzilla->dbh;
my ($id, $type) = @_;
$id = trim($id);
# If the ID isn't a number, it might be an alias, so try to convert it.
my $alias = $id;
if (!detaint_natural($id) && $type eq 'case') {
$id = tc_alias_to_id($alias);
$id || ThrowUserError("testopia-invalid-test-id-or-alias",
{'case_id' => $alias});
}
# Modify the calling code's original variable to contain the trimmed,
# converted-from-alias ID.
$_[0] = $id;
# First check that the object exists
my ($res) = $dbh->selectrow_array("SELECT ". $type. "_id FROM test_". $type."s
WHERE ". $type ."_id=?",undef, $id);
$res
|| ThrowUserError("invalid-test-id-non-existent",
{'id' => $alias, 'type' => $type});
return $res;
}
=head2 validate_selection
Checks that the selected option is a valid one
=cut
sub validate_selection {
my $dbh = Bugzilla->dbh;
my ($id, $field, $table) = @_;
$id = trim($id);
# First check that the object exists taint check should have been
# done before calling this function.
my ($res) = $dbh->selectrow_array(
"SELECT $field
FROM $table
WHERE $field = ?",
undef, $id);
$res
|| ThrowUserError("invalid-test-id-non-existent",
{'id' => $id, 'type' => $table});
return $res;
}
sub validate_version {
my $dbh = Bugzilla->dbh;
my ($version, $product) = @_;
# First check that the object exists.
# Taint check should have been done before calling this function.
my ($res) = $dbh->selectrow_array(
"SELECT 1
FROM versions
WHERE product_id = ?",
undef, $product);
# If the version does not match the product return the first one
# that does
unless ($res){
($res) = $dbh->selectrow_array(
"SELECT value
FROM versions
WHERE product_id = ?",
undef, $product);
}
return $res;
}
=head1 AUTHOR
Greg Hendricks <ghendricks@novell.com>
=cut
1;

View File

@@ -1,5 +0,0 @@
[%# 1.0@bugzilla.org %]
[% IF caserun_id %]
<a href="tr_show_caserun.cgi?caserun_id=[% caserun_id FILTER url_quote %]">Back to test case-run.</a>
[% END %]

View File

@@ -1,5 +0,0 @@
[%# 1.0@bugzilla.org %]
[% IF caserun_id %]
<input type="hidden" name="caserun_id" value="[% caserun_id FILTER none %]" />
[% END %]

View File

@@ -1,5 +0,0 @@
[%# 1.0@bugzilla.org %]
[% IF caserun %]
<h4 style="color:#C00;">[% terms.Bug %] attached to <a href="tr_show_caserun.cgi?caserun_id=[% caserun.id FILTER none %]">Test case-run</a></h4>
[% END %]

View File

@@ -1,4 +0,0 @@
[%# 1.0@bugzilla.org %]
&nbsp; | &nbsp;
<a href="tr_list_caseruns.cgi?bug_id=[% bug.bug_id FILTER none %]&current_tab=case_run">View [% terms.Bug %] Test Case Runs</a>

View File

@@ -1,6 +0,0 @@
[%# 1.0@bugzilla.org %]
[% IF caserun_id %]
<br />
<a href="tr_show_caserun.cgi?caserun_id=[% caserun_id FILTER url_quote %]">Back to test case-run.</a>
[% END %]

View File

@@ -1,2 +0,0 @@
<a href="http://www.mozilla.org/projects/testopia"><span>Testopia</span></a>
<span>Version 1.0 BETA</span>

View File

@@ -1,61 +0,0 @@
[%# 1.0@bugzilla.org %]
[% IF plan_id %]
[% plan_id = plan_id %]
[% ELSIF plan %]
[% plan_id = plan.id %]
[% ELSIF case %]
[% plan_id = case.plan.0.id %]
[% ELSIF run %]
[% plan_id = run.plan_id %]
[% ELSIF caserun %]
[% plan_id = caserun.run.plan_id %]
[% END %]
<div id="links-saved" class="leadcopy">
<div class="label">
Testopia:
</div>
<div class="links">
<a href="tr_new_plan.cgi">New Plan</a>&nbsp;|&nbsp;
<a href="tr_new_case.cgi?plan_id=[% plan_id FILTER none %]">New Case</a>&nbsp;|&nbsp;
<a href="tr_new_run.cgi?plan_id=[% plan_id FILTER none %]">New Run</a>&nbsp;|&nbsp;
<a href="tr_list_runs.cgi?current_tab=run&run_status=0">Current Runs</a>&nbsp;|&nbsp;
<a href="tr_environment.cgi">Environments</a>&nbsp;|&nbsp;
<table border="0">
<tr>
<td>
<form action="tr_show_case.cgi">
Test Case #
<input name="case_id" size="5" class="txt"/>
<input type="submit" value="Find" class="btn"/>
</form>
</td><td>
<form action="tr_show_run.cgi">
Test Run #
<input name="run_id" size="5" class="txt"/>
<input type="submit" value="Find" class="btn"/>
</form>
</td><td>
<form action="tr_show_plan.cgi">
Test Plan #
<input name="plan_id" size="5" class="txt"/>
<input type="submit" value="Find" class="btn"/>
</form>
</td><td>
<form action="tr_tags.cgi">
Tag
<input name="tag" size="5" class="txt"/>
<input type="submit" value="Find" class="btn"/>
</form>
</td>
</tr>
</table>
<a href="tr_query.cgi">Search</a>&nbsp;|&nbsp;
[% IF user.login %]
<a href="tr_list_plans.cgi?current_tab=plan&name_type=allwordssubstr&name=&plan_text_type=allwordssubstr&plan_text=&tag_type=allwords&tags=&author_type=exact&author=[% user.login FILTER url_quote %]&editor_type=exact&editor=&plan_id=">My Plans</a>&nbsp;|&nbsp;
<a href="tr_list_cases.cgi?current_tab=case&summary_type=allwordssubstr&summary=&tcaction_type=allwordssubstr&tcaction=&tceffect_type=allwordssubstr&tceffect=&script_type=allwordssubstr&script=&requirement_type=allwordssubstr&requirement=&tag_type=allwords&tags=&author_type=exact&author=&default_tester_type=substring&default_tester=[% user.login FILTER url_quote %]&case_id=&plan_id=">My Cases</a>&nbsp;|&nbsp;
<a href="tr_list_runs.cgi?current_tab=run&summary_type=allwordssubstr&summary=&notes_type=allwordssubstr&notes=&environment_type=allwordssubstr&environment=&tag_type=allwords&tag=&manager_type=substring&manager=[% user.login FILTER url_quote %]&run_id=&plan_id=">My Runs</a>&nbsp;|&nbsp;
[% END %]
<a href="testopia/doc/Manual.pdf" target="_blank">Help</a>&nbsp;|&nbsp;
</div>
</div>

View File

@@ -1,113 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[% IF error == "testopia-permission-denied" %]
[% title = "Insufficient Permissions" %]
You are not authorized to view this [% object FILTER html %]
[% ELSIF error == "testopia-read-only" %]
[% title = "Insufficient Permissions" %]
You are not authorized to edit this [% object FILTER html %]
[% ELSIF error == "testopia-no-delete" %]
[% title = "Insufficient Permissions" %]
You are not authorized to delete this [% object FILTER html %]
If you are the administrator, you can check that your installation
allows deletion of Testopia objects in the
<a href="editparams.cgi">paramaters </a>.
[% ELSIF error == "testopia-create-denied" %]
[% title = "Cannot Create Object" %]
You do not have sufficient rights to create new [% object FILTER html %]s.
[% ELSIF error == "testopia-missing-parameter" %]
[% title = "Missing Parameter" %]
Missing required parameter [% param FILTER html %]
[% ELSIF error == "testopia-non-zero-case-count" %]
[% title = "Category Has Test Cases" %]
You have attempted to delete a category that still has test cases
associated with it.
Please move the test cases to another category first.
[% ELSIF error == "testopia-non-zero-run-count" %]
[% title = "$object Has Test Runs" %]
You have attempted to delete a [% object FILTER html %] that has test runs
associated with it.
[% ELSIF error == "testopia-non-zero-case-run-count" %]
[% title = "Build Has Case Runs" %]
You have attempted to delete a build that still has test case runs
associated with it. This is historical data and should not be removed.
[% ELSIF error == "testopia-incorrect-plan" %]
[% title = "Plan mismatch" %]
You have attempted to modify a category that does not belong to this plan.
[% ELSIF error == "testopia-missing-attachment-key" %]
[% title = "Missing Key" %]
You have requested to save an attachment, but I didn't see which test plan
or test case you had in mind to store it with.
[% ELSIF error == "testopia-invalid-test-id-or-alias" %]
[% title = "Invalid ID or Alias" %]
The test case you entered does not exist.
[% ELSIF error == "invalid-test-id-non-existent" %]
[% title = "Invalid ID" %]
[% IF type == 'case_run' %]
The specified case-run does not exist.
[% ELSE %]
Test [% type FILTER html %]&nbsp;[% id FILTER html %] does not exist.
[% END %]
[% ELSIF error == "testopia-name-not-unique" %]
[% title = "Name Must be Unique" %]
The name you chose, [% name FILTER html %], for this
[% object FILTER html %] must be unique. Another [% object FILTER html %]
of the same name already exists. Please choose a different one.
[% ELSIF error == 'testopia-create-category' %]
[% title = "No Categories Defined" %]
No categories have been created for this product yet.
[% IF plan %]
You can create categories <a href="tr_categories.cgi?plan_id=[% plan.id FILTER none %]">
here</a>.
[% END %]
[% ELSIF error == "testopia-create-build" %]
[% title = "No Builds Defined" %]
No builds have been created for this product yet.
[% IF plan %]
You can create builds <a href="tr_builds.cgi?plan_id=[% plan.id FILTER none %]">
here</a>.
[% END %]
[% ELSIF error == "testopia-create-environment" %]
[% title = "No Environments Defined" %]
No environments have been created yet.
You can create environments <a href="tr_environment.cgi">here</a>.
[% ELSIF error == "testopia-missing-required-field" %]
[% title = "Missing Required Field" %]
It seems there was no value entered for [% field FILTER none %].
[% ELSIF error == "testopia-missing-plans-list" %]
[% title = "Plan list missing" %]
Somehow the list of plans associated with the test case to be cloned is missing.
Please try again.
[% ELSIF error == "testopia-unkown-object" %]
[% title = "Unkown Object" %]
Attempted to attach tags to something other than a Test Plan, Test Case or Test Run.
[% ELSIF error == "testiopia-alias-exists" %]
[% title = "Alias Unavailable" %]
The alias '[% alias FILTER html %]' is already in use by another test case, please
select another one.
[% ELSIF error == "testiopia-invalid-data" %]
[% title = "Invalid Option Selected" %]
The field [% field FILTER none %] has and invalid value of [% value FILTER html %]
[% ELSIF error == "testopia-none-selected" %]
[% title = "Nothing Selected" %]
You did not select any [% object FILTER none %]s to change.
[% END %]

View File

@@ -1,23 +0,0 @@
[%# 1.0@bugzilla.org %]
<hr />
<a name="testopia" />
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr valign="TOP">
<td width="128">
<p><img
src="testopia/img/testopia_city_128.png"
width="128" height="128" border="0" alt="Testopia"><br>
</p>
</td>
<td>
<p><b>Testopia</b> choices:</p>
<p><a href="tr_list_runs.cgi?current_tab=run&run_status=0">Do some testing</a><br>
<a href="tr_query.cgi?current_tab=plan">Manage test plans</a><br>
<a href="tr_query.cgi?current_tab=case">Search existing test cases</a><br>
<a href="tr_environment.cgi">Manage run environments</a></p>
</td>
</tr>
</table>
<hr />
<br />

View File

@@ -1,3 +0,0 @@
[%# 1.0@bugzilla.org %]
<!-- <a href="tr_buglist_to_plan.cgi">Add [% terms.bugs %] to test plan</a> | -->

View File

@@ -1,38 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Gervase Markham <gerv@gerv.net>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS global/header.html.tmpl
title = "Search by Attachment Number"
%]
<form method="get" action="tr_attachment.cgi">
<p>
You may find an attachment by entering its id here:
<input name="attach_id" size="6" />
<input type="hidden" name="action" value="edit" />
<input type="submit" value="Show Me This Attachment" />
</p>
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,52 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% IF attachment.case_id %]
[% SET item = "Test Case $attachment.case_id" %]
[% ELSE %]
[% SET item = "Test Plan $attachment.plan_id" %]
[% END %]
[% title = "Delete Attachment $attachment.description for $item" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
You are about to permanantly delete this attachment.
<form method="POST" action="tr_attachment.cgi">
<input type="hidden" name="action" value="do_delete" />
<input type="hidden" name="attach_id" value="[% attachment.id FILTER none %]" />
<input type="submit" value="Continue" />
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,102 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% IF attachment.case_id %]
[% SET item = "Test Case $attachment.case_id" %]
[% ELSE %]
[% SET item = "Test Plan $attachment.plan_id" %]
[% END %]
[% title = "Edit Attachment $attachment.description for $item" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
<p><a href="[% attachment.plan_id ? "tr_show_plan.cgi?plan_id=$attachment.plan_id" : "tr_show_case.cgi?case_id=$attachment.case_id" %]">Back</a> to [% attachment.plan_id ? "test plan" : "test case" %]</p>
<form method="POST" action="tr_attachment.cgi">
<input type="hidden" name="action" value="do_edit" />
<input type="hidden" name="attach_id" value="[% attachment.id FILTER none %]" />
<table border="0">
<tr>
<th class="bz_row_header" align="right">Description:</th>
<td colspan="3"><input name="description" value="[% attachment.description %]" size="30" /></td>
</tr>
<tr>
<th class="bz_row_header" align="right">Filename:</th>
<td><input name="filename" value="[% attachment.filename %]" size="30" /></td>
<th class="bz_row_header" align="right">Mime Type:</th>
<td><input name="mime_type" value="[% attachment.mime_type %]" size="30" /></td>
</tr>
<tr>
<td colspan="4">
<table width="100%">
<tr class="bz_row_header">
<th>Submitter</th>
<th>Created</th>
<th>Size</th>
</tr>
<tr>
<td>[% attachment.submitter.identity FILTER html %]</td>
<td>[% attachment.creation_ts FILTER time %]</td>
<td>[% attachment.datasize FILTER unitconvert %]</td>
</tr>
</table>
</td>
</tr>
<tr>
[% IF isviewable %]
<td colspan="4" width="75%">
<iframe id="viewFrame" src="tr_attachment.cgi?attach_id=[% attachment.id FILTER none %]&action=view" style="height: 400px; width: 100%;">
<b>You cannot view the attachment while editing it because your browser does not support IFRAMEs.
<a href="tr_attachment.cgi?attach_id=[% attachment.id FILTER none %]&action=view">View the attachment on a separate page</a>.</b>
</iframe>
[% ELSE %]
<td colspan="4" >
<div style="margin:20px; padding: 5px; border: solid 1px #000; font-weight: bold;">
This attachment is not viewable in your browser because its MIME type
(<span style="color: #990000;">[% attachment.mime_type FILTER html %]</span>)
is not one that your browser is able to display.
<p>
You can however, <a href="tr_attachment.cgi?attach_id=[% attachment.id FILTER none %]&action=view">download the attachment</a>.
</p>
</div>
</td>
[% END %]
</tr>
</table>
<input type="submit" value="Submit">
</form>
[% IF Param("allow-test-deletion") %]
<p><a href="tr_attachment.cgi?attach_id=[% attachment.id FILTER none %]&action=delete">Delete Attachment</a></p>
<p><a href="[% attachment.plan_id ? "tr_show_plan.cgi?plan_id=$attachment.plan_id" : "tr_show_case.cgi?case_id=$attachment.case_id" %]">Back</a> to [% attachment.plan_id ? "test plan" : "test case" %]</p>
[% END %]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,56 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
<table width="100%">
<tr class="bz_row_header">
<th>Attachment</th>
<th>Submitter</th>
<th>Type</th>
<th>Created</th>
<th>Size</th>
<th>Actions</th>
</tr>
[% FOREACH a = item.attachments %]
<tr>
<td><a href="tr_attachment.cgi?attach_id=[% a.id FILTER none %]&action=view">[% a.description FILTER html %]</a></td>
<td>[% a.submitter.login FILTER html %]</td>
<td>[% a.mime_type FILTER html %]</td>
<td>[% a.creation_ts FILTER time %]</td>
<td>[% a.datasize FILTER unitconvert %]</td>
<td><a href="tr_attachment.cgi?attach_id=[% a.id FILTER none %]&action=edit">Edit</a>
[% IF Param("allow-test-deletion") %]<a href="tr_attachment.cgi?attach_id=[% a.id FILTER none %]&action=delete">Delete</a>[% END %]</td>
</tr>
[% END %]
<input type="hidden" name="[% type FILTER none %]_id" value="[% item.id FILTER none %]">
<table border="0" width="100%" style="border: 1px solid #000;">
<tr>
<th align="right">File</td>
<td><input name="data" type="file"></td>
<th align="right">Description:</td>
<td><input name="description"></td>
<td align="right">
<input type="submit" name="action" value="Attach"></td>
</tr>
</table>

View File

@@ -1,83 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%############################################################################%]
[%# Block for SELECT fields #%]
[%############################################################################%]
[% BLOCK select %]
<label for="[% sel.name %]" accesskey="[% sel.accesskey %]"></label>
<select name="[% sel.name %]" id="[% sel.name %]"
[%- "multiple=\"multiple\"" IF sel.mult %]
[%- "size=\"$sel.elements\"" IF sel.elements %]
[%- sel.events IF sel.events %]
[%- sel.style IF sel.style %]>
[% FOREACH item = sel.list %]
<option value="[% item.id FILTER html %]" [% 'selected="selected"' IF (sel.default == item.name) || (sel.default == item.id || sel.default == 'all') %][% 'selected="selected"' IF (sel.deflist == 1 AND lsearch(sel.default, item.id)> -1) %]>
[% item.name FILTER html %]</option>
[% END %]
</select>
[% END %]
[% BLOCK navigation %]
[% IF ajax %]
[% url = "javascript:page(" %]
[% pc = ")" %]
[% ELSE %]
[% url = "$table.get_page_url&page="%]
[%# url = "$table.url_loc?direction=$direction&getlist=1&page="%]
[% END %]
<table align="center">
<tr>
[% IF table.page != 0 %]
<td><a href="[% url %]0[% pc %]">&lt;&lt;&nbsp;First</a></td>
<td><a href="[% url %][% table.page - 1 %][% pc %]">&lt;&nbsp;Previous</a></td>
[% ELSE %]
<td>&lt;&lt;&nbsp;First</td>
<td>&lt;&nbsp;Previous</td>
[% END %]
<td align="center">
[% SET p = 0 %]
[% WHILE p <= table.page_count - 1 %]
[% IF p != table.page %]
<a href="[% url %][% p %][% pc %]">[% p + 1 %]</a>&nbsp;
[% ELSE %]
[% p + 1 %]
[% END %]
[% p = p + 1 %]
[% END %]
[% IF ajax %]
<a href="[% url %]null,1[% pc %]">All</a>&nbsp;
[% ELSE %]
<a href="[% url %]&viewall=1">All</a>&nbsp;
[% END %]
</td>
[% IF table.page < table.page_count - 1 %]
<td><a href="[% url %][% table.page + 1 %][% pc %]">Next&nbsp;&gt;</a></td>
<td><a href="[% url %][% table.page_count - 1 %][% pc %]">Last&nbsp;&gt;&gt;</a></td>
[% ELSE %]
<td>Next&nbsp;&gt;</td>
<td>Last&nbsp;&gt;&gt;</td>
[% END %]
</tr>
</table>
[% END %]

View File

@@ -1,54 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/header.html.tmpl
title = "Delete Category $build.name From Plan $plan.name"
%]
<form method="POST" action="tr_builds.cgi">
<input type="HIDDEN" name="action" value="do_delete">
<input type="HIDDEN" name="build_id" value="[% build.id FILTER none %]">
<input type="hidden" name="plan_id" value="[% plan.id FILTER none %]">
[% IF build.case_run_count %]
<table style="border-collapse:collapse;" border="1" bordercolor="red" width="100%" cellspacing="0" cellpadding="6"><tr><td>
<font color="red">
This build is used by [% build.case_run_count FILTER html %] test case runs.<br>.
It cannot be deleted.<br>
<p>Please press your browsers back button to return to your test plan.</p>
[% tr_error %]</font>
</td></tr></table>
[% ELSE %]
You are about to delete build '[% build.name FILTER html %]' from test plan
[% plan.name FILTER html %]. <br>
<p>
<b>Are you sure?</b>
</p>
<input type="SUBMIT" value="Delete"/>
[% END %]
</form>
<p>
<a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">Back</a> to test plan or
<a href="tr_builds.cgi?plan_id=[% plan.id FILTER none %]">edit</a> builds
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,53 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
<form method="POST" action="tr_builds.cgi" name="form">
<input type="HIDDEN" name="action" value="[% action FILTER none %]"/>
<input type="HIDDEN" name="plan_id" value="[% plan.id FILTER none %]"/>
<input type="hidden" name="build_id" value="[% build.id FILTER none %]"/>
<table border="0" cellpadding="2" cellspacing="0">
<tr>
<th align="right" valign="top">Build Name: </th>
<td><input size="40" name="name" value="[% build.name FILTER none %]"/></td>
</tr>
<tr>
<th align="right" valign="top">Milestone: </th>
<td>[% PROCESS select sel = { name => 'milestone',
accesskey => 'm',
list => plan.get_product_milestones
default => build.milestone } %]
</td>
</tr>
<tr>
<th align="right" valign="top">Build Description: </th>
<td> <textarea rows="10" cols="70" name="desc">[% build.description FILTER none %]</textarea><br> </td>
</tr>
</table>
<input type="submit" value="Submit">
</form>
<p>
<a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">Back</a> to test plan or
<a href="tr_builds.cgi?plan_id=[% plan.id FILTER none %]">edit</a> builds
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,56 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/header.html.tmpl
title = "Product Builds for $plan.product_name"
%]
<table>
<tr>
<th class="bz_row_header" align="right">Name</th>
<th class="bz_row_header" align="right">Milestone</th>
<th class="bz_row_header" align="right">Description</th>
<th class="bz_row_header" align="right">Actions</th>
</tr>
[% FOREACH cat = plan.builds %]
<tr>
<td valign="top">[% cat.name FILTER html %]</td>
<td valign="top">[% cat.milestone FILTER html %]</td>
<td valign="top">[% cat.description FILTER html %]</td>
<td valign="top">
<a href="tr_builds.cgi?action=edit&amp;build_id=[% cat.id FILTER none %]&amp;plan_id=[% plan.id FILTER none %]">Edit</a>
[% IF plan.candelete %]
&nbsp;|&nbsp;
<a href="tr_builds.cgi?action=delete&amp;build_id=[% cat.id FILTER none %]&amp;plan_id=[% plan.id FILTER none %]">Delete</a>
[% END %]
</td>
</tr>
[% END %]
</table>
<br>
[% IF plan.canedit %]
<a href="tr_builds.cgi?action=add&amp;plan_id=[% plan.id FILTER none %]">Add new</a>
[% END %]
<p>
<a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">Back</a> to test plan
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,57 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% title = "Create a New Test Case" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = title
style = style
%]
<script src="testopia/dojo-ajax/dojo.js" type="text/javascript"></script>
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<form method="POST" action="[% form_action %]">
<h3>Link to Selected Plans</h3>
<table>
[% FOREACH plan = case.plans %]
<tr>
<td><input type="checkbox" name="plan_id" value="[% plan.id FILTER none %]" checked="checked"></td>
<td>[% plan.name FILTER html %]</td>
</tr>
[% END %]
</table>
<br/>
<h3>Attributes</h3>
[% PROCESS testopia/case/form.html.tmpl %]
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,56 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<script src="testopia/js/util.js" type="text/javascript"></script>
<p>The following special symbols are available:
<ul><li><b>%id%</b> gets replaced by the bug's id.</li>
<li><b>%description%</b> gets replaced by the bug's description.</li>
</ul></p>
<hr/>
[% PROCESS testopia/case/form.html.tmpl %]
<p>
Back to <A HREF="buglist.cgi?regetlastlist=1">[% terms.bug %] list</a>
or <A HREF="tr_buglist_to_plan.cgi[% '?run_id=$run.id' IF run %]">select</A> another plan
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,66 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = title
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% UNLESS tr_error %]
<FORM METHOD="POST" ACTION="tr_buglist_to_plan.cgi">
<INPUT TYPE="HIDDEN" NAME="form_action" VALUE="add">
<INPUT TYPE="HIDDEN" NAME="run_id" VALUE="$run_id">
<p><b>Select a test plan:</b>&nbsp;&nbsp;
<select name="plan_id" id="plan_id">
[% FOREACH plan = plans %]
<option value="[% plan.plan_id FILTER none %]">[% plan.name FILTER html %]</option>
[% END %]
</select>
</p>
<p><INPUT TYPE="submit" VALUE="Continue >>"></p>
</FORM>
[% END %]
<p>
[% IF $run_id %]
Back to <A HREF="tr_testrun_regression.cgi?run_id=[% run_id FILTER none %]">test run regression test cases</a>
[% ELSE %]
Back to <A HREF="buglist.cgi?regetlastlist=1">[% terms.bug %] list</a>
[% END %]
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,37 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Gervase Markham <gerv@gerv.net>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS global/header.html.tmpl
title = "Search by Test Case Number"
%]
<form method="get" action="tr_show_case.cgi">
<p>
You may find a test case by entering its id here:
<input name="case_id" size="6">
<input type="submit" value="Show Me This Test Case">
</p>
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,113 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% SET title = "Clone Test Case: $case.summary" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
<form action="tr_show_case.cgi" method="POST">
<input type="hidden" name="case_id" value="[% case.id FILTER none %]">
<input type="hidden" name="action" value="do_clone">
<table>
<tr BGCOLOR="lightyellow">
<td COLSPAN=2><FONT SIZE=+1>Select Clone Options</FONT></TD>
</tr>
<tr>
<td align="left">Create a Copy
<input type="radio" name="copymethod" value="copy" checked="checked"></td>
</tr>
<tr>
<td>
<table style="border: solid 1px #000;">
<tr>
<td align="right">Copy to Existing Plans</td>
<td><input type="checkbox" name="existing" value="1" checked="checked"></td>
</tr>
<tr>
<td align="right">Copy to Additional Plans</td>
<td><input name="newplans"></td>
</tr>
<tr>
<td/>
<td align="left">(comma-separated list of plan IDs)</td>
</tr>
<tr>
<td align="right">Copy Document</td>
<td><input type="radio" name="copy_doc" value="1" checked="checked">Yes <input type="radio" name="copy_doc" value="0">No</td>
</tr>
<tr>
<td align="right">Copy Tags</td>
<td><input type="radio" name="copy_tags" value="1" checked="checked">Yes <input type="radio" name="copy_tags" value="0">No</td>
</tr>
<tr>
<td align="right">Copy Components</td>
<td><input type="radio" name="copy_comps" value="1" checked="checked">Yes <input type="radio" name="copy_comps" value="0">No</td>
</tr>
<tr>
<td></td>
<td></td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="left">Create a Link
<input type="radio" name="copymethod" value="link"></td>
</tr>
<tr>
<td>
<table style="border: solid 1px #000;" width="100%">
<tr>
<td align="right">Link to Plans</td>
<td><input name="linkplans"></td>
</tr>
<tr>
<td/>
<td align="left">(comma-separated list of plan IDs)</td>
</tr>
</table>
</td>
</tr>
</table>
<input TYPE="SUBMIT" VALUE="Clone">
</form>
<p>
<A HREF="tr_show_case.cgi?case_id=[% case.id FILTER none %]">Back</A> to test case
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,195 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[% IF case.canedit %]
<script type="text/javascript">
function updateScript() {
var rm = document.getElementById('isautomated').value;
var o;
o = document.getElementById('script');
if (o) {
o.disabled = (rm != 1);
}
o = document.getElementById('arguments');
if (o) {
o.disabled = (rm != 1);
}
}
dojo.require("dojo.widget.Editor");
</script>
[% END %]
<a name="attributes"></a>
<input type="hidden" name="case_id" value="[% case.id FILTER none %]"/>
<table border="0">
<tr><td>
<table border="0">
<tr>
<td valign="top" align="right"><b>Summary</b></td>
<td colspan="3"><input name="summary" size="80" value="[% case.summary FILTER none %]"></td>
</tr>
<tr>
<td align="right"><b>Default Tester</b></td>
<td><input name="tester" size="30" value="[% case.default_tester.login ? case.default_tester.login : user.login FILTER html %]" /></td>
<td align="right"><b>Add Tags</b></td>
<td><input name="addtags" size="30" /></td>
</tr>
<tr>
<td align="right"><b>Alias</b></td>
<td><input name="alias" size="30" value="[% case.alias FILTER none %]"></td>
<td align="right"><b>Requirement:</b></td>
<td><input name="requirement" size="30" value="[% case.requirement FILTER none %]"></td>
</tr>
<tr>
<td align="right"><b>Status</b></td>
<td>
[% IF action == 'Add' %]
[% status_default = Param('default-test-case-status') %]
[% ELSE %]
[% status_default = case.status %]
[% END %]
[% PROCESS select sel = { name => 'status',
accesskey => 's',
list => case.get_status_list
default => status_default } %]
</td>
<td align="right"><b>Automatic</b></td>
<td><select name="isautomated" id="isautomated" onchange="updateScript();">
<option value="0">Manual</option>
<option value="1" [% 'selected' IF case.isautomated %]>Automatic</option>
</select>
</td>
</tr>
<tr>
<td align="right"><b>Priority<b></b></b></td>
<td>
[% PROCESS select sel = { name => 'priority',
accesskey => 'p',
list => case.get_priority_list
default => case.priority ? case.priority : Param('defaultpriority')} %]
</td>
<td align="right"><b>Script</b></td>
<td><input name="script" id="script" value="[% case.script FILTER none %]" [%- 'disabled="disabled"' IF NOT case.isautomated %]></td>
</tr>
<tr>
<td align="right"><b><a href="tr_categories.cgi?plan_id=[% case.plans.0.id %]">Category</a></b></td>
<td>
[% PROCESS select sel = { name => 'category',
accesskey => 'c',
list => case.get_category_list
default => case.category.name } %]
</td>
<td align="right"><b>Arguments:</b></td>
<td><input name="arguments" id="arguments" value="[% case.arguments FILTER none %]" [%- 'disabled="disabled"' IF NOT case.isautomated %]></td>
</tr>
</table>
</td>
[% IF action == "Add" %]
<td valign="top"><b>Components</b><br/>
[% comps = [] %]
[% FOREACH c = case.components %]
[% comps.push(c.id) %]
[% END %]
[% PROCESS select sel = { name => 'components',
accesskey => 'c',
list => case.get_selectable_components(1)
default => comps
mult => 1
deflist => 1
elements => 7 } %]
</td>
[% END %]
</tr>
</table>
<p align="right">
<input type="SUBMIT" name="action" class="tr_button" value="[% action FILTER html %]">
</p>
<br><br>
<h3>Dependencies</h3>
<table align="center">
<tr>
<th> Depends on </th>
<th> Blocks </th>
</tr>
<tr>
<td>
[% FOREACH dep = case.dependson %]
<a href="tr_show_case.cgi?case_id=[% dep.id FILTER none %]" title="[% dep.summary %]">[% dep.id FILTER none %]</a>
[% END %]
</td>
<td>
[% FOREACH dep = case.blocked %]
<a href="tr_show_case.cgi?case_id=[% dep.id FILTER none %]" title="[% dep.summary %]">[% dep.id FILTER none %]</a>
[% END %]
</td>
</tr>
<tr>
<td> <input name="tcdependson" size="30" value="[% case.dependson_list %]"> </td>
<td> <input name="tcblocks" size="30" value="[% case.blocked_list %]"> </td>
</tr>
<tr>
<td>
<!--
<a href="tr_showdependencytree.cgi?case_id=[% case.id FILTER none %]">Show dependency tree</a>
-->
</td>
<td>
<!--
[% IF Param('webdotbase') %]
<a href="tr_showdependencygraph.cgi?case_id=[% case.id FILTER none %]">Show dependency graph</a>
[% END %]
-->
</td>
</tr>
</table>
[%# action, effect %]
<h3>Action</h3>
<div id="case_docs" style="border: 1px solid #000000; padding-bottom: 5px;">
<textarea cols="80" rows="25" dojotype="Editor"
items="blockGroup;|;textGroup;|;justifyGroup;|;colorGroup;|;listGroup;|;indentGroup;|;linkGroup;"
id="effect" name="tcaction" style="cursor:text;">
[% case.text.action %]</textarea>
</div>
<br><br>
<h3>Expected Results</h3>
<div style="border: 1px solid #000000; padding-bottom: 5px;">
<textarea cols="80" rows="25" dojotype="Editor"
items="blockGroup;|;textGroup;|;justifyGroup;|;colorGroup;|;listGroup;|;indentGroup;|;linkGroup;"
id="effect" name="tceffect" style="cursor:text;">
[% case.text.effect %]</textarea>
</div>
<p align="right">
<input type="SUBMIT" name="action" class="tr_button" value="[% action FILTER html %]">
</p>

View File

@@ -1,116 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Case History for Case $case.id: $case.summary" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<table border=0>
<tr class="bz_row_header">
<th>Who</th>
<th>When</th>
<th>What</th>
<th>Old Value</th>
<th>New Value</th>
</tr>
[% FOREACH row = case.history %]
<tr class="[% loop.count % 2 == 0 ? 'bz_row_odd' : 'bz_row_even' %]">
<td><a href="mailto:[% row.who %]">[% row.who FILTER html %]</a></td>
<td>[% row.changed FILTER time %]</td>
<td>[% row.what FILTER html %]</td>
<td>[% row.oldvalue FILTER html %]</td>
<td>[% row.newvalue FILTER html %]</td>
</tr>
[% END %]
</table>
<br><br>
<h3>Diff Case Document</h3>
<form action="tr_show_case.cgi">
<input type="hidden" name="action" value="History" />
<input type="hidden" name="case_id" value="[% case.id FILTER none %]" />
<table>
<tr>
<th colspan="5" class="bz_row_header">Diff Versions</th>
</tr>
<tr>
<td><input type="submit" value="Compare"/></td>
<td>Version:</td>
<td>
<select name="new">
[% i = 1 %]
[% WHILE i <= case.version %]
<option value="[% i %]" [% 'selected="selected"' IF i == new %]>[% i %]</option>
[% i = i +1 %]
[% END %]
</select>
</td>
<td>Version:</td>
<td>
<select name="old">
[% i = 1 %]
[% WHILE i <= case.version %]
<option value="[% i %]" [% 'selected="selected"' IF i == old %]>[% i %]</option>
[% i = i +1 %]
[% END %]
</select>
</td>
</tr>
</table>
<div id="diff">
<br>ACTION<hr>
<div id="case_action">
<pre>
[% diff.action %]
</pre>
</div>
<br>EFFECT<hr>
<div id="case_effect">
<pre>
[% diff.effect %]
</pre>
</div>
</div>
<p>
<a href="tr_show_case.cgi?case_id=[% case.id FILTER none %]">Back to case</a>
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,140 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Cases" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<script src="testopia/js/util.js" type="text/javascript"></script>
<form id="table" action="tr_list_cases.cgi" method="POST">
[% PROCESS testopia/case/table.html.tmpl %]
<p>
[% IF table.list_count == 0 %]
No test cases
[% ELSE %]
[% IF table.list_count == 1 %]
One test case
[% ELSE %]
[% table.list_count FILTER none %] test cases
[% END %]
[% END %]
found.
</p>
[% IF dotweak AND table.list_count %]
<h3>Update Selected Test Cases</h3>
<table border="0">
<tr>
<td align="right"><b>Requirement</b></td>
<td><input name="requirement" value="--Do Not Change--" size="30"></td>
<td align="right"><b>Add Tags</b></td>
<td><input name="addtags" size="30"></td>
</tr>
<tr>
<td align="right"><b>Status</b></td>
<td>
[% PROCESS select sel = { name => 'status',
accesskey => 's',
list => status_list
default => "--Do Not Change--" } %]
</td>
<td align="right"><b>Automatic</b></td>
<td>
<select name="isautomated" id="isautomated">
<option value="-1">--Do Not Change--</option>
<option value="0">Manual</option>
<option value="1">Automatic</option>
</select>
</td>
</tr>
<tr>
<td align="right"><b>Priority<b></td>
<td>
[% PROCESS select sel = { name => 'priority',
accesskey => 'p',
list => priority_list
default => "--Do Not Change--" } %]
</td>
<td align="right"><b>Script</b></td>
<td><input name="script" id="script" size="30" value="--Do Not Change--" /></td>
</tr>
<tr>
<td align="right"><b>Category<b></td>
<td>
[% PROCESS select sel = { name => 'category',
accesskey => 'c',
list => category_list
default => "--Do Not Change--" } %]
</td>
<td align="right"><b>Arguments:</b></td>
<td><input name="arguments" id="arguments" size="30" value="--Do Not Change--" /></td>
</tr>
<tr>
<td align="right"><b>Default Tester<b></td>
<td><input name="tester" value="--Do Not Change--" /></td>
</tr>
<tr>
<th colspan="3">Add selected cases to the following runs
(comma-separated list of ids):</th>
<td><input name="addruns" value="[% addrun FILTER none %]" /></td>
</tr>
</table>
<p align="right">
<input type="hidden" name="getlist" value="1"/>
<input TYPE="SUBMIT" name="action" class="tr_button" VALUE="Commit">
</p>
[% END %]
</form>
[%############################################################################%]
[%# Page Footer #%]
[%############################################################################%]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,67 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Gervase Markham <gerv@gerv.net>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% list = table.get_saved_list('case') %]
<b>Case List:</b>
[% IF table && list > 0 %]
[% curr = lsearch(list, case.id) %]
[% IF curr != -1 && (curr > 0) %]
<a href="tr_show_case.cgi?case_id=[% list.first %]">&lt;&lt;&nbsp;First</a>
[% ELSE %]
<i><font color="#777777">&lt;&lt;First</font></i>
[% END %]
[% IF case %]
[% IF curr != -1 %]
[% IF curr > 0 %]
[% prev = curr - 1 %]
<a href="tr_show_case.cgi?case_id=[% list.$prev %]">&lt;&nbsp;Prev</a>
[% ELSE %]
<i><font color="#777777">Prev</font></i>
[% END %]
[% IF curr != -1 %]
&nbsp;&nbsp;([% curr + 1 %] of [% list.size %])&nbsp;&nbsp;
[% END %]
[% IF curr + 1 < list.size %]
[% next = curr + 1 %]
<a href="tr_show_case.cgi?case_id=[% list.$next %]">Next&nbsp;&gt;</a>
[% ELSE %]
<i><font color="#777777">Next</font></i>
[% END %]
[% END %]
[% ELSE %]
&nbsp;&nbsp;
[% END %]
[% IF curr != -1 && (curr + 1 < list.size) %]
<a href="tr_show_case.cgi?case_id=[% list.last %]">Last&nbsp;&gt;&gt;</a>
[% ELSE %]
<i><font color="#777777">Last&gt;&gt;</font></i>
[% END %]
[% ELSE %]
[%# With no list, don't show link to search results %]
&nbsp;&nbsp;
<i><font color="#777777">No search results available</font></i>
[% END %]

View File

@@ -1,257 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% SET title = "Test Case $case.id: $case.summary" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
<script src="testopia/js/util.js" type="text/javascript"></script>
<script src="testopia/js/tags.js" type="text/javascript"></script>
<script src="testopia/dojo-ajax/dojo.js" type="text/javascript"></script>
<script type="text/javascript">
function addOption(selectElement,newOption) {
try {
selectElement.add(newOption,null);
}
catch (e) {
selectElement.add(newOption,selectElement.length);
}
}
function fillSelects (data){
var xmldocroot = data.documentElement;
var selected = xmldocroot.getElementsByTagName('selected');
var comps = document.getElementById("components");
comps.options.length = 0;
for (i=0; i< selected.length; i++){
var id = selected[i].childNodes[0].firstChild.nodeValue;
var name = selected[i].childNodes[1].firstChild.nodeValue;
var myOp = new Option(name, id);
addOption(comps,myOp);
}
var nonselected = xmldocroot.getElementsByTagName('nonselected');
var pick = document.getElementById("comp_pick");
pick.options.length = 0;
for (i=0; i< nonselected.length; i++){
var id = nonselected[i].childNodes[0].firstChild.nodeValue;
var name = nonselected[i].childNodes[1].firstChild.nodeValue;
var myOp = new Option(name, id);
addOption(pick,myOp);
}
document.getElementById("addComp").disabled = false;
document.getElementById("deleteComp").disabled = false;
}
function updateComponent(comp_id, action){
if (comp_id == 0)
return;
document.getElementById("addComp").disabled = true;
document.getElementById("deleteComp").disabled = true;
dojo.io.bind({
url: "tr_show_case.cgi",
content: { component_id: comp_id, case_id: [% case.id FILTER none %], action: action },
load: function(type, data, evt){ fillSelects(data);},
error: function(type, error){ alert("ERROR");},
mimetype: "text/xml"
});
}
</script>
[% PROCESS testopia/messages.html.tmpl %]
[% PROCESS testopia/case/navigate.html.tmpl %]
[%##### Overview #####%]
[% IF copied %]
<h3>Case copied from test case [% copied.id FILTER none %]</h3>
<a href="tr_show_case.cgi?case_id=[% copied.id FILTER none %]">Back to case [% copied.id FILTER none %]</a>
<br>
[% END %]
<FORM name="TestCaseForm" id="TestCaseForm" method="POST" action="tr_show_case.cgi" enctype="multipart/form-data">
<div id="case_overview">
<h3>Overview</h3>
<table border="0" cellpadding="1" width="100%">
<tbody align="left">
<tr class="bz_row_header">
<th>Alias</th>
<th>Requirement</th>
<th>Created</th>
</tr>
<tr class="bz_row_data">
<td>[% case.alias FILTER html %]</td>
<td>[% case.requirement FILTER html %]</td>
<td>[% case.creation_date FILTER time %]</td>
</tr>
<tr class="bz_row_header">
<th>Author</th>
<th>Case Version</th>
<th>Category</th>
</tr>
<tr class="bz_row_data">
<td>Author <a href="mailto:[% case.author.email FILTER html %]">[% case.author.identity FILTER html %]</a><br>
Default Tester <a href="mailto:[% case.default_tester.email FILTER html %]">[% case.default_tester.identity FILTER html %]</a></td>
<td>[% case.version FILTER html %]</td>
<td>[% case.category.name FILTER html %]</td>
</tr>
<tr class="bz_row_header">
<th>Priority</th>
<th>Status</th>
<th>Automated</th>
</tr>
<tr class="bz_row_data">
<td>[% case.priority FILTER html %]</td>
<td>[% case.status FILTER html %]</td>
<td>[% case.isautomated ? "YES" : "NO" FILTER html %]</td>
</tr>
<tr class="bz_row_header">
<th>Used in Plans</th>
<th>[% terms.Bugs %] Detected</th>
<th>Found in Runs</th>
</tr>
<tr class="bz_row_data">
<td>
[% FOREACH plan = case.plans %]
<a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">[% plan.id FILTER none %]: [% plan.name FILTER html %]</a><br/>
[% END %]
</td>
<td>
[% FOREACH bug_id = case.bugs %]
<a href="show_bug.cgi?id=[% bug.id FILTER none %]">[% bug.id FILTER none %]</a>
[% END %]
</td>
<td>[% case.run_count FILTER none %]</td>
</tr>
<tr class="bz_row_data">
<td colspan="3"><div align="right">
<a href="#attributes">Edit Case Attributes</a>
<input type="submit" name="action" value="Commit">
<input type="submit" name="action" value="History">
<input type="submit" name="action" value="Clone">
</div></td>
</tr>
</tbody>
</table>
</div>
[%##### Components and Tags #####%]
<h3>Components and Tags</h3>
<div id="case_components">
<table width="100%" border="0">
<tr class="bz_row_header">
<th>Components</th>
<th><a href="tr_tags.cgi?id=[% case.id FILTER none %]&type=case">Tags</a></th>
</tr>
<tr>
<td align="left">
<table>
<tr><td>
[% PROCESS select sel = { name => 'comp_pick',
list => case.get_selectable_components
accesskey => 'p' } %]
<input type="button" id="addComp" value="Add" onClick="updateComponent(document.getElementById('comp_pick').value, 'addcomponent')">
</td></tr>
<tr><td>
[% SET components = case.components %]
[% PROCESS select sel = { name => 'components',
list => components
accesskey => 'c'
elements => 7 } %]
<br>
<input type="button" id="deleteComp" value="Remove" onClick="updateComponent(document.getElementById('components').value, 'removecomponent')">
</td></tr>
</table>
</td>
<td valign="top" align="center" rowspan="2">
<div id="tagTable">
[% PROCESS testopia/tag/table.html.tmpl
item = case
type = 'case'
%]
</div>
</td>
</tr>
</table>
</div>
[%##### Test Case Runs #####%]
<br><br>
<h3>Test Case Run History</h3>
<div id="case_run_history">
[% PROCESS 'testopia/caserun/case-history.html.tmpl'
testcaseruns = case.caseruns %]
</div>
[%##### Reports #####%]
<br><br>
<h3>Reports</h3>
[%##### Attachments #####%]
<br><br>
<h3>Attachments</h3>
<div id="attachment">
[% PROCESS testopia/attachment/table.html.tmpl
item = case
type = "case"
%]
</div>
[%##### Edit Case #####%]
<br><br>
[% IF case.canedit %]
<h3>Attributes</h3>
<div id="edit_case">
[% PROCESS testopia/case/form.html.tmpl %]
</div>
[% ELSE %]
[%##### Case Document #####%]
<br><br>
<h3>Action</h3>
<div id="case_docs">
[% case.text.action %]
<br><br>
<h3>Expected Results</h3>
[% case.text.effect %]
</div>
[% END %]
</FORM>
[%##### Footer #####%]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,126 +0,0 @@
[%# 1.0@bugzilla.org %][%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# We need to do this again since this may be called from ajax %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% IF table.list_count > 0 %]
<a href="javascript:coal()">Collapse All</a>
<a href="javascript:exal()">Expand All</a>
[% IF dotweak %]
Select:
<a href="javascript:sall()">All</a>,
<a href="javascript:snone()">None</a>
[% END %]
[% SET nav = { curr => page,
last => pagecount }
%]
[% IF table.ajax %]
[% link = "javascript:updateCaseList(\'" %]
[% paren = "\', $table.direction)" %]
[% ELSE %]
[% link = "${table.get_order_url}&order=" %]
[%# link = "${table.url_loc}?reverse=${table.reverse_sort}&getlist=1&viewall=${table.viewall}&order=" %]
[% END %]
[% DECORATIVE_BORDER_100_BEGIN %]
<table width="100%" id="ttt">
<tr class="bz_row_header">
<th colspan="2" align="right">
<a href="[% link %]case_id[% paren %]">ID[% table.arrow IF table.last_sort == 'case_id' %]</a></th>
<th align="left"><a href="[% link %]alias[% paren %]">Alias[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th align="left"><a href="[% link %]summary[% paren %]">Summary[% table.arrow IF table.last_sort == 'summary' %]</a></th>
<th align="left"><a href="[% link %]requirement[% paren %]">Requirement[% table.arrow IF table.last_sort == 'requirement' %]</a></th>
<th align="left"><a href="[% link %]author[% paren %]">Author[% table.arrow IF table.last_sort == 'author' %]</a></th>
<th align="left"><a href="[% link %]created[% paren %]">Created[% table.arrow IF table.last_sort == 'author' %]</a></th>
<th align="left"><a href="[% link %]category[% paren %]">Category[% table.arrow IF table.last_sort == 'category' %]</a></th>
<th align="left"><a href="[% link %]priority[% paren %]">Priority[% table.arrow IF table.last_sort == 'priority' %]</a></th>
<th align="left"><a href="[% link %]case_status[% paren %]">Status[% table.arrow IF table.last_sort == 'status' %]</a></th>
</tr>
[% FOREACH case = table.list %]
[% index = loop.count %]
<tr id="trr[% index FILTER none %]" class="[% loop.count % 2 == 0 ? "bz_row_odd" : "bz_row_even" %]" onclick="sr([% loop.count %]);" style="cursor:pointer;">
<td class="cc_trg" valign="top" width="24">
<table style="border-spacing:0px;border-collapse:collapse;" width="24">
<tr>
<td style="padding:0;border-width:0;">[% IF dotweak %]<input type="checkbox" id="c_[% case.id FILTER none %]" name="c_[% case.id FILTER none %]" onclick="[% IF canedit %]ck(this);[% ELSE %]_disable_sr=true;[% END %]">[% END %]</td>
<td style="padding:0;border-width:0;"><img id="id[% index FILTER none %]" src="testopia/img/tr.gif" width="11" height="11"></td>
</tr>
</table>
</td>
<td align="right" valign="top"><a onclick="_disable_sr=true;" href="tr_show_case.cgi?case_id=[% case.case_id FILTER none %]">[% case.id FILTER none %]</a></td>
<td align="left" valign="top">[% case.alias %]</td>
<td align="left" valign="top">[% case.summary %]</td>
<td align="left" valign="top">[% case.requirement %]</td>
<td align="left" valign="top"><a href="mailto:[% case.username %]">[% case.author.login %]</a></td>
<td align="left" valign="top">[% case.creation_date FILTER time %]</td>
<td align="left" valign="top">[% case.category.name FILTER html %]</td>
<td align="left" valign="top">[% case.priority FILTER html %]</td>
<td align="left" valign="top"><span id="sta[% case.status %]">[% case.status %]</span></td>
</tr>
<tr class="[% rowclass %]_first">
<td></td>
<td colspan="8" style="margin:0px;padding:0px;">
<div id="ra[% loop.count %]" class="ae_dv" style=
"padding-top:5px;padding-bottom:10px;">
<table class="ae_tb">
<tr>
<td colspan="2"><b>Summary:</b> [% case.summary FILTER html %]</td>
</tr>
<tr>
<td valign="top" class="ae_a"><b>Action:</b><br>
[% case.text.action %]</td>
<td style="width:10px">
</td>
<td valign="top" class="ae_e"><b>Expected Results:</b><br>
[% case.text.effect %]</td>
</tr>
</table>
<div class="cc_xx">
<div style="float:left;">
<b>Found in Plans:</b>
[% FOREACH p = case.plans %]
<a href="tr_show_plan.cgi?plan_id=[% p.id FILTER none %]">[% p.id FILTER none %]</a>
[% END %]
</div>
</div>
</div>
</td>
</tr>
[% END %]
</table>
[% IF NOT table.viewall %]
[% PROCESS navigation %]
[% END %]
[% DECORATIVE_BORDER_END %]
[%# No else clause required here -- see list.html.tmpl just below
# PROCESS testopia/case/table.html.tmpl
#%]
[% END %]

View File

@@ -1,80 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WIthOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[% IF table.list_count %]
[% IF dotweak %]
Select:
<a href="javascript:sall()">All</a>,
<a href="javascript:snone()">None</a>
[% END %]
[% DECORATIVE_BORDER_100_BEGIN %]
[% link = "${table.get_order_url}&order=" %]
<table width="100%">
<tr class="bz_row_header">
[% IF dotweak %]<th></th>[% END %]
[% IF dotweak %]<th><a href="[% link %]case_id">Case</a></th>[% END %]
<th><a href="[% link %]run_id">Run</a></th>
<th><a href="[% link %]build">Build</a></th>
<th><a href="[% link %]assignee">Assigned</a></th>
<th><a href="[% link %]testedby">Tested by</a></th>
<th><a href="[% link %]close_date">Close&nbsp;date</a></th>
<th><a href="[% link %]case_run_status">Status</a></th>
<th><a href="[% link %]category">Category</a></th>
<th>Bugs</th>
</tr>
[% FOREACH caserun = table.list %]
<tr class="[% loop.count % 2 == 0 ? "bz_row_odd" : "bz_row_even" %]" [% IF NOT dotweak %]style="cursor:pointer;" onclick="location='tr_show_caserun.cgi?caserun_id=[% caserun.id FILTER none %]'" [% END%]>
[% IF dotweak %]<td align="center"><input type="checkbox" id="r_[% caserun.id FILTER none %]" name="r_[% caserun.id FILTER none %]" /></td> [% END %]
[% IF dotweak %]<td align="center"><a href="tr_show_case.cgi?case_id=[% caserun.case.id FILTER none %]" title="[% caserun.case.summary FILTER html %]">[% caserun.case.id FILTER html %]</a></td>[% END %]
<td align="center"><a href="tr_show_run.cgi?run_id=[% caserun.run.id FILTER none %]&case_id=[% caserun.case.id FILTER none %]"
title="[% caserun.run.summary FILTER html %]">[% caserun.run.id FILTER html %]</a></td>
<td>[% caserun.build.name FILTER html %]</td>
<td>[% caserun.assignee.login FILTER html %]</td>
<td>[% caserun.testedby.login FILTER html %]</td>
<td>[% caserun.close_date FILTER html %]</td>
<td align="center">
<a href="tr_show_caserun.cgi?caserun_id=[% caserun.id FILTER none %]">
<img src="testopia/img/[% caserun.status FILTER none %]_small.gif"
title="[% caserun.status FILTER none %]"
alt="[% caserun.status FILTER none %]"
width="14" height="14"
border="0" /></a></td>
<td>[% caserun.case.category.name FILTER html %]</td>
<td align="center">
[% IF caserun.bug_count %]
<a href="buglist.cgi?bug_id=[% caserun.bug_list FILTER none %]">[% caserun.bug_count FILTER html %]</a>
[% ELSE %]
0
[% END %]
</td>
</tr>
[% END %]
[% IF NOT table.viewall %]
[% PROCESS navigation %]
[% END %]
</table>
[% DECORATIVE_BORDER_END %]
[% ELSE %]
No Runs Found
[% END %]

View File

@@ -1,94 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% title = "Confirm Test Case-Run Update" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
<p>The build you selected already has a record in the database.</p>
<table style="border: 1px solid #000;">
<tr class="bz_row_header">
<th>Build</th>
<th>Assignee</th>
<th>Tested By</th>
<th>Close Date</th>
<th>Status</th>
</tr>
<tr>
<td>[% existing.build.name FILTER html %]</td>
<td>[% existing.assignee.login FILTER html %]</td>
<td>[% existing.testedby.login FILTER html %]</td>
<td>[% existing.close_date FILTER time %]</td>
<td>[% existing.status FILTER html %]</td>
</tr>
</table>
<p> Do you wish to over write this information with the following?</p>
<table style="border: 1px solid #000;">
<tr class="bz_row_header">
<th>Assignee</th>
<th>Tested By</th>
<th>Close Date</th>
<th>Status</th>
</tr>
<tr>
<td>[% assignee FILTER html %]</td>
<td>[% testedby FILTER html %]</td>
<td>[% close_date FILTER time %]</td>
<td>[% status_name FILTER html %]</td>
</tr>
</table>
<br/>
<form action="tr_show_caserun.cgi">
<b>Notes:</b><br/>
<textarea name="notes" cols="80" rows="15">[% notes FILTER none %]</textarea>
<input type="hidden" name="caserun_id" value="[% existing.id FILTER none %]">
<input type="hidden" name="confirm" value="1">
<input type="hidden" name="status" value="[% status FILTER none %]">
<input type="hidden" name="assignee" value="[% assignee FILTER none %]">
<input type="hidden" name="caserun_build" value="[% existing.build.id FILTER url_quote %]">
<input type="hidden" name="bugs" value="[% bugs FILTER none %]">
<input type="hidden" name="action" value="Commit">
<p>
<input type="submit" value="Yes">
</p>
</form>
<a href="tr_show_caserun.cgi?caserun_id=[% current.id FILTER none %]">No, take me back</a>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,43 +0,0 @@
<script type="text/javascript">
function filterTable(type){
if (type == 1){
if (document.getElementById("ftr_case_run_status_id").value == 0 )
return;
document.location="[% form_action FILTER none %]?run_id=[% run.id FILTER none %]&case_run_status_id=" + document.getElementById("ftr_case_run_status_id").value + "#table";
}
else if (type == 2){
if (document.getElementById("ftr_category_id").value == 0 )
return;
document.location="[% form_action FILTER none %]?run_id=[% run.id FILTER none %]&category=" + document.getElementById("ftr_category_id").value + "#table";
}
else if (type == 3){
if (document.getElementById("ftr_build_id").value == 0 )
return;
document.location="[% form_action FILTER none %]?run_id=[% run.id FILTER none %]&build=" + document.getElementById("ftr_build_id").value + "#table";
}
}
</script>
Filter:
<a href="[% form_action FILTER none %]?run_id=[% run.id FILTER none %]#table">Show All</a>&nbsp;|&nbsp;
<a href="[% form_action FILTER none %]?run_id=[% run.id FILTER none %]&assignee=[% user.login FILTER url_quote %]&assignee_type=exact#table">Assigned to Me</a>&nbsp;|&nbsp;
<a href="[% form_action FILTER none %]?run_id=[% run.id FILTER none %]&testedby=[% user.login FILTER url_quote %]&testedby_type=exact#table">Tested by Me</a>&nbsp;|&nbsp;
<a href="[% form_action FILTER none %]?run_id=[% run.id FILTER none %]&close_date=0#table">Open</a>&nbsp;|&nbsp;
<a href="[% form_action FILTER none %]?run_id=[% run.id FILTER none %]&close_date=1#table">Closed</a>&nbsp;|&nbsp;
[% statuslist = run.current_caseruns.0.get_status_list %]
[% statuslist.unshift({id => 0, name => '--Status--'}) %]
[% PROCESS select sel = { name => "ftr_case_run_status_id",
list => statuslist,
events => 'onchange="filterTable(1)"' }
%]&nbsp;|&nbsp;
[% categorylist = run.plan.get_product_categories %]
[% categorylist.unshift({id => 0, name => '--Category--'}) %]
[% PROCESS select sel = { name => "ftr_category_id",
list => categorylist,
events => 'onchange="filterTable(2)"' }
%]&nbsp;|&nbsp;
[% buildlist = run.plan.get_product_builds %]
[% buildlist.unshift({id => 0, name => '--Build--'}) %]
[% PROCESS select sel = { name => "ftr_build_id",
list => buildlist,
events => 'onchange="filterTable(3)"' }
%]

View File

@@ -1,134 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[% IF NOT dotweak %]
[% build_list = caserun.run.plan.builds %]
[% default_build = caserun.build.name %]
[% ELSE %]
[% default_build = "--Do Not Change--" %]
[% END %]
<table width="100%">
<tr>
[% IF NOT dotweak %]
<td align="center" valign="top" width="50%">
[% IF caserun.bugs.size > 0 %]
<table>
<tr class="bz_row_header">
<th colspan="3" >[% terms.Bugs %]</th>
</tr>
<tr class="bz_row_header">
<th>ID</th><th>Summary</th><th>Remove</th>
</tr>
[% FOREACH bug = caserun.bugs %]
<tr>
<td>[% bug.bug_id FILTER bug_link(bug.bug_id) %] </td>
<td>[% bug.short_desc FILTER html %]</td>
<td><a href="tr_show_caserun.cgi?caserun_id=[% caserun.id FILTER none %]&bug_id=[% bug.bug_id FILTER none %]&action=detach_bug"><img src="testopia/img/del.gif" alt="detach bug" /></a>
</tr>
[% END %]
</table>
[% END %]
</td>
<td align="center" valign="top" width="50%">
[% IF caserun.case.bugs.size > 0 %]
<table>
<tr class="bz_row_header">
<th colspan="3" >[% terms.Bugs %] in all runs</th>
</tr>
<tr class="bz_row_header">
<th>ID</th><th>Summary</th>
</tr>
[% FOREACH bug = caserun.case.bugs %]
<tr>
<td>[% bug.bug_id FILTER bug_link(bug.bug_id) %] </td>
<td>[% bug.short_desc FILTER html %]</td>
</tr>
[% END %]
</table>
[% END %]
</td>
[% END %]
</tr>
</table>
<table width="100%">
<tr>
<th align="right">Build</th>
<td>
[% PROCESS select sel = { name => "caserun_build",
list => build_list,
default => default_build }
%]
</td>
<th align="right">Assignee</th>
<td><input name="assignee" value="[% dotweak ? "--Do Not Change--" : caserun.assignee.login FILTER html %]"></td>
<th align="right" valign="top" colspan="2">Attach [% terms.Bugs %]</th>
<td><input name="bugs">&nbsp;<a href="enter_bug.cgi?product=[% caserun.run.plan.product_name FILTER url_quote %]&caserun_id=[% caserun.id FILTER none %]">Log a New [% terms.Bug %]</a></td>
</tr>
</table>
<table width="100%">
<tr>
<td colspan="2">
<table>
<tr>
<th colspan="3" class="bz_row_header">Status</th>
</tr>
[% FOREACH status = caserun.get_status_list %]
<tr>
<td><label for="[% status.name FILTER none %]"><img src="testopia/img/[% status.name FILTER none %].gif" alt="[% status.name FILTER none %]"></label></td>
<td align="right"><input type="radio" name="status" id="[% status.name FILTER none %]" value="[% status.id FILTER none %]" [% 'checked="checked"' IF caserun.status == status.name AND NOT dotweak %]></td>
<th align="left"><label for="[% status.name FILTER none %]">[% status.name FILTER html %]</label></th>
</tr>
[% END %]
[% IF dotweak %]
<tr>
<td>&nbsp;</td>
<td align="right"><input type="radio" name="status" value="-1" [% 'checked="checked"' IF dotweak %]></td>
<th align="left"><label for="[% status.name FILTER none %]">No Change</label></th>
</tr>
[% END %]
</table>
</td>
<td colspan="2" align="center">
<table>
<tr>
<th class="bz_row_header">Notes</th>
</tr>
<tr>
<td><textarea name="notes" cols="80" rows="15">[% caserun.notes %]</textarea></td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="right" colspan="4">
<input type="hidden" name="caserun_id" value="[% caserun.id FILTER none %]">
<input type="submit" name="action" value="Commit">
</td>
</tr>
</table>
</div>

View File

@@ -1,77 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Case Runs" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<script src="testopia/js/util.js" type="text/javascript"></script>
<form id="table" action="tr_list_caseruns.cgi" method="POST">
[% PROCESS "testopia/caserun/filter.html.tmpl" %]
<br/>
[% IF table.list_count %]
[% PROCESS "testopia/caserun/case-history.html.tmpl" %]
[% END %]
<p>
[% IF table.list_count == 0 %]
No test case runs
[% ELSE %]
[% IF table.list_count == 1 %]
One test caserun
[% ELSE %]
[% table.list_count %] test case runs
[% END %]
[% END %]
found.
</p>
[% IF dotweak AND table.list_count %]
<h3>Update Selected Test Case-Runs</h3>
[% PROCESS testopia/caserun/form.html.tmpl %]
[% END %]
<input type="hidden" name="run_id" value="[% run.id FILTER none %]"/>
</form>
[%############################################################################%]
[%# Page Footer #%]
[%############################################################################%]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,67 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Gervase Markham <gerv@gerv.net>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% list = table.get_saved_list %]
<b>Case-Run List:</b>
[% IF table && list > 0 %]
[% curr = lsearch(list, caserun.id) %]
[% IF curr != -1 && (curr > 0) %]
<a href="tr_show_caserun.cgi?caserun_id=[% list.first %]">&lt;&lt;&nbsp;First</a>
[% ELSE %]
<i><font color="#777777">&lt;&lt;First</font></i>
[% END %]
[% IF caserun %]
[% IF curr != -1 %]
[% IF curr > 0 %]
[% prev = curr - 1 %]
<a href="tr_show_caserun.cgi?caserun_id=[% list.$prev %]">&lt;&nbsp;Prev</a>
[% ELSE %]
<i><font color="#777777">Prev</font></i>
[% END %]
[% IF curr != -1 %]
&nbsp;&nbsp;([% curr + 1 %] of [% table.get_saved_list.size %])&nbsp;&nbsp;
[% END %]
[% IF curr + 1 < list.size %]
[% next = curr + 1 %]
<a href="tr_show_caserun.cgi?caserun_id=[% list.$next %]">Next&nbsp;&gt;</a>
[% ELSE %]
<i><font color="#777777">Next</font></i>
[% END %]
[% END %]
[% ELSE %]
&nbsp;&nbsp;
[% END %]
[% IF curr != -1 && (curr + 1 < list.size) %]
<a href="tr_show_caserun.cgi?caserun_id=[% list.last %]">Last&nbsp;&gt;&gt;</a>
[% ELSE %]
<i><font color="#777777">Last&gt;&gt;</font></i>
[% END %]
[% ELSE %]
[%# With no list, don't show link to search results %]
&nbsp;&nbsp;
<i><font color="#777777">No search results available</font></i>
[% END %]

View File

@@ -1,62 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS testopia/blocks.html.tmpl %]
<td valign="top" width="24">
<table style="border-spacing:0px;border-collapse:collapse;" width="24">
<tr>
[% IF !caserun.canedit %]
<td valign="middle" style="cursor:pointer;" onclick="sr([% index %]);">
<img src="testopia/img/lk.gif" width="13" height="15" alt="locked" border="0"/>
</td>
[% END %]
<td valign="bottom" style="padding:2;border-width:0; cursor:pointer;" onclick="sr([% index %]);">
<img id="id[% index %]" src="testopia/img/tr.gif" width="11" height="11" alt="click to expand" border="0"/>
</td>
</tr>
</table>
</td>
<td align="left"><a href="tr_show_case.cgi?case_id=[% caserun.case.id FILTER none %]" title="[% caserun.case.summary FILTER html %]">[% caserun.case.id FILTER html %]</a></td>
<td align="right" valign="top">
[% PROCESS select sel = { name => "caserun_build",
list => caserun.run.plan.builds,
default => caserun.build.name
events => "onChange='chBld($index, this.value, \"$caserun.status\", $caserun.id)'"}
%]
</td>
<td align="left" valign="top"><span id="own[% index %]"><a href="mailto:[% caserun.testedby.login %]">[% caserun.assignee.login %]</a></span></td>
<td align="left" valign="top"><span id="tdb[% index %]"><a href="mailto:[% caserun.testedby.login %]">[% caserun.testedby.login %]</a></span></td>
<td align="left" valign="top">
<span id="cld[% index %]">[% caserun.close_date FILTER time %] </span>
</td>
<td align="center" valign="top" onclick="sr([% index %]);">
<span style="width:14px;display:table-cell; align: center; cursor:pointer;">
<img id="xs[% caserun.id FILTER none %]"
src="testopia/img/[% caserun.status FILTER none %]_small.gif" title="[% caserun.status FILTER none %]" alt="[% caserun.status FILTER none %]"
width="14" height="14"/>
</span>
</td>
<td align="left" valign="top">[% caserun.case.category.name %]</td>
<td align="center" valign="top"><span id="nbgs[% index %]">[% IF caserun.bug_count %]<a href="buglist.cgi?bug_id=[% caserun.get_buglist %]">[% caserun.bug_count %]</a>[% ELSE %][% caserun.bug_count %][% END %]</span></td>

View File

@@ -1,122 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%##### BEGIN Hidden Pane #####%]
<td colspan="10" style="margin:0px;padding:0px;">
<div id="ra[% index %]" class="ae_dv">
[%##### Sumarry, Action, Expected Results #####%]
<table class="ae_tb">
<tr>
<td colspan="3"><b>Summary:</b>&nbsp;
[% caserun.case.summary FILTER html %]</td>
</tr>
<tr>
<td valign="top" class="ae_a">
<b>Action:</b><br/>[% caserun.case.text.action %]
</td>
<td style="width:10px";/>
<td valign="top" align="left" class="ae_e">
<b>Expected Results:</b><br/>[% caserun.case.text.effect %]
</td>
</tr>
</table>
<input id="no[% index %]" type="hidden" value=""/>
<input id="en[% index %]" type="hidden" value="[% caserun.canedit %]"/>
[%##### Notes #####%]
<div class="cc_xx">
<div style="float:left;font-weight:bold;">Notes:</div>
<div class="cc_i">
<textarea cols="45" id="notes[% index %]" onfocus="nc(this)" onblur="nb(this)"
[% IF caserun.canedit %]
onkeypress="document.getElementById('no[% index %]').value=1;document.getElementById('bs[% index %]').disabled = false"
[% END %]
style="height:20px;" rows="">[% caserun.notes %]</textarea>
</div>
<div class="cc_i"><input id="bs[% index %]" type="button" disabled="true" onclick="chNote([% index %], [% caserun.id FILTER none %], document.getElementById('notes[% index %]').value);" value="Submit"></div>
[%##### Status #####%]
<div class="cc_i">
<b>Status:</b>
</div>
[% FOREACH status = caserun.get_status_list %]
<div class="cc_i">
[% IF NOT caserun.canedit %]
<a id="st1_[% index %]">
<img id="im[% loop.count %]_[% index %]" src="testopia/img/[% status.name FILTER none %]_gray.gif" width="23" height="23" alt="[% status.name FILTER none %] (disabled)" title="[% status.name FILTER none %](disabled)" border="0" /></a>
[% ELSE %]
<a id="st1_[% index %]" href="javascript:chStat([% index %], [% status.id FILTER none %], [% caserun.id FILTER none %]); chNote([% index %], [% caserun.id FILTER none %], document.getElementById('notes[% index %]').value);">
<img id="im1_[% index %]" src="testopia/img/[% status.name FILTER none %].gif" width="23" height="23" alt="[% status.name FILTER none %]" title="[% status.name FILTER none %]" border="0" /></a>
[% END %]
</div>
[% END %]
<div style="float:left;margin-left:7px;">
[% IF caserun.runningby != '' || caserun.canedit == 0 %]
<a id="aw_[% index %]">
<img id="awi_[% index %]" src="testopia/img/awg.gif" width="25" height="23"
[% IF caserun.canedit == 0 %]
alt="Can't run it" title="Can't run it"
[% else %]
alt="Already running" title="Already running"
[% END %]
border="0" /></a>
[% ELSE %]
[% END %]
</div>
</div>
[%##### Bugs #####%]
<div class="cc_xx">
<div style="float:left;">
<div style="float:left;font-weight:bold;">[% terms.Bugs %] detected (all runs):</div>
<div class="cc_i">
[<span id="bgl[% index %]">
[% FOREACH bug = caserun.case.bugs %]
[% bug.bug_id FILTER bug_link(bug.bug_id) %]
[% END %]
</span>]
</div>
<div class="cc_i">
<a href="enter_bug.cgi?product=[% caserun.run.plan.product_name FILTER url_quote %]&caserun_id=[% caserun.id FILTER none %]" target="_blank"><img src="testopia/img/snew.gif" alt="Log a New Bug" title="Log a New Bug" style="vertical-align:text-bottom;" /></a>&nbsp;
</div>
<div style="float:left;"><input type="text" size="6" value="" id="mbg[% index %]" [% enabled %]
[% IF caserun.canedit %]
onkeyup="edt_attch([% index %]);"
[% END %]
/></div>
<div class="cc_i"><input type="button" value="Attach" id="sk[% index %]" disabled="true" onclick="attch([% index %], [% caserun.id FILTER none %], document.getElementById('mbg[% index %]').value);"/></div>
[%##### Assignee #####%]
<div class="cc_i"><input value="[% user.login FILTER html %]" id="assignee_[% index %]" /><input type="button" value="Assign" onclick="chOwn([% index %], [% caserun.id FILTER none %], document.getElementById('assignee_[% index %]').value)">
<a href="javascript:userLookup('document.Create.assigned_to', document.Create.assigned_to.value);">
<image src="images/users.png" border="0" alt="Lookup User" title="Lookup User"></a>
<a id="aw_[% index %]" href="javascript:aws([% index %], [% caserun.id FILTER none %])">
</div>
<div style="float:right; margin-right:20px;"><a href="tr_show_caserun.cgi?caserun_id=[% caserun.id FILTER none %]">Classic interface...</a></div>
</div>
<div class="cc_xx" style="margin-bottom:10px;"><div id="pp[% index %]" class="floatMsg"></div></div>
</div>
</div>
</td>

View File

@@ -1,105 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% title = "Test Case Run Log For Test Case: $caserun.case.summary" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% PROCESS testopia/caserun/navigate.html.tmpl %]
[%##### Overview #####%]
<div id="run_overview">
<h3>Overview</h3>
<table border="0" cellpadding="1" width="100%">
<tbody align="left">
<tr class="bz_row_header">
<th width="33%">Test Case</th>
<th width="33%">Test Run</th>
<th width="33%">Test Plan</th>
</tr>
<tr class="bz_row_data">
<td><a href="tr_show_case.cgi?case_id=[% caserun.case.id FILTER html %]">[% caserun.case.id FILTER html %]: [% caserun.case.summary FILTER html %]</a></td>
<td><a href="tr_show_run.cgi?run_id=[% caserun.run.id FILTER html %]">[% caserun.run.id FILTER html %]: [% caserun.run.summary FILTER html %]</a></td>
<td><a href="tr_show_plan.cgi?plan_id=[% caserun.run.plan.id FILTER html %]">[% caserun.run.plan.id FILTER html %]: [% caserun.run.plan.name %]</a></td>
</tr>
<tr class="bz_row_header">
<th>Test Case Version</th>
<th>Product</th>
<th>Stop Date</th>
</tr>
<tr class="bz_row_data">
<td>[% caserun.case.version FILTER html %]</td>
<td>[% caserun.run.plan.product_name FILTER html %]</td>
<td>[% caserun.close_date FILTER html %]</td>
</tr>
<tr class="bz_row_header">
<th>Assignee</th>
<th>Status</th>
<th>Tested By</th>
</tr>
<tr class="bz_row_data">
<td><a href="mailto:[% caserun.assignee.email FILTER html %]">[% caserun.assignee.identity FILTER html %]</a></td>
<td align="center"><img src="testopia/img/[% caserun.status FILTER html %].gif" alt="[% caserun.status FILTER html %]" title="[% caserun.status FILTER html %]"></td>
<td><a href="mailto:[% caserun.testedby.email FILTER html %]">[% caserun.testedby.identity FILTER html %]</a></td>
</tr>
</tbody>
</table>
</div>
<br><br>
[%##### Case Action & Expected Results #####%]
<h3>Case Action & Expected Results</h3>
<div style="width:800">
<table width="100%">
<tr class="bz_row_header">
<th colspan="2">Action</th>
<th colspan="2">Expected Results</th>
</tr>
<tr>
<td colspan="2" class="ae_a">[% caserun.case.text.action FILTER none %]</td>
<td colspan="2" class="ae_e">[% caserun.case.text.effect FILTER none %]</td>
</tr>
</table>
<h3>Attributes</h3>
<form action="[% action FILTER none %]" method="POST">
[% PROCESS testopia/caserun/form.html.tmpl %]
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,72 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[% show_order = 0 %]
<script src="testopia/js/caserun.js" type="text/javascript"></script>
<p style="margin-top:0;margin-bottom:4px;">
<a href="javascript:coal()">Collapse All</a>
<a href="javascript:exal()">Expand All</a>
</p>
<div id="caserun_table">
[% DECORATIVE_BORDER_100_BEGIN %]
[%##### TABLE HEADER #####%]
[% link = "${table.get_order_url}&order=" %]
<table width="100%">
<tr class="bz_row_header">
<th width="24" colspan="2">
<a href="[% link %]case_id">Case&nbsp;ID</a></th>
<th><a href="[% link %]build">Build</a></th>
<th><a href="[% link %]assignee">Assigned</a></th>
<th><a href="[% link %]testedby">Tested by</a></th>
<th><a href="[% link %]close_date">Close&nbsp;date</a></th>
<th><a href="[% link %]case_run_status">Status</a></th>
<th><a href="[% link %]category">Category</a></th>
<th>Bugs</th>
</tr>
[%##### Loop start #####%]
[% FOREACH caserun = table.list %]
[% index = loop.count %]
<!-- START HEADER FOR [% index %]: CASE [% caserun.case.id %] -->
<tr id="head_caserun_[% index %]" class="[% loop.count % 2 == 0 ? "bz_row_odd" : "bz_row_even" %]">
[% PROCESS "testopia/caserun/short-form-header.html.tmpl" %]
</tr>
<!-- ### START BODY FOR CASE [% caserun.case.id %] ### -->
<tr id="body_caserun_[% index %]" class="[% loop.count % 2 == 0 ? "bz_row_odd" : "bz_row_even" %]">
[% PROCESS "testopia/caserun/short-form.html.tmpl" %]
</tr>
[% END %]
[% IF NOT table.viewall %]
[% PROCESS navigation %]
[% END %]
</table>
[% DECORATIVE_BORDER_END %]
</div>

View File

@@ -1,53 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/header.html.tmpl
title = "Delete Category $category.name From Product $plan.product_name"
%]
<form method="POST" action="tr_categories.cgi">
<input type="HIDDEN" name="action" value="do_delete">
<input type="HIDDEN" name="category_id" value="[% category.id FILTER none %]">
<input type="hidden" name="plan_id" value="[% plan.id FILTER none %]">
[% IF category.case_count %]
<table style="border-collapse:collapse;" border="1" bordercolor="red" width="100%" cellspacing="0" cellpadding="6"><tr><td>
<font color="red">
This category is used by [% category.casecount FILTER html %] test cases.<br>
Please move all test cases to other categories first.
[% tr_error %]</font>
</td></tr></table>
[% ELSE %]
You are about to delete category '[% category.name FILTER html %]' from test plan
[% plan.name FILTER html %]. <br>
<p>
<b>Are you sure?</b>
</p>
<input type="SUBMIT" value="Delete"/>
[% END %]
</form>
<p>
<a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">Back</a> to test plan or
<a href="tr_categories.cgi?plan_id=[% plan.id FILTER none %]">edit</a> categories
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,44 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/header.html.tmpl %]
<form method="POST" action="tr_categories.cgi" name="form">
<input type="HIDDEN" name="action" value="[% action FILTER none %]"/>
<input type="HIDDEN" name="plan_id" value="[% plan.id FILTER none %]"/>
<input type="hidden" name="category_id" value="[% category.id FILTER none %]"/>
<table border="0" cellpadding="2" cellspacing="0">
<tr>
<th align="right" valign="top">Category Name: </th>
<td><input size="40" name="name" value="[% category.name FILTER none %]"/></td>
</tr>
<tr>
<th align="right" valign="top">Category Description: </th>
<td> <textarea rows="10" cols="70" name="desc">[% category.description FILTER none %]</textarea><br> </td>
</tr>
</table>
<input type="submit" value="Submit">
</form>
<p>
<a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">Back</a> to test plan or
<a href="tr_categories.cgi?plan_id=[% plan.id FILTER none %]">edit</a> categories
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,52 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/header.html.tmpl
title = "Test Categories for $plan.product_name"
%]
<table>
<tr>
<th class="bz_row_header" align="right">Name</th>
<th class="bz_row_header" align="right">Description</th>
<th class="bz_row_header" align="right">Actions</th>
</tr>
[% FOREACH cat = plan.categories %]
<tr>
<td valign="top">[% cat.name FILTER html %]</td>
<td valign="top">[% cat.description FILTER html %]</td>
<td valign="top">
<a href="tr_categories.cgi?action=edit&amp;category_id=[% cat.id FILTER none %]&amp;plan_id=[% plan.id FILTER none %]">Edit</a>
[% IF plan.candelete %]
&nbsp;|&nbsp;
<a href="tr_categories.cgi?action=delete&amp;category_id=[% cat.id FILTER none %]&amp;plan_id=[% plan.id FILTER none %]">Delete</a>
[% END %]
</td>
</tr>
[% END %]
</table>
<br>
[% IF plan.canedit %]
<a href="tr_categories.cgi?action=add&amp;plan_id=[% plan.id FILTER none %]">Add new</a>
[% END %]
<p>
<a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">Back</a> to test plan
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,44 +0,0 @@
[%# 1.0@bugzilla.org %][%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Create New Test Run Environment" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% PROCESS testopia/environment/form.html.tmpl %]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,56 +0,0 @@
[%# 1.0@bugzilla.org %][%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% IF attachment.case_id %]
[% SET item = "Test Case $attachment.case_id" %]
[% ELSE %]
[% SET item = "Test Plan $attachment.plan_id" %]
[% END %]
[% title = "Delete Attachment $attachment.description for $item" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% IF environment.get_run_count %]
<b>This environment is being used by [% environment.get_run_count FILTER none %]
test runs. Please reassign these runs to a different Environment before deleting.
[% ELSE %]
You are about to permanantly delete this environment.
<br>
<form method="POST" action="tr_environment.cgi">
<input type="hidden" name="action" value="do_delete" />
<input type="hidden" name="env_id" value="[% environment.id FILTER none %]" />
<input type="submit" value="Continue" />
</form>
[% END %]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,62 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
<form method="POST" action="tr_environment.cgi">
<input type="hidden" name="action" value="[% action FILTER none %]" />
<input type="hidden" name="env_id" value="[% environment.id FILTER none %]" />
<h3>Attributes</h3>
<table border="0">
<tr>
<th class="bz_row_header" align="right">Name:</th>
<td colspan="3"><input name="name" value="[% environment.name %]" size="30" /></td>
</tr>
<tr>
<th class="bz_row_header" align="right">OS:</th>
<td>
[% PROCESS select sel = { name => 'op_sys',
list => environment.get_op_sys_list,
accesskey => 'o'
default => environment.op_sys } %]
</td>
<th class="bz_row_header" align="right">Platform:</th>
<td>
[% PROCESS select sel = { name => 'rep_platform',
list => environment.get_rep_platform_list,
accesskey => 'f'
default => environment.rep_platform } %]
</td>
</tr>
</table>
<br>
<h3>XML</h3>
<textarea name="xml" cols="80" rows="20">[% environment.xml FILTER none %]</textarea>
<br>
<a href="testopia/doc/Manual.pdf" target="_blank">Help</a><br>
<p>
<input type="submit" value="Submit">
</p>
</form>
[% IF Param("allow-test-deletion") %]
<a href="tr_attachment.cgi?attach_id=[% attachment.id FILTER none %]&action=delete">Delete Attachment</a>
[% END %]

View File

@@ -1,50 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Environments" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% PROCESS testopia/environment/table.html.tmpl %]
<br>
<form action="tr_environment.cgi">
<input type="hidden" name="action" value="add" />
<input type="submit" value="Create" />
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,45 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Edit Test Environment: $environment.name" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% PROCESS testopia/environment/form.html.tmpl %]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,46 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
<table>
<tr class="bz_row_header">
<th>ID</th>
<th>Name</th>
<th>OS</th>
<th>Platform</th>
<th>Runs</th>
<th>Actions</th>
</tr>
[% FOREACH env = environments %]
<tr>
<td><a href="tr_environment.cgi?env_id=[% env.id FILTER none %]&action=edit">[% env.id FILTER html %]</a></td>
<td>[% env.name FILTER html %]</td>
<td>[% env.op_sys FILTER html %]</td>
<td>[% env.rep_platform FILTER html %]</td>
<td align="center"><a href="tr_list_runs.cgi?run_id=[% env.get_run_list FILTER none %]">[% env.get_run_count(1) FILTER none %]</a></td>
<td align="center">
<a href="tr_environment.cgi?env_id=[% env.id FILTER none %]&action=delete">Delete</a>
</td>
</tr>
[% END %]
</table>

View File

@@ -1,39 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
[% IF tr_message %]
<p>
<table style="border-collapse:collapse;" border="1" bordercolor="black" width="100%" cellspacing="0" cellpadding="6"><tr><td>
<font color="green">[% tr_message %]</font>
</td></tr></table>
</p>
[% END %]
[% IF tr_error %]
<p>
<table style="border-collapse:collapse;" border="1" bordercolor="red" width="100%" cellspacing="0" cellpadding="6"><tr><td>
<font color="red">[% tr_error %]</font>
</td></tr></table>
</p>
[% END %]

View File

@@ -1,34 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
<div style="vertical-align:middle;font-size:10px;width:102px;">
<span style="width:82px;float:left;position:relative;left:+10px;">
<span style="float:left;width:1px;height:13px;background-color:black;"></span>
[%# IFs needed for Opera browser #%]
[% IF percent > 0 %]<span style="float:left;"><img src="testopia/img/pb.gif" style="width:[% percent * 0.8 %]px;height:13px;padding:0px;margin:0px;border-width:0px;"/></span>[% END %]
[% IF percent < 100 %]<span style="float:left;"><img src="testopia/img/pg.gif" style="width:[% 80 - percent * 0.8 %]px;height:13px;"/></span>[% END %]
<span style="float:left;width:1px;height:13px;background-color:black;"></span>
</span>
<span style="font-family:Arial;font-size:11px;float:left;"><div style="position:relative;left:-40px;text-align:center;width:20px;">[% percent %]</div></span>
</div>

View File

@@ -1,46 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% title = "Create a New Test Plan" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = title
style = style
%]
<script src="testopia/dojo-ajax/dojo.js" type="text/javascript"></script>
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<form name="planform" action="[% form_action FILTER none %]" method="POST">
[% PROCESS testopia/plan/form.html.tmpl %]
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,37 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Gervase Markham <gerv@gerv.net>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS global/header.html.tmpl
title = "Search by Test Plan Number"
%]
<form method="get" action="[% form_action %]">
<p>
Please enter a plan id:
<input name="plan_id" size="6">
<input type="submit" value="Use This Test Plan">
</p>
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,109 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = "Clone Test Plan: $plan.name"
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<form method="POST" action="tr_show_plan.cgi"><input type="HIDDEN"
name="action" value="do_clone"> <input type="HIDDEN" name="plan_id"
value="[% plan.id FILTER none %]">
<table border="0" cellspacing="4">
<tr bgcolor="lightyellow">
<td colspan="2"><font size="+1">Select Clone Options</font></td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">New plan name:</td>
<td><input size="30" name="plan_name"
value="Copy of [% plan.name FILTER html %]" /></td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">Product version:</td>
<td>[% PROCESS select sel = { name => 'product_version',
list => plan.get_product_versions
accesskey => 'v'
default => plan.product_version }
%]
</td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">Copy plan document:</td>
<td><input type="radio" name="copy_doc" value="1" checked />Yes <input
type="radio" name="copy_doc" value="0" />No</td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">Copy tags:</td>
<td><input type="radio" name="copy_tags" value="1" checked />Yes <input
type="radio" name="copy_tags" value="0" />No</td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">Copy/Link test cases:</td>
<td>
<input type="radio" name="copy_cases" value="2" checked />Copy
<input type="radio" name="copy_cases" value="1" />Link
<input type="radio" name="copy_cases" value="0" />No</td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">Copy/Link test cases from selected
categories only:</td>
<td>
[% PROCESS select sel = { name => 'clone_categories',
list => plan.categories
accesskey => 'c'
mult => 1
elements => 5
default => 'all'}
%]
</td>
</tr>
</table>
<input type="SUBMIT" value="Clone"></form>
<p><a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">Back</a>
to test plan</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,45 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/header.html.tmpl
title = title
%]
<p>
<FORM METHOD="POST" ACTION="tr_testplan_form.cgi" name="form">
<p>You are about to delete test plan <b>'[% plan_name FILTER html %]'</b>
for product <b>'[% product_name FILTER html %]'</b></p>
<p>If you click on 'delete' the test plan together with all its test cases and test runs
will be deleted and will not be able to be recovered.</p>
<p>This test plan has currently [% runs FILTER html %] run(s) and
[% cases FILTER html %] case(s) defined</p>
<INPUT TYPE="HIDDEN" NAME="form_action" VALUE="">
<INPUT TYPE="HIDDEN" NAME="plan_id" VALUE="[% plan_id FILTER html %]">
<INPUT TYPE="BUTTON" VALUE="Delete" onClick="form.form_action.value='do_delete';form.action='tr_edittestplans.cgi';submit();">
&nbsp;&nbsp;
<INPUT TYPE="SUBMIT" VALUE="Cancel">
</FORM>
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,110 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
<script type="text/javascript">
dojo.require("dojo.widget.Editor");
function addOption(selectElement,newOption) {
try {
selectElement.add(newOption,null);
}
catch (e) {
selectElement.add(newOption,selectElement.length);
}
}
function getProdVers(product, plan){
document.getElementById("prod_version").disabled = true;
dojo.io.bind({
url: "[% form_action %]",
content: { product_id: product, plan_id: plan, action: "getversions" },
load: function(type, data, evt){
var prodvers = document.getElementById("prod_version");
prodvers.options.length = 0;
var vers = data.split("|");
for (i=0; i < vers.length; i++){
var myOp = new Option(vers[i], vers[i]);
addOption(prodvers, myOp);
if (vers[i] == '[% plan.product_version FILTER none %]'){
prodvers.options[i].selected = true;
}
}
document.getElementById("prod_version").disabled = false;
},
error: function(type, error){ alert("ERROR");},
mimetype: "text/plain"
});
}
</script>
<a name="attributes"></a>
<input type="hidden" name="plan_id" value="[% plan.id FILTER none %]">
<!--input type="hidden" name="action" value="[% action FILTER none %]"-->
<table width="100%">
<tr>
<th class="bz_row_header" align="right" width="100">Name</th>
<td><input name="plan_name" value="[% plan.name FILTER none %]" style="width:300px;"></td>
<th class="bz_row_header" align="right" width="100">Product</th>
<td>[% IF plan.test_case_count OR plan.test_run_count %]
<input type="hidden" name='product_id' value="[% plan.product_id FILTER none %]" />
[% plan.product_name FILTER html %]
[% ELSE %]
[% PROCESS select sel = { name => 'product_id',
list => plan.get_available_products,
accesskey => 'p'
default => plan.product_id
events => "onChange='getProdVers(this.value, $plan.id)'"} %]</td>
[% END %]
</tr>
<tr>
<th class="bz_row_header" align="right" width="100">Type</th>
<td>[% PROCESS select sel = { name => 'type',
list => plan.get_plan_types,
accesskey => 't'
default => plan.type } %]</td>
<th class="bz_row_header" align="right" width="100">Product Version</th>
<td>[% PROCESS select sel = { name => 'prod_version',
list => plan.get_product_versions,
accesskey => 'v'
default => plan.product_version } %]</td>
</tr>
</table>
[% UNLESS plan.test_case_count OR plan.test_run_count %]
<script type="text/javascript">
getProdVers(document.getElementById('product_id').value, [% plan.id FILTER none %]);
</script>
[% END %]
<br><br>
<h3>Plan Document</h3>
<div id="plan_doc" style="border: 1px solid #000000; padding-bottom: 5px;">
<textarea cols="80" rows="25" dojoType="Editor"
items="textGroup;|;blockGroup;|;justifyGroup;|;colorGroup;|;listGroup;|;indentGroup;|;linkGroup;"
id="plandoc" name="plandoc" style="cursor:text;">
[% plan.text %]</textarea>
</div>
<p>
<input type="submit" name="action" value="[% action FILTER html %]">
</p>

View File

@@ -1,115 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Plan History for Plan $plan.id: $plan.name" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<table border=0>
<tr class="bz_row_header">
<th>Who</th>
<th>When</th>
<th>What</th>
<th>Old Value</th>
<th>New Value</th>
</tr>
[% FOREACH row = plan.history %]
<tr class="[% loop.count % 2 == 0 ? 'bz_row_odd' : 'bz_row_even' %]">
<td><a href="mailto:[% row.who %]">[% row.who FILTER html %]</a></td>
<td>[% row.changed FILTER time %]</td>
<td>[% row.what FILTER html %]</td>
<td>[% row.oldvalue FILTER html %]</td>
<td>[% row.newvalue FILTER html %]</td>
</tr>
[% END %]
</table>
<br><br>
<h3>Diff Plan Document</h3>
<form action="tr_show_plan.cgi">
<input type="hidden" name="action" value="History" />
<input type="hidden" name="plan_id" value="[% plan.id FILTER none %]" />
<table>
<tr>
<th colspan="5" class="bz_row_header">Diff Versions</th>
</tr>
<tr>
<td><input type="submit" value="Compare"/></td>
<td>Version:</td>
<td>
<select name="new">
[% i = 1 %]
[% WHILE i <= plan.version %]
<option value="[% i %]" [% 'selected="selected"' IF i == new %]>[% i %]</option>
[% i = i +1 %]
[% END %]
</select>
</td>
<td>Version:</td>
<td>
<select name="old">
[% i = 1 %]
[% WHILE i <= plan.version %]
<option value="[% i %]" [% 'selected="selected"' IF i == old %]>[% i %]</option>
[% i = i +1 %]
[% END %]
</select>
</td>
</tr>
</table>
<div id="diff">
<pre>
[% diff %]
</pre>
</div>
<p>
<a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">Back to plan</a>
</p>
[% PROCESS global/footer.html.tmpl %]
[% BLOCK version %]
[% i = 1 %]
[% WHILE i <= plan.version %]
<option value="[% i %]">[% i %]</option>
[% i = i +1 %]
[% END %]
[% END %]

View File

@@ -1,76 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[%# PROCESS global/variables.none.tmpl %]
[% title = "Test Plans by Product" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = title
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
<p><b>Please select a product from the list to view its list of test plans:</b></p>
[% IF classifications %]
[% FOREACH c = classifications %]
<h3> [% c.name FILTER html %] </h3>
<div id="c_[% c.id FILTER none %]">
[% PROCESS table products = c.viewable_products %]
</div>
<br>
[% END %]
[% ELSE %]
[% PROCESS table %]
[% END %]
[% PROCESS global/footer.html.tmpl %]
[% BLOCK table %]
<table width="100%">
<tr class="bz_row_header">
<th>Product</th>
<th>Description</th>
<th>Plans</th>
</tr>
[% FOREACH prod = products %]
<tr class="[% loop.count % 2 == 1 ? "bz_row_odd" : "bz_row_even" %]" style="cursor:pointer;" onclick="location='tr_list_plans.cgi?product_id=[% prod.id FILTER none %]';">
<td width="150">[% prod.name %]</td>
<td>[% prod.description%]</td>
<td align="center" width="30">[% prod.test_plan_count %]</td>
</tr>
[% END %]
</table>
[% END %]

View File

@@ -1,149 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Plans" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<script src="testopia/js/util.js" type="text/javascript"></script>
<script src="testopia/dojo-ajax/dojo.js" type="text/javascript"></script>
<script src="testopia/js/util.js" type="text/javascript"></script>
<script type="text/javascript">
dojo.require("dojo.widget.Editor");
function addOption(selectElement,newOption) {
try {
selectElement.add(newOption,null);
}
catch (e) {
selectElement.add(newOption,selectElement.length);
}
}
function getProdVers(product, plan){
document.getElementById("prod_version").disabled = true;
dojo.io.bind({
url: "tr_show_plan.cgi",
content: { product_id: product, plan_id: plan, action: "getversions" },
load: function(type, data, evt){
var prodvers = document.getElementById("prod_version");
prodvers.options.length = 0;
var vers = data.split("|");
for (i=0; i < vers.length; i++){
var myOp = new Option(vers[i], vers[i]);
addOption(prodvers, myOp);
}
document.getElementById("prod_version").disabled = false;
},
error: function(type, error){ alert("ERROR");},
mimetype: "text/plain"
});
}
</script>
<form id="table" action="tr_list_plans.cgi" method="POST">
[% PROCESS testopia/plan/table.html.tmpl %]
<p>
[% IF table.list_count == 0 %]
No test plans
[% ELSE %]
[% IF table.list_count == 1 %]
One test plan
[% ELSE %]
[% table.list_count %] test plans
[% END %]
[% END %]
found.
</p>
[% IF dotweak AND table.list_count %]
<h3>Update Selected Test Plans</h3>
<table border="0">
<tr>
<td align="right"><b>Type</b></td>
<td>
[% PROCESS select sel = { name => 'plan_type',
accesskey => 't',
list => type_list
default => "--Do Not Change--" } %]
</td>
<td align="right"><b>Product<b></td>
<td>
[% PROCESS select sel = { name => 'product_id',
accesskey => 'p',
list => product_list
default => "--Do Not Change--"
events => "onChange='getProdVers(this.value, $plan.id)'"} %]
</td>
<td align="right"><b>Product Version<b></td>
<td>
[% PROCESS select sel = { name => 'prod_version',
accesskey => 'p',
list => prodver_list
default => "--Do Not Change--" } %]
</td>
</tr>
<tr>
<td align="right"><b>Archive/Unarchive</b></td>
<td><input name="togglearch" type="checkbox" value="1" /></td>
<td align="right"><b>Add Tags</b></td>
<td><input name="addtags" size="30" /></td>
</tr>
</table>
<a href="tr_new_case.cgi?plan_id=[% table.id_list FILTER none %]">Create a new test case linked to plans listed here</a>
<p>
<input TYPE="SUBMIT" name="action" class="tr_button" VALUE="Commit">
</p>
[% END %]
</form>
[%############################################################################%]
[%# Page Footer #%]
[%############################################################################%]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,67 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Gervase Markham <gerv@gerv.net>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% list = case_table.get_saved_list('plan') %]
<b>Plan List:</b>
[% IF list > 0 %]
[% curr = lsearch(list, plan.id) %]
[% IF curr != -1 && (curr > 0) %]
<a href="tr_show_plan.cgi?plan_id=[% list.first %]">&lt;&lt;&nbsp;First</a>
[% ELSE %]
<i><font color="#777777">&lt;&lt;First</font></i>
[% END %]
[% IF plan %]
[% IF curr != -1 %]
[% IF curr > 0 %]
[% prev = curr - 1 %]
<a href="tr_show_plan.cgi?plan_id=[% list.$prev %]">&lt;&nbsp;Prev</a>
[% ELSE %]
<i><font color="#777777">Prev</font></i>
[% END %]
[% IF curr != -1 %]
&nbsp;&nbsp;([% curr + 1 %] of [% list.size %])&nbsp;&nbsp;
[% END %]
[% IF curr + 1 < list.size %]
[% next = curr + 1 %]
<a href="tr_show_plan.cgi?plan_id=[% list.$next %]">Next&nbsp;&gt;</a>
[% ELSE %]
<i><font color="#777777">Next</font></i>
[% END %]
[% END %]
[% ELSE %]
&nbsp;&nbsp;
[% END %]
[% IF curr != -1 && (curr + 1 < list.size) %]
<a href="tr_show_plan.cgi?plan_id=[% list.last %]">Last&nbsp;&gt;&gt;</a>
[% ELSE %]
<i><font color="#777777">Last&gt;&gt;</font></i>
[% END %]
[% ELSE %]
[%# With no list, don't show link to search results %]
&nbsp;&nbsp;
<i><font color="#777777">No search results available</font></i>
[% END %]

View File

@@ -1,67 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
[% title = "Test Plan Document" %]
<html>
<head>
<title>[% plan.name %]</title>
<link href="testopia/css/report.css" rel="stylesheet" type="text/css">
</head>
<body>
<h1>Test Plan [% plan.name FILTER html %]</h1>
<div class="header">
<table>
<tr>
<td class="caption">Product:</td>
<td>[% plan.product_name FILTER html %]</td>
<td class="caption">Product version:</td>
<td>[% plan.product_version FILTER html %]</td>
</tr>
<tr>
<td class="caption">Plan version:</td>
<td>[% plan.version %]</td>
<td class="caption">Created:</td>
<td>[% plan.creation_date %]</td>
</tr>
<tr>
<td class="caption">Author:</td>
<td colspan="3">[% plan.author.identity FILTER html %]</td>
</tr>
<tr>
<td class="caption">Last Edited by:</td>
<td colspan="3">[% plan.editor.identity FILTER html %]</td>
</tr>
</table>
</div>
<div class="content1">[% IF plan.text %] [% plan.text %] [% ELSE %] <i>&lt;Empty
content&gt;</i> [% END %]</div>
</body>
</html>

View File

@@ -1,271 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% SET title = "Test Plan $plan.id: $plan.name" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = title
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% IF plan.canedit %]
<script src="testopia/js/util.js" type="text/javascript"></script>
<script src="testopia/js/tags.js" type="text/javascript"></script>
<script src="testopia/dojo-ajax/dojo.js" type="text/javascript"></script>
<script type="text/javascript">
[% IF plan.candelete %]
function addOption(selectElement,newOption) {
try {
selectElement.add(newOption,null);
}
catch (e) {
selectElement.add(newOption,selectElement.length);
}
}
function fillSelects (data, item){
var xmldocroot = data.documentElement;
var err = xmldocroot.getElementsByTagName('error');
if (err.length > 0){
alert(err[0].childNodes[0].firstChild.nodeValue);
document.getElementById("remBuild").disabled = false;
document.getElementById("remCat").disabled = false;
exit;
}
var selected = xmldocroot.getElementsByTagName(item);
var comps = document.getElementById(item);
comps.options.length = 0;
for (i=0; i< selected.length; i++){
var id = selected[i].childNodes[0].firstChild.nodeValue;
var name = selected[i].childNodes[1].firstChild.nodeValue;
var myOp = new Option(name, id);
addOption(comps,myOp);
}
document.getElementById("remBuild").disabled = false;
document.getElementById("remCat").disabled = false;
}
function removeCatBuild(id,item){
if (id == 0)
return;
var choice = confirm("You are about to delete this " + item + ". Continue?");
if (choice == 0)
return;
var myURL = (item == 'category' ? 'tr_categories.cgi' : 'tr_builds.cgi');
document.getElementById("remBuild").disabled = true;
document.getElementById("remCat").disabled = true;
dojo.io.bind({
url: myURL,
content: { category_id: id, build_id: id, plan_id: [% plan.id FILTER none %], action: 'do_delete', ajax: 1 },
load: function(type, data, evt){ fillSelects(data, item);},
error: function(type, error){ alert("ERROR Removing Category or Build " + String(error));},
mimetype: "text/xml"
});
}
[% END %]
function updateCaseList(order, direction){
dojo.io.bind({
url: 'tr_show_plan.cgi',
content: { direction: direction, getlist: [% getlist ||'null' %], viewall: [% viewall || 'null'%], order: order, plan_id: [% plan.id FILTER none %], action: 'caselist', ajax: 1 },
load: function(type, data, evt){ document.getElementById('plan_cases').innerHTML = data; },
error: function(type, error){ alert("ERROR Error updating case list" + String(error));},
mimetype: "text/html"
});
}
function page(pagenum, viewall){
dojo.io.bind({
url: 'tr_show_plan.cgi',
content: { getlist: [% getlist ||'null' %], viewall: viewall, plan_id: [% plan.id FILTER none %], action: 'caselist', ajax: 1 },
load: function(type, data, evt){ document.getElementById('plan_cases').innerHTML = data; },
error: function(type, error){ alert("ERROR Getting Page" + String(error));},
mimetype: "text/html"
});
}
</script>
[% END %]
[% PROCESS testopia/plan/navigate.html.tmpl %]
[%##### Overview #####%]
<form name="planform" action="[% form_action FILTER none %]" method="POST" enctype="multipart/form-data">
<div id="plan_overview">
<h3>Overview</h3>
<table border="0" cellpadding="1" width="100%">
<tbody align="left">
<tr class="bz_row_header">
<th>Product</th>
<th>Product Version </th>
<th>Created</th>
</tr>
<tr class="bz_row_data">
<td>[% plan.product_name FILTER html %]</td>
<td>[% plan.product_version FILTER html %]</td>
<td>[% plan.creation_date FILTER time %]</td>
</tr>
<tr class="bz_row_header">
<th>Author</th>
<th>Plan Version</th>
<th>Type</th>
</tr>
<tr class="bz_row_data">
<td><a href="mailto:[% plan.author.email FILTER html %]">[% plan.author.identity FILTER html %]</a></td>
<td>[% plan.version FILTER html %]</td>
<td>[% plan.type FILTER html %]</td>
</tr>
<tr class="bz_row_data">
<td colspan="3"><div align="right">
<a href="#attributes">Edit Plan Attributes</a>
<input type="hidden" name="plan_id" value="[% plan.id FILTER none %]">
<input type="submit" name="action" value="Commit">
<input type="submit" name="action" value="[% plan.isactive ? "Archive" : "Unarchive" %]">
<input type="submit" name="action" value="History">
<input type="submit" name="action" value="Clone">
<input type="submit" name="action" value="Print">
</div></td>
</tr>
</tbody>
</table>
</div>
[%##### Categories and Tags #####%]
<h3>Categories and Tags</h3>
<div id="plan_categories">
<table width="100%" border="0">
<tr class="bz_row_header">
<th><a href="tr_categories.cgi?plan_id=[% plan.id FILTER none %]">Categories</a></th>
<th><a href="tr_tags.cgi?id=[% plan.id FILTER none %]&type=plan">Tags</a></th>
<th><a href="tr_builds.cgi?plan_id=[% plan.id FILTER none %]">Builds</a></th>
</tr>
<tr>
<td align="left">
[% PROCESS select sel = { name => 'category',
list => plan.categories
accesskey => 'c'
elements => 7 } %]
<br>
[% IF plan.candelete %]
<input type="button" value="Remove" id="remCat" onClick='removeCatBuild(document.getElementById("category").value, "category")'>
[% END %]
</td>
<td valign="top" align="center" rowspan="2">
<div id="tagTable">
[% PROCESS testopia/tag/table.html.tmpl
item = plan
type = 'plan'
%]
</div>
</td>
<td align="right">
[% PROCESS select sel = { name => 'build',
list => plan.builds
accesskey => 'b'
elements => 7 } %]
<br>
[% IF plan.candelete %]
<input type="button" value="Remove" id="remBuild" onClick='removeCatBuild(document.getElementById("build").value, "build")'>
[% END %]
</td>
</tr>
<tr>
<td align="left"><a href="tr_categories.cgi?plan_id=[% plan.id FILTER none %]&action=add">Add</a></p></td>
<td align="right"><a href="tr_builds.cgi?plan_id=[% plan.id FILTER none %]&action=add">Add</a></p></td>
</tr>
</table>
</div>
[%##### Test Cases #####%]
<br><br>
<h3>Test Cases</h3>
<div id="plan_cases">
[% IF case_table.list_count >0 %]
<a href="tr_new_case.cgi?plan_id=[% plan.id FILTER none %]">Create a New Test Case</a>
[% END %]
[% PROCESS testopia/case/table.html.tmpl
table = case_table %]
<a href="tr_new_case.cgi?plan_id=[% plan.id FILTER none %]">Create a New Test Case</a>
</div>
[%##### Test Runs #####%]
<br><br>
<h3>Test Runs</h3>
<div id="plan_runs">
[% IF run_table.list_count >0 %]
<a href="tr_new_run.cgi?plan_id=[% plan.id FILTER none %]">Create a New Test Run</a><br />
[% END %]
[% PROCESS testopia/run/table.html.tmpl
table = run_table %]
<a href="tr_new_run.cgi?plan_id=[% plan.id FILTER none %]">Create a New Test Run</a>
</div>
[%##### Attachments #####%]
<br><br>
<h3>Attachments</h3>
<div id="attachment">
[% PROCESS testopia/attachment/table.html.tmpl
item = plan
type = "plan"
%]
</div>
[%### Reports ###%]
<br><br>
<h3>Reports</h3>
<a href="tr_plan_reports.cgi?plan_id=[% plan.id FILTER none %]">Build Coverage</a>
[%##### Edit Plan #####%]
<br><br>
[% IF plan.canedit %]
<h3>Attributes</h3>
<div id="edit_plan">
[% PROCESS testopia/plan/form.html.tmpl %]
</div>
[% ELSE %]
[%##### Plan Document #####%]
<div id="plan_doc">
[% plan.text %]
</div>
[% END %]
</form>
[%##### Footer #####%]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,78 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS testopia/blocks.html.tmpl %]
[% IF table.list_count %]
[% IF dotweak %]
Select:
<a href="javascript:sall()">All</a>,
<a href="javascript:snone()">None</a>
[% END %]
[% link = "${table.get_order_url}&order=" %]
[% DECORATIVE_BORDER_100_BEGIN %]
<table class="resultsTable" width="100%">
<tr class="bz_row_header">
[% IF dotweak %]<th></th>[% END %]
<th><a href="[% link %]name[% paren %]">Name[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th><a href="[% link %]author[% paren %]">Author[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th><a href="[% link %]created[% paren %]">Created[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th><a href="[% link %]product[% paren %]">Product[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th><a href="[% link %]plan_prodver[% paren %]">Product Version[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th><a href="[% link %]plan_type[% paren %]">Type[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th>Cases</th>
<th>Runs</th>
<th><a href="[% link %]isactive[% paren %]">Archived[% table.arrow IF table.last_sort == 'alias' %]</a></th>
</tr>
[% FOREACH plan = table.list %]
<tr class="[% loop.count % 2 == 1 ? "bz_row_odd" : "bz_row_even" %]">
[% IF dotweak %]<td align="center"><input type="checkbox" id="p_[% plan.id FILTER none %]" name="p_[% plan.id FILTER none %]"</td> [% END %]
<td><a href="tr_show_plan.cgi?plan_id=[% plan.plan_id FILTER none %]">[% plan.name FILTER html %]</a></td>
<td>[% plan.author.login FILTER html %]</td>
<td>[% plan.creation_date FILTER time %]</td>
<td>[% plan.product_name FILTER html%]</td>
<td>[% plan.product_version FILTER html%]</td>
<td align="center">[% plan.type FILTER html %]</td>
<td align="center">
<a href="tr_list_cases.cgi?plan_id=[% plan.plan_id FILTER none %]">[% plan.test_case_count FILTER html %]</a>
</td>
<td align="center">
<a href="tr_list_runs.cgi?plan_id=[% plan.plan_id FILTER none %]">[% plan.test_run_count FILTER html %]</a>
</td>
<td align="center">
[% plan.isactive ? 'No' : 'Yes' %]
</td>
</tr>
[% END %]
</tr>
</table>
[% IF NOT table.viewall %]
[% PROCESS navigation %]
[% END %]
[% DECORATIVE_BORDER_END %]
[% END %]

View File

@@ -1,126 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test run report - Bugs severity status" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = title
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% PROCESS testopia/navlinks.html.tmpl
request = "BackToTestRun"
%]
<hr/>
[% PROCESS testopia/run/edit.html.tmpl
canmanage = 0
%]
<hr/>
<FORM METHOD=POST ACTION=tr_testrun_reports.cgi>
<input type="hidden" name="action" value="do_bug_sever"/>
<input type="hidden" name="run_id" value="[% run.id FILTER none %]"/>
<TABLE BORDER="0" CELLPADDING="2" CELLSPACING="0">
<TR>
<TH ALIGN="right">Output type:</TH>
[% PROCESS select sel = { name => "output",
list => types
default => version } %]
</TR>
<TR>
<TH ALIGN="right">[% terms.Bug %] severity:</TH>
[% PROCESS select sel = { name => "severity",
list => bug_severity
mult => 1 } %]
</TR>
<TR>
<TH ALIGN="right">Who detected:</TH>
[% PROCESS select sel = { name => "testers",
list => testers
mult => 1 } %]
</TR>
<tr>
<TH ALIGN="right">Totals Only:</TH>
<td><INPUT TYPE=checkbox NAME="totals_only" value="1"></td>
</tr>
<tr>
<TH ALIGN="right">Links to [% terms.Bugs %]:</TH>
<td><INPUT TYPE=checkbox NAME="links_to_bugs" value="1" CHECKED></td>
</tr>
<TR>
<TD COLSPAN=2><INPUT TYPE="SUBMIT" VALUE="Continue"></TD>
</TR>
</TABLE>
</FORM>
<p>
[% PROCESS testopia/navlinks.html.tmpl
request = "BackToTestRun"
%]
</p>
[% PROCESS global/footer.html.tmpl %]
[%############################################################################%]
[%# Block for SELECT fields #%]
[%############################################################################%]
[% BLOCK select %]
<td align="left">
<label for="[% sel.name %]" accesskey="[% sel.accesskey %]">
<select name="[% sel.name %]" id="[% sel.name %]"
[% IF sel.mult %]
multiple="multiple"
size="7"
[% END %]>
[% FOREACH name = sel.list %]
<option value="[% name FILTER html %]"[% " selected" IF (sel.default == name OR sel.mult) %]>
[% name FILTER html %]</option>
[% END %]
</select>
</label>
</td>
[% END %]

View File

@@ -1,134 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test run report - Bugs detected" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = title
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% PROCESS testopia/navlinks.html.tmpl
request = "BackToTestRun"
%]
<hr/>
[% PROCESS testopia/run/edit.html.tmpl
canmanage = 0
%]
<hr/>
<FORM METHOD=POST ACTION=tr_testrun_reports.cgi>
<input type="hidden" name="action" value="do_bug_stats"/>
<input type="hidden" name="run_id" value="[% run.id FILTER none %]"/>
<TABLE BORDER="0" CELLPADDING="2" CELLSPACING="0">
<TR>
<TH ALIGN="right">Output type:</TH>
[% PROCESS select sel = { name => "output",
list => types
default => version } %]
</TR>
<TR>
<TH ALIGN="right">[% terms.Bug %] status:</TH>
[% PROCESS select sel = { name => "status",
list => stats
mult => 1 } %]
</TR>
<TR>
<TH ALIGN="right">[% terms.Bug %] resolution:</TH>
[% PROCESS select sel = { name => "resolution",
list => res
mult => 1 } %]
</TR>
<TR>
<TH ALIGN="right">Who detected:</TH>
[% PROCESS select sel = { name => "testers",
list => testers
mult => 1 } %]
</TR>
<tr>
<TH ALIGN="right">Totals Only:</TH>
<td><INPUT TYPE=checkbox NAME="totals_only" value="1"></td>
</tr>
<tr>
<TH ALIGN="right">Links to [% terms.Bugs %]:</TH>
<td><INPUT TYPE=checkbox NAME="links_to_bugs" value="1" CHECKED></td>
</tr>
<TR>
<TD COLSPAN=2><INPUT TYPE="SUBMIT" VALUE="Continue"></TD>
</TR>
</TABLE>
</FORM>
<p>
[% PROCESS testopia/navlinks.html.tmpl
request = "BackToTestRun"
%]
</p>
[% PROCESS global/footer.html.tmpl %]
[%############################################################################%]
[%# Block for SELECT fields #%]
[%############################################################################%]
[% BLOCK select %]
<td align="left">
<label for="[% sel.name %]" accesskey="[% sel.accesskey %]">
<select name="[% sel.name %]" id="[% sel.name %]"
[% IF sel.mult %]
multiple="multiple"
size="7"
[% END %]>
[% FOREACH name = sel.list %]
<option value="[% name FILTER html %]"[% " selected" IF (sel.default == name OR sel.mult) %]>
[% name FILTER html %]</option>
[% END %]
</select>
</label>
</td>
[% END %]

View File

@@ -1,70 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Build Coverage Report for Plan $plan.id: $plan.name" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
<table border="1">
<tr>
<td>&nbsp;&nbsp;&nbsp;&nbsp;Build<br>Case</td>
[% FOREACH b = report.builds %]
<td>[% b.value %]</td>
[% END %]
</tr>
[% FOREACH case = report.keys %]
[% IF case == 'builds' %]
[% NEXT %]
[% END %]
<tr>
<td><a href="tr_show_case.cgi?case_id=[% case %]">[% case %]</a></td>
[% FOREACH bid = report.builds.keys %]
<td align="center">
[% IF report.$case.$bid.status %]
<a href="tr_show_caserun.cgi?caserun_id=[% report.$case.$bid.id %]">
<img src="testopia/img/[% report.$case.$bid.status %]_small.gif" alt="[% report.$case.$bid.status %]" border="0" />
[% ELSE %]
&nbsp;
[% END %]
</td>
[% END %]
</tr>
[% END %]
</table>
<p>
Back to <a href="tr_show_plan.cgi?plan_id=[% plan.id FILTER none %]">plan</a>
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,68 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
<div class="header">
<table>
<tr>
<td class="caption">Product:</td>
<td>[% product %]</td>
<td class="caption">Product version:</td>
<td>[% product_version %]</td>
</tr>
<tr>
<td class="caption">Plan:</td>
<td>[% plan_name %]</td>
<td class="caption">Plan version:</td>
<td>[% plan_version %]</td>
</tr>
<tr>
<td class="caption"><b>Platform:</b></td>
<td>[% rep_platform %]</td>
<td class="caption"><b>OS:</b></td>
<td>[% op_sys %]</td>
</tr>
<tr>
<td class="caption">Summary:</td>
<td colspan="3">[% test_run_summary %]</td>
</tr>
<tr>
<td class="caption" valign="top">Notes:</td>
<td colspan="3"><pre class="tr_notes">[% test_run_notes %]</pre></td>
</tr>
<tr>
<td class="caption">Start date:</td>
<td>[% start_date %]</td>
<td class="caption">Stop date:</td>
<td>
[% IF test_run_status == 'running' %]
&lt;running&gt;
[% ELSE %]
[% stop_date %]
[% END %]
</td>
</tr>
</table>
</div>

View File

@@ -1,124 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Incident Report" %]
[%############################################################################%]
[%# Page #%]
[%############################################################################%]
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>[% title %]</title>
<link href="testopia/css/report.css" rel="stylesheet" type="text/css">
</head>
<body>
<h1>[% title %]</h1>
[% PROCESS testopia/reports/header.html.tmpl %]
<h2>Failed test cases:</h2>
[% IF caseslogs.size > 0 %]
<table>
<tr>
<th align="left">Closed at</th>
<th align="right">ID</th>
<th align="left">Summary</th>
<th align="right">Case ID</th>
<th align="left">Tested by</th>
<th align="left">Component</th>
<th align="left">Group</th>
<th align="right">Reported<br/>[% terms.bug %] IDs</th>
</tr>
[% FOREACH log = caseslogs %]
[% IF log.notes %]
[% td_class = '' %]
[% ELSE %]
[% td_class = 'class="sep"' %]
[% END %]
<tr>
<td [% td_class %] align="left">[% log.closed_date %]</td>
<td [% td_class %] align="right">[% log.id FILTER none %]</td>
<td [% td_class %] align="left">[% log.summary %]</td>
<td [% td_class %] align="right">[% log.case_id FILTER none %]</td>
<td [% td_class %] align="left">[% log.testedby %]</td>
<td [% td_class %] align="left">[% log.component %]</td>
<td [% td_class %] align="left">[% log.group %]</td>
<td [% td_class %] align="right">
[% i = 1 %]
[% FOREACH bug = log.bug_list %][% bug %][% IF i < log.bug_list.size %],&nbsp;[% END %][% i=i+1 %][% END %]
</td>
</tr>
[% IF log.notes %]
<tr>
<td class="sep" align="right" valign="top"><span class="notes">Notes:</span></td>
<td class="sep" align="left" valign="top" colspan="7"><span class="notes">[% log.notes %]</span></td>
</tr>
[% END %]
[% END %]
</table>
[% END %]
<h3>Total: [% caseslogs.size %]</h3>
<h2>Reported [% terms.bugs %]:</h2>
[% IF bugs.size > 0 %]
<table>
<tr>
<th align="right">ID</th>
<th align="left">Summary</th>
<th align="left">Severity</th>
<th align="left">Status</th>
<th align="left">Product</th>
<th align="left">Component</th>
</tr>
[% FOREACH bug = bugs %]
<tr>
<td class="sep" align="right">[% bug.id FILTER none %]</td>
<td class="sep" align="left">[% bug.short_desc %]</td>
<td class="sep" align="left">[% bug.severity %]</td>
<td class="sep" align="left">[% bug.status %]</td>
<td class="sep" align="left">[% bug.product_name %]</td>
<td class="sep" align="left">[% bug.component_name %]</td>
</tr>
[% END %]
</table>
[% END %]
<h3>Total: [% bugs.size %]</h3>
</body>
</html>

View File

@@ -1,121 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Log Report" %]
[%############################################################################%]
[%# Page #%]
[%############################################################################%]
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>[% title %]</title>
<link href="testopia/css/report.css" rel="stylesheet" type="text/css">
</head>
<body>
<h1>[% title %]</h1>
[% PROCESS testopia/reports/header.html.tmpl %]
<h2>Run test cases:</h2>
[% IF caseslogs.size > 0 %]
<table>
<tr>
<th align="left">Closed at</th>
<th align="right">ID</th>
<th align="left">Summary</th>
<th align="right">Case ID</th>
<th align="left">Tested by</th>
<th align="left">Component</th>
<th align="left">Group</th>
<th align="left">Status</th>
</tr>
[% FOREACH log = caseslogs %]
[% IF log.notes %]
[% td_class = '' %]
[% ELSE %]
[% td_class = 'class="sep"' %]
[% END %]
<tr>
<td [% td_class %] align="left">[% log.closed_date %]</td>
<td [% td_class %] align="right">[% log.id FILTER none %]</td>
<td [% td_class %] align="left">[% log.summary %]</td>
<td [% td_class %] align="right">[% log.case_id FILTER none %]</td>
<td [% td_class %] align="left">[% log.testedby %]</td>
<td [% td_class %] align="left">[% log.component %]</td>
<td [% td_class %] align="left">[% log.group %]</td>
<td [% td_class %] align="left"><span class="highlight">[% log.status %]</span></td>
</tr>
[% IF log.notes %]
<tr>
<td class="sep" align="right" valign="top"><span class="notes">Notes:</span></td>
<td class="sep" align="left" valign="top" colspan="7"><span class="notes">[% log.notes %]</span></td>
</tr>
[% END %]
[% END %]
</table>
[% END %]
<h3>Total: [% caseslogs.size %]</h3>
<h2>Pending test cases:</h2>
[% IF idlecaseslogs.size > 0 %]
<table>
<tr>
<th align="right">ID</th>
<th align="left">Summary</th>
<th align="right">Case ID</th>
<th align="left">Component</th>
<th align="left">Group</th>
</tr>
[% FOREACH log = idlecaseslogs %]
<tr>
<td class="sep" align="right">[% log.id FILTER none %]</td>
<td class="sep" align="left">[% log.summary %]</td>
<td class="sep" align="right">[% log.case_id FILTER none %]</td>
<td class="sep" align="left">[% log.component %]</td>
<td class="sep" align="left">[% log.group %]</td>
</tr>
[% END %]
</table>
[% END %]
<h3>Total: [% idlecaseslogs.size %]</h3>
<h3>Test run completed: [% completed %]&nbsp;%</h3>
</body>
</html>

View File

@@ -1,125 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test run report - Test burnout chart" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = title
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% PROCESS testopia/navlinks.html.tmpl
request = "BackToTestRun"
%]
<hr/>
[% PROCESS testopia/run/edit.html.tmpl
canmanage = 0
%]
<hr/>
<FORM METHOD=POST ACTION=tr_testrun_reports.cgi>
<input type="hidden" name="action" value="do_burnout"/>
<input type="hidden" name="run_id" value="[% run.id FILTER none %]"/>
<p>Enter time period for gathering [% terms.bugs %] counts.</p>
<p>Default values below select this test-run time boundary.</p>
<TABLE BORDER="0" CELLPADDING="2" CELLSPACING="0">
<TR>
<TH ALIGN="right">From (yyyy-mm-dd):</TH>
<TD><INPUT SIZE=12 NAME="from_date" VALUE="[% test_start FILTER html %]">
</TR>
<TR>
<TH ALIGN="right">To (yyyy-mm-dd):</TH>
<TD><INPUT SIZE=12 NAME="to_date" VALUE="[% test_end FILTER html %]">
</TR>
<tr>
<TH ALIGN="right">Show only [% terms.bugs %] detected by this test run:</TH>
<td><INPUT TYPE=checkbox NAME="run_only" value="1" checked="checked">
</tr>
<tr>
<TH ALIGN="right">Show 'bugs-cumulative':</TH>
<td><INPUT TYPE=checkbox NAME="cumulative" value="1" checked="checked">
</tr>
<TR>
<TH ALIGN="right">Size:</TH>
[% PROCESS select sel = { name => "size",
list => size
default => "normal" } %]
</TR>
<TR>
<TD COLSPAN=2><INPUT TYPE="SUBMIT" VALUE="Continue"><TD>
</TR>
</TABLE>
</FORM>
<p>
[% PROCESS testopia/navlinks.html.tmpl
request = "BackToTestRun"
%]
</p>
[% PROCESS global/footer.html.tmpl %]
[%############################################################################%]
[%# Block for SELECT fields #%]
[%############################################################################%]
[% BLOCK select %]
<td align="left">
<label for="[% sel.name %]" accesskey="[% sel.accesskey %]">
<select name="[% sel.name %]" id="[% sel.name %]"
[% IF sel.mult %]
multiple="multiple"
size="7"
[% END %]>
[% FOREACH name = sel.list %]
<option value="[% name FILTER html %]"[% " selected" IF (sel.default == name OR sel.mult) %]>
[% name FILTER html %]</option>
[% END %]
</select>
</label>
</td>
[% END %]

View File

@@ -1,55 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% title = "New Test Run For Plan: $plan.name" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
<script src="testopia/js/util.js" type="text/javascript"></script>
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<form id="table" method="post" action="tr_new_run.cgi">
<h3>Select Test Cases</h3>
[% PROCESS testopia/case/table.html.tmpl
cases = plan.test_cases %]
<br><br>
<h3>Run Attributes</h3>
[% PROCESS testopia/run/form.html.tmpl %]
<input type="hidden" name="plan_id" value="[% plan.id FILTER none %]">
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,37 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Gervase Markham <gerv@gerv.net>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS global/header.html.tmpl
title = "Search by Test Run Number"
%]
<form method="get" action="tr_show_run.cgi">
<p>
You may find a test run by entering its run id here:
<input name="run_id" size="6">
<input type="submit" value="Show Me This Test Run">
</p>
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,106 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = "Clone Test Run: $run.summary"
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<form method="POST" action="tr_show_run.cgi">
<input type="HIDDEN" name="action" value="do_clone" />
<input type="HIDDEN" name="run_id" value="[% run.id FILTER none %]" />
<table border="0" cellspacing="4">
<tr bgcolor="lightyellow">
<td colspan="2"><font size="+1">Select Clone Options</font></td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">New run summary:</td>
<td><input size="30" name="summary"
value="Copy of [% run.summary FILTER html %]" /></td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">Product version:</td>
<td>[% PROCESS select sel = { name => 'product_version',
list => run.plan.get_product_versions
accesskey => 'v'
default => run.product_version } %]</td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">Build:</td>
<td>[% PROCESS select sel = { name => 'build',
list => run.plan.builds
accesskey => 'b'
default => run.build.id } %]</td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">Copy tags:</td>
<td><input type="radio" name="copy_tags" value="1" checked />Yes <input
type="radio" name="copy_tags" value="0" />No</td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">Copy test cases:</td>
<td><input type="radio" name="copy_test_cases" value="1" checked />Yes
<input type="radio" name="copy_test_cases" value="0" />No</td>
</tr>
<tr>
<td valign="TOP" align="RIGHT">With status:</td>
<td>
[% PROCESS select sel = { name => 'status',
list => caserun.get_status_list
accesskey => 's'
mult => 1
default => 'all' } %]
</td>
</tr>
</table>
<input type="SUBMIT" value="Clone">
</form>
<p><a href="tr_show_run.cgi?run_id=[% run.id FILTER none %]">Back</a> to
test run</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,92 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
<a name="attributes"></a>
<input type="hidden" name="run_id" value="[% run.id FILTER none %]">
<table border="0" cellpadding="2" cellspacing="0">
<tr>
<th align="right">Product Version</td>
<td>
[% PROCESS select sel = { name => "product_version",
list => run.plan.get_product_versions,
default => run.product_version ? run.product_version : run.plan.product_version }
%]
</td>
<th align="right">Plan Version</td>
<td>
[% PROCESS select sel = { name => "plan_version",
list => run.plan.get_plan_versions,
default => run.plan_text_version }
%]
</td>
</tr>
<tr>
<th align="right">Manager</th>
<td><input name="manager" value="[% run.manager.login ? run.manager.login : user.login FILTER html %]"></td>
<th align="right"><a href="tr_environment.cgi">Environment</a></td>
<td>
[% PROCESS select sel = { name => "environment",
list => run.get_environments,
default => run.environment.id}
%]
</td>
</tr>
<tr>
<th align="right">Status</th>
<td>
[% SET statuslist = [{ id => 1, name => 'Running'}, {id => 0, name=> 'Stopped'}] %]
[% PROCESS select sel = { name => "status",
list => statuslist,
default => run.stop_date ? 0 : 1 }
%]
</td>
<th align="right"><a href="tr_builds.cgi?plan_id=[% run.plan.id FILTER none %]">Build</a></td>
<td>
[% PROCESS select sel = { name => "build",
list => run.plan.builds,
default => run.build.id }
%]
</td>
</tr>
<tr>
<th align="right">Summary</th>
<td colspan="3"><input type="text" size="80" name="summary" value="[% run.summary FILTER html %]"></td>
</tr>
<tr>
<th align="right" valign="top">Notes:</th>
<td colspan="5">
<textarea rows="15" cols="80" name="notes">
[% run.notes FILTER none %]
</textarea>
</td>
</tr>
</table>
<div class="submits">
<input type="submit" name="action" value="[% action %]" />
</div>

View File

@@ -1,67 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Run History for Run $run.id: $run.summary" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<table border=0>
<tr class="bz_row_header">
<th>Who</th>
<th>When</th>
<th>What</th>
<th>Old Value</th>
<th>New Value</th>
</tr>
[% FOREACH row = run.history %]
<tr class="[% loop.count % 2 == 0 ? 'bz_row_odd' : 'bz_row_even' %]">
<td><a href="mailto:[% row.who %]">[% row.who FILTER html %]</a></td>
<td>[% row.changed FILTER time %]</td>
<td>[% row.what FILTER html %]</td>
<td>[% row.oldvalue FILTER html %]</td>
<td>[% row.newvalue FILTER html %]</td>
</tr>
[% END %]
</table>
<p>
<a href="tr_show_run.cgi?run_id=[% run.id FILTER none %]">Back to run</a>
</p>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,116 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Runs" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<script src="testopia/js/util.js" type="text/javascript"></script>
<form id="table" action="tr_list_runs.cgi" method="POST">
[% PROCESS testopia/run/table.html.tmpl %]
<p>
[% IF table.list_count == 0 %]
No test runs
[% ELSE %]
[% IF table.list_count == 1 %]
One test run
[% ELSE %]
[% table.list_count FILTER none %] test runs
[% END %]
[% END %]
found.
</p>
[% IF dotweak AND table.list_count %]
<h3>Update Selected Test Runs</h3>
<table border="0">
<tr>
<td align="right"><b>Manager</b></td>
<td><input name="manager"/></td>
<td align="right"><b>Add Tags</b></td>
<td><input name="addtags" size="30" /></td>
</tr>
<tr>
</td>
<td align="right"><b>Status<b></td>
<td>
[% PROCESS select sel = { name => 'run_status',
accesskey => 's',
list => status_list
default => "--Do Not Change--" } %]
</td>
<td align="right"><b>Environment<b></td>
<td>
[% PROCESS select sel = { name => 'environment',
accesskey => 'e',
list => env_list
default => "--Do Not Change--" } %]
</td>
[% IF NOT multiprod %]
<td align="right"><b>Build<b></td>
<td>
[% PROCESS select sel = { name => 'build',
accesskey => 'b',
list => build_list
default => "--Do Not Change--" } %]
</td>
[% END %]
</tr>
</table>
<p>
<input TYPE="SUBMIT" name="action" class="tr_button" VALUE="Commit">
</p>
[% END %]
</form>
[%############################################################################%]
[%# Page Footer #%]
[%############################################################################%]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,67 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Gervase Markham <gerv@gerv.net>
# Greg Hendricks <ghendricks@novell.com>
#%]
[% list = table.get_saved_list('run') %]
<b>Run List:</b>
[% IF table && list > 0 %]
[% curr = lsearch(list, run.id) %]
[% IF curr != -1 && (curr > 0) %]
<a href="tr_show_run.cgi?run_id=[% list.first %]">&lt;&lt;&nbsp;First</a>
[% ELSE %]
<i><font color="#777777">&lt;&lt;First</font></i>
[% END %]
[% IF run %]
[% IF curr != -1 %]
[% IF curr > 0 %]
[% prev = curr - 1 %]
<a href="tr_show_run.cgi?run_id=[% list.$prev %]">&lt;&nbsp;Prev</a>
[% ELSE %]
<i><font color="#777777">Prev</font></i>
[% END %]
[% IF curr != -1 %]
&nbsp;&nbsp;([% curr + 1 %] of [% list.size %])&nbsp;&nbsp;
[% END %]
[% IF curr + 1 < list.size %]
[% next = curr + 1 %]
<a href="tr_show_run.cgi?run_id=[% list.$next %]">Next&nbsp;&gt;</a>
[% ELSE %]
<i><font color="#777777">Next</font></i>
[% END %]
[% END %]
[% ELSE %]
&nbsp;&nbsp;
[% END %]
[% IF curr != -1 && (curr + 1 < list.size) %]
<a href="tr_show_run.cgi?run_id=[% list.last %]">Last&nbsp;&gt;&gt;</a>
[% ELSE %]
<i><font color="#777777">Last&gt;&gt;</font></i>
[% END %]
[% ELSE %]
[%# With no list, don't show link to search results %]
&nbsp;&nbsp;
<i><font color="#777777">No search results available</font></i>
[% END %]

View File

@@ -1,151 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% title = "Test Run Regression Test Cases" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl
title = title
style = style
%]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
<hr/>
[% IF bugs.size == 0 %]
<p>There are no [% terms.bugs %] reported in this test run.</p>
[% ELSE %]
<form method="POST" action="tr_testrun_regression.cgi">
<input type="HIDDEN" name="form_action" value="do_create"/>
<input type="HIDDEN" name="run_id" value="[% run_id FILTER none %]"/>
<p>[% terms.Bugs %] reported in this test run:</p>
[% DECORATIVE_BORDER_BEGIN %]
<table class="resultsTable">
<tr>
<th align="right">[% terms.Bug %] ID</th>
<th align="left">Summary</th>
<th align="left">Severity</th>
<th align="left">Status</th>
<th align="left">Product</th>
</tr>
[% rowclass = "evenRow_first" %]
[% FOREACH bug = bugs %]
<tr class="[% rowclass %]"
[% IF bug.enabled %]
[% ELSE %]
style="color:grey;"
[% END %]
>
<td align="right"><input type="CHECKBOX" name="b[% bug.bug_id FILTER none %]"
[% IF bug.enabled %]
checked="TRUE" onclick="ck(this.checked);"
[% ELSE %]
disabled="true"
[% END %]
/>&nbsp;[% bug.bug_id FILTER none %]</td>
<td align="left">[% bug.summary %]</td>
<td align="left">[% bug.severity %]</td>
<td align="left">[% bug.status %]</td>
<td align="left">[% bug.product_name %]</td>
</tr>
[% IF rowclass == "oddRow" %]
[% rowclass = "evenRow" %]
[% ELSE %]
[% rowclass = "oddRow" %]
[% END %]
[% END %]
</table>
[% DECORATIVE_BORDER_END %]
<p>
Create regression test cases for each checked [% terms.bug %]?
&nbsp;<input id="bb" type="SUBMIT" value="Yes, please. Continue &gt;&gt;"/>
</p>
</form>
<input type="HIDDEN" id="cc" value="[% bugs.size %]"/>
<script type="text/javascript">
function ck(f) {
var cc = document.getElementById('cc');
if (f) {
cc.value++;
} else {
cc.value--;
}
var bb = document.getElementById('bb');
if (cc.value > 0) {
bb.disabled = false;
} else {
bb.disabled = true;
}
}
</script>
<p>
<i>Regression test cases are added to the test plan and will be available for future test runs.
[% terms.Bugs %] reported to products other than the plan's product cannot be selected.
</i>
</p>
[% END %]
<p>
<a href="tr_testruns.cgi?action=view&amp;run_id=[% run_id FILTER none %]">Go back to the test run page</a>.
</p>
<p></p>
[%############################################################################%]
[%# Page Footer #%]
[%############################################################################%]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,272 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% title = "Test Run $run.id: $run.summary" %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% IF run.canedit %]
<script src="testopia/js/util.js" type="text/javascript"></script>
<script src="testopia/js/tags.js" type="text/javascript"></script>
<script src="testopia/dojo-ajax/dojo.js" type="text/javascript"></script>
<script type="text/javascript">
function getSelected (ccbox){
var ccselected = new Array();
for (j=0; j < ccbox.options.length; j++){
if (ccbox.options[j].selected != 0)
ccselected.push(ccbox.options[j].value);
}
var sel = ccselected.toString();
return sel;
}
function fillcc (data){
var xmldocroot = data.documentElement;
var newcc = xmldocroot.getElementsByTagName('user');
var cc = document.getElementById("cc");
cc.options.length = 0;
for (i=0; i< newcc.length; i++){
var id = newcc[i].childNodes[0].firstChild.nodeValue;
var name = newcc[i].childNodes[1].firstChild.nodeValue;
var myOp = new Option(name, id);
cc.add(myOp,null);
}
document.getElementById("newcc").value = '';
document.getElementById("addCC").disabled = false;
document.getElementById("deleteCC").disabled = false;
}
function updateCC(cctext, action){
if (cctext == '')
return;
document.getElementById("addCC").disabled = true;
document.getElementById("deleteCC").disabled = true;
dojo.io.bind({
url: "tr_show_run.cgi",
content: { cc: cctext, run_id: [% run.id FILTER none %], action: action },
load: function(type, data, evt){ fillcc(data);},
error: function(type, error){ alert("ERROR");},
mimetype: "text/xml"
});
}
</script>
<style>
.number_cell{
border: 1px solid #000;
width: 100px;
text-align: right;
}
</style>
[% END %]
[% PROCESS testopia/run/navigate.html.tmpl %]
[%##### Overview #####%]
<form method="post" action="tr_show_run.cgi">
<div id="run_overview">
<h3>Overview</h3>
<table border="0" cellpadding="1" width="100%">
<tbody align="left">
<tr class="bz_row_header">
<th>Plan</th>
<th>Plan Text Version</th>
<th>Start Date</th>
</tr>
<tr class="bz_row_data">
<td><a href="tr_show_plan.cgi?plan_id=[% run.plan.id FILTER none %]">[% run.plan.name FILTER html %]</a></td>
<td>[% run.plan_text_version FILTER html %]</td>
<td>[% run.start_date FILTER time %]</td>
</tr>
<tr class="bz_row_header">
<th>Product</th>
<th>Product Version</th>
<th>Stop Date</th>
</tr>
<tr class="bz_row_data">
<td>[% run.plan.product_name FILTER html %]</td>
<td>[% run.product_version FILTER html %]</td>
<td>[% run.stop_date FILTER time %]</td>
</tr>
<tr class="bz_row_header">
<th>Manager</th>
<th>Percent Complete</th>
<th>Status</th>
</tr>
<tr class="bz_row_data">
<td><a href="mailto:[% run.manager.email FILTER html %]">[% run.manager.identity FILTER html %]</a></td>
<td align="center">
[% PROCESS testopia/percent_bar.html.tmpl
percent = run.percent_complete
%]
</td>
<td align="center">
[% IF run.stop_date %]
STOPPED
[% ELSE %]
RUNNING
[% END %]
</td>
</tr>
<tr class="bz_row_data">
<td colspan="3"><div align="right">
<table>
<tr>
<!--
<td><a href="tr_testrun_regression.cgi?run_id=[% run.id FILTER none %]">Create regression test cases</a></td> -->
<td><a href="#attributes">Edit Run Attributes</a></td>
<td><input type="submit" name="action" value="Commit"></td>
<td><input type="submit" name="action" value="History"></td>
[% IF run.candelete %]
<td><input type="submit" name="action" value="Delete"></td>
[% END %]
<td><input type="submit" name="action" value="Clone"></td>
</tr>
</table>
</div></td>
</tr>
</tbody>
</table>
</div>
<br><br>
[%##### Categories and Tags #####%]
<h3>CC, Coverage, Tags</h3>
<div id="run_categories">
<table width="100%" border="0">
<tr class="bz_row_header">
<th>CC List</th>
<th>Case Run Status</th>
<th><a href="tr_tags.cgi?id=[% run.id FILTER none %]&amp;type=run">Tags</a></th>
</tr>
<tr>
<td valign="top">
<table>
<tr>
<td>
<input name="newcc" id="newcc">
<input type="button" id="addCC" value="Add" onclick="updateCC(document.getElementById('newcc').value, 'addcc')">
</td>
</tr>
<tr>
<td>
<select name="cc" id="cc" size="5" multiple="multiple">
[% FOREACH cc = run.cc %]
<option value="[% cc.id FILTER none %]">[% cc.login FILTER html %]</option>
[% END %]
</select>
<br>
<input type="button" id="deleteCC" value="Remove" onclick="updateCC(getSelected(document.getElementById('cc')), 'removecc')">
</td>
</tr>
</table>
</td>
<td>
<table align="center">
<tr>
<th align="right">Idle:</th>
<td class="number_cell"><b>[% run.idle_count FILTER html %]</b></td>
</tr>
<tr>
<th align="right">Passed:</th>
<td class="number_cell"><b>[% run.passed_count FILTER html %]</b></td>
</tr>
<tr>
<th align="right">Failed:</th>
<td class="number_cell"><b>[% run.failed_count FILTER html %]</b></td>
</td>
</tr>
<tr>
<th align="right">Running:</th>
<td class="number_cell"><b>[% run.running_count FILTER html %]</b></td>
</tr>
<tr>
<th align="right">Paused:</th>
<td class="number_cell"><b>[% run.paused_count FILTER html %]</b></td>
</tr>
<tr>
<th align="right">Blocked:</th>
<td class="number_cell"><b>[% run.blocked_count FILTER html %]</b></td>
</td>
</tr>
<tr>
<th align="right">Total:</th>
<td class="number_cell"><b>[% run.case_count FILTER html %]</b></td>
</tr>
</table>
</td>
<td valign="top" align="center">
<div id="tagTable">
[% PROCESS testopia/tag/table.html.tmpl
item = run
type = 'run'
%]
</div>
</td>
</tr>
</table>
</div>
<br/><br/>
<h3>Test Case Run Logs</h3><a name="table" />
[% PROCESS testopia/caserun/filter.html.tmpl %]
<br/>
[% PROCESS testopia/caserun/table.html.tmpl
caseruns = run.current_caseruns %]
<a href="tr_list_cases.cgi?current_tab=case&plan_id=[% run.plan.id FILTER none %]&exclude=[% run.case_id_list FILTER none %]&addrun=[% run.id FILTER none %]">Add Cases</a>&nbsp;
<a href="tr_list_caseruns.cgi?run_id=[% run.id FILTER none %]">Update Multiple</a>
<!--
<form action="tr_list_cases.cgi" method="POST">
<input type="hidden" name="exclude" value="[% run.case_id_list FILTER none %]" />
<input type="hidden" name="current_tab" value="case" />
<input type="hidden" name="plan_id" value="[% run.plan.id FILTER none %]" />
<input type="submit" value="Add Cases" />
</form>
-->
<br><br>
<h3>Attributes</h3>
[% PROCESS testopia/run/form.html.tmpl %]
</form>
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,82 +0,0 @@
[%# 1.0@bugzilla.org %][%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Ed Fuentetaja <efuentetaja@acm.org>
# Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[% IF table.list_count > 0 %]
[% IF dotweak %]
Select:
<a href="javascript:sall()">All</a>,
<a href="javascript:snone()">None</a>
[% END %]
[% link = "${table.get_order_url}&order=" %]
[% DECORATIVE_BORDER_100_BEGIN %]
<tr class="bz_row_header">
[% IF dotweak %]<th></th>[% END %]
<th align="left"><a href="[% link %]run_id[% paren %]">ID[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th align="left"><a href="[% link %]summary[% paren %]">Summary[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th align="left"><a href="[% link %]build[% paren %]">Build[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th align="left"><a href="[% link %]manager[% paren %]">Manager[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th align="left"><a href="[% link %]environment[% paren %]">Environment[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th align="left"><a href="[% link %]start_date[% paren %]">Started[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th align="left"><a href="[% link %]stop_date[% paren %]">Finished[% table.arrow IF table.last_sort == 'alias' %]</a></th>
<th align="center">% Completed</th>
[% IF NOT plan %]<th align="left"><a href="[% link %]plan_id[% paren %]">Plan[% table.arrow IF table.last_sort == 'alias' %]</a></th>[% END %]
</tr>
[% FOREACH run = table.list %]
<TR class="[% loop.count % 2 == 1 ? "bz_row_even" : "bz_row_odd" %]">
[% IF dotweak %]<td align="center"><input type="checkbox" id="r_[% run.id FILTER none %]" name="r_[% run.id FILTER none %]" /></td> [% END %]
<td align="left"><a href="tr_show_run.cgi?run_id=[% run.id FILTER none %]">[% run.id FILTER html %]</a></td>
<td align="left">[% run.summary FILTER html %]</td>
<td align="left">[% run.build.name FILTER html %]</td>
<td align="left">[% run.manager.login FILTER html %]</td>
<td align="left">[% run.environment.name FILTER html %]</td>
<td align="left">[% run.start_date FILTER time %]</td>
<td align="left">
[% IF NOT run.stop_date %]
Running
[% ELSE %]
[% run.stop_date FILTER time %]
[% END %]
</td>
<td>
[% percent = run.percent_complete %]
[% PROCESS testopia/percent_bar.html.tmpl %]
</td>
[% IF NOT plan %]<td align="left"><a href="tr_show_plan.cgi?plan_id=[% run.plan.id FILTER none %]">[% run.plan.id FILTER html %]</a></td>[% END %]
</tr>
[% END %]
[% IF NOT table.viewall %]
[% PROCESS navigation %]
[% END %]
</table>
[% DECORATIVE_BORDER_END %]
[%# No else clause required here -- see list.html.tmpl just below
# PROCESS testopia/run/table.html.tmpl
#%]
[% END %]

View File

@@ -1,52 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Bug Tracking System.
#
# The Initial Developer of the Original Code is Netscape Communications
# Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Gervase Markham <gerv@gerv.net>
# Myk Melez <myk@mozilla.org>
#%]
[%# INTERFACE:
# tabs: List of hashes. May not be empty. Each hash has two members:
# name: string. Name of the tab and the format it represents.
# description: string. Description of the tab (used in tab title).
#%]
[% tabs = [ { name => 'c', description => "Components " },
{ name => 'b', description => "Tested by" }
{ name => 't', description => "Assigned testers" } ] %]
<table cellspacing="0" cellpadding="2" border="0" >
<tr>
[% FOREACH tab = tabs %]
[% IF tab.name == current_tab %]
<td align="center" bgcolor="lightblue" class="selected_tab">
[% tab.description %]
</td>
[% ELSE %]
<td align="center" bgcolor="#BBBBEE" class="unselected_tab">
<A HREF="tr_testruns.cgi?action=view&what_table=[% tab.name %]&run_id=[% run.id FILTER none %]">
[% tab.description %]
</a>
</td>
[% END %]
[% END %]
</tr>
</table>
</center>

View File

@@ -1,185 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
[%# INTERFACE:
# ...
#%]
[%############################################################################%]
[%# Template Initialization #%]
[%############################################################################%]
[% PROCESS global/variables.none.tmpl %]
[%############################################################################%]
[%# Page Header #%]
[%############################################################################%]
[% PROCESS global/header.html.tmpl %]
[% PROCESS testopia/messages.html.tmpl %]
[% PROCESS testopia/style.none.tmpl %]
[% PROCESS testopia/blocks.html.tmpl %]
[% tabs = [ { name => 'case', description => "Find Test Cases" },
{ name => 'run', description => "Find Test Runs" },
{ name => 'plan', description => "Find Test Plans" } ] %]
<script src="testopia/dojo-ajax/dojo.js" type="text/javascript"></script>
<script type="text/javascript">
function addOption(selectElement,newOption) {
try {
selectElement.add(newOption,null);
}
catch (e) {
selectElement.add(newOption,selectElement.length);
}
}
function fillSelects (data){
var xmldocroot = data.documentElement;
var tab = '[% current_tab FILTER none %]';
if (tab == 'run' || tab == 'plan'){
var versions = xmldocroot.getElementsByTagName('version');
var selVersion = document.getElementById("default_product_version");
selVersion.options.length = 0;
for (i=0; i< versions.length; i++){
var id = versions[i].firstChild.nodeValue;
var name = versions[i].firstChild.nodeValue;
var myOp = new Option(name, id);
addOption(selVersion,myOp);
}
}
if (tab == 'run'){
var milestones = xmldocroot.getElementsByTagName('milestone');
var builds = xmldocroot.getElementsByTagName('build');
var selMilestone = document.getElementById("milestone");
var selBuild = document.getElementById("build");
selBuild.options.length = 0;
selMilestone.options.length = 0;
for (i=0; i< milestones.length; i++){
var id = milestones[i].firstChild.nodeValue;
var name = milestones[i].firstChild.nodeValue;
var myOp = new Option(name, id);
addOption(selMilestone,myOp);
}
for (i=0; i< builds.length; i++){
var id = builds[i].firstChild.nodeValue;
var name = builds[i].firstChild.nodeValue;
var myOp = new Option(name, id);
addOption(selBuild,myOp);
}
}
if (tab == 'case' || tab == ''){
var components = xmldocroot.getElementsByTagName('component');
var categories = xmldocroot.getElementsByTagName('category');
var selComponent = document.getElementById("component");
var selCategory = document.getElementById("category");
selComponent.options.length = 0;
selCategory.options.length = 0;
for (i=0; i< components.length; i++){
var id = components[i].firstChild.nodeValue;
var name = components[i].firstChild.nodeValue;
var myOp = new Option(name, id);
addOption(selComponent,myOp);
}
for (i=0; i< categories.length; i++){
var id = categories[i].firstChild.nodeValue;
var name = categories[i].firstChild.nodeValue;
var myOp = new Option(name, id);
addOption(selCategory,myOp);
}
}
}
function onProductSelection(){
var prod = document.getElementById("product_id");
var ids = new Array;
for (var i=0; i<prod.options.length; i++){
if (prod.options[i].selected == true)
ids.push(prod.options[i].value);
}
dojo.io.bind({
url: "tr_query.cgi",
content: { current_tab: "[% current_tab FILTER none %]", prod_ids: ids.join(","), action: "getversions" },
load: function(type, data, evt){ fillSelects(data);},
error: function(type, error){ alert("ERROR");},
mimetype: "text/xml"
});
}
</script>
<table cellspacing="0" cellpadding="10" border="0" width="100%">
<tr>
<td class="spacer">&nbsp;</td>
[% FOREACH tab = tabs %]
[% IF tab.name == current_tab %]
<td align="center" bgcolor="lightblue" class="selected_tab">
[% tab.description %]
</td>
[% ELSE %]
<td align="center" bgcolor="#BBBBEE" class="unselected_tab">
<a href="tr_query.cgi?current_tab=[% tab.name %]" >
[% tab.description %]
</a>
</td>
[% END %]
[% END %]
<td class="spacer">&nbsp;</td>
</tr>
</table>
[%# Taken from bugzilla search/form.html.tmpl %]
[% query_variants = [
{ id => "allwordssubstr", name => "contains all of the words/strings" },
{ id => "anywordssubstr", name => "contains any of the words/strings" },
{ id => "substring", name => "contains the string" },
{ id => "casesubstring", name => "contains the string (exact case)" },
{ id => "allwords", name => "contains all of the words" },
{ id => "anywords", name => "contains any of the words" },
{ id => "regexp", name => "matches the regexp" },
{ id => "notregexp", name => "doesn't match the regexp" } ] %]
[% email_variants = [
{ id => "substring", name => "contains" },
{ id => "exact", name => "is" },
{ id => "regexp", name => "matches regexp" },
{ id => "notregexp", name => "doesn't match regexp" } ] %]
[% tag_variants = [
{ id => "allwords", name => "contains all of the tags" },
{ id => "anywords", name => "contains any of the tags" },
{ id => "nowords", name => "contains none of the tags" } ] %]
[% IF current_tab == 'plan' %]
[% PROCESS testopia/search/plan.html.tmpl %]
[% ELSIF current_tab == 'run' %]
[% PROCESS testopia/search/run.html.tmpl %]
[% ELSE %]
[% PROCESS testopia/search/case.html.tmpl %]
[% END %]
[% PROCESS global/footer.html.tmpl %]

View File

@@ -1,189 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
<form action="tr_list_cases.cgi" method="GET">
<input type="hidden" name="current_tab" value="[% current_tab FILTER none %]" />
<fieldset>
<legend><strong>Product</strong></legend>
<table>
<tr class="bz_row_header">
<th>Status</th>
<th>Product</th>
<th>Components</th>
<th>Category</th>
<th>Priority</th>
<th>Automatic</th>
</tr>
<tr>
<td style="padding-right: 30px;">
[% PROCESS select sel = { name => 'case_status_id',
accesskey => 'c',
list => case.get_status_list,
elements => 5,
mult => 1 } %]
</td>
<td style="padding-right: 30px;">
[% PROCESS select sel = { name => 'product_id',
accesskey => 'p',
list => plan.get_available_products,
elements => 5,
mult => 1
events => 'onChange="onProductSelection()"' } %]
</td>
<td style="padding-right: 30px;">
[% PROCESS select sel = { name => 'component',
accesskey => 'm',
list => case.get_available_components
elements => 5,
mult => 1 } %]
</td>
<td style="padding-right: 30px;">
[% PROCESS select sel = { name => 'category',
accesskey => 't',
list => case.get_distinct_categories,
elements => 5,
mult => 1 } %]
</td>
<td style="padding-right: 30px;">
[% PROCESS select sel = { name => 'priority_id',
accesskey => 'p',
list => case.get_priority_list
elements => 5,
mult => 1 } %]
</td>
<td style="padding-right: 30px;">
[% PROCESS select sel = { name => 'isautomated',
accesskey => 'a',
list =>
[ { id => "0", name => "Manual" },
{ id => "1", name => "Automatic" } ]
elements => 5,
mult => 1 } %]
</td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><strong>Attributes</strong></legend>
<table>
<tr>
<th align="right">Summary:</tH>
<td>
[% PROCESS select sel = { name => 'summary_type',
list => query_variants } %]</td>
<td><input name="summary"></td>
</tr>
<tr>
<th align="right">Action:</tH>
<td>
[% PROCESS select sel = { name => 'tcaction_type',
list => query_variants } %]</td>
<td><input name="tcaction"></td>
</tr>
<tr>
<th align="right">Expected Results:</tH>
<td>
[% PROCESS select sel = { name => 'tceffect_type',
list => query_variants } %]</td>
<td><input name="tceffect"></td>
</tr>
<tr>
<th align="right">Script:</tH>
<td>
[% PROCESS select sel = { name => 'script_type',
list => query_variants } %]</td>
<td><input name="script"></td>
</tr>
<tr>
<th align="right">Requirement:</tH>
<td>
[% PROCESS select sel = { name => 'requirement_type',
list => query_variants } %]</td>
<td><input name="requirement"></td>
</tr>
<tr>
<th align="right">Tags:</tH>
<td>
[% PROCESS select sel = { name => 'tags_type',
list => tag_variants } %]</td>
<td><input name="tags"></td>
</tr>
<tr>
<th align="right">Author:</tH>
<td>
[% PROCESS select sel = { name => 'author_type',
list => email_variants } %]</td>
<td><input name="author"></td>
<th><input type="radio" name="andor" value="1"/>AND
<input type="radio" name="andor" value="0" checked="checked"/>OR</th>
</tr>
<tr>
<th align="right">Default Tester:</th>
<td>
[% PROCESS select sel = { name => 'default_tester_type',
list => email_variants } %]</td>
<td><input name="default_tester"></td>
</tr>
</tr>
</table>
</fieldset>
<!--
<fieldset>
<legend><strong>Case Changes</strong></legend>
<dl class="bug_changes">
<dt>Only cases changed between:</dt>
<dd>
<input name="chfieldfrom" size="10" value="[% default.chfieldfrom.0 FILTER html %]">
and <input name="chfieldto" size="10" value="[% default.chfieldto.0 FILTER html %]">
(YYYY-MM-DD or relative dates)
</dd>
<dt>where one or more of the following changed:</dt>
<dd>
[% PROCESS select sel = { name => 'chfield_type',
accesskey => 'p',
list => case.get_fields
elements => 5,
mult => 1 } %]
</dd>
<dt>and the new value was:</dt>
<dd>
<input name="chfieldvalue" size="20" value="[% default.chfieldvalue.0 FILTER html %]">
</dd>
</dl>
</fieldset>
-->
<p style="font-weight: bold;">
<label for="case_id">
Include cases numbered:
</label>
<input name="case_id" id="case_id">
<br/><br/>
<label for="plan_id">
Include cases from plans numbered:
</label>
<input name="plan_id" id="plan_id">
<br/><br/>
</p>
<input type="submit" value="Submit">
</form>

View File

@@ -1,141 +0,0 @@
[%# 1.0@bugzilla.org %]
[%# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is the Bugzilla Test Runner System.
#
# The Initial Developer of the Original Code is Maciej Maczynski.
# Portions created by Maciej Maczynski are Copyright (C) 2001
# Maciej Maczynski. All Rights Reserved.
#
# Contributor(s): Greg Hendricks <ghendricks@novell.com>
#%]
<form action="tr_list_plans.cgi" method="GET">
<input type="hidden" name="current_tab" value="[% current_tab FILTER none %]" />
<fieldset>
<legend><strong>Product</strong></legend>
<table>
<tr class="bz_row_header">
<th>Product</th>
<th>Product Version</th>
<th>Type</th>
</tr>
<tr>
<td style="padding-right: 30px;">
[% PROCESS select sel = { name => 'product_id',
accesskey => 'p',
list => plan.get_available_products,
elements => 5,
mult => 1
events => 'onChange="onProductSelection()"' } %]
</td>
<td style="padding-right: 30px;">
[% PROCESS select sel = { name => 'default_product_version',
accesskey => 'v',
list => product_versions,
elements => 5,
mult => 1 } %]
</td>
<td style="padding-right: 30px;">
[% PROCESS select sel = { name => 'type_id',
accesskey => 'p',
list => plan.get_plan_types
elements => 5,
mult => 1 } %]
</td>
</tr>
</table>
</fieldset>
<fieldset>
<legend><strong>Attributes</strong></legend>
<table>
<tr>
<th align="right">Name:</tH>
<td>
[% PROCESS select sel = { name => 'name_type',
list => query_variants } %]</td>
<td><input name="name"></td>
</tr>
<tr>
<th align="right">Text:</tH>
<td>
[% PROCESS select sel = { name => 'plan_text_type',
list => query_variants } %]</td>
<td><input name="plan_text"></td>
</tr>
<tr>
<th align="right">Tags:</tH>
<td>
[% PROCESS select sel = { name => 'tags_type',
list => tag_variants } %]</td>
<td><input name="tags"></td>
</tr>
<tr>
<th align="right">Author:</tH>
<td>
[% PROCESS select sel = { name => 'author_type',
list => email_variants } %]</td>
<td><input name="author"></td>
<th><input type="radio" name="andor" value="1"/>AND
<input type="radio" name="andor" value="0" checked="checked"/>OR</th>
</tr>
<tr>
<th align="right">Editor:</tH>
<td>
[% PROCESS select sel = { name => 'editor_type',
list => email_variants } %]</td>
<td><input name="editor"></td>
</tr>
</table>
</fieldset>
<!--
<fieldset>
<legend><strong>Plan Changes</strong></legend>
<dl class="bug_changes">
<dt>Only plans changed between:</dt>
<dd>
<input name="chfieldfrom" size="10" value="[% default.chfieldfrom.0 FILTER html %]">
and <input name="chfieldto" size="10" value="[% default.chfieldto.0 FILTER html %]">
(YYYY-MM-DD or relative dates)
</dd>
<dt>where one or more of the following changed:</dt>
<dd>
[% PROCESS select sel = { name => 'chfield_type',
accesskey => 'p',
list => plan.get_fields
elements => 5,
mult => 1 } %]
</dd>
<dt>and the new value was:</dt>
<dd>
<input name="chfieldvalue" size="20" value="[% default.chfieldvalue.0 FILTER html %]">
</dd>
</dl>
</fieldset>
-->
<p style="font-weight: bold;">
<label for="plan_id">
Include plans numbered:
</label>
<input name="plan_id" id="plan_id">
<br/><br/>
<label for="archived">
Include Archived Plans:
</label>
<input type="checkbox" name="isactive" id="isactive" value="1" />
</p>
<input type="submit" value="Submit">
</form>

Some files were not shown because too many files have changed in this diff Show More