Commit Graph

74 Commits

Author SHA1 Message Date
Lucas Bickel 625f92fe44 Vendorize ZF1, fix PHPUnit and configure travis
This a a rather large commit due to the nature of the stuff it is touching. To get PHPUnit up and running again I had to update some deps and I did so by vendorizing them. The vendorizing of zf1 makes sense since distros are already considering to drop it from their repos.

* [x] install vendorized zf1 with composer
* [x] load composer autoloader before zf1
* [x] Implement headAction for all Zend_Rest_Controller based controllers
* [x] switch to yml dataset to get around string only limitations of xml sets (also removed warning in readme)
* [x] use year 2044 as hardcoded date for tests since it is in the future and has the same days like previously used 2016
* [x] make tests easier to run when accessing phpunit directly
* [x] clean up test helper to always use airtime.conf
* [x] switch test dbname to libretime_test
* [x] test db username password switched to libretime/libretime
* [x] install phpunit with composer in a clear version (make tests easier to reproduce on other platforms)
* [x] remove local libs from airtime repo (most of airtime_mvc/library was not needed of in vendor already)
* [x] configure composer autoloading and use it (also removed requires that are not needed anymore)
* [x] add LibreTime prefix for FileNotFoundException (phing had a similar class and these are all pre-namespace style)
* [x] add .travis.yml file
* [x] make etc and logdir configurable with LIBRETIME_CONF_DIR and LIBRETIME_LOG_DIR env (so travis can change it)
* [x] slight cleanup in config for travis not to fail
* [x] add cloud_storage.conf for during test runs
* [x] rewrite mvc testing docs and move them to docs/ folder
* [x] don't use `static::class` in a class that does not have a parent class, use `__CLASS__` instead.
* [x] don't use `<ClassName>::class`, since we already know what class we want `"<ClassName>"` ist just fine.
* [x] fix "can't use method in write context" errors on 5.4 (also helps the optimizer)
* [x] add build status badge on main README.md

Fixes https://github.com/LibreTime/libretime/issues/4

The PHP parts of https://github.com/LibreTime/libretime/pull/10 get obsoleted by this change and it will need rebasing.

This also contains https://github.com/LibreTime/libretime/pull/8, the late static binding compat code was broken for no reason and until CentOS drops php 5.4 there is no reason I'm aware of not to support it. I inlined #8 since the test would be failing on php 5.4 without the change.

If you want to run tests you need to run `composer install` in the root directory and then `cd airtime_mvc/tests && ../../vendor/bin/phpunit`. For the tests to run the user `libretime` needs to be allowed to create the `libretime_test` database. See `docs/TESTING.md` for more info on getting set up.
2017-02-27 17:59:01 +01:00
Duncan Sommerville 5fe70754bd Replace all timestamp strings with constant 2015-06-26 14:42:52 -04:00
Albert Santoni b4c9a77e7c CC-6055: Improved escaping 2015-06-12 13:48:54 -04:00
Mark Lewis a27ca2f583 cleanup new HTTP apiendpoints, added HTTPHelper and getStartEndFromRequest and updated all controllers that called their own versions of this function 2015-01-09 13:02:25 -05:00
Mark Lewis 44b4faf6d9 added shows, show-schedules, show-preview, show-history-feed, item-history-feed endpoints to the HTTP api to be used via NewscoopAirtimePlugin 2015-01-09 13:01:42 -05:00
drigato 3b9608a8df CC-5693: API call to notify-item-start-playing fails because an invalid schedule id is sent
Temporary fix for this bug. Throw an exception if no schedule item is found.
2014-02-10 16:19:26 -05:00
Naomi 4c331aa955 CRLF 2013-10-11 11:08:49 -04:00
Naomi 61bab553ff CC-5396 : Playout History: Restart airtime-liquidsoap will cause redundant items in history log 2013-10-11 11:07:59 -04:00
Naomi 0c4dcda508 CC-5394 : File Summary Fix
need to check if length is set.
2013-10-10 16:01:53 -04:00
Naomi 1fa13eed13 CRLF 2013-09-30 13:59:08 -04:00
Naomi 7d739a0f66 CC-5316 : Playout History: Doesn't support webstream
adding the webstream metadata to the history table.
2013-09-30 13:56:27 -04:00
Daniel James 577bbf14b6 Remove swear words from source code 2013-09-23 16:16:51 +01:00
Naomi Aro 4a4ef2767e CC-5318 : Playout History: The last song of the show will display wrong end time. 2013-09-01 17:59:47 -04:00
Naomi Aro 9c0bee3877 adding show instance to the create form if it's already set. 2013-08-31 23:34:37 -04:00
Naomi 0c379ef840 a working show instance select. 2013-08-30 15:03:43 -04:00
Naomi Aro 15e27f8166 history records for a show have times validated within show range. 2013-08-30 00:43:43 -04:00
Naomi Aro 0f0958ee6b changing the query to only filter by instance id not starts/ends if instance id is set. 2013-08-29 18:32:42 -04:00
Naomi d50cdd16c2 starting association of a show instance. 2013-08-29 17:40:08 -04:00
Naomi f97069bd0b displaying show list in proper time zone. 2013-08-29 15:58:24 -04:00
Naomi 5780eb5bbe show tables filtering by instance id. 2013-08-29 15:17:24 -04:00
Naomi Aro a4c97479b6 using an accordian to display per show logs. 2013-08-28 23:30:15 -04:00
Naomi 429cdeeffb filtering by a host's show so they can edit their own playout history. 2013-08-28 19:37:46 -04:00
Naomi 653a6384b9 creating a separate controller for playouthistory templates. 2013-08-28 18:25:46 -04:00
Naomi 5aa983be36 adding an instance id to the playout history table. 2013-08-28 17:15:36 -04:00
Naomi dbe160c5d9 beginning of displaying form errors, need to keep working on this. 2013-08-23 15:52:49 -04:00
Naomi 84efdfd64a crlf 2013-08-20 17:23:48 -04:00
Naomi 007a7ee7ef casting non mandatory types from "", to avoid database query problems. 2013-08-20 17:23:15 -04:00
Naomi 2e572c652c creating a random string for field names to work for all languages. 2013-08-20 15:31:13 -04:00
Naomi Aro 3ea2b920a6 crlf 2013-08-19 23:20:26 -04:00
Naomi Aro 09693ef174 changing to context menu single edit/delete. 2013-08-19 23:19:13 -04:00
Naomi 7cf654551d crlf 2013-08-14 16:39:50 -04:00
Naomi 673c422015 replacing booleans in table with checkbox + column title 2013-08-14 16:38:59 -04:00
Naomi c3c64e6fb1 crlf 2013-08-12 18:18:58 -04:00
Naomi fdf18ec3ce upgrading table tools to version 2.1.5 2013-08-12 18:18:33 -04:00
Naomi b65007868a crlf fix 2013-08-12 15:08:09 -04:00
Naomi d83c004fb9 subclassing the template types, files summary table is now fully configurable form wise. 2013-08-12 15:06:26 -04:00
Naomi 27b079ace9 adding a label to the form fields (Datatables column headers) 2013-08-07 17:55:18 -04:00
Naomi aaf2e5c2f6 better casting on form checkbox, setting populate flag properly based on if id is set (for create/update) 2013-08-05 15:05:26 -04:00
Naomi 31c604d09c can update an existing history item entry. Form is pre-populated. 2013-08-02 18:16:23 -04:00
Naomi 590837a357 crlf 2013-08-02 16:16:04 -04:00
Naomi e047c2f71d can configure the file summary template as well now. 2013-08-02 16:15:32 -04:00
Naomi 774027c9bd crlf 2013-08-02 15:30:35 -04:00
Naomi c110b4b4df file summary table now starting to work with templates.need to change query around to be configurable still. 2013-08-02 15:29:39 -04:00
Naomi b480a5ae18 crlf 2013-08-02 11:19:46 -04:00
Naomi 6e43094d10 pagination working properly (but not with filtering, have removed serach for now anyways.) 2013-08-02 11:18:15 -04:00
Naomi af38d3cb02 CRLF 2013-08-01 17:10:04 -04:00
Naomi 2341b7b68c can order data in the item table 2013-08-01 17:09:42 -04:00
Naomi 557b3f9c9b CRLF 2013-08-01 16:37:10 -04:00
Naomi a5a99da21e Editing templates, strictly typing metadata for datatables (for unions) 2013-08-01 16:36:18 -04:00
Naomi b33f33964a crlf 2013-07-31 17:39:45 -04:00