FOSSology  3.2.0rc1
Open Source License Compliance by Open Source Software
AgentTestMockHelper.php
1 <?php
2 
3 namespace Fossology\Lib\Agent;
4 
5 function cli_Init()
6 {
7 }
8 
9 function getopt($arg1, $arg2)
10 {
11  global $userId;
12  global $jobId;
13  global $groupId;
14  global $extraOpts;
15 
16  if (! is_array($extraOpts)) {
17  $extraOpts = array();
18  }
19 
20  $opts = array_merge(
21  array(
22  "scheduler_start" => "",
23  "userID" => $userId,
24  "jobId" => $jobId,
25  "groupID" => $groupId
26  ), $extraOpts);
27 
28  return $opts;
29 }
30 
31 function fgets($in)
32 {
33  global $fgetsMock;
34 
35  return $fgetsMock->fgets($in);
36 }
37 
38 class FgetsMock
39 {
40  function fgets($in)
41  {
42  }
43 }
44 
cli_Init()
Initialize the fossology environment for CLI use. This routine loads the plugins so they can be use b...
Definition: common-cli.php:36