1
1
Fork 0
mirror of https://code.mensbeam.com/MensBeam/Arsse.git synced 2024-12-23 09:02:41 +00:00
Commit graph

7 commits

Author SHA1 Message Date
J. King
6b2be0a877 Use Phake to create mock objects in tests 2017-03-28 20:30:40 -04:00
J. King
6bb129db2f Mock correct method of Lang 2017-03-28 19:58:20 -04:00
J. King
f902346b6c Eliminated passing of RuntimeData instances
- RuntimeData has now been replaced by a single static Data class
- The Data class has a load() method which fills the same role as the constructor of RuntimeData
- The static Lang class is now an instantiable class and is a member of Data
- All tests have been adjusted and pass
- The Exception tests no longer require convoluted workarounds: a simple mock  for Data::$l suffices; Lang tests also use a mock to prevent loops now instead of using a workaround
2017-03-28 18:50:00 -04:00
Dustin Wilson
7236020b8b Changed "NewsSync" to "Arsse" 2017-03-27 23:12:12 -05:00
J. King
8db31cf3e4 Tweaked Lang; added comments and tests
Tweaks:
- get() method can now report loaded and well as wanted locale
- msg() passed without vars still gets formatted to catch malformed strings
- set('en', false) followed by set('en', true) will now immediately load
- Lang::$synched was not getting set to true properly

Tests:
- Added test for get()
- Added test for malformed strings (exception code was missing)
- Added test for missing strings
- Added test for strings taking variables not being passed any variables
2017-02-16 17:50:34 -05:00
Dustin Wilson
c5fac33398 Converted all hard tabs to soft tabs 2017-02-16 14:29:42 -06:00
J. King
8e2a2c46b1 Refactor test infrastructure to use PSR-4. 2017-02-14 22:34:08 -05:00
Renamed from tests/bootstrap.php (Browse further)