Commit Graph
33 Commits
Author SHA1 Message Date
Martin Carlberg 111b12161c Added: test cases for ’intValue’ and ’integerValue’ methods on CPString and CPNumber 2016-03-23 09:02:09 +01:00
Alexandre Wilhelm b04e5760fb Test: added unittest for method stringByReplacingCharactersInRange of CPString 2015-10-27 12:06:47 -07:00
Sebastian Balay fa5fd1e71c Add support to diacritic insensitive search in CPString rangeOfString:options:range: method
When searching by range, the option of diacritic insensitive search was not being contemplated

Also add support to strip variants of 'E' 'I' 'O' 'U' that were not implemented.
Source: http://www.ascii-code.com/
2014-09-08 10:01:12 -03:00
Martin Carlberg fc403d679c New: CPString 'compare:' method handles nil and CPNull in correct way
This is the same way as Cocoa works.
Also added test case.
2013-07-09 13:37:12 +02:00
Tim Lewis bd6d2e71e7 Fixed: stringByTrimmingCharactersInSet not removing characters at end
If a string had characters from the set at both the start and end,
the end trim was one character less than required.
2013-03-21 13:44:00 +00:00
Alexander Ljungberg 401a5f7ff7 Clean up. 2013-01-23 22:28:01 +00:00
Martin Carlberg c35ccde682 Added stringByAppendingPathComponent: and stringByAppendingPathExtension: to CPString. Also, changed CPString path behaviour to correspond to Cocoa behaviour. 2012-05-11 15:32:18 +02:00
Alexander Ljungberg c77a282aaf Raise CPRangeException if CPString substringToIndex: is out of bounds. 2011-08-27 23:50:18 +01:00
Alexander Ljungberg e44ffdc7f4 CPString subtringWithRange: and rangeOfString:options:range now throws CPRangeException for out of bounds ranges. 2011-04-10 21:20:22 -04:00
Alexander Ljungberg 91ef6bf925 Fixed: CPString rangeOfString:options:range returned locations relative to the passed-in range instead of the full string. 2011-04-10 21:05:43 -04:00
Alexander Ljungberg a33dd51d8e Fixed: searching a string for @"" with CPString rangeOfString returned results other than CPNotFound. 2011-04-10 20:38:51 -04:00
Alexander Ljungberg 2166fc1d51 Fixed: CPString rangeOfString: anchored backwards search did not work. 2011-04-10 20:19:04 -04:00
Alexander Ljungberg 06122bba19 Test CPString rangeOfString: in CPCaseInsensitiveSearch | CPBackwardsSearch mode. 2011-04-10 20:10:08 -04:00
Francisco Ryan Tolmasky I d69f46f7ee More capp_linting.
Reviewed by me.
2010-12-09 13:45:29 -08:00
Francisco Ryan Tolmasky I 400bdb5103 Further capp_linting.
Reviewed by me.
2010-12-02 11:44:42 -08:00
Francisco Ryan Tolmasky I 0ab92c77bd More capp_linting.
Reviewed by me.
2010-12-01 22:57:57 -08:00
cacaodev 3b35219beb Fix [[string copy] isEqual:[string copy]] == NO 2010-11-07 21:43:02 +01:00
Arkadiusz MłynarczykandAlexander Ljungberg ddfac8d717 - moved componentsSeparatedByCharactersInSet: into CPCharacterSetAdditions CPString category
- added tests for componentsSeparatedByCharactersInSet:
- ensured Cocoa compatibility of componentsSeparatedByCharactersInSet:
- added new test for CPString boolValue
- fixed CPString boolValue (" ++01" should return NO as in Cocoa, previously it returned YES)
2010-09-10 18:58:18 -04:00
Emmanuel MaillardandRoss Boucher 1ff873e170 - add tests for pathExtension and stringByDeletingPathExtension 2010-03-27 13:22:36 -07:00
Abhinav GuptaandRoss Boucher 0575e96b60 Added commonPrefixWithString method to CPString and tests for it. 2009-11-26 18:13:01 -05:00
Ross Boucher 229debc2b7 Fixes a bug in testHasSuffix, adds test cases for hasSuffix and hasPrefix. 2009-11-09 13:11:04 +01:00
Ross Boucher 377107d63a Fix for stringByReplacingOccurrencesOfString: not working with strings that have regex control characters in them. 2009-05-25 16:12:27 -07:00
tlrobinson ff6487caf3 import -> @import in Tests and NibApp 2009-04-27 20:32:59 -07:00
tlrobinson 9e7ca719d8 Merge branch 'master' of git@github.com:280north/cappuccino 2009-03-17 18:38:47 -07:00
tlrobinson b7b0ca40b0 Fixed CPString pathComponents and lastPathComponent to match Cocoa. Added tests. 2009-03-17 18:38:14 -07:00
Ross Boucher 6750b90671 Fixes for some new CPString tests. 2009-02-26 21:30:54 -08:00
Russell MullandRoss Boucher 723c9ae556 improved CPStringTest 2009-02-26 21:00:58 -08:00
Sam McDonaldandFrancisco Ryan Tolmasky I 9f9cc4c22c Fix for stringByDeletingLastPathComponent.
[#126 state:resolved]

Reviewed by tolmasky
2008-11-08 13:53:53 -08:00
Tom Robinson bf28b8bbc6 CPString -capitalizedString fixed
Reviewed by me.

[#90 state:resolved responsible:tlrobinson]
2008-10-05 18:15:36 -07:00
vijaykiran 9a397bf03f Added method stringByReplacingOccurrencesOfStringWithString and testcase for the same. 2008-09-17 23:17:56 +02:00
vijaykiran 6c2a50f767 Added method stringByAppendingFormat and a simple test case for the method 2008-09-17 22:52:11 +02:00
vijaykiran 34f58026df Updated assertFalse message in CPStringTest
Converted tabs to spaces according to coding guidelines
2008-09-17 11:56:57 +02:00
vijaykiran 33c0dcd482 First unit test for CPString for method boolValue 2008-09-16 18:59:07 +02:00