5 Commits

Author SHA1 Message Date
David Mudrák
9d6eb027b4 MDL-34401 Cache the contents of version.php files
This saves many inclusions of version.php files.
2013-03-11 12:51:30 +01:00
David Mudrák
3daedb5c5a MDL-35238 Implement deployment authorization
The caller of the mdeploy.php utility is expected to create a file in
the data directory. The name of such file and the passphrase in it are
then sent to mdeploy.php as a part of the request. The submitted and
stored values are then compared.
2012-11-08 22:33:07 +01:00
David Mudrák
7683e550ac MDL-35238 Introduce available_update_deployer class
This class represents the communication bridge from Moodle UI to the
(standalone) mdeploy.php utility. It consists of various helper methods
useful when dealing with user interface, update confirmation etc.

The class is implemented as a singleton. This allows us easily
transfer required data from top level scripts (like /admin/index.php)
into the rendering methods deep in the stack without the need to change
the API of many methods on the way.
2012-11-08 22:33:06 +01:00
David Mudrák
720f7c12e8 MDL-35109 Improve unittests for cron based fetching of available updates
The expected behaviour is as follows:

* If the recently fetched data is older than 48 hours, it is considered
  as outdated and the new fetch is executed
* else, if the recently fetched data is younger than 24 hours, it is
  considered as fresh enough and no fetch is executed
* else, if the current time is after 01:00 AM plus a certain offset
  (which is randomly generated for each site), the fetch is
  executed.
2012-08-28 22:59:26 +02:00
Petr Skoda
37ba2528c1 MDL-32569 convert the remaining tests 2012-04-21 17:47:30 +02:00