3619 Commits

Author SHA1 Message Date
Jamie McClymont
a2b393317d Populate first_instance_start and last_instance_end on resource write 2019-01-03 17:48:42 +13:00
Jamie McClymont
cf7de16e59 Handle default timezones in getVCalendarRange
Also includes some PHPUnit-based tests for this function!
2019-01-03 17:48:42 +13:00
Jamie McClymont
0c006b5c7c Make the recurrence range columns in the database tz-aware 2019-01-03 16:04:28 +13:00
Jamie McClymont
5fc3875345 Pull the freebusy floating-time handling into a function 2019-01-03 16:04:28 +13:00
Jamie McClymont
28c78023b5 Keep Apache logs as CI artifacts for debugging failures 2019-01-03 16:04:28 +13:00
Florian Schlichting
7330eaf995 checkpoint scheduling test results and add them to CI runner (fixes: #170)
I think these remaining changes are due to AWLs vCalendar->GetItip()
creating a "minimal iTIP version" of events, and Jan Mate's "various
scheduling related fixes" in 31af435c and 92f48f38
2018-12-31 03:34:37 +01:00
Florian Schlichting
df13612a68 mask unstable DTSTAMP in scheduling tests
It is reset to the current date in AWL's vCalendar->GetItip()
2018-12-31 03:23:08 +01:00
Andrew Ruthven
040ed9767f Merge remote-tracking branch 'origin/include-version-in-setup' 2018-12-30 21:58:18 +13:00
Florian Schlichting
19eb79ebf9 provide defaults for unused function parameters (fixes #155)
PHP 7.1 throws an exception when a user-defined function is called with
too few arguments: http://php.net/manual/en/migration71.incompatible.php

As explained in the comments, collection_privilege_format_function and
principal_privilege_format_function take three arguments because of
their use as a rendering callback, however the latter two of them are
never used and thus can be ommitted in other uses.
2018-12-29 19:38:13 +01:00
Florian Schlichting
0023b066fd Debian: use system perl in dba/update-davical-database 2018-12-29 11:54:09 +01:00
Florian Schlichting
3115c92a74 Update debian/watch to changed Gitlab directory layout 2018-12-29 11:10:24 +01:00
Florian Schlichting
44bb5cf7b6 fix to more uses of continue inside switch discovered by CI
I wonder why I saw the first few, but not these?
2018-12-22 19:56:25 +01:00
Florian Schlichting
a51caa38f1 properly check if $row has been unset (fixes #141)
Also fix deprecation warnings introduced with PHP 7.3 about the use of
continue inside switch statements, see
https://wiki.php.net/rfc/continue_on_switch_deprecation
2018-12-22 19:13:13 +01:00
Andrew Ruthven
55586c784e Remove use of $old_attendees
Closes #141
2018-12-22 19:12:50 +01:00
Florian Schlichting
9e8c3c47c4 Test: max-resource-size is no longer infinity
c5891abc7f brought back a new, higher limit, which is configurable by
the site admin.
2018-12-22 00:18:27 +01:00
Florian Schlichting
1301b2c494 Apache 2.4.35 stops sending Content-Type headers for 204 No Content responses
Normalize results so tests work with newer and older versions

This change is similar to e565cc0a5e4af0330fe5a1ab6f2476be7fb10df4 and
following

From the Apache 2.4.35 changelog:

  *) http: Enforce consistently no response body with both 204 and 304
     statuses.  [Yann Ylavic]
2018-12-22 00:12:54 +01:00
Florian Schlichting
c3654a9d48 call fetch_external with external_ua_string (fixes #164) 2018-12-22 00:02:09 +01:00
Florian Schlichting
c21313d05e Merge branch 'fix_max_carddav_resource_size' into 'master'
Introduce new global variable to control maximum size of carddav resources.

See merge request davical-project/davical!53
2018-12-21 22:43:53 +00:00
Andrew Ruthven
5effad3e80 Merge branch 'ci' into 'master'
Add Gitlab CI

See merge request davical-project/davical!56
2018-11-30 11:03:51 +00:00
Jamie McClymont
a4c9718bb2 Add Gitlab CI
Signed-off-by: Jamie McClymont <jamiemcclymont@catalyst.net.nz>
2018-11-30 15:59:04 +13:00
Jamie McClymont
0e0a07eb30 Fix returning dead properties in an allprop PROPFIND
dead_properties is an assoc.array from name to value, but it was being merged
with simple arrays of property names.

This means that tests 0824 and 0828 now actually return the dead properties, so
I've updated those result files.

Signed-off-by: Jamie McClymont <jamiemcclymont@catalyst.net.nz>
2018-11-30 15:59:04 +13:00
Andrew Ruthven
8c01c83e4b Ignore the id in our test comparision
Gitlab CI has a different collection_id for US Holidays than running
the tests locally. We don't actually care about ID for this test,
just the fact that the binding is present is enough for us.
2018-11-30 15:02:53 +13:00
Andrew Ruthven
0c074e4348 Explicitly set the Charset to use, and look for the usual format.
In the GitLab CI environment, the command:

@header("Content-Type: text/plain");

Generates the Content-Type line of:

Content-Type: text/plain; charset=UTF-8

But on my workstation it generates this:

Content-Type: text/plain;charset=UTF-8

By adding that charset to our call to @header, we receive a
predictable result.
2018-11-29 13:40:12 +13:00
Andrew Ruthven
9d2969982c Exclude the ctags from the test
We don't really care about the ctag in this test, and the ctag
for user1 will change from test run to test run.
2018-11-29 13:24:25 +13:00
Andrew Ruthven
46c76c645f Atually, options aren't supported on the end of REPLACE 2018-11-29 13:20:44 +13:00
Andrew Ruthven
bdc480b785 Merge branch 'freebusy-no-ci' into 'master'
Correctly place floating events in freebusy

Closes #169 and #146

See merge request davical-project/davical!57
2018-11-13 22:19:49 +00:00
Andrew Ruthven
12565cb6bd Make the tests more interesting by using ctag 2018-11-12 20:14:40 +13:00
Andrew Ruthven
deb743fdcf Add tests for: Fix Fatal PHP Error if Depth is more than 1.
I'm not 100% this is working as intended, but it does kind
of make sense.
2018-11-12 20:00:20 +13:00
Andrew Ruthven
48efbb272b Fix Fatal PHP Error if Depth is more than 1.
Merge request was proposed by xhess on GitLab, but the commit
had no content. I've solved it, possibly the same way.

For the initial commit:
Executing the second example at https://wiki.davical.org/index.php?title=PROPFIND
The "Depth: 2" header is the problem. Setting the depth header larger than 1
causes the function "compare_val_with_re" to be defined again. Now checking if
the function has already been defined fixes the problem.
2018-11-12 19:32:34 +13:00
Andrew Ruthven
872f4fc6ad Allow over riding the value of ALLSUITES 2018-11-12 18:33:01 +13:00
Andrew Ruthven
a394c73cc4 This looks like an acceptable change 2018-11-12 18:31:28 +13:00
Andrew Ruthven
95ad5ec373 Allow database dumps to be restored in test suite.
Primary fix is the search_path to ensure that the collection table
is in the search path so that the copy into dav_binding (and
possibly others) will work.

I also suppressed the warning about plpgsql.
2018-11-12 18:00:30 +13:00
Andrew Ruthven
b0a1c9212d Ignore the PostgreSQL version for tests
This just creates bogus test result diffs.
2018-11-12 17:59:51 +13:00
Jamie McClymont
ec67b28bf0 Guess the timezone of non-all-day floating events in freebusy
Signed-off-by: Jamie McClymont <jamiemcclymont@catalyst.net.nz>
2018-11-09 15:41:02 +13:00
Jamie McClymont
91aaf48648 Guess the timezone of VALUE=DATE events in freebusy
Resolves #146
2018-10-31 12:09:45 +13:00
Andrew Ruthven
ca5c618740 Add trivial translations of Passed: %s, using what is already present for Passed. 2018-10-02 20:41:42 +13:00
Andrew Ruthven
979667850b If DAViCal or AWL versions pass, show the running version.
Closes #151
2018-10-02 20:41:12 +13:00
Andrew Ruthven
bc61d51f5b Test that max-resource-size is infinity.
Commit 9a430130d84e9512ebaecdb02d634c367b63de46 removed the limit,
update the regression tests to reflect this.
2018-10-02 19:55:25 +13:00
Andrew Ruthven
2873c89149 Fix a typo of this.
Closes #145
2018-10-02 19:53:44 +13:00
“Paul
c5891abc7f Introduce new global variable to control maximum size of carddav resources. 2018-08-30 17:23:12 +02:00
Paul Kallnbach
9a430130d8 increase maximum resource size to infinity. this might be potentially dangerous but it is what's claimed in inc/caldav-MKCOL.php:
case 'urn:ietf:params:xml:ns:caldav:max-resource-size':  /** Ignored, since we will support arbitrary size */
this solves issue #80 (large contact photos not being accepted by the server). we might wanna think about a larger limit instead, e.g. increase the limit from 65kB to 6.5MB
2018-05-22 15:17:28 +00:00
Florian Schlichting
5801916722 Merge branch 'awl_appuser-awl_dbauser' into 'master'
Allow user to define awl_appuser and awl_dbauser on create-database script

See merge request davical-project/davical!48
2018-04-25 16:25:06 +00:00
Florian Schlichting
04bf91cf5c Merge branch 'php4-constructor-removal' into 'master'
replace php4 style constructors with __construct

See merge request davical-project/davical!50
2018-04-25 16:08:05 +00:00
Florian Schlichting
b3c9480b6e Merge branch 'patch-1' into 'master'
Fix a typo in DAV_AllProperties which caused dead properties to be omitted

See merge request davical-project/davical!51
2018-04-25 16:02:06 +00:00
wmbr
fc37b68461 Fix a typo in DAV_AllProperties which caused dead properties to be omitted 2018-04-25 00:50:53 +00:00
Till Schäfer
26bab04599 replace php4 style constructors with __construct 2018-03-21 16:59:35 +01:00
Antoine
c2254d7682 Allow user to define awl_appuser and awl_dbauser on create-database script 2018-02-21 12:36:03 +01:00
Florian Schlichting
d459b489ac external fetch: improve error reporting 2018-01-13 23:46:46 +01:00
Florian Schlichting
81874649f7 external fetch: handle initial NULL of collection.modified 2018-01-13 23:22:12 +01:00
Florian Schlichting
05397d635c release 1.1.6 r1.1.7 2018-01-12 00:15:36 +01:00