Adrien Crivelli
9e835676a6
Update dev dependencies
2017-01-23 16:02:59 +09:00
Adrien Crivelli
fe73b2d402
Drop PHPSPREADSHEET_ROOT constant
2017-01-23 15:35:10 +09:00
Adrien Crivelli
909353ea39
Simplify bootstrap for tests
2017-01-23 15:05:41 +09:00
Adrien Crivelli
8dddf56c2e
Use proper syntax for variadic functions
...
This simplify code, increase readability and improve the function
signature for API users.
2017-01-23 15:01:20 +09:00
Adrien Crivelli
031af1e9d2
Standardize writers and readers name to be the format most common extension in CamelCase
2017-01-22 17:39:23 +09:00
Henrik Gemal
5a8acce94c
minor fixes to unit tests ( #72 )
2017-01-13 12:06:00 +09:00
Adrien Crivelli
ec928d393f
Fix indentation as suggested by Scrunitizer
2017-01-05 12:26:20 +09:00
Adrien Crivelli
f0445366d2
Fix date related unit tests for 2017
2017-01-04 17:37:23 +09:00
Adrien Crivelli
56245d558e
Use `::class` notation as much as possible
...
```
* ,
_/^\_
< >
* /.-.\ *
* `/&\` *
,@.*;@,
/_o.I %_\ *
* (`'--:o(_@;
/`;--.,__ `') *
;@`o % O,*`'`&\
* (`'--)_@ ;o %'()\ *
/`;--._`''--._O'@;
/&*,()~o`;-.,_ `""`)
* /`,@ ;+& () o*`;-';\
(`""--.,_0 +% @' &()\
/-.,_ ``''--....-'`) *
* /@%;o`:;'--,.__ __.'\
;*,&(); @ % &^;~`"`o;@(); *
/(); o^~; & ().o@*&`;&%O\
jgs `"="==""==,,,.,="=="==="`
__.----.(\-''#####---...___...-----._
'` \)_`"""""`
.--' ')
o( )_-\
`"""` `
```
2016-12-26 13:21:12 +09:00
Adrien Crivelli
8c66afe39a
Upgrade to PHP-CS-Fixer 2.0
2016-12-22 23:46:26 +09:00
Adrien Crivelli
5d3fdf4f78
Skip test on Travis because of recent PHP upgrade
2016-12-14 22:40:21 +09:00
Adrien Crivelli
c8a8fd2610
Stricter check whether file exists before reading
...
This should avoid issues when user submit a non-existing filename
that is wrongly identified as CSV.
Typically https://github.com/PHPOffice/PHPExcel/issues/1076 and
https://github.com/PHPOffice/PHPExcel/issues/1078 could have been
avoided.
2016-12-09 00:15:22 +09:00
mattkibbler
62345ef4da
Allow start and end date of DATEDIF function to be the same
2016-12-04 19:04:10 +09:00
Adrien Crivelli
3bd0f6f985
Fix autofilter cloning across PHP versions
...
Avoid indirect access variable ambiguity across PHP 5.6 and PHP 7.0
2016-12-04 16:44:40 +09:00
Matthias Van Woensel
39b8dbd0a1
Adding float cast to MOD function
...
If $a or $b are not strings, you can get an error that fmod needs param 1 ($a) to be of type double.
MS Excel does not fall over when you insert an empty string in MOD, so I'm guessing PHPExcel should do the same?
2016-12-04 16:12:51 +09:00
Adrien Crivelli
e6d8362fb2
Some functions were not callable because of wrong declaration
2016-12-03 14:51:04 +09:00
Adrien Crivelli
5ad6ced95c
Introduce a tool to migrate from PHPExcel to PhpSpreadsheet
2016-11-28 00:13:57 +09:00
Adrien Crivelli
e6bbc4bd25
Convert all line ending to unix style
2016-11-27 15:45:15 +09:00
Green Wang
8c58385d6c
Fix cant get right format chinese date format error
...
modify preg expression in NumberFormat.php
[DBNum1][$-804]yyyy"年"m"月"d"日";@
[DBNum1][$-804]yyyy"年"m"月";@
[DBNum1][$-804]m"月"d"日";@
FIX #44
2016-11-27 13:39:45 +09:00
Alexander Kurilo
408da0c17a
Make HTML checks more strict
2016-11-16 22:21:30 +09:00
Alexander Kurilo
928b592c14
Add readable labels for data provider samples
2016-11-16 22:21:30 +09:00
Alexander Kurilo
2809cce298
Remove unused data from test provider data set
2016-11-16 22:21:30 +09:00
Alexander Kurilo
edb3974a0d
Move XEEE test data to add data for other readers
2016-11-16 22:21:30 +09:00
Adrien Crivelli
e2e982f98a
Rename OOCalc and OpenDocument into Ods
...
FIX #6
2016-10-06 21:07:57 +09:00
Adrien Crivelli
39b55ded30
Rename Excel2007 into Xlsx
...
FIX #5
2016-10-06 20:39:10 +09:00
Adrien Crivelli
ae1b85f961
Fix code style
2016-10-02 15:21:52 +09:00
Adrien Crivelli
431a1799fb
Fix unit tests for YEARFRAC()
2016-10-02 15:17:52 +09:00
Adrien Crivelli
8c4c11346b
Fix unit tests for DATEDIF()
...
Leap years where not properly taken into consideration
2016-10-02 14:46:11 +09:00
Adrien Crivelli
8061f7516e
Rename SECONDOFMINUTE into SECOND for consistency
2016-10-02 09:43:13 +09:00
Adrien Crivelli
b5af5a772e
Fix unit tests for SECOND()
2016-10-02 09:42:14 +09:00
Adrien Crivelli
75c34f2694
Rename MINUTEOFHOUR into MINUTE for consistency
2016-10-02 09:41:20 +09:00
Adrien Crivelli
7de0439b96
Fix unit tests for MINUTE()
2016-10-02 09:40:07 +09:00
Adrien Crivelli
c15ab515a7
Fix unit tests for testTIMEVALUEtoPHP
2016-10-02 09:37:52 +09:00
Adrien Crivelli
382d15a5c3
Rename DAYOFWEEK into WEEKDAY for consistency
2016-10-02 09:35:50 +09:00
Adrien Crivelli
4c41a6992a
Fix unit tests for testTIMEtoPHP
2016-10-02 09:31:14 +09:00
Adrien Crivelli
60533a4f59
Fix unit tests for WEEKDAY()
...
In Excel the expected value was incorrect (but it would be different
for LibreOffice)
2016-10-02 09:28:00 +09:00
Adrien Crivelli
9629151e45
Rename WEEKOFYEAR into WEEKNUM for consistency
2016-10-01 22:44:33 +09:00
Adrien Crivelli
23fbc845dd
Fix unit tests for WEEKNUM()
2016-10-01 22:33:12 +09:00
Adrien Crivelli
93ccf78dd5
Exclude more tests
2016-09-09 11:58:12 +09:00
Adrien Crivelli
2c96a06d6e
Exclude long tests on Travis
...
Tests that run too long without output tends to break Travis builds.
This is typically the case when running code-coverage, so we need to
exclude a few test cases to ensure that the builds are stable.
2016-09-09 01:27:09 +09:00
Adrien Crivelli
67918419c4
Fix code style
2016-09-01 12:50:10 +09:00
Adrien Crivelli
150ad19580
Ask Travis to wait longer for PHPUnit to finish
2016-09-01 11:20:22 +09:00
MarkBaker
fb2edfdacf
Merge branch 'develop' of https://github.com/PHPOffice/PhpSpreadsheet into develop
...
# Conflicts:
# src/Autoloader.php
2016-08-31 21:58:08 +01:00
MarkBaker
fae27a6d63
As iconv is now enabled by default in PHP, make it a requirement, and modify strig functions to use it where appropriate
2016-08-31 21:52:42 +01:00
Adrien Crivelli
cfa1feffed
Attempt to show samples output so Travis don't interrupt tests
2016-09-01 02:22:19 +09:00
Adrien Crivelli
47cde0dadc
Introduce vendor prefix `PhpOffice` to namespace
2016-09-01 02:20:47 +09:00
Adrien Crivelli
2922a13764
Reorganize code samples
...
This introduce a helper class that should be used to log things,
avoiding a lot of boilerplate code.
Also all output are made in /tmp folder instead of beside the script
itself. This is because there is a high chance that the folder containing
the script is not writtable by webserver. So using the /tmp folder
makes it more likely to works in a variety of setup.
2016-09-01 01:17:13 +09:00
Adrien Crivelli
f917b3b1f4
Avoid `call_user_func()` whenever possible
2016-08-26 15:39:29 +09:00
Adrien Crivelli
04d6182a81
Remove unused variables
2016-08-26 15:05:40 +09:00
Adrien Crivelli
a85f1bdbed
Apply Scrutinizer patches for spacing
2016-08-25 18:46:02 +09:00
Adrien Crivelli
20ccfa0d59
Fix unit tests for MDETERM()
2016-08-25 14:23:26 +09:00
Adrien Crivelli
29bdbd4e0b
Respect PSR-0 with matching folder name and namespace `PhpSpreadsheetTests`
2016-08-25 13:53:15 +09:00
Adrien Crivelli
b9ce2b901e
Format date unit tests is now working
2016-08-25 13:47:27 +09:00
Adrien Crivelli
09d456e477
Introduce PHP-CS-Fixer for stricter code style rules
...
PHP-CS-Fixer allow to check different things than phpcs and it allows
code to be more consistent. Configuration can be changed in `.php_cs`
2016-08-17 00:33:57 +09:00
Adrien Crivelli
539a89a918
Rename namespace `PHPExcel` to `PhpSpreadsheet`
...
This also fix a few bugs that were introduced when migrating to
namespace. Some non-namespaces classes were leftover
FIX #15
2016-08-16 23:24:47 +09:00
Adrien Crivelli
e1f81f0fe0
Refactor tests data from custom format to PHP
...
FIX #14
2016-08-16 21:00:19 +09:00
MarkBaker
65078a0fba
PSR-2 standards for test data
2016-08-15 00:20:31 +01:00
MarkBaker
91573b5c93
Split PHPToExcel logic for different input types
2016-08-14 22:36:30 +01:00
MarkBaker
aa97bb3e45
Merge branch 'develop' into feature/gh-7
...
# Conflicts:
# tests/PhpSpreadsheet/Shared/DateTest.php
2016-08-14 15:41:50 +01:00
MarkBaker
f0e167c182
Unit tests for modified Date functions
2016-08-14 15:35:43 +01:00
Adrien Crivelli
ea513d9c1b
Autofix style code with phpcs
2016-08-14 13:55:34 +09:00
Adrien Crivelli
c981efe272
Mark failing tests as incomplete
...
This is a temporary fix to have a clear view of what is working or not
and to prevent breaking even more tests. Incomplete tests will be fixed
in the comming days/weeks.
2016-08-14 13:32:43 +09:00
Adrien Crivelli
d49a573f58
Use `::class` notation instead of string for class names in unit tests
2016-08-14 13:08:43 +09:00
MarkBaker
850594c4d2
Merge branch 'develop' into feature/gh-7
...
# Conflicts:
# tests/PhpSpreadsheet/Shared/DateTest.php
# tests/rawTestData/Shared/DateTimeExcelToPHP1900.data
# tests/rawTestData/Shared/DateTimeExcelToPHP1900Timezone.data
# tests/rawTestData/Shared/DateTimeExcelToPHP1904.data
# unitTests/rawTestData/Shared/DateTimeExcelToPHP1900.data
# unitTests/rawTestData/Shared/DateTimeExcelToPHP1904.data
# unitTests/rawTestData/Shared/DateTimeExcelToTimestamp1900.data
# unitTests/rawTestData/Shared/DateTimeExcelToTimestamp1904.data
2016-08-14 02:07:10 +01:00
Adrien Crivelli
00657c906e
Reorganize unit tests
...
All code for unit tests is now under the `PhpSpreadsheet\Tests` namespace
which is autoloaded via composer mechanism. So there is no need for
`require()` anymore.
Also, tests were moved in `tests/` folder and phpunit should be executed from
the project root folder. This is to conform to the de facto standard, notably
in use in phpunit itself.
2016-08-14 02:29:33 +09:00