28 require_once(
'../fossologyTestCase.php');
29 require_once(
'../commonTestFuncs.php');
30 require_once(
'../TestEnvironment.php');
31 require_once(
'../testClasses/parseBrowseMenu.php');
32 require_once(
'../testClasses/parseMiniMenu.php');
33 require_once(
'../testClasses/parseFolderPath.php');
34 require_once(
'../testClasses/dom-parseLicenseTable.php');
35 require_once(
'../copyright/libCopyRight.php');
57 $name =
'RedHat.tar.gz';
58 $safeName = escapeDots($name);
59 $this->host = getHost($URL);
64 $page = $this->mybrowser->get($URL);
65 $page = $this->mybrowser->clickLink(
'Browse');
66 $this->assertTrue($this->myassertText($page,
'/Browse/'),
67 "verifySimpletest FAILED! Could not find Browse menu\n");
68 $page = $this->mybrowser->clickLink(
'Testing');
69 $this->assertTrue($this->myassertText($page,
"/$safeName/"),
70 "verifySimpleTest FAILED! Could not find RedHat.tar upload\n");
71 $result = $this->myassertText($page,
"/$name/");
82 print
"starting print lics\n";
83 $page = $this->mybrowser->clickLink(
'Browse');
84 $this->assertTrue($this->myassertText($page,
'/Browse/'),
85 "verifySimpleTest FAILED! Could not find Browse menu\n");
86 $this->assertTrue($this->myassertText($page,
"/Browse/"),
87 "verifySimpleTest FAILED! Browse Title not found\n");
88 $this->assertTrue($this->myassertText($page,
"/$safeName/"),
89 "verifySimpleTest FAILED! did not find $name\n");
90 $this->assertTrue($this->myassertText($page,
"/>View</"),
91 "verifySimpletest FAILED! >View< not found\n");
92 $this->assertTrue($this->myassertText($page,
"/>Info</"),
93 "verifySimpletest FAILED! >Info< not found\n");
94 $this->assertTrue($this->myassertText($page,
"/>Download</"),
95 "verifySimpletest FAILED! >Download< not found\n");
98 $page = $this->mybrowser->clickLink(
'Testing');
99 $page = $this->mybrowser->clickLink($name);
101 $this->assertTrue($this->myassertText($page,
"/1 item/"),
102 "verifySimpletest FAILED! '1 item' not found\n");
103 $this->assertTrue($this->myassertText($page,
"/RedHat/"),
104 "verifySimpletest FAILED! 'RedHat' not found\n");
105 $page = $this->mybrowser->clickLink(
'RedHat/');
110 $miniMenu = $mini->parseMiniMenu();
112 $url = makeUrl($this->host, $miniMenu[
'Nomos License']);
113 if($url === NULL) { $this->fail(
"RHEL Lics Failed, host/URL is not set"); }
115 $page = $this->mybrowser->get($url);
119 $ct->parseLicenseTbl();
122 $this->fail(
"Error! table with id=copyright has no rows!" .
123 " nothing to process, There should be!\n");
125 else if(empty($ct->hList)) {
126 $this->fail(
"Error! table with id=copyright was not found on" .
127 "the page, There should be one\n");
131 print
"\$copyStd = array(\n";
132 foreach($ct->hList as $list)
134 $cs = cleanString($list[
'textOrLink']);
135 print
" '$cs' => $list[count],\n";
136 $total += (int)$list[
'count'];
Login($User=NULL, $Password=NULL)