refactor-tests: Move blocks and variables into G8RecognitionTestsHelper
Merge pull request #118 from BamX/refactor-tests

Refactored tests.
Fixed misspelling.
Squashed commits:
[7dab0a3] 1. dataPath is now readonly public.
2. designated initializer changed to - (id)initWithLanguage:(NSString *)language configDictionary:(NSDictionary *)configDictionary configFileNames:(NSArray *)configFileNames dataPath:(NSString *)dataPath engineMode:(G8OCREngineMode)engineMode NS_DESIGNATED_INITIALIZER;
where configDictionary is a dictioanry of the config variables and configFileNames is an array of file names containing key-value config pairs. All the config variables can be init only and debug time both. Furthermore they could be specified at the same time, in such case tesseract will get variables from every file and dictionary all together.
3. To avoid ambiguity with Apple Naming Conventions the following functions were renamed:
- setUpTesseractToSearchTrainedDataInTrainedDataFolderOfTheApplicatinBundle (only setters should start with set)
- initEngine (only initializer should start with init. in such case the function should return id)
- copyDataToDocumentsDirectory (if function starts from copy, the special rules are implemented by ARC to the function)
4. if the dataPath is specified, the whole content of the tessdata from the application bundle is copied to the Documents/dataPath/tessdata and tesseract is initialized with that path.
5. _dataPath is replaced with self.dataPath everywhere besides init method.

2. some unit tests

print a message if the result of copyItemAtPath == NO

Small changes

Symlinking tessdata files from app bundle to the Documents folder.

updated lib

Check that destination file doesn't exist before symlinking

updated lib.
1. changed dataPath property to absoluteDataPath
2. changed dataPath parameter of the designatedInitializer to cachesRelativeDataPath
3. So if that parameter is specified, the tessdata files are copied to caches folder from now.
4. Fixed unit tests.
1. documentsPath is renamed to cachesPath
2. Fixed some unnecessary logs in unit tests.
3. removed assertion on documetsPath
1. more unit tests.
2. fixed unit tests
3. removed all Documets
1. added variableValueForKey function
2. Added tests to check loading tess parameters from the config files.
3. Added a note for the search path to the config files.
4. Added 2 config files.
1. Added tests to verify config files and config dictionaries.
2. Added empty .user-patterns and .user-words files to avoid error messages from tesseract.