/Users/runner/work/EasyMapping/EasyMapping/codecov.yml .swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata Configs/EasyMapping.plist Configs/EasyMappingTests.plist Configs/UniversalFramework_Base.xcconfig Configs/UniversalFramework_Framework.xcconfig Configs/UniversalFramework_Test.xcconfig EasyMapping.podspec EasyMapping.xcodeproj/project.pbxproj EasyMapping.xcodeproj/project.xcworkspace/contents.xcworkspacedata EasyMapping.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist EasyMapping.xcodeproj/xcshareddata/xcbaselines/52D6D9851BEFF229002C0205.xcbaseline/1E6FCF61-AA37-4627-ADA8-8DAC90EB656B.plist EasyMapping.xcodeproj/xcshareddata/xcbaselines/52D6D9851BEFF229002C0205.xcbaseline/35DBA270-84C4-460A-BFCE-8A905723A8E8.plist EasyMapping.xcodeproj/xcshareddata/xcbaselines/52D6D9851BEFF229002C0205.xcbaseline/66DA8F14-FB87-4F0E-B945-EE835145A2CD.plist EasyMapping.xcodeproj/xcshareddata/xcbaselines/52D6D9851BEFF229002C0205.xcbaseline/FA860112-387D-4F01-B2B1-33DBAE3D200B.plist EasyMapping.xcodeproj/xcshareddata/xcbaselines/52D6D9851BEFF229002C0205.xcbaseline/Info.plist EasyMapping.xcodeproj/xcshareddata/xcschemes/EasyMapping.xcscheme Example/FixtureLoader/FixtureLoader.swift Example/Models/Car.swift Example/Models/Person.swift Example/Models/Phone.swift Example/Specs/CarTestCase.swift Example/Specs/PersonTestCase.swift Example/Specs/PhoneTestCase.swift Gemfile Gemfile.lock LICENSE Package.swift Sources/EasyMapping+XCTestCase/XCTestCase+EasyMapping.h Sources/EasyMapping+XCTestCase/XCTestCase+EasyMapping.m Sources/EasyMapping/EKCoreDataImporter.h Sources/EasyMapping/EKCoreDataImporter.m Sources/EasyMapping/EKManagedObjectMapper.h Sources/EasyMapping/EKManagedObjectMapper.m Sources/EasyMapping/EKManagedObjectMapping.h Sources/EasyMapping/EKManagedObjectMapping.m Sources/EasyMapping/EKManagedObjectModel.h Sources/EasyMapping/EKManagedObjectModel.m Sources/EasyMapping/EKMapper.h Sources/EasyMapping/EKMapper.m Sources/EasyMapping/EKMappingBlocks.h Sources/EasyMapping/EKMappingBlocks.m Sources/EasyMapping/EKMappingProtocol.h Sources/EasyMapping/EKObjectMapping.h Sources/EasyMapping/EKObjectMapping.m Sources/EasyMapping/EKObjectModel.h Sources/EasyMapping/EKObjectModel.m Sources/EasyMapping/EKPropertyHelper.h Sources/EasyMapping/EKPropertyHelper.m Sources/EasyMapping/EKPropertyMapping.h Sources/EasyMapping/EKPropertyMapping.m Sources/EasyMapping/EKRelationshipMapping.h Sources/EasyMapping/EKRelationshipMapping.m Sources/EasyMapping/EKSerializer.h Sources/EasyMapping/EKSerializer.m Sources/EasyMapping/EasyMapping.h Sources/EasyMapping/NSArray+FlattenArray.h Sources/EasyMapping/NSArray+FlattenArray.m Sources/EasyMapping/NSDateFormatter+EasyMappingAdditions.h TestFixtures/EKCoreDataManager.h TestFixtures/EKCoreDataManager.m TestFixtures/Fixtures/Address.json TestFixtures/Fixtures/Alien.json TestFixtures/Fixtures/Car.json TestFixtures/Fixtures/CarWithAttributesRemoved.json TestFixtures/Fixtures/CarWithDate.json TestFixtures/Fixtures/CarWithNestedAttributes.json TestFixtures/Fixtures/CarWithRoot.json TestFixtures/Fixtures/Cars.json TestFixtures/Fixtures/CarsWithNullItem.json TestFixtures/Fixtures/CommentsRecursive.json TestFixtures/Fixtures/ComplexRepresentation.json TestFixtures/Fixtures/EasyMapping.xcdatamodeld/.xccurrentversion TestFixtures/Fixtures/EasyMapping.xcdatamodeld/EasyMapping.xcdatamodel/contents TestFixtures/Fixtures/Female.json TestFixtures/Fixtures/FixtureClasses/Dog.h TestFixtures/Fixtures/FixtureClasses/Dog.m TestFixtures/Fixtures/FixtureClasses/MutableFoundationClass.h TestFixtures/Fixtures/FixtureClasses/MutableFoundationClass.m TestFixtures/Fixtures/FixtureClasses/Numbers.h TestFixtures/Fixtures/FixtureClasses/Numbers.m TestFixtures/Fixtures/FixtureClasses/Wolf.h TestFixtures/Fixtures/FixtureClasses/Wolf.m TestFixtures/Fixtures/Male.json TestFixtures/Fixtures/MutableFoundationClass.json TestFixtures/Fixtures/Native.json TestFixtures/Fixtures/NativeChild.json TestFixtures/Fixtures/Person.json TestFixtures/Fixtures/PersonNonNested.json TestFixtures/Fixtures/PersonRecursive.json TestFixtures/Fixtures/PersonWithAnimals.json TestFixtures/Fixtures/PersonWithDifferentNaming.json TestFixtures/Fixtures/PersonWithNullCar.json TestFixtures/Fixtures/PersonWithNullPhones.json TestFixtures/Fixtures/PersonWithOtherPhones.json TestFixtures/Fixtures/PersonWithZeroPhones.json TestFixtures/Fixtures/PersonWithoutRelations.json TestFixtures/Fixtures/PersonsWithSamePhones.json TestFixtures/Fixtures/Plane.json TestFixtures/Fixtures/RecursiveDuplicates.json TestFixtures/TestModels/Models/CoreData/BaseManagedTestModel.h TestFixtures/TestModels/Models/CoreData/BaseManagedTestModel.m TestFixtures/TestModels/Models/CoreData/ManagedCar.h TestFixtures/TestModels/Models/CoreData/ManagedCar.m TestFixtures/TestModels/Models/CoreData/ManagedPerson.h TestFixtures/TestModels/Models/CoreData/ManagedPerson.m TestFixtures/TestModels/Models/CoreData/ManagedPhone.h TestFixtures/TestModels/Models/CoreData/ManagedPhone.m TestFixtures/TestModels/Models/NSObject/Address.h TestFixtures/TestModels/Models/NSObject/Address.m TestFixtures/TestModels/Models/NSObject/Alien.h TestFixtures/TestModels/Models/NSObject/Alien.m TestFixtures/TestModels/Models/NSObject/BaseTestModel.h TestFixtures/TestModels/Models/NSObject/BaseTestModel.m TestFixtures/TestModels/Models/NSObject/Car.h TestFixtures/TestModels/Models/NSObject/Car.m TestFixtures/TestModels/Models/NSObject/Cat.h TestFixtures/TestModels/Models/NSObject/Cat.m TestFixtures/TestModels/Models/NSObject/CommentObject.h TestFixtures/TestModels/Models/NSObject/CommentObject.m TestFixtures/TestModels/Models/NSObject/Finger.h TestFixtures/TestModels/Models/NSObject/Finger.m TestFixtures/TestModels/Models/NSObject/Native.h TestFixtures/TestModels/Models/NSObject/Native.m TestFixtures/TestModels/Models/NSObject/Person.h TestFixtures/TestModels/Models/NSObject/Person.m TestFixtures/TestModels/Models/NSObject/Phone.h TestFixtures/TestModels/Models/NSObject/Phone.m TestFixtures/TestModels/Models/NSObject/Plane.h TestFixtures/TestModels/Models/NSObject/Plane.m TestFixtures/TestModels/Models/NSObject/Recursive.h TestFixtures/TestModels/Models/NSObject/Recursive.m TestFixtures/TestModels/Models/NSObject/UFO.h TestFixtures/TestModels/Models/NSObject/UFO.m TestFixtures/TestModels/Providers/ManagedMappingProvider.h TestFixtures/TestModels/Providers/ManagedMappingProvider.m TestFixtures/TestModels/Providers/MappingProvider.h TestFixtures/TestModels/Providers/MappingProvider.m TestFixtures/Tests-Bridging-Header.h TestFixtures/Utilities/EKCoreDataImporter+SwiftExtensions.h TestFixtures/Utilities/FixtureLoader.swift TestFixtures/Utilities/Storage.swift Tests/EasyMappingTests/EKCoreDataImporterTestCase.swift Tests/EasyMappingTests/EKManagedObjectMapperTestCase.swift Tests/EasyMappingTests/EKManagedObjectMappingTestCase.swift Tests/EasyMappingTests/EKManagedObjectModelTestCase.swift Tests/EasyMappingTests/EKMapperTestCase.swift Tests/EasyMappingTests/EKMappingBlocksTestCase.swift Tests/EasyMappingTests/EKObjectMappingTestCase.swift Tests/EasyMappingTests/EKObjectModelTestCase.swift Tests/EasyMappingTests/EKPropertyHelperTestCase.swift Tests/EasyMappingTests/EKPropertyMappingTestCase.swift Tests/EasyMappingTests/EKRelationshipMappingTestCase.swift Tests/EasyMappingTests/EKSerializerTestCase.swift Tests/EasyMappingTests/EasyMappingPerfomanceTests.swift Tests/EasyMappingTests/EasyMappingTests.swift Tests/EasyMappingTests/LinuxMain.swift Tests/EasyMappingTests/XCTestEasyMappingSupportTestCase.swift codecov.sh fastlane/Fastfile fastlane/Scanfile <<<<<< network # path=/Users/runner/work/EasyMapping/EasyMapping/fastlane/EasyMapping.framework.coverage.txt /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKCoreDataImporter.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2014 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "EKCoreDataImporter.h" 25| |#import "EKPropertyHelper.h" 26| |#import "NSArray+FlattenArray.h" 27| |#import "EKRelationshipMapping.h" 28| | 29| |@interface EKCoreDataImporter () 30| | 31| |@property (nonatomic, strong) NSMutableSet * collectedEntityNames; 32| | 33| |@property (nonatomic, strong) NSSet * entityNames; 34| | 35| |// Keys are entity names, values - NSSet with primary keys 36| |@property (nonatomic, strong) NSDictionary * existingEntitiesPrimaryKeys; 37| | 38| |// Keys are entity names, values - NSDictionary, where keys = primary keys, values = fetched objects 39| |@property (nonatomic, strong) NSMutableDictionary * fetchedExistingEntities; 40| | 41| |@end 42| | 43| |@implementation EKCoreDataImporter 44| | 45| |+ (instancetype)importerWithMapping:(EKManagedObjectMapping *)mapping 46| | externalRepresentation:(id)externalRepresentation 47| | context:(NSManagedObjectContext *)context 48| 8.13k|{ 49| 8.13k| EKCoreDataImporter * importer = [self new]; 50| 8.13k| 51| 8.13k| importer.mapping = mapping; 52| 8.13k| importer.externalRepresentation = externalRepresentation; 53| 8.13k| importer.context = context; 54| 8.13k| 55| 8.13k| importer.fetchedExistingEntities = [NSMutableDictionary dictionary]; 56| 8.13k| [importer collectEntityNames]; 57| 8.13k| [importer inspectRepresentationInContext:context]; 58| 8.13k| 59| 8.13k| return importer; 60| 8.13k|} 61| | 62| |#pragma mark - collect entity names 63| | 64| |- (void)collectEntityNames 65| 8.13k|{ 66| 8.13k| NSMutableSet * entityNames = [NSMutableSet set]; 67| 8.13k| self.collectedEntityNames = [NSMutableSet set]; 68| 8.13k| 69| 8.13k| [self collectEntityNamesRecursively:entityNames mapping:self.mapping]; 70| 8.13k| 71| 8.13k| self.entityNames = [entityNames copy]; 72| 8.13k|} 73| | 74| |- (void)collectEntityNamesRecursively:(NSMutableSet *)entityNames mapping:(EKManagedObjectMapping *)mapping 75| 13.2k|{ 76| 13.2k| [entityNames addObject:mapping.entityName]; 77| 13.2k| 78| 13.2k| for (EKRelationshipMapping * oneMapping in mapping.hasOneMappings) 79| 5.16k| { 80| 5.16k| EKManagedObjectMapping * mapping = (EKManagedObjectMapping *)[[oneMapping objectClass] objectMapping]; 81| 5.16k| if ([self.collectedEntityNames containsObject:mapping.entityName]) 82| 2.07k| { 83| 2.07k| continue; 84| 2.07k| } 85| 3.09k| else { 86| 3.09k| [self.collectedEntityNames addObject:mapping.entityName]; 87| 3.09k| [self collectEntityNamesRecursively:entityNames mapping:mapping]; 88| 3.09k| } 89| 5.16k| } 90| 13.2k| 91| 13.2k| for (EKRelationshipMapping * manyMapping in mapping.hasManyMappings) 92| 5.16k| { 93| 5.16k| EKManagedObjectMapping * mapping = (EKManagedObjectMapping *)[[manyMapping objectClass] objectMapping]; 94| 5.16k| if ([self.collectedEntityNames containsObject:mapping.entityName]) 95| 3.11k| { 96| 3.11k| continue; 97| 3.11k| } 98| 2.05k| else { 99| 2.05k| [self.collectedEntityNames addObject:mapping.entityName]; 100| 2.05k| [self collectEntityNamesRecursively:entityNames mapping:mapping]; 101| 2.05k| } 102| 5.16k| } 103| 13.2k|} 104| | 105| |#pragma mark - Inspecting representation 106| | 107| |- (void)inspectRepresentationInContext:(NSManagedObjectContext *)context 108| 8.13k|{ 109| 8.13k| NSMutableDictionary * existingPrimaryKeys = [NSMutableDictionary dictionary]; 110| 8.13k| for (NSString * entityName in self.entityNames) 111| 12.2k| { 112| 12.2k| existingPrimaryKeys[entityName] = [NSMutableSet set]; 113| 12.2k| } 114| 8.13k| [self inspectRepresentation:self.externalRepresentation 115| 8.13k| usingMapping:self.mapping 116| 8.13k| accumulateInside:existingPrimaryKeys 117| 8.13k| context:context]; 118| 8.13k| 119| 8.13k| self.existingEntitiesPrimaryKeys = existingPrimaryKeys; 120| 8.13k|} 121| | 122| |- (void)inspectRepresentation:(id)representation 123| | usingMapping:(EKManagedObjectMapping *)mapping 124| | accumulateInside:(NSMutableDictionary *)dictionary 125| | context:(NSManagedObjectContext *)context 126| 12.2k|{ 127| 12.2k| id rootRepresentation = [EKPropertyHelper extractRootPathFromExternalRepresentation:representation 128| 12.2k| withMapping:mapping]; 129| 12.2k| if ([rootRepresentation isKindOfClass:[NSArray class]]) 130| 2.06k| { 131| 2.06k| for (NSDictionary * objectInfo in rootRepresentation) 132| 304k| { 133| 304k| id value = [self primaryKeyValueFromRepresentation:objectInfo usingMapping:mapping context:context]; 134| 304k| if (value && value != (id)[NSNull null]) 135| 304k| { 136| 304k| [(NSMutableSet *)dictionary[mapping.entityName] addObject:value]; 137| 304k| } 138| 304k| } 139| 2.06k| } 140| 10.1k| else if ([rootRepresentation isKindOfClass:[NSDictionary class]]) 141| 10.1k| { 142| 10.1k| id value = [self primaryKeyValueFromRepresentation:rootRepresentation usingMapping:mapping context:context]; 143| 10.1k| if (value && value != (id)[NSNull null]) 144| 7.12k| { 145| 7.12k| [(NSMutableSet *)dictionary[mapping.entityName] addObject:value]; 146| 7.12k| } 147| 10.1k| } 148| 12.2k| 149| 12.2k| for (EKRelationshipMapping *relationship in mapping.hasOneMappings) 150| 3.10k| { 151| 3.10k| id oneMappingRepresentation = [rootRepresentation valueForKeyPath:relationship.keyPath]; 152| 3.10k| if (oneMappingRepresentation && ![oneMappingRepresentation isEqual:[NSNull null]]) 153| 2.05k| { 154| 2.05k| // This is needed, because if one of the objects in array does not contain object for key, returned structure would be something like this: 155| 2.05k| // 156| 2.05k| // @[,@[value2,value3]] 157| 2.05k| // 158| 2.05k| // And we are interested in flat structure like this: @[value2,value3] 159| 2.05k| if ([oneMappingRepresentation isKindOfClass:[NSArray class]]) { 160| 6| oneMappingRepresentation = [oneMappingRepresentation ek_flattenedCompactedArray]; 161| 6| 162| 6| // if after compact, the array is empty, we should skip this 163| 6| if ([oneMappingRepresentation count] == 0) { 164| 4| continue; 165| 4| } 166| 2.04k| } 167| 2.04k| 168| 2.04k| [self inspectRepresentation:oneMappingRepresentation 169| 2.04k| usingMapping:(EKManagedObjectMapping *)[relationship mappingForRepresentation:oneMappingRepresentation] 170| 2.04k| accumulateInside:dictionary 171| 2.04k| context:context]; 172| 2.04k| } 173| 3.10k| } 174| 12.2k| 175| 12.2k| for (EKRelationshipMapping *relationship in mapping.hasManyMappings) 176| 3.10k| { 177| 3.10k| NSArray * manyMappingRepresentation = [rootRepresentation valueForKeyPath:relationship.keyPath]; 178| 3.10k| 179| 3.10k| if (manyMappingRepresentation && ![manyMappingRepresentation isEqual:[NSNull null]]) 180| 2.05k| { 181| 2.05k| // This is needed, because if one of the objects in array does not contain object for key, returned structure would be something like this: 182| 2.05k| // 183| 2.05k| // @[,@[value2,value3]] 184| 2.05k| // 185| 2.05k| // And we are interested in flat structure like this: @[value2,value3] 186| 2.05k| manyMappingRepresentation = [manyMappingRepresentation ek_flattenedCompactedArray]; 187| 2.05k| 188| 2.05k| // if after compact, the array is empty, we should skip this 189| 2.05k| if ([manyMappingRepresentation count] == 0) { 190| 7| continue; 191| 7| } 192| 2.05k| 193| 2.05k| [self inspectRepresentation:manyMappingRepresentation 194| 2.05k| usingMapping:(EKManagedObjectMapping *)[relationship mappingForRepresentation:manyMappingRepresentation] 195| 2.05k| accumulateInside:dictionary 196| 2.05k| context:context]; 197| 2.05k| } 198| 3.10k| } 199| 12.2k|} 200| | 201| |- (id)primaryKeyValueFromRepresentation:(id)representation usingMapping:(EKManagedObjectMapping *)mapping context:(NSManagedObjectContext *)context 202| 314k|{ 203| 314k| EKPropertyMapping * primaryKeyMapping = [mapping primaryKeyPropertyMapping]; 204| 314k| return [EKPropertyHelper getValueOfManagedProperty:primaryKeyMapping 205| 314k| fromRepresentation:representation 206| 314k| inContext:context]; 207| 314k|} 208| | 209| |#pragma mark - Fetching existing objects 210| | 211| |- (NSMutableDictionary *)fetchExistingObjectsForMapping:(EKManagedObjectMapping *)mapping 212| 12.2k|{ 213| 12.2k| NSSet * lookupValues = self.existingEntitiesPrimaryKeys[mapping.entityName]; 214| 12.2k| if (lookupValues.count == 0) return [NSMutableDictionary dictionary]; 215| 9.16k| 216| 9.16k| NSFetchRequest * fetchRequest = [NSFetchRequest fetchRequestWithEntityName:mapping.entityName]; 217| 9.16k| NSPredicate * predicate = [NSPredicate predicateWithFormat:@"%K IN %@", mapping.primaryKey, lookupValues]; 218| 9.16k| [fetchRequest setPredicate:predicate]; 219| 9.16k| [fetchRequest setFetchLimit:lookupValues.count]; 220| 9.16k| 221| 9.16k| NSMutableDictionary * output = [NSMutableDictionary new]; 222| 9.16k| NSArray * existingObjects = [self.context executeFetchRequest:fetchRequest error:NULL]; 223| 9.16k| for (NSManagedObject * object in existingObjects) 224| 281k| { 225| 281k| output[[object valueForKey:mapping.primaryKey]] = object; 226| 281k| } 227| 9.16k| 228| 9.16k| return output; 229| 9.16k|} 230| | 231| |- (NSMutableDictionary *)cachedObjectsForMapping:(EKManagedObjectMapping *)mapping 232| 314k|{ 233| 314k| NSMutableDictionary * entityObjectsMap = self.fetchedExistingEntities[mapping.entityName]; 234| 314k| if (!entityObjectsMap) 235| 12.2k| { 236| 12.2k| entityObjectsMap = [self fetchExistingObjectsForMapping:mapping]; 237| 12.2k| self.fetchedExistingEntities[mapping.entityName] = entityObjectsMap; 238| 12.2k| } 239| 314k| 240| 314k| return entityObjectsMap; 241| 314k|} 242| | 243| |- (id)existingObjectForRepresentation:(id)representation mapping:(EKManagedObjectMapping *)mapping context:(NSManagedObjectContext *)context 244| 314k|{ 245| 314k| NSDictionary * entityObjectsMap = [self cachedObjectsForMapping:mapping]; 246| 314k| 247| 314k| id primaryKeyValue = [EKPropertyHelper getValueOfManagedProperty:[mapping primaryKeyPropertyMapping] 248| 314k| fromRepresentation:representation 249| 314k| inContext:context]; 250| 314k| if (primaryKeyValue == nil || primaryKeyValue == NSNull.null) return nil; 251| 310k| 252| 310k| return entityObjectsMap[primaryKeyValue]; 253| 310k|} 254| | 255| |-(void)cacheObject:(NSManagedObject *)object withMapping:(EKManagedObjectMapping *)mapping 256| 314k|{ 257| 314k| if(!mapping.primaryKey) return; 258| 314k| if (![object valueForKey:mapping.primaryKey]) return; 259| 311k| 260| 311k| NSMutableDictionary *entityObjectsMap = self.fetchedExistingEntities[mapping.entityName]; 261| 311k| entityObjectsMap[[object valueForKey:mapping.primaryKey]] = object; 262| 311k| self.fetchedExistingEntities[mapping.entityName] = entityObjectsMap; 263| 311k|} 264| | 265| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKManagedObjectMapper.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2014 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "EKManagedObjectMapper.h" 25| |#import "EKPropertyHelper.h" 26| |#import "EKCoreDataImporter.h" 27| |#import "EKRelationshipMapping.h" 28| | 29| |@interface EKManagedObjectMapper () 30| |@property (nonatomic, strong) EKCoreDataImporter * importer; 31| | 32| |+ (instancetype)mapperWithImporter:(EKCoreDataImporter *)importer; 33| | 34| |@end 35| | 36| |@implementation EKManagedObjectMapper 37| | 38| |+ (instancetype)mapperWithImporter:(EKCoreDataImporter *)importer 39| 8.12k|{ 40| 8.12k| EKManagedObjectMapper * mapper = [self new]; 41| 8.12k| mapper.importer = importer; 42| 8.12k| return mapper; 43| 8.12k|} 44| | 45| |- (id)objectFromExternalRepresentation:(NSDictionary *)externalRepresentation 46| | withMapping:(EKManagedObjectMapping *)mapping 47| 314k|{ 48| 314k| NSManagedObject * object = [self.importer existingObjectForRepresentation:externalRepresentation 49| 314k| mapping:mapping 50| 314k| context:self.importer.context]; 51| 314k| if (!object) 52| 34.1k| { 53| 34.1k| object = [NSEntityDescription insertNewObjectForEntityForName:mapping.entityName 54| 34.1k| inManagedObjectContext:self.importer.context]; 55| 34.1k| } 56| 314k| [self fillObjectProperties:object 57| 314k| fromExternalRepresentation:externalRepresentation 58| 314k| withMapping:mapping]; 59| 314k| [self.importer cacheObject:object 60| 314k| withMapping:mapping]; 61| 314k| [self fillObjectOneRelationships:object 62| 314k| fromExternalRepresentation:externalRepresentation 63| 314k| withMapping:mapping]; 64| 314k| [self fillObjectManyRelationships:object 65| 314k| fromExternalRepresentation:externalRepresentation 66| 314k| withMapping:mapping]; 67| 314k| 68| 314k| return object; 69| 314k|} 70| | 71| |- (void)fillObjectProperties:(id)object fromExternalRepresentation:(NSDictionary *)externalRepresentation 72| | withMapping:(EKManagedObjectMapping *)mapping 73| 314k|{ 74| 314k| NSDictionary * representation = [EKPropertyHelper extractRootPathFromExternalRepresentation:externalRepresentation 75| 314k| withMapping:mapping]; 76| 314k| [mapping.propertyMappings enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL * stop) 77| 1.20M| { 78| 1.20M| [EKPropertyHelper setProperty:obj 79| 1.20M| onObject:object 80| 1.20M| fromRepresentation:representation 81| 1.20M| inContext:self.importer.context 82| 1.20M| respectPropertyType:mapping.respectPropertyFoundationTypes 83| 1.20M| ignoreMissingFields:mapping.ignoreMissingFields]; 84| 1.20M| }]; 85| 314k|} 86| | 87| |- (void)fillObjectOneRelationships:(id)object 88| | fromExternalRepresentation:(NSDictionary *)externalRepresentation 89| | withMapping:(EKManagedObjectMapping *)mapping 90| 314k|{ 91| 314k| NSDictionary *representation = [EKPropertyHelper extractRootPathFromExternalRepresentation:externalRepresentation 92| 314k| withMapping:mapping]; 93| 314k| for (EKRelationshipMapping *relationship in mapping.hasOneMappings) { 94| 3.08k| NSDictionary * value = [relationship extractObjectFromRepresentation:representation]; 95| 3.08k| if(mapping.ignoreMissingFields && !value) 96| 2| { 97| 2| continue; 98| 2| } 99| 3.08k| if (value && value != (id)[NSNull null]) { 100| 2.04k| id result = [self objectFromExternalRepresentation:value withMapping:(EKManagedObjectMapping *)[relationship mappingForRepresentation:value]]; 101| 2.04k| [EKPropertyHelper setValue:result onObject:object forKeyPath:relationship.property]; 102| 2.04k| } else { 103| 1.04k| [EKPropertyHelper setValue:nil onObject:object forKeyPath:relationship.property]; 104| 1.04k| } 105| 3.08k| 106| 3.08k| } 107| 314k|} 108| | 109| |- (void)fillObjectManyRelationships:(id)object 110| | fromExternalRepresentation:(NSDictionary *)externalRepresentation 111| | withMapping:(EKManagedObjectMapping *)mapping 112| 314k|{ 113| 314k| NSDictionary *representation = [EKPropertyHelper extractRootPathFromExternalRepresentation:externalRepresentation 114| 314k| withMapping:mapping]; 115| 314k| for (EKRelationshipMapping *relationship in mapping.hasManyMappings) { 116| 53.0k| NSArray * arrayToBeParsed = [representation valueForKeyPath:relationship.keyPath]; 117| 53.0k| if(mapping.ignoreMissingFields && !arrayToBeParsed) 118| 2| { 119| 2| continue; 120| 2| } 121| 53.0k| 122| 53.0k| if (arrayToBeParsed && arrayToBeParsed != (id)[NSNull null]) 123| 52.0k| { 124| 52.0k| NSArray * parsedArray = [self arrayOfObjectsFromExternalRepresentation:arrayToBeParsed 125| 52.0k| withRelationship:relationship]; 126| 52.0k| id parsedObjects = [EKPropertyHelper propertyRepresentation:parsedArray 127| 52.0k| forObject:object 128| 52.0k| withPropertyName:[relationship property]]; 129| 52.0k| if(mapping.incrementalData) { 130| 6| [EKPropertyHelper addValue:parsedObjects onObject:object forKeyPath:relationship.property]; 131| 6| } 132| 52.0k| else { 133| 52.0k| [EKPropertyHelper setValue:parsedObjects onObject:object forKeyPath:relationship.property]; 134| 52.0k| } 135| 52.0k| } else if (!mapping.incrementalData) { 136| 1.03k| [EKPropertyHelper setValue:nil onObject:object forKeyPath:relationship.property]; 137| 1.03k| } 138| 53.0k| } 139| 314k|} 140| | 141| |- (NSArray *)arrayOfObjectsFromExternalRepresentation:(NSArray *)externalRepresentation 142| | withRelationship:(EKRelationshipMapping *)mapping 143| 52.0k|{ 144| 52.0k| NSMutableArray * array = [NSMutableArray array]; 145| 52.0k| for (NSDictionary * representation in externalRepresentation) 146| 254k| { 147| 254k| id parsedObject = [self objectFromExternalRepresentation:representation withMapping:(EKManagedObjectMapping *)[mapping mappingForRepresentation:representation]]; 148| 254k| [array addObject:parsedObject]; 149| 254k| } 150| 52.0k| return [NSArray arrayWithArray:array]; 151| 52.0k|} 152| | 153| |- (NSArray *)arrayOfObjectsFromExternalRepresentation:(NSArray *)externalRepresentation 154| | withMapping:(EKManagedObjectMapping *)mapping 155| 12|{ 156| 12| 157| 12| NSMutableArray * array = [NSMutableArray array]; 158| 12| for (NSDictionary * representation in externalRepresentation) 159| 50.0k| { 160| 50.0k| id parsedObject = [self objectFromExternalRepresentation:representation withMapping:mapping]; 161| 50.0k| [array addObject:parsedObject]; 162| 50.0k| } 163| 12| return [NSArray arrayWithArray:array]; 164| 12|} 165| | 166| |- (NSArray *)syncArrayOfObjectsFromExternalRepresentation:(NSArray *)externalRepresentation 167| | withMapping:(EKManagedObjectMapping *)mapping 168| | fetchRequest:(NSFetchRequest *)fetchRequest 169| 2|{ 170| 2| NSAssert(mapping.primaryKey, @"A mapping with a primary key is required"); 171| 2| EKPropertyMapping * primaryKeyPropertyMapping = [mapping primaryKeyPropertyMapping]; 172| 2| 173| 2| // Create a dictionary that maps primary keys to existing objects 174| 2| NSArray * existing = [self.importer.context executeFetchRequest:fetchRequest error:NULL]; 175| 2| NSDictionary * existingByPK = [NSDictionary dictionaryWithObjects:existing 176| 2| forKeys:[existing valueForKey:primaryKeyPropertyMapping.property]]; 177| 2| 178| 2| NSMutableArray * array = [NSMutableArray array]; 179| 2| for (NSDictionary * representation in externalRepresentation) 180| 2| { 181| 2| // Look up the object by its primary key 182| 2| id primaryKeyValue = [EKPropertyHelper getValueOfManagedProperty:primaryKeyPropertyMapping 183| 2| fromRepresentation:representation 184| 2| inContext:self.importer.context]; 185| 2| id object = [existingByPK objectForKey:primaryKeyValue]; 186| 2| 187| 2| // Create a new object if necessary 188| 2| if (!object) 189| 2| object = [NSEntityDescription insertNewObjectForEntityForName:mapping.entityName 190| 2| inManagedObjectContext:self.importer.context]; 191| 2| 192| 2| [self fillObjectProperties:object 193| 2| fromExternalRepresentation:representation 194| 2| withMapping:mapping]; 195| 2| [self fillObjectOneRelationships:object 196| 2| fromExternalRepresentation:representation 197| 2| withMapping:mapping]; 198| 2| [self fillObjectManyRelationships:object 199| 2| fromExternalRepresentation:representation 200| 2| withMapping:mapping]; 201| 2| [array addObject:object]; 202| 2| } 203| 2| 204| 2| // Any object returned by the fetch request not in the external represntation has to be deleted 205| 2| NSMutableSet * toDelete = [NSMutableSet setWithArray:existing]; 206| 2| [toDelete minusSet:[NSSet setWithArray:array]]; 207| 2| for (NSManagedObject * o in toDelete) 208| 2| [self.importer.context deleteObject:o]; 209| 2| 210| 2| return [NSArray arrayWithArray:array]; 211| 2|} 212| | 213| | 214| |#pragma mark - CoreData Importer 215| |/* 216| | All methods below perform a redirection to instance methods, that use CoreData importer class 217| | */ 218| | 219| |+ (id)objectFromExternalRepresentation:(NSDictionary *)externalRepresentation 220| | withMapping:(EKManagedObjectMapping *)mapping 221| | inManagedObjectContext:(NSManagedObjectContext *)context 222| 8.10k|{ 223| 8.10k| NSParameterAssert([mapping isKindOfClass:[EKManagedObjectMapping class]]); 224| 8.10k| NSParameterAssert(context); 225| 8.10k| 226| 8.10k| EKCoreDataImporter * importer = [EKCoreDataImporter importerWithMapping:mapping 227| 8.10k| externalRepresentation:externalRepresentation 228| 8.10k| context:context]; 229| 8.10k| return [[self mapperWithImporter:importer] objectFromExternalRepresentation:externalRepresentation 230| 8.10k| withMapping:mapping]; 231| 8.10k|} 232| | 233| |+ (id) fillObject:(id)object 234| | fromExternalRepresentation:(NSDictionary *)externalRepresentation 235| | withMapping:(EKManagedObjectMapping *)mapping 236| | inManagedObjectContext:(NSManagedObjectContext*)context 237| 3|{ 238| 3| NSParameterAssert([mapping isKindOfClass:[EKManagedObjectMapping class]]); 239| 3| NSParameterAssert(context); 240| 3| 241| 3| EKCoreDataImporter * importer = [EKCoreDataImporter importerWithMapping:mapping 242| 3| externalRepresentation:externalRepresentation 243| 3| context:context]; 244| 3| EKManagedObjectMapper *mapper = [self mapperWithImporter:importer]; 245| 3| [mapper fillObjectProperties:object 246| 3| fromExternalRepresentation:externalRepresentation 247| 3| withMapping:mapping]; 248| 3| [mapper fillObjectOneRelationships:object 249| 3| fromExternalRepresentation:externalRepresentation 250| 3| withMapping:mapping]; 251| 3| [mapper fillObjectManyRelationships:object 252| 3| fromExternalRepresentation:externalRepresentation 253| 3| withMapping:mapping]; 254| 3| return object; 255| 3|} 256| | 257| |+ (NSArray *)arrayOfObjectsFromExternalRepresentation:(NSArray *)externalRepresentation 258| | withMapping:(EKManagedObjectMapping *)mapping 259| | inManagedObjectContext:(NSManagedObjectContext*)context 260| 12|{ 261| 12| NSParameterAssert([mapping isKindOfClass:[EKManagedObjectMapping class]]); 262| 12| NSParameterAssert(context); 263| 12| 264| 12| EKCoreDataImporter * importer = [EKCoreDataImporter importerWithMapping:mapping 265| 12| externalRepresentation:externalRepresentation 266| 12| context:context]; 267| 12| 268| 12| return [[self mapperWithImporter:importer] arrayOfObjectsFromExternalRepresentation:externalRepresentation 269| 12| withMapping:mapping]; 270| 12|} 271| | 272| |+ (NSArray *)syncArrayOfObjectsFromExternalRepresentation:(NSArray *)externalRepresentation 273| | withMapping:(EKManagedObjectMapping *)mapping 274| | fetchRequest:(NSFetchRequest *)fetchRequest 275| | inManagedObjectContext:(NSManagedObjectContext *)context 276| 2|{ 277| 2| NSParameterAssert([mapping isKindOfClass:[EKManagedObjectMapping class]]); 278| 2| NSParameterAssert(context); 279| 2| 280| 2| EKCoreDataImporter * importer = [EKCoreDataImporter importerWithMapping:mapping 281| 2| externalRepresentation:externalRepresentation 282| 2| context:context]; 283| 2| return [[self mapperWithImporter:importer] syncArrayOfObjectsFromExternalRepresentation:externalRepresentation 284| 2| withMapping:mapping 285| 2| fetchRequest:fetchRequest]; 286| 2|} 287| | 288| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKManagedObjectMapping.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2014 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "EKManagedObjectMapping.h" 25| | 26| |@implementation EKManagedObjectMapping 27| | 28| |@synthesize propertyMappings = _propertyMappings; 29| |@synthesize hasManyMappings = _hasManyMappings; 30| |@synthesize hasOneMappings = _hasOneMappings; 31| |@synthesize rootPath = _rootPath; 32| | 33| |+ (EKManagedObjectMapping *)mappingForEntityName:(NSString *)entityName withBlock:(void (^)(EKManagedObjectMapping * mapping))mappingBlock 34| 257|{ 35| 257| EKManagedObjectMapping * mapping = [[EKManagedObjectMapping alloc] initWithEntityName:entityName]; 36| 257| if (mappingBlock) 37| 257| { 38| 257| mappingBlock(mapping); 39| 257| } 40| 257| return mapping; 41| 257|} 42| | 43| |+ (EKManagedObjectMapping *)mappingForEntityName:(NSString *)entityName withRootPath:(NSString *)rootPath withBlock:(void (^)(EKManagedObjectMapping * mapping))mappingBlock 44| 16|{ 45| 16| EKManagedObjectMapping * mapping = [[EKManagedObjectMapping alloc] initWithEntityName:entityName withRootPath:rootPath]; 46| 16| if (mappingBlock) 47| 16| { 48| 16| mappingBlock(mapping); 49| 16| } 50| 16| return mapping; 51| 16|} 52| | 53| |- (id)initWithEntityName:(NSString *)entityName 54| 294|{ 55| 294| self = [super init]; 56| 294| if (self) 57| 294| { 58| 294| _entityName = entityName; 59| 294| _propertyMappings = [NSMutableDictionary dictionary]; 60| 294| _hasOneMappings = [NSMutableArray array]; 61| 294| _hasManyMappings = [NSMutableArray array]; 62| 294| } 63| 294| return self; 64| 294|} 65| | 66| |- (id)initWithEntityName:(NSString *)entityName withRootPath:(NSString *)rootPath 67| 17|{ 68| 17| self = [self initWithEntityName:entityName]; 69| 17| if (self) 70| 17| { 71| 17| _rootPath = rootPath; 72| 17| } 73| 17| return self; 74| 17|} 75| | 76| |- (EKPropertyMapping *)primaryKeyPropertyMapping 77| 628k|{ 78| 628k| __block EKPropertyMapping * primaryKeyMapping = nil; 79| 628k| [self.propertyMappings enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL * stop) 80| 632k| { 81| 632k| EKPropertyMapping * mapping = obj; 82| 632k| if ([mapping.property isEqualToString:self.primaryKey]) 83| 628k| { 84| 628k| primaryKeyMapping = mapping; 85| 628k| *stop = YES; 86| 628k| } 87| 632k| }]; 88| 628k| return primaryKeyMapping; 89| 628k|} 90| | 91| |-(void)mapKeyPath:(NSString *)keyPath toProperty:(NSString *)property withValueBlock:(EKManagedMappingValueBlock)valueBlock 92| 1|{ 93| 1| NSParameterAssert(keyPath); 94| 1| NSParameterAssert(property); 95| 1| NSParameterAssert(valueBlock); 96| 1| 97| 1| EKPropertyMapping *mapping = [EKPropertyMapping mappingWithKeyPath:keyPath forProperty:property]; 98| 1| mapping.managedValueBlock = valueBlock; 99| 1| [self addPropertyMappingToDictionary:mapping]; 100| 1|} 101| | 102| |-(void)mapKeyPath:(NSString *)keyPath toProperty:(NSString *)property withValueBlock:(EKManagedMappingValueBlock)valueBlock reverseBlock:(EKManagedMappingReverseValueBlock)reverseBlock 103| 15|{ 104| 15| NSParameterAssert(keyPath); 105| 15| NSParameterAssert(property); 106| 15| NSParameterAssert(valueBlock); 107| 15| NSParameterAssert(reverseBlock); 108| 15| 109| 15| EKPropertyMapping *mapping = [EKPropertyMapping mappingWithKeyPath:keyPath forProperty:property]; 110| 15| mapping.managedValueBlock = valueBlock; 111| 15| mapping.managedReverseBlock = reverseBlock; 112| 15| [self addPropertyMappingToDictionary:mapping]; 113| 15|} 114| | 115| |- (void)addPropertyMappingToDictionary:(EKPropertyMapping *)mapping 116| 961|{ 117| 961| [self.propertyMappings setObject:mapping forKey:mapping.keyPath]; 118| 961|} 119| | 120| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKManagedObjectModel.m: 1| |// 2| |// EKManagedObjectModel.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 22.06.14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "EKManagedObjectModel.h" 10| |#import "EKManagedObjectMapper.h" 11| |#import "EKManagedObjectMapping.h" 12| |#import "EKSerializer.h" 13| | 14| |@implementation EKManagedObjectModel 15| | 16| |#pragma mark - constructors 17| | 18| |+(instancetype)objectWithProperties:(NSDictionary *)properties inContext:(NSManagedObjectContext *)context 19| 0|{ 20| 0| return [EKManagedObjectMapper objectFromExternalRepresentation:properties 21| 0| withMapping:[self objectMapping] 22| 0| inManagedObjectContext:context]; 23| 0|} 24| | 25| |#pragma mark - serialization 26| | 27| |- (NSDictionary *)serializedObjectInContext:(NSManagedObjectContext *)context 28| 0|{ 29| 0| return [EKSerializer serializeObject:self 30| 0| withMapping:[self.class objectMapping] 31| 0| fromContext:context]; 32| 0|} 33| | 34| |#pragma mark - EKManagedMappingProtocol 35| | 36| |+(EKManagedObjectMapping *)objectMapping 37| 14|{ 38| 14| return [[EKManagedObjectMapping alloc] initWithEntityName:NSStringFromClass(self)]; 39| 14|} 40| | 41| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKMapper.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2014 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "EKMapper.h" 25| |#import "EKPropertyHelper.h" 26| |#import "EKPropertyMapping.h" 27| |#import "EKRelationshipMapping.h" 28| | 29| |@implementation EKMapper 30| | 31| |+ (id)objectFromExternalRepresentation:(NSDictionary *)externalRepresentation withMapping:(EKObjectMapping *)mapping 32| 240k|{ 33| 240k| if (![externalRepresentation isKindOfClass:NSDictionary.class]) { return nil; } 34| 240k| id object = [[mapping.objectClass alloc] init]; 35| 240k| return [self fillObject:object fromExternalRepresentation:externalRepresentation withMapping:mapping]; 36| 240k|} 37| | 38| |+ (id)fillObject:(id)object fromExternalRepresentation:(NSDictionary *)externalRepresentation 39| | withMapping:(EKObjectMapping *)mapping 40| 240k|{ 41| 240k| NSDictionary *representation = [EKPropertyHelper extractRootPathFromExternalRepresentation:externalRepresentation withMapping:mapping]; 42| 791k| [mapping.propertyMappings enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL *stop) { 43| 791k| [EKPropertyHelper setProperty:obj 44| 791k| onObject:object 45| 791k| fromRepresentation:representation 46| 791k| respectPropertyType:mapping.respectPropertyFoundationTypes 47| 791k| ignoreMissingFields:mapping.ignoreMissingFields]; 48| 791k| }]; 49| 240k| for (EKRelationshipMapping *oneRelationship in mapping.hasOneMappings) { 50| 50.0k| if (oneRelationship.condition) { 51| 1| if (!oneRelationship.condition(representation)) { 52| 1| continue; 53| 1| } 54| 50.0k| } 55| 50.0k| 56| 50.0k| NSDictionary * value = [oneRelationship extractObjectFromRepresentation:representation]; 57| 50.0k| 58| 50.0k| if(mapping.ignoreMissingFields && !value) 59| 2| { 60| 2| continue; 61| 2| } 62| 50.0k| 63| 50.0k| if (value && value != (id)[NSNull null]) { 64| 20.0k| id result = [self objectFromExternalRepresentation:value withMapping:[oneRelationship mappingForRepresentation:value]]; 65| 20.0k| [object setValue:result forKeyPath:oneRelationship.property]; 66| 30.0k| } else { 67| 30.0k| [object setValue:nil forKey:oneRelationship.property]; 68| 30.0k| } 69| 50.0k| } 70| 240k| 71| 240k| for (EKRelationshipMapping *manyRelationship in mapping.hasManyMappings) { 72| 70.1k| 73| 70.1k| if (manyRelationship.condition) { 74| 1| if (!manyRelationship.condition(representation)) { 75| 1| continue; 76| 1| } 77| 70.1k| } 78| 70.1k| 79| 70.1k| NSArray *arrayToBeParsed = [representation valueForKeyPath:manyRelationship.keyPath]; 80| 70.1k| if(mapping.ignoreMissingFields && !arrayToBeParsed) 81| 2| { 82| 2| continue; 83| 2| } 84| 70.1k| 85| 70.1k| if (arrayToBeParsed && arrayToBeParsed != (id)[NSNull null]) { 86| 40.0k| NSArray *parsedArray = [self arrayOfObjectsFromExternalRepresentation:arrayToBeParsed 87| 40.0k| withRelationship:manyRelationship]; 88| 40.0k| id parsedObjects = [EKPropertyHelper propertyRepresentation:parsedArray 89| 40.0k| forObject:object 90| 40.0k| withPropertyName:[manyRelationship property]]; 91| 40.0k| if(mapping.incrementalData) { 92| 4| [EKPropertyHelper addValue:parsedObjects onObject:object forKeyPath:manyRelationship.property]; 93| 4| } 94| 40.0k| else { 95| 40.0k| [EKPropertyHelper setValue:parsedObjects onObject:object forKeyPath:manyRelationship.property]; 96| 40.0k| } 97| 40.0k| } else if(!mapping.incrementalData) { 98| 30.0k| [EKPropertyHelper setValue:nil onObject:object forKeyPath:manyRelationship.property]; 99| 30.0k| } 100| 70.1k| } 101| 240k| return object; 102| 240k|} 103| | 104| |+ (NSArray *)arrayOfObjectsFromExternalRepresentation:(NSArray *)externalRepresentation 105| | withRelationship:(EKRelationshipMapping *)mapping 106| 40.0k|{ 107| 40.0k| if (![externalRepresentation isKindOfClass:[NSArray class]] || 108| 40.0k| ![mapping isKindOfClass:[EKRelationshipMapping class]]) { 109| 0| return nil; 110| 0| } 111| 40.0k| 112| 40.0k| NSMutableArray *array = [NSMutableArray array]; 113| 90.1k| for (NSDictionary *representation in externalRepresentation) { 114| 90.1k| id parsedObject = [self objectFromExternalRepresentation:representation withMapping:[mapping mappingForRepresentation:representation]]; 115| 90.1k| if (parsedObject) { 116| 90.1k| [array addObject:parsedObject]; 117| 90.1k| } 118| 90.1k| } 119| 40.0k| return [NSArray arrayWithArray:array]; 120| 40.0k|} 121| | 122| | 123| |+ (NSArray *)arrayOfObjectsFromExternalRepresentation:(NSArray *)externalRepresentation 124| | withMapping:(EKObjectMapping *)mapping 125| 3|{ 126| 3| if (![externalRepresentation isKindOfClass:[NSArray class]] || 127| 3| ![mapping isKindOfClass:[EKObjectMapping class]]) { 128| 0| return nil; 129| 0| } 130| 3| 131| 3| NSMutableArray *array = [NSMutableArray array]; 132| 6| for (NSDictionary *representation in externalRepresentation) { 133| 6| id parsedObject = [self objectFromExternalRepresentation:representation withMapping:mapping]; 134| 6| if (parsedObject) { 135| 5| [array addObject:parsedObject]; 136| 5| } 137| 6| } 138| 3| return [NSArray arrayWithArray:array]; 139| 3|} 140| | 141| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKMappingBlocks.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2015 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "EKMappingBlocks.h" 25| | 26| |@implementation EKMappingBlocks 27| | 28| |+(EKMappingValueBlock)urlMappingBlock 29| 84|{ 30| 10.0k| return ^id(NSString * key, id value) { 31| 10.0k| if ([value isKindOfClass:[NSString class]]) 32| 10.0k| { 33| 10.0k| return [NSURL URLWithString:value]; 34| 10.0k| } 35| 1| return nil; 36| 1| }; 37| 84|} 38| | 39| |+(EKMappingReverseBlock)urlReverseMappingBlock 40| 83|{ 41| 83| return ^id(id value){ 42| 5| if ([value isKindOfClass:[NSURL class]]) 43| 4| { 44| 4| return [value absoluteString]; 45| 4| } 46| 1| return nil; 47| 1| }; 48| 83|} 49| | 50| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKObjectMapping.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2014 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "EKObjectMapping.h" 25| |#import "EKPropertyMapping.h" 26| |#import "EKRelationshipMapping.h" 27| |#import "EKMappingProtocol.h" 28| |#import "NSDateFormatter+EasyMappingAdditions.h" 29| |#import "EKPropertyHelper.h" 30| | 31| |@implementation EKObjectMapping 32| | 33| |+ (EKObjectMapping *)mappingForClass:(Class)objectClass withBlock:(void (^)(EKObjectMapping *))mappingBlock 34| 20.3k|{ 35| 20.3k| EKObjectMapping *mapping = [[EKObjectMapping alloc] initWithObjectClass:objectClass]; 36| 20.3k| if (mappingBlock) 37| 20.3k| { 38| 20.3k| mappingBlock(mapping); 39| 20.3k| } 40| 20.3k| return mapping; 41| 20.3k|} 42| | 43| |+ (EKObjectMapping *)mappingForClass:(Class)objectClass withRootPath:(NSString *)rootPath withBlock:(void (^)(EKObjectMapping *))mappingBlock 44| 12|{ 45| 12| EKObjectMapping *mapping = [[EKObjectMapping alloc] initWithObjectClass:objectClass withRootPath:rootPath]; 46| 12| if (mappingBlock) 47| 12| { 48| 12| mappingBlock(mapping); 49| 12| } 50| 12| return mapping; 51| 12|} 52| | 53| |- (id)initWithObjectClass:(Class)objectClass 54| 20.4k|{ 55| 20.4k| self = [super init]; 56| 20.4k| if (self) { 57| 20.4k| _objectClass = objectClass; 58| 20.4k| _propertyMappings = [NSMutableDictionary dictionary]; 59| 20.4k| _hasOneMappings = [NSMutableArray array]; 60| 20.4k| _hasManyMappings = [NSMutableArray array]; 61| 20.4k| } 62| 20.4k| return self; 63| 20.4k|} 64| | 65| |- (id)initWithObjectClass:(Class)objectClass withRootPath:(NSString *)rootPath 66| 13|{ 67| 13| self = [self initWithObjectClass:objectClass]; 68| 13| if (self) { 69| 13| _rootPath = rootPath; 70| 13| } 71| 13| return self; 72| 13|} 73| | 74| |- (void)mapKeyPath:(NSString *)keyPath toProperty:(NSString *)property 75| 22.1k|{ 76| 22.1k| NSParameterAssert(keyPath); 77| 22.1k| NSParameterAssert(property); 78| 22.1k| 79| 22.1k| EKPropertyMapping *mapping = [EKPropertyMapping mappingWithKeyPath:keyPath forProperty:property]; 80| 22.1k| [self addPropertyMappingToDictionary:mapping]; 81| 22.1k|} 82| | 83| |-(void)mapKeyPath:(NSString *)keyPath toProperty:(NSString *)property withDateFormatter:(NSDateFormatter *)formatter 84| 29|{ 85| 29| NSParameterAssert(keyPath); 86| 29| NSParameterAssert(property); 87| 29| NSParameterAssert(formatter); 88| 29| 89| 29| [self mapKeyPath:keyPath 90| 29| toProperty:property 91| 11.0k| withValueBlock:^id(NSString * key, id value) { 92| 11.0k| if (value == NSNull.null) return value; 93| 11.0k| return [value isKindOfClass:[NSString class]] ? [formatter dateFromString:value] : nil; 94| 11.0k| } reverseBlock:^id(id value) { 95| 4| return [value isKindOfClass:[NSDate class]] ? [formatter stringFromDate:value] : nil; 96| 4| }]; 97| 29|} 98| | 99| |- (void)mapPropertiesFromArray:(NSArray *)propertyNamesArray 100| 20.6k|{ 101| 20.6k| NSParameterAssert([propertyNamesArray isKindOfClass:[NSArray class]]); 102| 20.6k| 103| 21.4k| for (NSString *key in propertyNamesArray) { 104| 21.4k| [self mapKeyPath:key toProperty:key]; 105| 21.4k| } 106| 20.6k|} 107| | 108| |-(void)mapPropertiesFromArrayToPascalCase:(NSArray *)propertyNamesArray 109| 1|{ 110| 1| NSParameterAssert([propertyNamesArray isKindOfClass:[NSArray class]]); 111| 2| for (NSString *key in propertyNamesArray) { 112| 2| NSString *pascalKey = [key stringByReplacingCharactersInRange:NSMakeRange(0,1) withString:[[key substringToIndex:1] uppercaseString]]; 113| 2| 114| 2| [self mapKeyPath:pascalKey toProperty:key]; 115| 2| } 116| 1|} 117| | 118| |- (void)mapPropertiesFromUnderscoreToCamelCase:(NSArray *)propertyNamesArray 119| 1|{ 120| 4| for (NSString *key in propertyNamesArray) { 121| 4| NSString *convertedKey = [EKPropertyHelper convertStringFromUnderScoreToCamelCase: key]; 122| 4| 123| 4| [self mapKeyPath:key toProperty:convertedKey]; 124| 4| } 125| 1|} 126| | 127| |- (void)mapPropertiesFromDictionary:(NSDictionary *)propertyDictionary 128| 411|{ 129| 411| NSParameterAssert([propertyDictionary isKindOfClass:[NSDictionary class]]); 130| 411| 131| 535| [propertyDictionary enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL *stop) { 132| 535| [self mapKeyPath:key toProperty:obj]; 133| 535| }]; 134| 411|} 135| | 136| |-(void)mapPropertiesFromMappingObject:(EKObjectMapping *)mappingObj 137| 1|{ 138| 1| NSParameterAssert([mappingObj isKindOfClass:EKObjectMapping.class]); 139| 1| 140| 1| for (NSString *key in mappingObj.propertyMappings) { 141| 1| [self addPropertyMappingToDictionary:mappingObj.propertyMappings[key]]; 142| 1| } 143| 1| 144| 1| for (EKRelationshipMapping *relationship in mappingObj.hasOneMappings) { 145| 1| [self.hasOneMappings addObject:relationship]; 146| 1| } 147| 1| 148| 1| for (EKRelationshipMapping *relationship in mappingObj.hasManyMappings) { 149| 1| [self.hasManyMappings addObject:relationship]; 150| 1| } 151| 1|} 152| | 153| |- (void)mapKeyPath:(NSString *)keyPath toProperty:(NSString *)property 154| |withValueBlock:(id (^)(NSString *, id))valueBlock 155| 1|{ 156| 1| NSParameterAssert(keyPath); 157| 1| NSParameterAssert(property); 158| 1| NSParameterAssert(valueBlock); 159| 1| 160| 1| EKPropertyMapping *mapping = [EKPropertyMapping mappingWithKeyPath:keyPath forProperty:property]; 161| 1| mapping.valueBlock = valueBlock; 162| 1| [self addPropertyMappingToDictionary:mapping]; 163| 1|} 164| | 165| |- (void)mapKeyPath:(NSString *)keyPath toProperty:(NSString *)property 166| |withValueBlock:(id (^)(NSString *, id))valueBlock reverseBlock:(id (^)(id))reverseBlock 167| 212|{ 168| 212| NSParameterAssert(keyPath); 169| 212| NSParameterAssert(property); 170| 212| NSParameterAssert(valueBlock); 171| 212| NSParameterAssert(reverseBlock); 172| 212| 173| 212| EKPropertyMapping *mapping = [EKPropertyMapping mappingWithKeyPath:keyPath forProperty:property]; 174| 212| mapping.valueBlock = valueBlock; 175| 212| mapping.reverseBlock = reverseBlock; 176| 212| [self addPropertyMappingToDictionary:mapping]; 177| 212|} 178| | 179| |- (EKRelationshipMapping *)hasOne:(Class)objectClass forKeyPath:(NSString *)keyPath 180| 273|{ 181| 273| return [self hasOne:objectClass forKeyPath:keyPath forProperty:keyPath withObjectMapping:nil]; 182| 273|} 183| | 184| |- (EKRelationshipMapping *)hasOne:(Class)objectClass forKeyPath:(NSString *)keyPath forProperty:(NSString *)property 185| 3|{ 186| 3| return [self hasOne:objectClass forKeyPath:keyPath forProperty:property withObjectMapping:nil]; 187| 3|} 188| | 189| |- (EKRelationshipMapping *)hasOne:(Class)objectClass forKeyPath:(NSString *)keyPath forProperty:(NSString *)property withObjectMapping:(EKObjectMapping*)objectMapping 190| 277|{ 191| 277| if (!objectMapping) { 192| 277| NSParameterAssert([objectClass conformsToProtocol:@protocol(EKMappingProtocol)] || 193| 277| [objectClass conformsToProtocol:@protocol(EKManagedMappingProtocol)]); 194| 277| } 195| 277| NSParameterAssert(keyPath); 196| 277| NSParameterAssert(property); 197| 277| 198| 277| EKRelationshipMapping * relationship = [EKRelationshipMapping mappingForClass:objectClass 199| 277| withKeyPath:keyPath 200| 277| forProperty:property]; 201| 277| relationship.mappingResolver = [self defaultMappingResolveBlockFor:objectClass 202| 277| with:objectMapping]; 203| 277| relationship.serializationResolver = [self defaultSerializationResolveBlockFor:objectClass 204| 277| with:objectMapping]; 205| 277| [self.hasOneMappings addObject:relationship]; 206| 277| 207| 277| return relationship; 208| 277|} 209| | 210| |- (EKRelationshipMapping *)hasOne:(Class)objectClass forDictionaryFromKeyPaths:(NSArray *)keyPaths forProperty:(NSString *)property withObjectMapping:(EKObjectMapping *)mapping 211| 8|{ 212| 8| if (!mapping) { 213| 0| NSParameterAssert([objectClass conformsToProtocol:@protocol(EKMappingProtocol)] || 214| 0| [objectClass conformsToProtocol:@protocol(EKManagedMappingProtocol)]); 215| 0| } 216| 8| NSParameterAssert(keyPaths); 217| 8| NSParameterAssert(property); 218| 8| 219| 8| EKRelationshipMapping * relationship = [EKRelationshipMapping mappingForClass:objectClass 220| 8| withKeyPath:@"" 221| 8| forProperty:property]; 222| 8| relationship.nonNestedKeyPaths = keyPaths; 223| 8| relationship.mappingResolver = [self defaultMappingResolveBlockFor:objectClass 224| 8| with:mapping]; 225| 8| relationship.serializationResolver = [self defaultSerializationResolveBlockFor:objectClass 226| 8| with:mapping]; 227| 8| [self.hasOneMappings addObject:relationship]; 228| 8| 229| 8| return relationship; 230| 8|} 231| | 232| |- (EKRelationshipMapping *)hasMany:(Class)objectClass forKeyPath:(NSString *)keyPath 233| 292|{ 234| 292| return [self hasMany:objectClass forKeyPath:keyPath forProperty:keyPath withObjectMapping:nil]; 235| 292|} 236| | 237| |- (EKRelationshipMapping *)hasMany:(Class)objectClass forKeyPath:(NSString *)keyPath forProperty:(NSString *)property 238| 7|{ 239| 7| return [self hasMany:objectClass forKeyPath:keyPath forProperty:property withObjectMapping:nil]; 240| 7|} 241| | 242| |- (EKRelationshipMapping *)hasMany:(Class)objectClass forKeyPath:(NSString *)keyPath forProperty:(NSString *)property withObjectMapping:(EKObjectMapping*)objectMapping 243| 300|{ 244| 300| if (!objectMapping) { 245| 300| NSParameterAssert([objectClass conformsToProtocol:@protocol(EKMappingProtocol)] || 246| 300| [objectClass conformsToProtocol:@protocol(EKManagedMappingProtocol)]); 247| 300| } 248| 300| NSParameterAssert(keyPath); 249| 300| NSParameterAssert(property); 250| 300| 251| 300| EKRelationshipMapping * relationship = [EKRelationshipMapping mappingForClass:objectClass 252| 300| withKeyPath:keyPath 253| 300| forProperty:property]; 254| 300| relationship.mappingResolver = [self defaultMappingResolveBlockFor:objectClass 255| 300| with:objectMapping]; 256| 300| relationship.serializationResolver = [self defaultSerializationResolveBlockFor:objectClass 257| 300| with:objectMapping]; 258| 300| [self.hasManyMappings addObject:relationship]; 259| 300| 260| 300| return relationship; 261| 300|} 262| | 263| |- (void)addPropertyMappingToDictionary:(EKPropertyMapping *)propertyMapping 264| 21.4k|{ 265| 21.4k| [self.propertyMappings setObject:propertyMapping forKey:propertyMapping.keyPath]; 266| 21.4k|} 267| | 268| 585|-(EKMappingResolvingBlock)defaultMappingResolveBlockFor:(Class)objectClass with:(EKObjectMapping *) mapping { 269| 370k| return ^(id representation ){ 270| 370k| if (mapping != nil) { 271| 4| return mapping; 272| 4| } 273| 370k| return [objectClass objectMapping]; 274| 370k| }; 275| 585|} 276| | 277| 585|-(EKSerializationResolvingBlock)defaultSerializationResolveBlockFor:(Class)objectClass with:(EKObjectMapping *)objectMapping { 278| 585| return ^(id object) { 279| 21| if (objectMapping != nil) { 280| 4| return objectMapping; 281| 4| } 282| 17| return [objectClass objectMapping]; 283| 17| }; 284| 585|} 285| | 286| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKObjectModel.m: 1| |// 2| |// EKObjectModel.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 22.06.14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "EKObjectModel.h" 10| |#import "EKMapper.h" 11| |#import "EKSerializer.h" 12| | 13| |@implementation EKObjectModel 14| | 15| |#pragma mark - constructors 16| | 17| |+(instancetype)objectWithProperties:(NSDictionary *)properties 18| 1|{ 19| 1| return [EKMapper objectFromExternalRepresentation:properties 20| 1| withMapping:[self objectMapping]]; 21| 1|} 22| | 23| |-(instancetype)initWithProperties:(NSDictionary *)properties 24| 3|{ 25| 3| if (self = [super init]) 26| 3| { 27| 3| [EKMapper fillObject:self 28| 3| fromExternalRepresentation:properties 29| 3| withMapping:[self.class objectMapping]]; 30| 3| } 31| 3| return self; 32| 3|} 33| | 34| |#pragma mark - serialization 35| | 36| |- (NSDictionary *)serializedObject 37| 1|{ 38| 1| return [EKSerializer serializeObject:self 39| 1| withMapping:[self.class objectMapping]]; 40| 1|} 41| | 42| |#pragma mark - EKMappingProtocol 43| | 44| |+(EKObjectMapping *)objectMapping 45| 5|{ 46| 5| return [[EKObjectMapping alloc] initWithObjectClass:self]; 47| 5|} 48| | 49| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKPropertyHelper.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2014 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "EKPropertyHelper.h" 25| |#import 26| |@import ObjectiveC.runtime; 27| | 28| |static const char scalarTypes[] = { 29| | _C_BOOL, _C_BFLD, // BOOL 30| | _C_CHR, _C_UCHR, // char, unsigned char 31| | _C_SHT, _C_USHT, // short, unsigned short 32| | _C_INT, _C_UINT, // int, unsigned int, NSInteger, NSUInteger 33| | _C_LNG, _C_ULNG, // long, unsigned long 34| | _C_LNG_LNG, _C_ULNG_LNG, // long long, unsigned long long 35| | _C_FLT, _C_DBL // float, CGFloat, double 36| |}; 37| | 38| |@implementation EKPropertyHelper 39| | 40| |#pragma mark - Property introspection 41| | 42| |+ (BOOL)propertyNameIsNativeProperty:(NSString *)propertyName fromObject:(id)object 43| 43.1k|{ 44| 43.1k| objc_property_t property = class_getProperty(object_getClass(object), [propertyName UTF8String]); 45| 43.1k| NSString *type = property ? [self propertyTypeStringRepresentationFromProperty:property] : nil; 46| 43.1k| 47| 43.1k| BOOL isScalar = (type.length == 1) && memchr(scalarTypes, type.UTF8String[0], sizeof(scalarTypes)); 48| 43.1k| BOOL isStruct = (type.length > 2) && [type characterAtIndex:0] == '{' && [type characterAtIndex:type.length - 1] == '}'; 49| 43.1k| return isScalar || isStruct; 50| 43.1k|} 51| | 52| |+ (NSString *) propertyTypeStringRepresentationFromProperty:(objc_property_t)property 53| 135k|{ 54| 135k| const char *TypeAttribute = "T"; 55| 135k| char *type = property_copyAttributeValue(property, TypeAttribute); 56| 135k| NSString *propertyType = (type[0] != _C_ID) ? @(type) : ({ 57| 125k| (type[1] == 0) ? @"id" : ({ 58| 125k| // Modern format of a type attribute (e.g. @"NSSet") 59| 125k| type[strlen(type) - 1] = 0; 60| 125k| @(type + 2); 61| 125k| }); 62| 125k| }); 63| 135k| free(type); 64| 135k| return propertyType; 65| 135k|} 66| | 67| |+ (id)propertyRepresentation:(id)value forObject:(id)object withPropertyName:(NSString *)propertyName 68| 92.1k|{ 69| 92.1k| if (!value) 70| 0| { 71| 0| return nil; 72| 0| } 73| 92.1k| 74| 92.1k| objc_property_t property = class_getProperty([object class], [propertyName UTF8String]); 75| 92.1k| if (property) 76| 92.1k| { 77| 92.1k| NSString *type = [self propertyTypeStringRepresentationFromProperty:property]; 78| 92.1k| if ([type isEqualToString:@"NSSet"]) { 79| 62.0k| return [NSSet setWithArray:value]; 80| 62.0k| } 81| 30.0k| else if ([type isEqualToString:@"NSMutableSet"]) { 82| 2| return [NSMutableSet setWithArray:value]; 83| 2| } 84| 30.0k| else if ([type isEqualToString:@"NSOrderedSet"]) { 85| 2| return [NSOrderedSet orderedSetWithArray:value]; 86| 2| } 87| 30.0k| else if ([type isEqualToString:@"NSMutableOrderedSet"]) { 88| 2| return [NSMutableOrderedSet orderedSetWithArray:value]; 89| 2| } 90| 30.0k| else if ([type isEqualToString:@"NSMutableArray"]) { 91| 10.0k| return [NSMutableArray arrayWithArray:value]; 92| 20.0k| } else if ([type isEqualToString:@"NSMutableDictionary"]) { 93| 1| return [NSMutableDictionary dictionaryWithDictionary:value]; 94| 1| } 95| 20.0k| } 96| 20.0k| return value; 97| 20.0k|} 98| | 99| |#pragma mark Property accessor methods 100| | 101| |+ (void)setProperty:(EKPropertyMapping *)propertyMapping onObject:(id)object 102| | fromRepresentation:(NSDictionary *)representation respectPropertyType:(BOOL)respectPropertyType ignoreMissingFields:(BOOL)ignoreMissingFields 103| 791k|{ 104| 791k| id value = [self getValueOfProperty:propertyMapping fromRepresentation:representation]; 105| 791k| if (value && value != (id)NSNull.null) { 106| 751k| if (respectPropertyType) { 107| 6| value = [self propertyRepresentation:value 108| 6| forObject:object 109| 6| withPropertyName:propertyMapping.property]; 110| 6| } 111| 751k| [self setValue:value onObject:object forKeyPath:propertyMapping.property]; 112| 751k| } else { 113| 40.0k| if (!value && ignoreMissingFields) return; 114| 40.0k| 115| 40.0k| if (![self propertyNameIsNativeProperty:propertyMapping.property fromObject:object]) { 116| 30.0k| [self setValue:nil onObject:object forKeyPath:propertyMapping.property]; 117| 30.0k| } 118| 40.0k| } 119| 791k|} 120| | 121| |+ (void) setProperty:(EKPropertyMapping *)propertyMapping 122| | onObject:(id)object 123| | fromRepresentation:(NSDictionary *)representation 124| | inContext:(NSManagedObjectContext *)context 125| | respectPropertyType:(BOOL)respectPropertyType 126| |ignoreMissingFields:(BOOL)ignoreMissingFields 127| 1.20M|{ 128| 1.20M| id value = [self getValueOfManagedProperty:propertyMapping 129| 1.20M| fromRepresentation:representation 130| 1.20M| inContext:context]; 131| 1.20M| if (value && value != (id)NSNull.null) { 132| 1.19M| if (respectPropertyType) { 133| 4| value = [self propertyRepresentation:value 134| 4| forObject:object 135| 4| withPropertyName:propertyMapping.property]; 136| 4| } 137| 1.19M| [self setValue:value onObject:object forKeyPath:propertyMapping.property]; 138| 1.19M| } else { 139| 3.04k| if (!value && ignoreMissingFields) return; 140| 3.03k| 141| 3.03k| if (![self propertyNameIsNativeProperty:propertyMapping.property fromObject:object]) { 142| 3.03k| [self setValue:nil onObject:object forKeyPath:propertyMapping.property]; 143| 3.03k| } 144| 3.03k| } 145| 1.20M|} 146| | 147| |+(void)setValue:(id)value onObject:(id)object forKeyPath:(NSString *)keyPath 148| 2.10M|{ 149| 2.10M| if ([(id )object isKindOfClass:[NSManagedObject class]]) 150| 1.25M| { 151| 1.25M| // Reducing update times in CoreData 152| 1.25M| id _value = [object valueForKeyPath:keyPath]; 153| 1.25M| 154| 1.25M| if (_value != value && ![_value isEqual:value]) { 155| 135k| [object setValue:value forKeyPath:keyPath]; 156| 135k| } 157| 1.25M| } 158| 851k| else { 159| 851k| [object setValue:value forKeyPath:keyPath]; 160| 851k| } 161| 2.10M|} 162| | 163| |+(void)addValue:(id)value onObject:(id)object forKeyPath:(NSString *)keyPath 164| 11|{ 165| 11| id _value = [object valueForKeyPath:keyPath]; 166| 11| 167| 11| if ([object isKindOfClass:[NSManagedObject class]]) 168| 6| { 169| 6| // Reducing update times in CoreData 170| 6| if(_value != value && ![value isSubsetOfSet:_value]) { 171| 5| _value = [_value setByAddingObjectsFromSet:value]; 172| 5| [object setValue:_value forKey:keyPath]; 173| 5| } 174| 6| } 175| 5| else { 176| 5| if ([_value isKindOfClass:NSSet.class]) { 177| 1| _value = [_value setByAddingObjectsFromSet:value]; 178| 1| [object setValue:_value forKey:keyPath]; 179| 4| } else if ([_value isKindOfClass:NSArray.class]) { 180| 2| _value = [_value arrayByAddingObjectsFromArray:value]; 181| 2| [object setValue:_value forKey:keyPath]; 182| 2| } else { 183| 2| [self setValue:value onObject:object forKeyPath:keyPath]; 184| 2| } 185| 5| } 186| 11|} 187| | 188| |+ (id)getValueOfProperty:(EKPropertyMapping *)mapping fromRepresentation:(NSDictionary *)representation 189| 791k|{ 190| 791k| if (mapping == nil) return nil; 191| 791k| 192| 791k| if (mapping.valueBlock) { 193| 110k| id value = [representation valueForKeyPath:mapping.keyPath]; 194| 110k| if (value != nil) { 195| 80.1k| return mapping.valueBlock(mapping.keyPath, value); 196| 80.1k| } 197| 30.0k| return value; 198| 30.0k| } 199| 681k| else { 200| 681k| return [representation valueForKeyPath:mapping.keyPath]; 201| 681k| } 202| 791k|} 203| | 204| |+(id)getValueOfManagedProperty:(EKPropertyMapping *)mapping 205| | fromRepresentation:(NSDictionary *)representation 206| | inContext:(NSManagedObjectContext *)context 207| 1.82M|{ 208| 1.82M| if (mapping == nil) return nil; 209| 1.82M| 210| 1.82M| if (mapping.managedValueBlock) { 211| 1.01k| id value = [representation valueForKeyPath:mapping.keyPath]; 212| 1.01k| if (value != nil) { 213| 1.01k| return mapping.managedValueBlock(mapping.keyPath,value,context); 214| 1.01k| } 215| 1| return value; 216| 1| } 217| 1.82M| else { 218| 1.82M| return [representation valueForKeyPath:mapping.keyPath]; 219| 1.82M| } 220| 1.82M|} 221| | 222| |+ (NSDictionary *)extractRootPathFromExternalRepresentation:(NSDictionary *)externalRepresentation 223| | withMapping:(EKObjectMapping *)mapping 224| 1.19M|{ 225| 1.19M| if (mapping.rootPath) { 226| 14.0k| return [externalRepresentation valueForKeyPath:mapping.rootPath]; 227| 14.0k| } 228| 1.18M| return externalRepresentation; 229| 1.18M|} 230| | 231| 4|+ (NSString *)convertStringFromUnderScoreToCamelCase:(NSString *)string { 232| 4| NSMutableString *output = [NSMutableString string]; 233| 4| BOOL makeNextCharacterUpperCase = NO; 234| 29| for (NSInteger idx = 0; idx < [string length]; idx += 1) { 235| 25| unichar c = [string characterAtIndex:idx]; 236| 25| if (c == '_') { 237| 2| makeNextCharacterUpperCase = YES; 238| 23| } else if (makeNextCharacterUpperCase) { 239| 2| [output appendString:[[NSString stringWithCharacters:&c length:1] uppercaseString]]; 240| 2| makeNextCharacterUpperCase = NO; 241| 21| } else { 242| 21| [output appendFormat:@"%C", c]; 243| 21| } 244| 25| } 245| 4| return output; 246| 4|} 247| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKPropertyMapping.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2014 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "EKPropertyMapping.h" 25| | 26| |@implementation EKPropertyMapping 27| | 28| 22.3k|+(instancetype)mappingWithKeyPath:(NSString *)keyPath forProperty:(NSString *)property { 29| 22.3k| EKPropertyMapping * mapping = [EKPropertyMapping new]; 30| 22.3k| mapping.keyPath = keyPath; 31| 22.3k| mapping.property = property; 32| 22.3k| return mapping; 33| 22.3k|} 34| | 35| |- (instancetype)init 36| 22.3k|{ 37| 22.3k| self = [super init]; 38| 22.3k| if (self) { 39| 22.3k| _keyPath = @""; 40| 22.3k| _property = @""; 41| 22.3k| } 42| 22.3k| return self; 43| 22.3k|} 44| | 45| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKRelationshipMapping.m: 1| |// 2| |// EKRelationshipMapping.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 14.06.14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "EKRelationshipMapping.h" 10| | 11| |@implementation EKRelationshipMapping 12| | 13| 370k|-(EKObjectMapping *)mappingForRepresentation:(id)representation { 14| 370k| if (self.mappingResolver) { 15| 370k| return self.mappingResolver(representation); 16| 370k| } 17| 0| return [[self objectClass] objectMapping]; 18| 0|} 19| | 20| 29|-(EKObjectMapping *)mappingForObject:(id)object { 21| 29| if (self.serializationResolver) { 22| 29| return self.serializationResolver(object); 23| 29| } 24| 0| return [[self objectClass] objectMapping]; 25| 0|} 26| | 27| |-(NSDictionary *)extractObjectFromRepresentation:(NSDictionary *)representation 28| 53.1k|{ 29| 53.1k| if (self.nonNestedKeyPaths == nil) 30| 53.1k| { 31| 53.1k| return [representation valueForKeyPath:self.keyPath]; 32| 53.1k| } 33| 3| else { 34| 3| NSMutableDictionary * values = [NSMutableDictionary dictionaryWithCapacity:self.nonNestedKeyPaths.count]; 35| 3| 36| 3| for (NSString * keyPath in self.nonNestedKeyPaths) 37| 9| { 38| 9| id value = [representation valueForKeyPath:keyPath]; 39| 9| if (value && value!=(id)[NSNull null]) 40| 9| { 41| 9| values[keyPath] = value; 42| 9| } 43| 9| } 44| 3| return [values copy]; 45| 3| } 46| 53.1k|} 47| | 48| 593|+(instancetype)mappingForClass:(Class)objectClass withKeyPath:(NSString *)keyPath forProperty:(NSString *)property { 49| 593| EKRelationshipMapping * mapping = [EKRelationshipMapping new]; 50| 593| mapping.objectClass = objectClass; 51| 593| mapping.keyPath = keyPath; 52| 593| mapping.property = property; 53| 593| return mapping; 54| 593|} 55| | 56| |- (instancetype)init 57| 593|{ 58| 593| self = [super init]; 59| 593| if (self) { 60| 593| _keyPath = @""; 61| 593| _property = @""; 62| 593| } 63| 593| return self; 64| 593|} 65| | 66| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKSerializer.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2014 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "EKSerializer.h" 25| |#import "EKPropertyMapping.h" 26| |#import "EKPropertyHelper.h" 27| |#import "EKRelationshipMapping.h" 28| | 29| |@implementation EKSerializer 30| | 31| |+ (NSDictionary *)serializeObject:(id)object withMapping:(EKObjectMapping *)mapping 32| 44|{ 33| 44| NSMutableDictionary *representation = [NSMutableDictionary dictionary]; 34| 44| 35| 126| [mapping.propertyMappings enumerateKeysAndObjectsUsingBlock:^(id key, EKPropertyMapping *propertyMapping, BOOL *stop) { 36| 126| [self setValueOnRepresentation:representation fromObject:object withPropertyMapping:propertyMapping]; 37| 126| }]; 38| 44| 39| 44| for (EKRelationshipMapping *relationship in mapping.hasOneMappings) { 40| 11| id hasOneObject = [object valueForKey:relationship.property]; 41| 11| 42| 11| if (hasOneObject) { 43| 6| NSDictionary *hasOneRepresentation = [self serializeObject:hasOneObject 44| 6| withMapping:[relationship mappingForObject:hasOneObject]]; 45| 6| 46| 6| if (relationship.nonNestedKeyPaths) 47| 2| { 48| 2| for (NSString * key in hasOneRepresentation.allKeys) 49| 4| { 50| 4| representation[key]=hasOneRepresentation[key]; 51| 4| } 52| 2| } 53| 4| else { 54| 4| [representation setObject:hasOneRepresentation forKey:relationship.keyPath]; 55| 4| } 56| 6| } 57| 11| } 58| 44| 59| 44| for (EKRelationshipMapping *relationship in mapping.hasManyMappings) { 60| 10| 61| 10| id hasManyObject = [object valueForKey:relationship.property]; 62| 10| if (hasManyObject) { 63| 4| NSArray *hasManyRepresentation = [self serializeCollection:hasManyObject 64| 4| withRelationship:relationship]; 65| 4| [representation setObject:hasManyRepresentation forKey:relationship.keyPath]; 66| 4| } 67| 10| } 68| 44| 69| 44| if (mapping.rootPath.length > 0) { 70| 1| NSMutableDictionary *rootRepresentation = [NSMutableDictionary new]; 71| 1| [self setValue:representation forKeyPath:mapping.rootPath inRepresentation:rootRepresentation]; 72| 1| representation = rootRepresentation; 73| 1| } 74| 44| return representation; 75| 44|} 76| | 77| |+ (NSArray *)serializeCollection:(NSArray> *)collection withMapping:(EKObjectMapping *)mapping 78| 0|{ 79| 0| NSMutableArray *array = [NSMutableArray array]; 80| 0| 81| 0| for (id object in collection) { 82| 0| NSDictionary *objectRepresentation = [self serializeObject:object withMapping:mapping]; 83| 0| [array addObject:objectRepresentation]; 84| 0| } 85| 0| 86| 0| return [NSArray arrayWithArray:array]; 87| 0|} 88| | 89| 5|+(NSArray *> *)serializeCollection:(NSArray *)collection withRelationship:(EKRelationshipMapping *)relationship { 90| 5| NSMutableArray *array = [NSMutableArray array]; 91| 5| 92| 14| for (id object in collection) { 93| 14| NSDictionary *objectRepresentation = [self serializeObject:object withMapping:[relationship mappingForObject:object]]; 94| 14| [array addObject:objectRepresentation]; 95| 14| } 96| 5| 97| 5| return [NSArray arrayWithArray:array]; 98| 5|} 99| | 100| |+(NSDictionary *)serializeObject:(id)object withMapping:(EKManagedObjectMapping *)mapping fromContext:(NSManagedObjectContext *)context 101| 9|{ 102| 9| NSMutableDictionary *representation = [NSMutableDictionary dictionary]; 103| 9| 104| 31| [mapping.propertyMappings enumerateKeysAndObjectsUsingBlock:^(id key, EKPropertyMapping *propertyMapping, BOOL *stop) { 105| 31| [self setValueOnRepresentation:representation 106| 31| fromManagedObject:object 107| 31| withPropertyMapping:propertyMapping 108| 31| inContext:context]; 109| 31| }]; 110| 9| 111| 9| for (EKRelationshipMapping *relationship in mapping.hasOneMappings) { 112| 4| 113| 4| id hasOneObject = [object valueForKey:relationship.property]; 114| 4| 115| 4| if (hasOneObject) { 116| 3| NSDictionary *hasOneRepresentation = [self serializeObject:hasOneObject 117| 3| withMapping:(EKManagedObjectMapping *)[relationship mappingForObject:hasOneObject] 118| 3| fromContext:context]; 119| 3| if (relationship.nonNestedKeyPaths) 120| 1| { 121| 1| for (NSString * key in hasOneRepresentation.allKeys) 122| 3| { 123| 3| representation[key]=hasOneRepresentation[key]; 124| 3| } 125| 1| } 126| 2| else { 127| 2| [representation setObject:hasOneRepresentation forKey:relationship.keyPath]; 128| 2| } 129| 3| } 130| 4| } 131| 9| 132| 9| for (EKRelationshipMapping *relationship in mapping.hasManyMappings) { 133| 2| 134| 2| id hasManyObject = [object valueForKey:relationship.property]; 135| 2| if (hasManyObject) { 136| 2| NSArray *hasManyRepresentation = [self serializeCollection:hasManyObject 137| 2| withRelationship:relationship 138| 2| fromContext:context]; 139| 2| [representation setObject:hasManyRepresentation forKey:relationship.keyPath]; 140| 2| } 141| 2| } 142| 9| 143| 9| if (mapping.rootPath.length > 0) { 144| 1| NSMutableDictionary *rootRepresentation = [NSMutableDictionary new]; 145| 1| [self setValue:representation forKeyPath:mapping.rootPath inRepresentation:rootRepresentation]; 146| 1| representation = rootRepresentation; 147| 1| } 148| 9| return representation; 149| 9|} 150| | 151| |+(NSArray *)serializeCollection:(NSArray *)collection withMapping:(EKManagedObjectMapping *)mapping fromContext:(NSManagedObjectContext *)context 152| 0|{ 153| 0| NSMutableArray *array = [NSMutableArray array]; 154| 0| 155| 0| for (id object in collection) { 156| 0| NSDictionary *objectRepresentation = [self serializeObject:object withMapping:mapping fromContext:context]; 157| 0| [array addObject:objectRepresentation]; 158| 0| } 159| 0| 160| 0| return [NSArray arrayWithArray:array]; 161| 0|} 162| | 163| |+(NSArray *)serializeCollection:(NSArray *)collection withRelationship:(EKRelationshipMapping *)relationship fromContext:(NSManagedObjectContext *)context 164| 2|{ 165| 2| NSMutableArray *array = [NSMutableArray array]; 166| 2| 167| 2| for (id object in collection) { 168| 2| NSDictionary *objectRepresentation = [self serializeObject:object withMapping:(EKManagedObjectMapping *)[relationship mappingForObject: object] fromContext:context]; 169| 2| [array addObject:objectRepresentation]; 170| 2| } 171| 2| 172| 2| return [NSArray arrayWithArray:array]; 173| 2|} 174| | 175| |+(void)setValueOnRepresentation:(NSMutableDictionary *)representation fromManagedObject:(id)object 176| | withPropertyMapping:(EKPropertyMapping *)propertyMapping inContext:(NSManagedObjectContext *)context 177| 31|{ 178| 31| id returnedValue = [object valueForKeyPath:propertyMapping.property]; 179| 31| 180| 31| if (returnedValue) { 181| 31| 182| 31| if (propertyMapping.managedReverseBlock) { 183| 1| returnedValue = propertyMapping.managedReverseBlock(returnedValue,context); 184| 1| } 185| 31| [self setValue:returnedValue forKeyPath:propertyMapping.keyPath inRepresentation:representation]; 186| 31| } 187| 31|} 188| | 189| |+ (void)setValueOnRepresentation:(NSMutableDictionary *)representation fromObject:(id)object withPropertyMapping:(EKPropertyMapping *)propertyMapping 190| 126|{ 191| 126| id returnedValue = [object valueForKeyPath:propertyMapping.property]; 192| 126| 193| 126| if (returnedValue) { 194| 121| 195| 121| if (propertyMapping.reverseBlock) { 196| 17| returnedValue = propertyMapping.reverseBlock(returnedValue); 197| 17| } 198| 121| [self setValue:returnedValue forKeyPath:propertyMapping.keyPath inRepresentation:representation]; 199| 121| } 200| 126|} 201| | 202| 154|+ (void)setValue:(id)value forKeyPath:(NSString *)keyPath inRepresentation:(NSMutableDictionary *)representation { 203| 154| NSArray *keyPathComponents = [keyPath componentsSeparatedByString:@"."]; 204| 154| if ([keyPathComponents count] == 1) { 205| 151| representation[keyPath] = value; 206| 151| } else if ([keyPathComponents count] > 1) { 207| 3| NSString *attributeKey = [keyPathComponents lastObject]; 208| 3| NSMutableArray *subPaths = [NSMutableArray arrayWithArray:keyPathComponents]; 209| 3| [subPaths removeLastObject]; 210| 3| 211| 3| id currentPath = representation; 212| 3| for (NSString *key in subPaths) { 213| 3| id subPath = [currentPath valueForKey:key]; 214| 3| if (subPath == nil) { 215| 3| subPath = [NSMutableDictionary new]; 216| 3| [currentPath setValue:subPath forKey:key]; 217| 3| } 218| 3| currentPath = subPath; 219| 3| } 220| 3| [currentPath setValue:value forKey:attributeKey]; 221| 3| } 222| 154|} 223| | 224| | 225| |@end /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/NSArray+FlattenArray.m: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2014 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |#import "NSArray+FlattenArray.h" 25| | 26| |@implementation NSArray (FlattenArray) 27| | 28| 52.0k|-(NSArray*)ek_flattenedCompactedArray { 29| 52.0k| NSMutableArray *result = [NSMutableArray arrayWithCapacity:self.count]; 30| 304k| for (id thing in self) { 31| 304k| if ([thing isKindOfClass:[NSArray class]]) { 32| 50.0k| [result addObjectsFromArray:[(NSArray*)thing ek_flattenedCompactedArray]]; 33| 254k| } else if (![thing isEqual:[NSNull null]]) { 34| 254k| [result addObject:thing]; 35| 254k| } 36| 304k| } 37| 52.0k| return [NSArray arrayWithArray:result]; 38| 52.0k|} 39| | 40| |@end <<<<<< EOF # path=/Users/runner/work/EasyMapping/EasyMapping/fastlane/Tests.xctest.coverage.txt /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping+XCTestCase/XCTestCase+EasyMapping.m: 1| |// 2| |// XCTestCase+EasyMapping.m 3| |// EasyMappingExample 4| |// 5| |// Created by Ilya Puchka on 14.01.15. 6| |// Copyright (c) 2015 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "XCTestCase+EasyMapping.h" 10| |#import "EKPropertyHelper.h" 11| |#import "EKObjectMapping.h" 12| |#import "EKMapper.h" 13| |#import "EKSerializer.h" 14| |#import "EKRelationshipMapping.h" 15| | 16| |@implementation XCTestCase (EasyMapping) 17| | 18| |- (id)testObjectFromExternalRepresentation:(NSDictionary *)externalRepresentation withMapping:(EKObjectMapping *)mapping expectedObject:(id)expectedObject 19| 2|{ 20| 2| return [self testObjectFromExternalRepresentation:externalRepresentation withMapping:mapping expectedObject:expectedObject skippingKeyPaths:nil]; 21| 2|} 22| | 23| |- (id)testObjectFromExternalRepresentation:(NSDictionary *)externalRepresentation withMapping:(EKObjectMapping *)mapping expectedObject:(id)expectedObject skippingKeyPaths:(NSArray *)keyPathsToSkip 24| 2|{ 25| 2| id mappedObject = [EKMapper objectFromExternalRepresentation:externalRepresentation withMapping:mapping]; 26| 2| [self testMappedObject:mappedObject withMapping:mapping expectedObject:expectedObject skippingKeyPaths:keyPathsToSkip rootKeyPath:nil]; 27| 2| return mappedObject; 28| 2|} 29| | 30| |- (void)testMappedObject:(id)mappedObject withMapping:(EKObjectMapping *)mapping expectedObject:(id)expectedObject skippingKeyPaths:(NSArray *)keyPathsToSkip rootKeyPath:(NSString *)rootKeyPath 31| 3|{ 32| 9| for (EKPropertyMapping *propertyMapping in mapping.propertyMappings.allValues) { 33| 9| NSString *keyPath = propertyMapping.property; 34| 9| if ([keyPathsToSkip containsObject:keyPath]) { 35| 0| continue; 36| 0| } 37| 9| id mappedValue = [mappedObject valueForKeyPath:keyPath]; 38| 9| id expectedValue = [expectedObject valueForKeyPath:keyPath]; 39| 9| NSString *keyPathString = [self keyPathByAppendingKeyPath:keyPath 40| 9| toRootKeyPath:rootKeyPath]; 41| 9| XCTAssertEqualObjects(mappedValue, expectedValue, "Mapping failed on keypath %@. Expected value is - %@, value after mapping is - %@", keyPathString, expectedValue, mappedValue); 42| 9| } 43| 3| 44| 3| for (EKRelationshipMapping *hasOneMapping in mapping.hasOneMappings) { 45| 1| NSString *keyPath = hasOneMapping.property; 46| 1| if ([keyPathsToSkip containsObject:keyPath]) { 47| 0| continue; 48| 0| } 49| 1| id relationshipObject = [mappedObject valueForKeyPath:keyPath]; 50| 1| id expectedRelationshipObject = [expectedObject valueForKeyPath:keyPath]; 51| 1| NSArray *relationshipKeyPathsToSkip = [self extractRelationshipKeyPathsFromKeyPaths:keyPathsToSkip forRelationship:keyPath]; 52| 1| NSString *relationshipRootKeyPath = [self keyPathByAppendingKeyPath:keyPath 53| 1| toRootKeyPath:rootKeyPath]; 54| 1| [self testMappedObject:relationshipObject withMapping:[hasOneMapping mappingForRepresentation:@{}] expectedObject:expectedRelationshipObject skippingKeyPaths:relationshipKeyPathsToSkip rootKeyPath:relationshipRootKeyPath]; 55| 1| } 56| 3| 57| 3| for (EKRelationshipMapping *hasManyMapping in mapping.hasManyMappings) { 58| 0| NSString *keyPath = hasManyMapping.property; 59| 0| if ([keyPathsToSkip containsObject:keyPath]) { 60| 0| continue; 61| 0| } 62| 0| NSArray *relationshipObjects = [mappedObject valueForKeyPath:keyPath]; 63| 0| NSArray *expectedRelationshipObjects = [expectedObject valueForKeyPath:keyPath]; 64| 0| NSArray *relationshipKeyPathsToSkip = [self extractRelationshipKeyPathsFromKeyPaths:keyPathsToSkip forRelationship:keyPath]; 65| 0| [relationshipObjects enumerateObjectsUsingBlock:^(id relationshipObject, NSUInteger idx, BOOL *stop) { 66| 0| id expectedRelationshipObject = expectedRelationshipObjects[idx]; 67| 0| NSString *indexKeyPath = [NSString stringWithFormat:@"%@[%@]", keyPath, @(idx)]; 68| 0| NSString *relationshipRootKeyPath = [self keyPathByAppendingKeyPath:indexKeyPath 69| 0| toRootKeyPath:rootKeyPath]; 70| 0| [self testMappedObject:relationshipObject withMapping:[hasManyMapping mappingForRepresentation:@{}] expectedObject:expectedRelationshipObject skippingKeyPaths:relationshipKeyPathsToSkip rootKeyPath:relationshipRootKeyPath]; 71| 0| }]; 72| 0| } 73| 3|} 74| | 75| |- (NSDictionary *)testSerializeObject:(id)object withMapping:(EKObjectMapping *)mapping expectedRepresentation:(NSDictionary *)expectedRepresentation 76| 2|{ 77| 2| return [self testSerializeObject:object withMapping:mapping expectedRepresentation:expectedRepresentation skippingKeyPaths:nil]; 78| 2|} 79| | 80| |- (NSDictionary *)testSerializeObject:(id)object withMapping:(EKObjectMapping *)mapping expectedRepresentation:(NSDictionary *)expectedRepresentation skippingKeyPaths:(NSArray *)keyPathsToSkip 81| 3|{ 82| 3| NSDictionary *serializedObject = [EKSerializer serializeObject:object withMapping:mapping]; 83| 3| [self testSerializedObject:serializedObject withMapping:mapping expectedRepresentation:expectedRepresentation skippingKeyPaths:keyPathsToSkip rootKeyPath:nil]; 84| 3| return serializedObject; 85| 3|} 86| | 87| |- (void)testSerializedObject:(NSDictionary *)serializedObject withMapping:(EKObjectMapping *)mapping expectedRepresentation:(NSDictionary *)expectedRepresentation skippingKeyPaths:(NSArray *)keyPathsToSkip rootKeyPath:(NSString *)rootKeyPath 88| 5|{ 89| 16| for (EKPropertyMapping *propertyMapping in mapping.propertyMappings.allValues) { 90| 16| NSString *keyPath = propertyMapping.keyPath; 91| 16| if ([keyPathsToSkip containsObject:keyPath]) { 92| 1| continue; 93| 1| } 94| 15| id propertyValue = [serializedObject valueForKeyPath:keyPath]; 95| 15| id expectedValue = [expectedRepresentation valueForKeyPath:keyPath]; 96| 15| NSString *propertyKeyPath = [self keyPathByAppendingKeyPath:keyPath toRootKeyPath:rootKeyPath]; 97| 15| XCTAssertEqualObjects(propertyValue, expectedValue, "Serialization failed on keypath %@. Expected value is - %@, value after serialization is - %@", propertyKeyPath, expectedValue, propertyValue); 98| 15| } 99| 5| 100| 5| for (EKRelationshipMapping *hasOneMapping in mapping.hasOneMappings) { 101| 2| if (hasOneMapping.keyPath) { 102| 2| NSString *keyPath = hasOneMapping.keyPath; 103| 2| if ([keyPathsToSkip containsObject:keyPath]) { 104| 0| continue; 105| 0| } 106| 2| id relationshipRepresentation = [serializedObject valueForKeyPath:keyPath]; 107| 2| id expectedRelationshipRepresentation = [expectedRepresentation valueForKeyPath:keyPath]; 108| 2| NSArray *relationshipKeyPathsToSkip = [self extractRelationshipKeyPathsFromKeyPaths:keyPathsToSkip forRelationship:keyPath]; 109| 2| NSString *relationshipRootKeyPath = [self keyPathByAppendingKeyPath:keyPath 110| 2| toRootKeyPath:rootKeyPath]; 111| 2| [self testSerializedObject:relationshipRepresentation withMapping:[hasOneMapping mappingForObject:relationshipRepresentation] expectedRepresentation:expectedRelationshipRepresentation skippingKeyPaths:relationshipKeyPathsToSkip rootKeyPath:relationshipRootKeyPath]; 112| 2| } 113| 0| else { 114| 0| [self testSerializedObject:serializedObject withMapping:[hasOneMapping mappingForObject:@{}] expectedRepresentation:expectedRepresentation skippingKeyPaths:keyPathsToSkip rootKeyPath:rootKeyPath]; 115| 0| } 116| 2| } 117| 5| 118| 5| for (EKRelationshipMapping *hasManyMapping in mapping.hasManyMappings) { 119| 1| NSString *keyPath = hasManyMapping.keyPath; 120| 1| if ([keyPathsToSkip containsObject:keyPath]) { 121| 1| continue; 122| 1| } 123| 0| NSArray *relationshipRepresentations = [serializedObject valueForKeyPath:keyPath]; 124| 0| NSArray *expectedRelationshipRepresentations = [expectedRepresentation valueForKeyPath:keyPath]; 125| 0| NSArray *relationshipKeyPathsToSkip = [self extractRelationshipKeyPathsFromKeyPaths:keyPathsToSkip forRelationship:keyPath]; 126| 0| [relationshipRepresentations enumerateObjectsUsingBlock:^(id relationshipRepresentation, NSUInteger idx, BOOL *stop) { 127| 0| id expectedRelationshipRepresentation = expectedRelationshipRepresentations[idx]; 128| 0| NSString *indexKeyPath = [NSString stringWithFormat:@"%@[%@]", keyPath, @(idx)]; 129| 0| NSString *relationshipRootKeyPath = [self keyPathByAppendingKeyPath:indexKeyPath 130| 0| toRootKeyPath:rootKeyPath]; 131| 0| [self testSerializedObject:relationshipRepresentation withMapping:[hasManyMapping mappingForObject:serializedObject] expectedRepresentation:expectedRelationshipRepresentation skippingKeyPaths:relationshipKeyPathsToSkip rootKeyPath:relationshipRootKeyPath]; 132| 0| }]; 133| 0| } 134| 5|} 135| | 136| |#pragma mark - Helpers 137| | 138| |- (NSArray *)extractRelationshipKeyPathsFromKeyPaths:(NSArray *)keyPaths forRelationship:(NSString *)property 139| 3|{ 140| 3| NSMutableArray *mKeyPaths = [NSMutableArray new]; 141| 3| for (NSString *keyPath in keyPaths) { 142| 2| NSString *pathPrefix = [NSString stringWithFormat:@"%@.", property]; 143| 2| if ([keyPath hasPrefix:pathPrefix]) { 144| 0| NSString *_keyPath = [keyPath substringFromIndex:pathPrefix.length]; 145| 0| [mKeyPaths addObject:_keyPath]; 146| 0| } 147| 2| } 148| 3| return [mKeyPaths copy]; 149| 3|} 150| | 151| |- (NSString *)keyPathByAppendingKeyPath:(NSString *)keyPath toRootKeyPath:(NSString *)rootKeyPath 152| 27|{ 153| 27| if (!rootKeyPath) { 154| 18| return keyPath; 155| 18| } 156| 9| else if (!keyPath) { 157| 0| return rootKeyPath; 158| 0| } 159| 9| else { 160| 9| return [NSString stringWithFormat:@"%@.%@", rootKeyPath, keyPath]; 161| 9| } 162| 27|} 163| | 164| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/EKCoreDataManager.m: 1| |// 2| |// EKCoreDataManager.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 04.05.14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "EKCoreDataManager.h" 10| | 11| |#if TARGET_OS_IPHONE 12| |#elif TARGET_OS_MAC 13| |@import Cocoa; 14| |#endif 15| |@implementation EKCoreDataManager 16| | 17| |@synthesize managedObjectContext=_managedObjectContext; 18| |@synthesize managedObjectModel=_managedObjectModel; 19| |@synthesize persistentStoreCoordinator = _persistentStoreCoordinator; 20| | 21| |+ (instancetype)sharedInstance 22| 16.1k|{ 23| 16.1k| static dispatch_once_t once; 24| 16.1k| static id sharedInstance; 25| 16.1k| dispatch_once(&once, ^{ 26| 1| sharedInstance = [[self alloc] init]; 27| 1| }); 28| 16.1k| return sharedInstance; 29| 16.1k|} 30| | 31| |- (NSManagedObjectModel *)managedObjectModel 32| 10|{ 33| 10| if (_managedObjectModel != nil) { 34| 9| return _managedObjectModel; 35| 9| } 36| 1| NSURL *modelURL = [[NSBundle bundleForClass:[self class]] URLForResource:@"EasyMapping" withExtension:@"momd"]; 37| 1| _managedObjectModel = [[NSManagedObjectModel alloc] initWithContentsOfURL:modelURL]; 38| 1| return _managedObjectModel; 39| 1|} 40| | 41| |- (void)deleteAllObjectsInCoreData 42| 9|{ 43| 9| NSArray *allEntities = self.managedObjectModel.entities; 44| 9| for (NSEntityDescription *entityDescription in allEntities) 45| 36| { 46| 36| NSFetchRequest *fetchRequest = [[NSFetchRequest alloc] init]; 47| 36| [fetchRequest setEntity:entityDescription]; 48| 36| 49| 36| fetchRequest.includesPropertyValues = NO; 50| 36| fetchRequest.includesSubentities = NO; 51| 36| 52| 36| NSError *error; 53| 36| NSArray *items = [self.managedObjectContext executeFetchRequest:fetchRequest error:&error]; 54| 36| 55| 36| if (error) { 56| 0| NSLog(@"Error requesting items from Core Data: %@", [error localizedDescription]); 57| 0| } 58| 36| 59| 34.0k| for (NSManagedObject *managedObject in items) { 60| 34.0k| [self.managedObjectContext deleteObject:managedObject]; 61| 34.0k| } 62| 36| 63| 36| if (![self.managedObjectContext save:&error]) { 64| 0| NSLog(@"Error deleting %@ - error:%@", entityDescription, [error localizedDescription]); 65| 0| } 66| 36| } 67| 9|} 68| | 69| |#if TARGET_OS_IPHONE 70| | 71| |+(void)cleanupDatabase 72| |{ 73| | NSURL *storeURL = [[self applicationDocumentsDirectory] URLByAppendingPathComponent:@"benchmark.sqlite"]; 74| | [[NSFileManager defaultManager] removeItemAtURL:storeURL error:nil]; 75| |} 76| | 77| |- (NSManagedObjectContext *)managedObjectContext 78| |{ 79| | if (_managedObjectContext != nil) { 80| | return _managedObjectContext; 81| | } 82| | 83| | NSPersistentStoreCoordinator *coordinator = [self persistentStoreCoordinator]; 84| | if (coordinator != nil) { 85| | _managedObjectContext = [[NSManagedObjectContext alloc] initWithConcurrencyType:NSMainQueueConcurrencyType]; 86| | [_managedObjectContext setPersistentStoreCoordinator:coordinator]; 87| | } 88| | return _managedObjectContext; 89| |} 90| | 91| |- (NSPersistentStoreCoordinator *)persistentStoreCoordinator 92| |{ 93| | if (_persistentStoreCoordinator != nil) { 94| | return _persistentStoreCoordinator; 95| | } 96| | 97| | NSURL *storeURL = [[[self class] applicationDocumentsDirectory] URLByAppendingPathComponent:@"benchmark.sqlite"]; 98| | 99| | NSError *error = nil; 100| | _persistentStoreCoordinator = [[NSPersistentStoreCoordinator alloc] initWithManagedObjectModel:[self managedObjectModel]]; 101| | if (![_persistentStoreCoordinator addPersistentStoreWithType:NSSQLiteStoreType configuration:nil URL:storeURL options:nil error:&error]) 102| | { 103| | NSLog(@"Unresolved error %@, %@", error, [error userInfo]); 104| | abort(); 105| | } 106| | 107| | return _persistentStoreCoordinator; 108| |} 109| | 110| |+ (NSURL *)applicationDocumentsDirectory 111| |{ 112| | return [[[NSFileManager defaultManager] URLsForDirectory:NSCachesDirectory inDomains:NSUserDomainMask] lastObject]; 113| |} 114| | 115| |#elif TARGET_OS_MAC 116| | 117| |+(void)cleanupDatabase 118| 0|{ 119| 0| NSURL *url = [[self applicationFilesDirectory] URLByAppendingPathComponent:@"benchmark.sqlite"]; 120| 0| [[NSFileManager defaultManager] removeItemAtURL:url error:nil]; 121| 0|} 122| | 123| |- (NSPersistentStoreCoordinator *)persistentStoreCoordinator 124| 1|{ 125| 1| if (_persistentStoreCoordinator) { 126| 0| return _persistentStoreCoordinator; 127| 0| } 128| 1| 129| 1| NSManagedObjectModel *mom = [self managedObjectModel]; 130| 1| if (!mom) { 131| 0| NSLog(@"%@:%@ No model to generate a store from", [self class], NSStringFromSelector(_cmd)); 132| 0| return nil; 133| 0| } 134| 1| 135| 1| NSFileManager *fileManager = [NSFileManager defaultManager]; 136| 1| NSURL *applicationFilesDirectory = [[self class] applicationFilesDirectory]; 137| 1| NSError *error = nil; 138| 1| 139| 1| NSDictionary *properties = [applicationFilesDirectory resourceValuesForKeys:@[NSURLIsDirectoryKey] error:&error]; 140| 1| 141| 1| if (!properties) { 142| 1| BOOL ok = NO; 143| 1| if ([error code] == NSFileReadNoSuchFileError) { 144| 1| ok = [fileManager createDirectoryAtPath:[applicationFilesDirectory path] withIntermediateDirectories:YES attributes:nil error:&error]; 145| 1| } 146| 1| if (!ok) { 147| 0| //[[NSApplication sharedApplication] presentError:error]; 148| 0| return nil; 149| 0| } 150| 0| } else { 151| 0| if (![properties[NSURLIsDirectoryKey] boolValue]) { 152| 0| // Customize and localize this error. 153| 0| /*NSString *failureDescription = [NSString stringWithFormat:@"Expected a folder to store application data, found a file (%@).", [applicationFilesDirectory path]]; 154| 0| 155| 0| NSMutableDictionary *dict = [NSMutableDictionary dictionary]; 156| 0| [dict setValue:failureDescription forKey:NSLocalizedDescriptionKey]; 157| 0| error = [NSError errorWithDomain:@"YOUR_ERROR_DOMAIN" code:101 userInfo:dict]; 158| 0| 159| 0| [[NSApplication sharedApplication] presentError:error];*/ 160| 0| return nil; 161| 0| } 162| 1| } 163| 1| 164| 1| NSURL *url = [applicationFilesDirectory URLByAppendingPathComponent:@"benchmark.sqlite"]; 165| 1| NSPersistentStoreCoordinator *coordinator = [[NSPersistentStoreCoordinator alloc] initWithManagedObjectModel:mom]; 166| 1| if (![coordinator addPersistentStoreWithType:NSSQLiteStoreType configuration:nil URL:url options:nil error:&error]) 167| 0| { 168| 0| //[[NSApplication sharedApplication] presentError:error]; 169| 0| return nil; 170| 0| } 171| 1| _persistentStoreCoordinator = coordinator; 172| 1| 173| 1| return _persistentStoreCoordinator; 174| 1|} 175| | 176| |// Returns the managed object context for the application (which is already bound to the persistent store coordinator for the application.) 177| |- (NSManagedObjectContext *)managedObjectContext 178| 50.2k|{ 179| 50.2k| if (_managedObjectContext) { 180| 50.2k| return _managedObjectContext; 181| 50.2k| } 182| 1| 183| 1| NSPersistentStoreCoordinator *coordinator = [self persistentStoreCoordinator]; 184| 1| if (!coordinator) { 185| 0| /*NSMutableDictionary *dict = [NSMutableDictionary dictionary]; 186| 0| [dict setValue:@"Failed to initialize the store" forKey:NSLocalizedDescriptionKey]; 187| 0| [dict setValue:@"There was an error building up the data file." forKey:NSLocalizedFailureReasonErrorKey]; 188| 0| NSError *error = [NSError errorWithDomain:@"YOUR_ERROR_DOMAIN" code:9999 userInfo:dict]; 189| 0| [[NSApplication sharedApplication] presentError:error];*/ 190| 0| return nil; 191| 0| } 192| 1| _managedObjectContext = [[NSManagedObjectContext alloc] initWithConcurrencyType:NSMainQueueConcurrencyType]; 193| 1| [_managedObjectContext setPersistentStoreCoordinator:coordinator]; 194| 1| 195| 1| return _managedObjectContext; 196| 1|} 197| | 198| |+ (NSURL *)applicationFilesDirectory 199| 1|{ 200| 1| NSFileManager *fileManager = [NSFileManager defaultManager]; 201| 1| NSURL *appSupportURL = [[fileManager URLsForDirectory:NSApplicationSupportDirectory inDomains:NSUserDomainMask] lastObject]; 202| 1| return [appSupportURL URLByAppendingPathComponent:@"com.easykit.MacOS_Benchmark"]; 203| 1|} 204| | 205| |#endif 206| | 207| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/Dog.m: 1| |// 2| |// Dog.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 18.09.16. 6| |// Copyright © 2016 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Dog.h" 10| | 11| |@implementation Dog 12| | 13| |@synthesize family; 14| | 15| 6|+ (EKObjectMapping *)objectMapping { 16| 6| return [EKObjectMapping mappingForClass:self withBlock:^(EKObjectMapping * _Nonnull mapping) { 17| 6| [mapping mapKeyPath:@"family" toProperty:@"family"]; 18| 6| }]; 19| 6|} 20| | 21| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/MutableFoundationClass.m: 1| |// 2| |// MutableFoundationClass.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 06.06.15. 6| |// Copyright (c) 2015 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "MutableFoundationClass.h" 10| | 11| |@implementation MutableFoundationClass 12| | 13| |+(EKObjectMapping *)objectMapping 14| 1|{ 15| 1| EKObjectMapping * mapping = [[EKObjectMapping alloc] initWithObjectClass:self]; 16| 1| 17| 1| [mapping mapPropertiesFromArray:@[@"array",@"dictionary", @"set"]]; 18| 1| [mapping mapKeyPath:@"ordered_set" toProperty:@"orderedSet"]; 19| 1| [mapping mapKeyPath:@"mutable_set" toProperty:@"mutableSet"]; 20| 1| [mapping mapKeyPath:@"mutable_ordered_set" toProperty:@"mutableOrderedSet"]; 21| 1| mapping.respectPropertyFoundationTypes = YES; 22| 1| return mapping; 23| 1|} 24| | 25| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/Numbers.m: 1| |// 2| |// One.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 22.06.14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Numbers.h" 10| | 11| |@implementation One 12| | 13| |@dynamic two; 14| | 15| |+(EKManagedObjectMapping *)objectMapping 16| 2|{ 17| 2| EKManagedObjectMapping * mapping = [super objectMapping]; 18| 2| 19| 2| [mapping hasOne:[Two class] forKeyPath:@"two"]; 20| 2| 21| 2| return mapping; 22| 2|} 23| | 24| |@end 25| | 26| |@implementation Two 27| | 28| |@dynamic three; 29| | 30| |+(EKManagedObjectMapping *)objectMapping 31| 3|{ 32| 3| EKManagedObjectMapping * mapping = [super objectMapping]; 33| 3| 34| 3| [mapping hasOne:[Three class] forKeyPath:@"three"]; 35| 3| 36| 3| return mapping; 37| 3|} 38| | 39| |@end 40| | 41| |@implementation Three 42| | 43| |@dynamic one; 44| |@dynamic twos; 45| | 46| |+(EKManagedObjectMapping *)objectMapping 47| 1|{ 48| 1| EKManagedObjectMapping * mapping = [super objectMapping]; 49| 1| 50| 1| [mapping hasOne:[One class] forKeyPath:@"one"]; 51| 1| [mapping hasMany:[Two class] forKeyPath:@"twos"]; 52| 1| 53| 1| return mapping; 54| 1|} 55| | 56| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/Wolf.m: 1| |// 2| |// Cat.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 18.09.16. 6| |// Copyright © 2016 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Wolf.h" 10| | 11| |@implementation Wolf 12| | 13| |@synthesize pack; 14| | 15| 6|+ (EKObjectMapping *)objectMapping { 16| 6| return [EKObjectMapping mappingForClass:self withBlock:^(EKObjectMapping * _Nonnull mapping) { 17| 6| [mapping mapKeyPath:@"pack" toProperty:@"pack"]; 18| 6| }]; 19| 6|} 20| | 21| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/BaseManagedTestModel.m: 1| |// 2| |// BaseManagedTestModel.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 22.06.14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "BaseManagedTestModel.h" 10| | 11| |@implementation BaseManagedTestModel 12| | 13| |+(void)registerMapping:(EKManagedObjectMapping *)objectMapping 14| 0|{ 15| 0|} 16| | 17| |+(EKManagedObjectMapping *)objectMapping 18| 0|{ 19| 0| return nil; 20| 0|} 21| | 22| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/ManagedCar.m: 1| |// 2| |// Car.m 3| |// EasyMappingCoreDataExample 4| |// 5| |// Created by Alejandro Isaza on 2013-03-14. 6| |// 7| |// 8| | 9| |#import "ManagedCar.h" 10| | 11| | 12| |@implementation ManagedCar 13| | 14| |@dynamic carID; 15| |@dynamic model; 16| |@dynamic year; 17| |@dynamic createdAt; 18| |@dynamic person; 19| | 20| |static EKManagedObjectMapping * mapping = nil; 21| | 22| |+(void)registerMapping:(EKManagedObjectMapping *)objectMapping 23| 91|{ 24| 91| mapping = objectMapping; 25| 91|} 26| | 27| |+(EKManagedObjectMapping *)objectMapping 28| 7.16k|{ 29| 7.16k| return mapping; 30| 7.16k|} 31| | 32| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/ManagedPerson.m: 1| |// 2| |// Person.m 3| |// EasyMappingCoreDataExample 4| |// 5| |// Created by Alejandro Isaza on 2013-03-14. 6| |// 7| |// 8| | 9| |#import "ManagedPerson.h" 10| |#import "Car.h" 11| | 12| | 13| |@implementation ManagedPerson 14| | 15| |@dynamic personID; 16| |@dynamic name; 17| |@dynamic email; 18| |@dynamic car; 19| |@dynamic phones; 20| |@dynamic gender; 21| |@dynamic relative; 22| |@dynamic children; 23| | 24| |static EKManagedObjectMapping * mapping = nil; 25| | 26| |+(void)registerMapping:(EKManagedObjectMapping *)objectMapping 27| 89|{ 28| 89| mapping = objectMapping; 29| 89|} 30| | 31| |+(EKManagedObjectMapping *)objectMapping 32| 4.15k|{ 33| 4.15k| return mapping; 34| 4.15k|} 35| | 36| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/ManagedPhone.m: 1| |// 2| |// Phone.m 3| |// EasyMappingCoreDataExample 4| |// 5| |// Created by Alejandro Isaza on 2013-03-14. 6| |// 7| |// 8| | 9| |#import "ManagedPhone.h" 10| |#import "Person.h" 11| | 12| | 13| |@implementation ManagedPhone 14| | 15| |@dynamic phoneID; 16| |@dynamic ddi; 17| |@dynamic ddd; 18| |@dynamic number; 19| | 20| |static EKManagedObjectMapping * mapping = nil; 21| | 22| |+(void)registerMapping:(EKManagedObjectMapping *)objectMapping 23| 90|{ 24| 90| mapping = objectMapping; 25| 90|} 26| | 27| |+(EKManagedObjectMapping *)objectMapping 28| 259k|{ 29| 259k| return mapping; 30| 259k|} 31| | 32| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Address.m: 1| |// 2| |// Address.m 3| |// EasyMappingExample 4| |// 5| |// Created by Lucas Medeiros on 26/02/13. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Address.h" 10| | 11| |@implementation Address 12| | 13| |static EKObjectMapping * mapping = nil; 14| | 15| |+(void)registerMapping:(EKObjectMapping *)objectMapping 16| 1|{ 17| 1| mapping = objectMapping; 18| 1|} 19| | 20| |+(EKObjectMapping *)objectMapping 21| 1|{ 22| 1| return mapping; 23| 1|} 24| | 25| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Alien.m: 1| |// 2| |// Alien.m 3| |// EasyMappingExample 4| |// 5| |// Created by Lucas Medeiros Leite on 12/7/13. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Alien.h" 10| |#import "Finger.h" 11| | 12| |@implementation Alien 13| | 14| |+(EKObjectMapping *)objectMapping 15| 11|{ 16| 11| return [EKObjectMapping mappingForClass:[Alien class] withBlock:^(EKObjectMapping *mapping) { 17| 11| [mapping mapPropertiesFromArray:@[@"name"]]; 18| 11| [mapping hasMany:[Finger class] forKeyPath:@"fingers"]; 19| 11| }]; 20| 11|} 21| | 22| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/BaseTestModel.m: 1| |// 2| |// BaseTestModel.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 22.06.14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "BaseTestModel.h" 10| | 11| |@implementation BaseTestModel 12| | 13| |static EKObjectMapping * mapping = nil; 14| | 15| |+(void)registerMapping:(EKObjectMapping *)objectMapping 16| 2|{ 17| 2| mapping = objectMapping; 18| 2|} 19| | 20| |+(EKObjectMapping *)objectMapping 21| 0|{ 22| 0| return mapping; 23| 0|} 24| | 25| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Car.m: 1| |// 2| |// Car.m 3| |// EasyMappingExample 4| |// 5| |// Created by Lucas Medeiros on 21/02/13. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Car.h" 10| | 11| |@implementation Car 12| | 13| |static EKObjectMapping * mapping = nil; 14| | 15| |+(void)registerMapping:(EKObjectMapping *)objectMapping 16| 120|{ 17| 120| mapping = objectMapping; 18| 120|} 19| | 20| |+(EKObjectMapping *)objectMapping 21| 20.0k|{ 22| 20.0k| return mapping; 23| 20.0k|} 24| | 25| |- (BOOL)isEqual:(Car *)object 26| 0|{ 27| 0| if (object == self) { 28| 0| return YES; 29| 0| } 30| 0| if (![object isKindOfClass:[self class]]) { 31| 0| return NO; 32| 0| } 33| 0| return (object.carId == self.carId && 34| 0| ([object.model isEqual:self.model] || (object.model == nil && self.model == nil)) && 35| 0| ([object.year isEqual:self.year] || (object.year == nil && self.year == nil))); 36| 0|} 37| | 38| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Cat.m: 1| |// 2| |// Cat.m 3| |// EasyMappingExample 4| |// 5| |// Created by Lucas Medeiros Leite on 1/28/14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Cat.h" 10| | 11| |@implementation Cat 12| | 13| |static EKObjectMapping * mapping = nil; 14| | 15| |+(void)registerMapping:(EKObjectMapping *)objectMapping 16| 0|{ 17| 0| mapping = objectMapping; 18| 0|} 19| | 20| |+(EKObjectMapping *)objectMapping 21| 0|{ 22| 0| return mapping; 23| 0|} 24| | 25| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/CommentObject.m: 1| |// 2| |// CommentObject.m 3| |// EasyMappingExample 4| |// 5| |// Created by Denys Telezhkin on 08.06.14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "CommentObject.h" 10| | 11| |@implementation CommentObject 12| | 13| |+(EKObjectMapping *)objectMapping 14| 3|{ 15| 3| return [EKObjectMapping mappingForClass:[CommentObject class] 16| 3| withBlock:^(EKObjectMapping *mapping) { 17| 3| [mapping mapKeyPath:@"name" toProperty:@"name"]; 18| 3| [mapping mapKeyPath:@"message" toProperty:@"message"]; 19| 3| [mapping hasMany:self 20| 3| forKeyPath:@"sub_comments" 21| 3| forProperty:@"subComments"]; 22| 3| }]; 23| 3|} 24| | 25| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Finger.m: 1| |// 2| |// Finger.m 3| |// EasyMappingExample 4| |// 5| |// Created by Lucas Medeiros Leite on 12/7/13. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Finger.h" 10| | 11| |@implementation Finger 12| | 13| |+(EKObjectMapping *)objectMapping 14| 20.0k|{ 15| 20.0k| return [EKObjectMapping mappingForClass:[Finger class] withBlock:^(EKObjectMapping *mapping) { 16| 20.0k| [mapping mapPropertiesFromArray:@[@"name"]]; 17| 20.0k| }]; 18| 20.0k|} 19| | 20| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Native.m: 1| |// 2| |// Native.m 3| |// EasyMappingExample 4| |// 5| |// Created by Philip Vasilchenko on 15.07.13. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Native.h" 10| | 11| |@implementation Native 12| | 13| |+(EKObjectMapping *)objectMapping 14| 17|{ 15| 17| return [EKObjectMapping mappingForClass:[Native class] withBlock:^(EKObjectMapping *mapping) { 16| 17| [mapping mapPropertiesFromArray:@[ 17| 17| @"charProperty", @"unsignedCharProperty", @"shortProperty", @"unsignedShortProperty", @"intProperty", @"unsignedIntProperty", 18| 17| @"integerProperty", @"unsignedIntegerProperty", @"longProperty", @"unsignedLongProperty", @"longLongProperty", 19| 17| @"unsignedLongLongProperty", @"floatProperty", @"cgFloatProperty", @"doubleProperty", @"boolProperty", @"smallBoolProperty", 20| 17| @"locationCoordinateProperty" 21| 17| ]]; 22| 17| }]; 23| 17|} 24| | 25| |@end 26| | 27| |@implementation NativeChild 28| | 29| |+(EKObjectMapping *)objectMapping 30| 12|{ 31| 12| return [EKObjectMapping mappingForClass:[NativeChild class] withBlock:^(EKObjectMapping *mapping) { 32| 12| [mapping mapPropertiesFromArray:@[@"intProperty", @"boolProperty", @"childProperty"]]; 33| 12| }]; 34| 12|} 35| | 36| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Person.m: 1| |// 2| |// Person.m 3| |// EasyMappingExample 4| |// 5| |// Created by Lucas Medeiros on 21/02/13. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Person.h" 10| | 11| |@implementation Person 12| | 13| |static EKObjectMapping * mapping = nil; 14| | 15| |+(void)registerMapping:(EKObjectMapping *)objectMapping 16| 101|{ 17| 101| mapping = objectMapping; 18| 101|} 19| | 20| |+(EKObjectMapping *)objectMapping 21| 30.0k|{ 22| 30.0k| return mapping; 23| 30.0k|} 24| | 25| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Phone.m: 1| |// 2| |// Phone.m 3| |// EasyMappingExample 4| |// 5| |// Created by Lucas Medeiros on 21/02/13. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Phone.h" 10| | 11| |@implementation Phone 12| | 13| |static EKObjectMapping * mapping = nil; 14| | 15| |+(void)registerMapping:(EKObjectMapping *)objectMapping 16| 119|{ 17| 119| mapping = objectMapping; 18| 119|} 19| | 20| |+(EKObjectMapping *)objectMapping 21| 40.0k|{ 22| 40.0k| return mapping; 23| 40.0k|} 24| | 25| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Plane.m: 1| |// 2| |// Plane.m 3| |// EasyMappingExample 4| |// 5| |// Created by Dany L'Hebreux on 2013-10-03. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Plane.h" 10| |#import "Person.h" 11| | 12| |@implementation Plane 13| | 14| |+(EKObjectMapping *)objectMapping 15| 10|{ 16| 10| return [EKObjectMapping mappingForClass:[Plane class] withBlock:^(EKObjectMapping *mapping) { 17| 10| [mapping mapKeyPath:@"flight_number" toProperty:@"flightNumber"]; 18| 10| [mapping hasMany:[Person class] forKeyPath:@"persons"]; 19| 10| }]; 20| 10|} 21| | 22| |@end 23| | 24| |@implementation Seaplane 25| | 26| |static EKObjectMapping * mapping = nil; 27| | 28| |+(void)registerMapping:(EKObjectMapping *)objectMapping 29| 0|{ 30| 0| mapping = objectMapping; 31| 0|} 32| | 33| |+(EKObjectMapping *)objectMapping 34| 0|{ 35| 0| return mapping; 36| 0|} 37| | 38| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Recursive.m: 1| |// 2| |// Recursive.m 3| |// EasyMappingExample 4| |// 5| |// Created by Денис Тележкин on 03.04.17. 6| |// Copyright © 2017 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "Recursive.h" 10| | 11| |@implementation Recursive 12| | 13| |@dynamic id; 14| |@dynamic link; 15| | 16| |+(EKManagedObjectMapping *)objectMapping 17| 7|{ 18| 7| EKManagedObjectMapping * mapping = [super objectMapping]; 19| 7| 20| 7| [mapping mapKeyPath:@"id" toProperty:@"id"]; 21| 7| [mapping hasOne:[Recursive class] forKeyPath:@"link"]; 22| 7| 23| 7| return mapping; 24| 7|} 25| | 26| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/UFO.m: 1| |// 2| |// UFO.m 3| |// EasyMappingExample 4| |// 5| |// Created by Jack Shurpin on 4/1/14. 6| |// Copyright (c) 2014 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "UFO.h" 10| | 11| |@implementation UFO 12| | 13| |+(EKObjectMapping *)objectMapping 14| 1|{ 15| 1| return [EKObjectMapping mappingForClass:[UFO class] withBlock:^(EKObjectMapping *mapping) { 16| 1| [mapping mapPropertiesFromArray:@[@"shape"]]; 17| 1| [mapping hasOne:[Alien class] forKeyPath:@"captain"]; 18| 1| [mapping hasMany:[Alien class] forKeyPath:@"crew"]; 19| 1| }]; 20| 1|} 21| | 22| |@end 23| | 24| | 25| |@implementation ColoredUFO 26| | 27| |+(EKObjectMapping *)objectMapping 28| 0|{ 29| 0| return [EKObjectMapping mappingForClass:[ColoredUFO class] withBlock:^(EKObjectMapping *mapping) { 30| 0| [mapping mapPropertiesFromArray:@[@"color"]]; 31| 0| [mapping mapPropertiesFromMappingObject:[super objectMapping]]; 32| 0| }]; 33| 0|} 34| | 35| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Providers/ManagedMappingProvider.m: 1| |// 2| |// MappingProvider.m 3| |// EasyMappingExample 4| |// 5| |// Created by Lucas Medeiros on 23/02/13. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "ManagedMappingProvider.h" 10| |#import "ManagedCar.h" 11| |#import "ManagedPhone.h" 12| |#import "ManagedPerson.h" 13| | 14| |@implementation ManagedMappingProvider 15| | 16| 14|+(NSDateFormatter *)iso8601DateFormatter { 17| 14| NSDateFormatter * formatter = [NSDateFormatter new]; 18| 14| formatter.dateFormat = EKISO_8601DateTimeFormat; 19| 14| return formatter; 20| 14|} 21| | 22| |+ (EKManagedObjectMapping *)carMapping 23| 59|{ 24| 59| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedCar class]) 25| 59| withBlock:^(EKManagedObjectMapping *mapping) { 26| 59| [mapping mapPropertiesFromDictionary:@{ @"id": @"carID" }]; 27| 59| [mapping mapPropertiesFromArray:@[@"model", @"year"]]; 28| 59| mapping.primaryKey = @"carID"; 29| 59| }]; 30| 59|} 31| | 32| |+ (EKManagedObjectMapping *)carWithRootKeyMapping 33| 15|{ 34| 15| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedCar class]) 35| 15| withRootPath:@"data.car" 36| 15| withBlock:^(EKManagedObjectMapping *mapping) { 37| 15| [mapping mapPropertiesFromDictionary:@{ @"id": @"carID" }]; 38| 15| [mapping mapPropertiesFromArray:@[@"model", @"year"]]; 39| 15| mapping.primaryKey = @"carID"; 40| 15| }]; 41| 15|} 42| | 43| 3|+ (EKManagedObjectMapping *)carNonNestedMapping { 44| 3| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedCar class]) withBlock:^(EKManagedObjectMapping *mapping) { 45| 3| [mapping mapPropertiesFromDictionary:@{ 46| 3| @"carId": @"carID", 47| 3| @"carModel":@"model", 48| 3| @"carYear":@"year" 49| 3| }]; 50| 3| mapping.primaryKey = @"carID"; 51| 3| }]; 52| 3|} 53| | 54| |+ (EKManagedObjectMapping *)carNestedAttributesMapping 55| 11|{ 56| 11| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedCar class]) 57| 11| withBlock:^(EKManagedObjectMapping *mapping) { 58| 11| [mapping mapPropertiesFromDictionary:@{ @"id": @"carID" }]; 59| 11| [mapping mapPropertiesFromArray:@[@"model"]]; 60| 11| [mapping mapPropertiesFromDictionary:@{ 61| 11| @"information.year" : @"year" 62| 11| }]; 63| 11| mapping.primaryKey = @"carID"; 64| 11| }]; 65| 11|} 66| | 67| |+ (EKManagedObjectMapping *)carWithDateMapping 68| 13|{ 69| 13| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedCar class]) 70| 13| withBlock:^(EKManagedObjectMapping *mapping) { 71| 13| [mapping mapPropertiesFromDictionary:@{ @"id": @"carID" }]; 72| 13| [mapping mapPropertiesFromArray:@[@"model", @"year"]]; 73| 13| [mapping mapKeyPath:@"created_at" toProperty:@"createdAt" withDateFormatter:[self iso8601DateFormatter]]; 74| 13| mapping.primaryKey = @"carID"; 75| 13| }]; 76| 13|} 77| | 78| |+ (EKManagedObjectMapping *)phoneMapping 79| 47|{ 80| 47| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedPhone class]) 81| 47| withBlock:^(EKManagedObjectMapping *mapping) { 82| 47| [mapping mapPropertiesFromDictionary:@{ @"id": @"phoneID" }]; 83| 47| [mapping mapPropertiesFromArray:@[@"number"]]; 84| 47| [mapping mapPropertiesFromDictionary:@{ 85| 47| @"ddi" : @"ddi", 86| 47| @"ddd" : @"ddd" 87| 47| }]; 88| 47| mapping.primaryKey = @"phoneID"; 89| 47| }]; 90| 47|} 91| | 92| |+(EKManagedObjectMapping *)personNonNestedMapping 93| 3|{ 94| 3| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedPerson class]) withBlock: 95| 3| ^(EKManagedObjectMapping *mapping) { 96| 3| [mapping mapPropertiesFromArray:@[@"name", @"email", @"gender"]]; 97| 3| 98| 3| [mapping hasOne:[ManagedCar class] forDictionaryFromKeyPaths:@[@"carId",@"carModel",@"carYear"] 99| 3| forProperty:@"car" withObjectMapping:[self carNonNestedMapping]]; 100| 3| mapping.primaryKey = @"personID"; 101| 3| }]; 102| 3|} 103| | 104| |+ (EKManagedObjectMapping *)personMapping 105| 74|{ 106| 74| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedPerson class]) 107| 74| withBlock:^(EKManagedObjectMapping *mapping) { 108| 74| [mapping mapPropertiesFromDictionary:@{ @"id": @"personID" }]; 109| 74| [mapping mapPropertiesFromArray:@[@"name", @"email", @"gender"]]; 110| 74| [mapping hasOne:ManagedCar.class forKeyPath:@"car"]; 111| 74| [mapping hasOne:ManagedPerson.class forKeyPath:@"relative"]; 112| 74| [mapping hasMany:ManagedPerson.class forKeyPath:@"children"]; 113| 74| [mapping hasMany:ManagedPhone.class forKeyPath:@"phones"]; 114| 74| mapping.primaryKey = @"personID"; 115| 74| }]; 116| 74|} 117| | 118| |+(EKManagedObjectMapping *)personWithReverseBlocksMapping 119| 1|{ 120| 1| EKManagedObjectMapping * personMapping = [self personWithCarMapping]; 121| 1| [personMapping mapKeyPath:@"gender" toProperty:@"gender" 122| 1| withValueBlock:^id(NSString *key, id value, NSManagedObjectContext *context) { 123| 1| if ([value isEqualToString:@"male"]) 124| 1| { 125| 1| return @"husband"; 126| 1| } 127| 0| else if ([value isEqualToString:@"female"]) 128| 0| { 129| 0| return @"wife"; 130| 0| } 131| 0| return nil; 132| 1| } reverseBlock:^id(id value, NSManagedObjectContext *context) { 133| 1| if ([value isEqualToString:@"husband"]) 134| 1| { 135| 1| return @"male"; 136| 1| } 137| 0| else if ([value isEqualToString:@"wife"]) 138| 0| { 139| 0| return @"female"; 140| 0| } 141| 0| return nil; 142| 0| }]; 143| 1| 144| 1| return personMapping; 145| 1|} 146| | 147| |+ (EKManagedObjectMapping *)personWithCarMapping 148| 11|{ 149| 11| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedPerson class]) 150| 11| withBlock:^(EKManagedObjectMapping *mapping) { 151| 11| [mapping mapPropertiesFromDictionary:@{ @"id": @"personID" }]; 152| 11| [mapping mapPropertiesFromArray:@[@"name", @"email"]]; 153| 11| [mapping hasOne:[ManagedCar class] forKeyPath:@"car"]; 154| 11| mapping.primaryKey = @"personID"; 155| 11| }]; 156| 11|} 157| | 158| |+ (EKManagedObjectMapping *)personWithPhonesMapping 159| 21|{ 160| 21| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedPerson class]) 161| 21| withBlock:^(EKManagedObjectMapping *mapping) { 162| 21| [mapping mapPropertiesFromDictionary:@{ @"id": @"personID" }]; 163| 21| [mapping mapPropertiesFromArray:@[@"name", @"email"]]; 164| 21| [mapping hasMany:[ManagedPhone class] forKeyPath:@"phones"]; 165| 21| mapping.primaryKey = @"personID"; 166| 21| }]; 167| 21|} 168| | 169| |+ (EKManagedObjectMapping *)personWithOnlyValueBlockMapping 170| 10|{ 171| 10| return [EKManagedObjectMapping mappingForEntityName:NSStringFromClass([ManagedPerson class]) 172| 10| withBlock:^(EKManagedObjectMapping *mapping) { 173| 10| [mapping mapPropertiesFromDictionary:@{ @"id": @"personID" }]; 174| 10| [mapping mapPropertiesFromArray:@[@"name", @"email", @"gender"]]; 175| 10| mapping.primaryKey = @"personID"; 176| 10| }]; 177| 10|} 178| | 179| |+(EKManagedObjectMapping *)complexPlaneMapping 180| 2|{ 181| 2| EKManagedObjectMapping * mapping = [[EKManagedObjectMapping alloc] initWithEntityName:@"Plane"]; 182| 2| [mapping hasOne:[ManagedPerson class] forKeyPath:@"captain"]; 183| 2| [mapping hasMany:[ManagedPerson class] forKeyPath:@"persons"]; 184| 2| return mapping; 185| 2|} 186| | 187| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Providers/MappingProvider.m: 1| |// 2| |// MappingProvider.m 3| |// EasyMappingExample 4| |// 5| |// Created by Lucas Medeiros on 23/02/13. 6| |// Copyright (c) 2013 EasyKit. All rights reserved. 7| |// 8| | 9| |#import "MappingProvider.h" 10| |#import "Car.h" 11| |#import "Phone.h" 12| |#import "Person.h" 13| |#import "Address.h" 14| |#import "Native.h" 15| |#import "Plane.h" 16| |#import "Alien.h" 17| |#import "UFO.h" 18| |#import "Finger.h" 19| |#import "Native.h" 20| |#import "Cat.h" 21| |#import "CommentObject.h" 22| |#import "Dog.h" 23| |#import "Wolf.h" 24| | 25| |@implementation MappingProvider 26| | 27| 15|+(NSDateFormatter *)iso8601DateFormatter { 28| 15| NSDateFormatter * formatter = [NSDateFormatter new]; 29| 15| formatter.dateFormat = EKISO_8601DateTimeFormat; 30| 15| return formatter; 31| 15|} 32| | 33| |+ (EKObjectMapping *)carMapping 34| 74|{ 35| 74| return [EKObjectMapping mappingForClass:[Car class] withBlock:^(EKObjectMapping *mapping) { 36| 74| [mapping mapKeyPath:@"id" toProperty:@"carId"]; 37| 74| [mapping mapPropertiesFromArray:@[@"model", @"year"]]; 38| 74| }]; 39| 74|} 40| | 41| |+ (EKObjectMapping *)carWithRootKeyMapping 42| 11|{ 43| 11| return [EKObjectMapping mappingForClass:[Car class] withRootPath:@"data.car" withBlock:^(EKObjectMapping *mapping) { 44| 11| [mapping mapPropertiesFromDictionary:@{@"id":@"carId"}]; 45| 11| [mapping mapPropertiesFromArray:@[@"model", @"year"]]; 46| 11| }]; 47| 11|} 48| | 49| |+ (EKObjectMapping *)carNestedAttributesMapping 50| 12|{ 51| 12| return [EKObjectMapping mappingForClass:[Car class] withBlock:^(EKObjectMapping *mapping) { 52| 12| [mapping mapPropertiesFromArray:@[@"model"]]; 53| 12| [mapping mapPropertiesFromDictionary:@{ 54| 12| @"information.year" : @"year" 55| 12| }]; 56| 12| }]; 57| 12|} 58| | 59| 5|+(EKObjectMapping *)carNonNestedMapping { 60| 5| return [EKObjectMapping mappingForClass:[Car class] withBlock:^(EKObjectMapping *mapping) { 61| 5| [mapping mapPropertiesFromDictionary:@{ 62| 5| @"carId": @"carId", 63| 5| @"carModel":@"model", 64| 5| @"carYear":@"year" 65| 5| }]; 66| 5| }]; 67| 5|} 68| | 69| |+ (EKObjectMapping *)carWithDateMapping 70| 14|{ 71| 14| return [EKObjectMapping mappingForClass:[Car class] withBlock:^(EKObjectMapping *mapping) { 72| 14| [mapping mapPropertiesFromArray:@[@"model", @"year"]]; 73| 14| [mapping mapKeyPath:@"created_at" toProperty:@"createdAt" withDateFormatter:[self iso8601DateFormatter]]; 74| 14| }]; 75| 14|} 76| | 77| |+ (EKObjectMapping *)phoneMapping 78| 59|{ 79| 59| return [EKObjectMapping mappingForClass:[Phone class] withBlock:^(EKObjectMapping *mapping) { 80| 59| [mapping mapPropertiesFromArray:@[@"number"]]; 81| 59| [mapping mapPropertiesFromDictionary:@{ 82| 59| @"ddi" : @"DDI", 83| 59| @"ddd" : @"DDD" 84| 59| }]; 85| 59| }]; 86| 59|} 87| | 88| |+(EKObjectMapping *)personNonNestedMapping 89| 5|{ 90| 5| return [EKObjectMapping mappingForClass:[Person class] withBlock:^(EKObjectMapping *mapping) { 91| 5| NSDictionary *genders = @{ @"male": @(GenderMale), @"female": @(GenderFemale) }; 92| 5| [mapping mapPropertiesFromArray:@[@"name", @"email"]]; 93| 5| [mapping mapKeyPath:@"gender" toProperty:@"gender" withValueBlock:^(NSString *key, id value) { 94| 2| return genders[value]; 95| 2| } reverseBlock:^id(id value) { 96| 2| return [genders allKeysForObject:value].lastObject; 97| 2| }]; 98| 5| 99| 5| [mapping hasOne:[Car class] forDictionaryFromKeyPaths:@[@"carId",@"carModel",@"carYear"] 100| 5| forProperty:@"car" withObjectMapping:[self carNonNestedMapping]]; 101| 5| }]; 102| 5|} 103| | 104| |+ (EKObjectMapping *)personMapping 105| 80|{ 106| 80| return [EKObjectMapping mappingForClass:[Person class] withBlock:^(EKObjectMapping *mapping) { 107| 80| NSDictionary *genders = @{ @"male": @(GenderMale), @"female": @(GenderFemale) }; 108| 80| [mapping mapPropertiesFromArray:@[@"name", @"email"]]; 109| 40.0k| [mapping mapKeyPath:@"gender" toProperty:@"gender" withValueBlock:^(NSString *key, id value) { 110| 40.0k| return genders[value]; 111| 40.0k| } reverseBlock:^id(id value) { 112| 7| return [genders allKeysForObject:value].lastObject; 113| 7| }]; 114| 80| [mapping hasOne:[Car class] forKeyPath:@"car"]; 115| 80| [mapping hasMany:[Phone class] forKeyPath:@"phones"]; 116| 80| [mapping mapKeyPath:@"socialURL" toProperty:@"socialURL" 117| 80| withValueBlock:[EKMappingBlocks urlMappingBlock] 118| 80| reverseBlock:[EKMappingBlocks urlReverseMappingBlock]]; 119| 80| }]; 120| 80|} 121| | 122| |+(EKObjectMapping *)personMappingThatAssertsOnNilInValueBlock 123| 1|{ 124| 1| return [EKObjectMapping mappingForClass:[Person class] withBlock:^(EKObjectMapping *mapping) { 125| 1| NSDictionary *genders = @{ @"male": @(GenderMale), @"female": @(GenderFemale) }; 126| 1| [mapping mapPropertiesFromArray:@[@"name", @"email"]]; 127| 1| [mapping mapKeyPath:@"gender" toProperty:@"gender" withValueBlock:^(NSString *key, id value) { 128| 1| if (value == nil) { [[[NSException alloc] initWithName:@"Received nil value" reason:@"In value block when ignore missing fields is turned on" userInfo:nil] raise]; } 129| 1| return genders[value]; 130| 1| } reverseBlock:^id(id value) { 131| 0| return [genders allKeysForObject:value].lastObject; 132| 0| }]; 133| 1| [mapping hasOne:[Car class] forKeyPath:@"car"]; 134| 1| [mapping hasMany:[Phone class] forKeyPath:@"phones"]; 135| 1| [mapping mapKeyPath:@"socialURL" toProperty:@"socialURL" 136| 1| withValueBlock:[EKMappingBlocks urlMappingBlock] 137| 1| reverseBlock:[EKMappingBlocks urlReverseMappingBlock]]; 138| 1| }]; 139| 1|} 140| | 141| |+ (EKObjectMapping *)personWithCarMapping 142| 11|{ 143| 11| return [EKObjectMapping mappingForClass:[Person class] withBlock:^(EKObjectMapping *mapping) { 144| 11| [mapping mapPropertiesFromArray:@[@"name", @"email"]]; 145| 11| [mapping hasOne:[Car class] forKeyPath:@"car"]; 146| 11| }]; 147| 11|} 148| | 149| |+ (EKObjectMapping *)personWithPhonesMapping 150| 11|{ 151| 11| return [EKObjectMapping mappingForClass:[Person class] withBlock:^(EKObjectMapping *mapping) { 152| 11| [mapping mapPropertiesFromArray:@[@"name", @"email"]]; 153| 11| [mapping hasMany:[Phone class] forKeyPath:@"phones"]; 154| 11| }]; 155| 11|} 156| | 157| |+ (EKObjectMapping *)personWithOnlyValueBlockMapping 158| 14|{ 159| 14| return [EKObjectMapping mappingForClass:[Person class] withBlock:^(EKObjectMapping *mapping) { 160| 14| NSDictionary *genders = @{ @"male": @(GenderMale), @"female": @(GenderFemale) }; 161| 14| [mapping mapPropertiesFromArray:@[@"name", @"email"]]; 162| 10.0k| [mapping mapKeyPath:@"gender" toProperty:@"gender" withValueBlock:^(NSString *key, id value) { 163| 10.0k| return genders[value]; 164| 10.0k| } reverseBlock:^id(id value) { 165| 2| return [[genders allKeysForObject:value] lastObject]; 166| 2| }]; 167| 14| }]; 168| 14|} 169| | 170| |+ (EKObjectMapping *)personWithRelativeMapping 171| 2|{ 172| 2| return [EKObjectMapping mappingForClass:[Person class] withBlock:^(EKObjectMapping *mapping) { 173| 2| NSDictionary *genders = @{ @"male": @(GenderMale), @"female": @(GenderFemale) }; 174| 2| [mapping mapPropertiesFromArray:@[@"name", @"email"]]; 175| 5| [mapping mapKeyPath:@"gender" toProperty:@"gender" withValueBlock:^(NSString *key, id value) { 176| 5| return genders[value]; 177| 5| } reverseBlock:^id(id value) { 178| 0| return [[genders allKeysForObject:value] lastObject]; 179| 0| }]; 180| 2| [mapping hasOne:[Person class] forKeyPath:@"relative"]; 181| 2| [mapping hasMany:[Person class] forKeyPath:@"children"]; 182| 2| }]; 183| 2|} 184| | 185| |+ (EKObjectMapping *)addressMapping 186| 12|{ 187| 12| return [EKObjectMapping mappingForClass:[Address class] withBlock:^(EKObjectMapping *mapping) { 188| 12| [mapping mapPropertiesFromArray:@[@"street"]]; 189| 10.0k| [mapping mapKeyPath:@"location" toProperty:@"location" withValueBlock:^(NSString *key, NSArray *locationArray) { 190| 10.0k| CLLocationDegrees latitudeValue = [[locationArray objectAtIndex:0] doubleValue]; 191| 10.0k| CLLocationDegrees longitudeValue = [[locationArray objectAtIndex:1] doubleValue]; 192| 10.0k| return [[CLLocation alloc] initWithLatitude:latitudeValue longitude:longitudeValue]; 193| 10.0k| } reverseBlock:^(CLLocation *location) { 194| 1| return @[ @(location.coordinate.latitude), @(location.coordinate.longitude) ]; 195| 1| }]; 196| 12| }]; 197| 12|} 198| | 199| |+ (EKObjectMapping *)nativeMappingWithNullPropertie 200| 1|{ 201| 1| return [EKObjectMapping mappingForClass:[Cat class] withBlock:^(EKObjectMapping *mapping) { 202| 1| [mapping mapPropertiesFromArray:@[ @"age" ]]; 203| 1| }]; 204| 1|} 205| | 206| |+(EKObjectMapping *)personWithPetsMapping 207| 3|{ 208| 3| EKObjectMapping * mapping = [self personMapping]; 209| 3| [mapping.hasManyMappings addObject:[self animalCollectionRelationship]]; 210| 3| return mapping; 211| 3|} 212| | 213| 4|+(EKRelationshipMapping *)animalCollectionRelationship { 214| 4| EKRelationshipMapping * relationship = [EKRelationshipMapping mappingForClass:Dog.class 215| 4| withKeyPath:@"animals" 216| 4| forProperty:@"pets"]; 217| 4| relationship.mappingResolver = ^EKObjectMapping *(id representation){ 218| 4| if ([representation[@"type"] isEqualToString:@"dog"]) { 219| 2| return [Dog objectMapping]; 220| 2| } else { 221| 2| return [Wolf objectMapping]; 222| 2| } 223| 4| }; 224| 8| relationship.serializationResolver = ^EKObjectMapping * _Nonnull(id _Nonnull object) { 225| 8| if ([object isKindOfClass:Dog.class]) { 226| 4| return Dog.objectMapping; 227| 4| } else { 228| 4| return Wolf.objectMapping; 229| 4| } 230| 8| }; 231| 4| return relationship; 232| 4|} 233| | 234| |+(EKObjectMapping *)personMappingThatIgnoresSocialUrlDuringSerialization 235| 1|{ 236| 1| EKObjectMapping *mapping = [self personMapping]; 237| 1| [mapping mapKeyPath:@"socialURL" toProperty:@"socialURL" 238| 1| withValueBlock:[EKMappingBlocks urlMappingBlock] 239| 1| reverseBlock:^id _Nullable(id _Nullable value) { return nil; }]; 240| 1| return mapping; 241| 1|} 242| | 243| |@end /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Utilities/FixtureLoader.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import Foundation 25| | 26| |final class FixtureLoader { 27| 296| static func json(fromFileNamed fileName: String) -> Any { 28| 296| let bundle = Bundle(for: self) 29| 296| if let filePath = bundle.path(forResource: fileName, ofType: nil), 30| 296| let data = NSData(contentsOfFile: filePath) as Data? 31| 296| { 32| 295| if let object = try? JSONSerialization.jsonObject(with: data, options: []) { 33| 295| return object 34| 295| } 35| 1| } 36| 1| return [:] 37| 296| } 38| | 39| 290| static func dictionary(fromFileNamed fileName: String) -> [String:Any] { 40| 290| return json(fromFileNamed: fileName) as? [String:Any] ?? [:] 41| 290| } 42| | 43| 4| static func array(fromFileNamed fileName: String) -> [[String:Any]] { 44| 4| return json(fromFileNamed: fileName) as? [[String:Any]] ?? [] 45| 4| } 46| | 47| 1| static func optionalArray(fromFileNamed fileName: String) -> [[String:Any]?] { 48| 1| return json(fromFileNamed: fileName) as? [[String:Any]?] ?? [] 49| 1| } 50| |} /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Utilities/Storage.swift: 1| |// 2| |// CoreDataStack.swift 3| |// EasyMapping 4| |// 5| |// Created by Denys Telezhkin on 23.04.17. 6| |// Copyright © 2017 EasyMapping. All rights reserved. 7| |// 8| | 9| |import Foundation 10| | 11| |// CoreData stack taken from 12| |// https://gist.github.com/avdyushin/b67e4524edcfb1aec47605da1a4bea7a 13| | 14| |import CoreData 15| | 16| |/// NSPersistentStoreCoordinator extension 17| |extension NSPersistentStoreCoordinator { 18| | 19| | /// NSPersistentStoreCoordinator error types 20| | public enum CoordinatorError: Error { 21| | /// .momd file not found 22| | case modelFileNotFound 23| | /// NSManagedObjectModel creation fail 24| | case modelCreationError 25| | } 26| | 27| | /// Return NSPersistentStoreCoordinator object 28| 0| static func coordinator(name: String) throws -> NSPersistentStoreCoordinator? { 29| 0| 30| 0| guard let modelURL = Bundle(for: Storage.self).url(forResource: name, withExtension: "momd") else { 31| 0| throw CoordinatorError.modelFileNotFound 32| 0| } 33| 0| 34| 0| guard let model = NSManagedObjectModel(contentsOf: modelURL) else { 35| 0| throw CoordinatorError.modelCreationError 36| 0| } 37| 0| 38| 0| let coordinator = NSPersistentStoreCoordinator(managedObjectModel: model) 39| 0| 40| 0| do { 41| 0| try coordinator.addPersistentStore(ofType: NSInMemoryStoreType, configurationName: nil, at: nil, options: nil) 42| 0| } catch { 43| 0| throw error 44| 0| } 45| 0| 46| 0| return coordinator 47| 0| } 48| |} 49| | 50| |final class Storage { 51| | 52| | static var shared = Storage() 53| | 54| | @available(iOS 10.0, *) 55| 1| private lazy var persistentContainer: NSPersistentContainer = { 56| 1| guard let modelURL = Bundle(for: type(of: self)).url(forResource: "EasyMapping", withExtension:"momd") else { 57| 0| fatalError("failed finding EasyMapping.momd") 58| 1| } 59| 1| guard let model = NSManagedObjectModel(contentsOf: modelURL) else { 60| 0| fatalError("failed loading EasyMapping object model") 61| 1| } 62| 1| let container = NSPersistentContainer(name: "EasyMapping", managedObjectModel: model) 63| 1| let description = NSPersistentStoreDescription() 64| 1| description.type = NSInMemoryStoreType 65| 1| container.persistentStoreDescriptions = [description] 66| 1| container.loadPersistentStores { (storeDescription, error) in 67| 1| print("CoreData: Inited \(storeDescription)") 68| 1| guard error == nil else { 69| 0| print("CoreData: Unresolved error \(error as Any)") 70| 0| return 71| 1| } 72| 1| } 73| 1| return container 74| 1| }() 75| | 76| 0| private lazy var persistentStoreCoordinator: NSPersistentStoreCoordinator? = { 77| 0| do { 78| 0| return try NSPersistentStoreCoordinator.coordinator(name: "EasyMapping") 79| 0| } catch { 80| 0| print("CoreData: Unresolved error \(error)") 81| 0| } 82| 0| return nil 83| 0| }() 84| | 85| 0| private lazy var managedObjectContext: NSManagedObjectContext = { 86| 0| let coordinator = self.persistentStoreCoordinator 87| 0| var managedObjectContext = NSManagedObjectContext(concurrencyType: .mainQueueConcurrencyType) 88| 0| managedObjectContext.persistentStoreCoordinator = coordinator 89| 0| return managedObjectContext 90| 0| }() 91| | 92| | // MARK: Public methods 93| | 94| | enum SaveStatus { 95| | case saved, rolledBack, hasNoChanges 96| | } 97| | 98| 88| var context: NSManagedObjectContext { 99| 88| if #available(iOS 10.0, *) { 100| 88| return persistentContainer.viewContext 101| 88| } else { 102| 0| return managedObjectContext 103| 0| } 104| 0| } 105| | 106| 0| func save() -> SaveStatus { 107| 0| if context.hasChanges { 108| 0| do { 109| 0| try context.save() 110| 0| return .saved 111| 0| } catch { 112| 0| context.rollback() 113| 0| return .rolledBack 114| 0| } 115| 0| } 116| 0| return .hasNoChanges 117| 0| } 118| | 119| 22| func resetStorage() { 120| 22| let coordinator : NSPersistentStoreCoordinator 121| 22| if #available(iOS 10.0, *) { 122| 22| coordinator = persistentContainer.persistentStoreCoordinator 123| 22| } else { 124| 0| coordinator = persistentStoreCoordinator! 125| 22| } 126| 22| if let store = coordinator.persistentStores.first { 127| 22| do { 128| 22| try coordinator.remove(store) 129| 22| try coordinator.addPersistentStore(ofType: NSInMemoryStoreType, 130| 22| configurationName: nil, 131| 22| at: nil, 132| 22| options: store.options) 133| 22| } 134| 22| catch { 135| 0| print(error) 136| 22| } 137| 22| 138| 22| } 139| 22| } 140| | 141| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKCoreDataImporterTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| |import EasyMapping 26| | 27| |class EKCoreDataImporterTestCase: XCTestCase { 28| | 29| 10| override func setUp() { 30| 10| super.setUp() 31| 10| 32| 10| ManagedPerson.register(ManagedMappingProvider.personMapping()) 33| 10| ManagedCar.register(ManagedMappingProvider.carMapping()) 34| 10| ManagedPhone.register(ManagedMappingProvider.phoneMapping()) 35| 10| } 36| | 37| 10| override func tearDown() { 38| 10| super.tearDown() 39| 10| ManagedPerson.register(nil) 40| 10| ManagedCar.register(nil) 41| 10| ManagedPhone.register(nil) 42| 10| } 43| | 44| 1| func testImporterIsAbleToCollectEntityNames() { 45| 1| let importer = EKCoreDataImporter(mapping: ManagedMappingProvider.personMapping(), externalRepresentation: [:], context: Storage.shared.context) 46| 1| 47| 1| XCTAssertEqual(importer.entityNames, Set(["ManagedPerson", "ManagedCar", "ManagedPhone"])) 48| 1| } 49| | 50| 1| func testImporterAbleToCollectEntitiesWithRootKey() { 51| 1| let importer = EKCoreDataImporter(mapping: ManagedMappingProvider.carWithRootKeyMapping(), externalRepresentation: [:], context: Storage.shared.context) 52| 1| 53| 1| XCTAssertEqual(importer.entityNames, Set(["ManagedCar"])) 54| 1| } 55| | 56| 1| func testImporterCanCollectEntitiesWithComplexStructure() { 57| 1| let mapping = EKManagedObjectMapping(entityName: "ManagedPerson") 58| 1| ManagedCar.register(ManagedMappingProvider.carWithRootKeyMapping()) 59| 1| mapping.hasOne(ManagedCar.self, forKeyPath: "car") 60| 1| mapping.hasOne(ManagedPhone.self, forKeyPath: "phone") 61| 1| let addressMapping = EKManagedObjectMapping(forEntityName: "Address") { 62| 1| $0.hasOne(ManagedPerson.self, forKeyPath: "postman") 63| 1| } 64| 1| Address.register(addressMapping) 65| 1| mapping.hasOne(Address.self, forKeyPath: "addressBook") 66| 1| 67| 1| let sut = EKCoreDataImporter(mapping: mapping, externalRepresentation: [:], 68| 1| context: Storage.shared.context) 69| 1| 70| 1| XCTAssertEqual(sut.entityNames, Set(["ManagedPerson","ManagedCar","ManagedPhone","Address"])) 71| 1| } 72| | 73| 1| func testImporterIsAbleToCollectFromRecursiveMapping() { 74| 1| let sut = EKCoreDataImporter(mapping: One.objectMapping(), externalRepresentation: [:], context: Storage.shared.context) 75| 1| 76| 1| XCTAssertEqual(sut.entityNames, Set(["One","Two", "Three"])) 77| 1| } 78| | 79| 1| func testImporterIsAbleToCollectEntitiesWithRootKeypath() { 80| 1| let info = FixtureLoader.json(fromFileNamed: "CarWithRoot.json") 81| 1| 82| 1| let sut = EKCoreDataImporter(mapping: ManagedMappingProvider.carWithRootKeyMapping(), externalRepresentation: info, context: Storage.shared.context) 83| 1| 84| 1| XCTAssertEqual(sut.existingEntitiesPrimaryKeys, ["ManagedCar":Set([1])]) 85| 1| } 86| | 87| 1| func testImporterIsAbleToCollectEntitiesFromArrayOfObjects() { 88| 1| let info = FixtureLoader.array(fromFileNamed: "Cars.json") 89| 1| 90| 1| let sut = EKCoreDataImporter(mapping: ManagedMappingProvider.carMapping(), 91| 1| externalRepresentation: info, 92| 1| context: Storage.shared.context) 93| 1| 94| 1| XCTAssertEqual(sut.existingEntitiesPrimaryKeys, ["ManagedCar":Set([1,2])]) 95| 1| } 96| | 97| 1| func testShouldCollectEntitiesFromHasOneAndHasManyRelationships() { 98| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 99| 1| 100| 1| let sut = EKCoreDataImporter(mapping: ManagedMappingProvider.personMapping(), 101| 1| externalRepresentation: info, 102| 1| context: Storage.shared.context) 103| 1| 104| 1| XCTAssertEqual(sut.existingEntitiesPrimaryKeys, [ 105| 1| "ManagedCar":Set([3]), 106| 1| "ManagedPerson":Set([23]), 107| 1| "ManagedPhone":Set([1,2]) 108| 1| ]) 109| 1| } 110| | 111| 1| func testShouldCollectEntitiesRecursively() { 112| 1| let info = FixtureLoader.dictionary(fromFileNamed: "ComplexRepresentation.json") 113| 1| Plane.register(ManagedMappingProvider.complexPlaneMapping()) 114| 1| defer { Plane.register(nil) } 115| 1| 116| 1| let sut = EKCoreDataImporter(mapping: ManagedMappingProvider.complexPlaneMapping(), 117| 1| externalRepresentation: info, 118| 1| context: Storage.shared.context) 119| 1| 120| 1| XCTAssertEqual(sut.existingEntitiesPrimaryKeys, [ 121| 1| "ManagedCar":Set([3,8]), 122| 1| "ManagedPerson":Set([3,17,89]), 123| 1| "ManagedPhone":Set([1,2,4,5]), 124| 1| "Plane":Set() 125| 1| ]) 126| 1| } 127| | 128| 1| func testShouldCollectEntitiesWhenHasOneMappingHasNull() { 129| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonWithNullCar.json") 130| 1| 131| 1| let sut = EKCoreDataImporter(mapping: ManagedMappingProvider.personMapping(), 132| 1| externalRepresentation: info, 133| 1| context: Storage.shared.context) 134| 1| 135| 1| XCTAssertEqual(sut.existingEntitiesPrimaryKeys, [ 136| 1| "ManagedCar":Set(), 137| 1| "ManagedPerson":Set([5]), 138| 1| "ManagedPhone":Set([6,7]) 139| 1| ]) 140| 1| } 141| | 142| 1| func testShouldCollectEntitiesWhenHasManyMappingHasNull() { 143| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonWithNullPhones.json") 144| 1| 145| 1| let sut = EKCoreDataImporter(mapping: ManagedMappingProvider.personMapping(), 146| 1| externalRepresentation: info, 147| 1| context: Storage.shared.context) 148| 1| 149| 1| XCTAssertEqual(sut.existingEntitiesPrimaryKeys, [ 150| 1| "ManagedCar":Set([56]), 151| 1| "ManagedPerson":Set([23]), 152| 1| "ManagedPhone":Set() 153| 1| ]) 154| 1| } 155| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKManagedObjectMapperTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| | 26| |class ManagedTestCase : XCTestCase { 27| 22| let context = Storage.shared.context 28| | 29| 22| override func setUp() { 30| 22| super.setUp() 31| 22| ManagedCar.register(ManagedMappingProvider.carMapping()) 32| 22| ManagedPhone.register(ManagedMappingProvider.phoneMapping()) 33| 22| ManagedPerson.register(ManagedMappingProvider.personMapping()) 34| 22| } 35| | 36| 22| override func tearDown() { 37| 22| super.tearDown() 38| 22| 39| 22| ManagedCar.register(nil) 40| 22| ManagedPhone.register(nil) 41| 22| ManagedPerson.register(nil) 42| 22| 43| 22| Storage.shared.resetStorage() 44| 22| Storage.shared.context.rollback() 45| 22| Storage.shared.context.reset() 46| 22| } 47| | 48| 9| func numberOfObjects(_ type: T.Type) -> Int { 49| 9| let request = NSFetchRequest(entityName: String(describing: T.self)) 50| 9| return (try? context.count(for: request)) ?? 0 51| 9| } 52| | 53| 4| func insert(_ type: T.Type) -> T { 54| 4| return NSEntityDescription.insertNewObject(forEntityName: String(describing: T.self), 55| 4| into: context) as! T 56| 4| } 57| |} 58| | 59| |class EKManagedObjectMapperTestCase: ManagedTestCase { 60| | 61| 1| func testSimpleObjectFromExternalRepresentationWithMapping() { 62| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Car.json") 63| 1| let car = EKManagedObjectMapper.object(fromExternalRepresentation: info, 64| 1| with: ManagedMappingProvider.carMapping(), 65| 1| in: context) as! ManagedCar 66| 1| 67| 1| XCTAssertEqual(car.model, info["model"] as? String) 68| 1| XCTAssertEqual(car.year, info["year"] as? String) 69| 1| } 70| | 71| 1| func testObjectWithRootKey() { 72| 1| let rootInfo = FixtureLoader.dictionary(fromFileNamed: "CarWithRoot.json") 73| 1| let car = EKManagedObjectMapper.object(fromExternalRepresentation: rootInfo, 74| 1| with: ManagedMappingProvider.carWithRootKeyMapping(), 75| 1| in: context) as? ManagedCar 76| 1| let info = (rootInfo["data"] as? [String:Any])?["car"] as? [String:Any] 77| 1| 78| 1| XCTAssertEqual(car?.model, info?["model"] as? String) 79| 1| XCTAssertEqual(car?.year, info?["year"] as? String) 80| 1| } 81| | 82| 1| func testNestedInformation() { 83| 1| let info = FixtureLoader.dictionary(fromFileNamed: "CarWithNestedAttributes.json") 84| 1| 85| 1| let car = EKManagedObjectMapper.object(fromExternalRepresentation: info, 86| 1| with: ManagedMappingProvider.carNestedAttributesMapping(), 87| 1| in: context) as? ManagedCar 88| 1| 89| 1| XCTAssertEqual(car?.model, info["model"] as? String) 90| 1| XCTAssertEqual(car?.year, (info["information"] as? [String:Any])?["year"] as? String) 91| 1| } 92| | 93| 1| func testObjectWithDateFormatter() { 94| 1| let info = FixtureLoader.dictionary(fromFileNamed: "CarWithDate.json") 95| 1| 96| 1| let car = EKManagedObjectMapper.object(fromExternalRepresentation: info, 97| 1| with: ManagedMappingProvider.carWithDateMapping(), 98| 1| in: context) as? ManagedCar 99| 1| 100| 1| XCTAssertEqual(car?.model, info["model"] as? String) 101| 1| XCTAssertEqual(car?.year, info["year"] as? String) 102| 1| 103| 1| let formatter = ManagedMappingProvider.iso8601DateFormatter() 104| 1| formatter.dateFormat = "yyyy-MM-dd" 105| 1| let expected = formatter.date(from: info["created_at"] as? String ?? "") 106| 1| 107| 1| XCTAssertEqual(car?.createdAt, expected) 108| 1| } 109| | 110| 1| func testExistingObject() { 111| 1| let oldCar = insert(ManagedCar.self) 112| 1| oldCar.carID = 1 113| 1| oldCar.year = "1980" 114| 1| oldCar.model = "i20" 115| 1| 116| 1| try! context.save() 117| 1| 118| 1| let info = ["id":1,"model":"i30","year":"2013"] as [String : Any] 119| 1| 120| 1| let car = EKManagedObjectMapper.object(fromExternalRepresentation: info, 121| 1| with: ManagedMappingProvider.carMapping(), 122| 1| in: context) as! ManagedCar 123| 1| 124| 1| XCTAssertEqual(car, oldCar) 125| 1| XCTAssertEqual(car.carID, oldCar.carID) 126| 1| XCTAssertEqual(car.model, info["model"] as? String) 127| 1| XCTAssertEqual(car.year, info["year"] as? String) 128| 1| XCTAssertEqual(numberOfObjects(ManagedCar.self), 1) 129| 1| } 130| | 131| 1| func testMissingValuesShouldNotBeCleared() { 132| 1| let old = insert(ManagedCar.self) 133| 1| old.carID = 1 134| 1| old.year = "1980" 135| 1| old.model = "" 136| 1| old.createdAt = Date() 137| 1| 138| 1| _ = try? context.save() 139| 1| 140| 1| let info = ["id":1,"model":"i30"] as [String : Any] 141| 1| let mapping = ManagedMappingProvider.carWithDateMapping() 142| 1| mapping.ignoreMissingFields = true 143| 1| let car = EKManagedObjectMapper.object(fromExternalRepresentation: info, 144| 1| with: mapping, 145| 1| in: context) as! ManagedCar 146| 1| 147| 1| XCTAssertEqual(car.carID, old.carID) 148| 1| XCTAssertEqual(car.model, info["model"] as? String) 149| 1| XCTAssertEqual(car.year, old.year) 150| 1| XCTAssertEqual(car.createdAt, old.createdAt) 151| 1| XCTAssertEqual(numberOfObjects(ManagedCar.self), 1) 152| 1| } 153| | 154| 1| func testExplicitlyNilAttributesShouldBeReplaced() { 155| 1| let old = insert(ManagedCar.self) 156| 1| old.carID = 1 157| 1| old.year = "1980" 158| 1| old.model = "" 159| 1| old.createdAt = Date() 160| 1| _ = try? context.save() 161| 1| 162| 1| let info = FixtureLoader.dictionary(fromFileNamed: "CarWithAttributesRemoved.json") 163| 1| let mapping = ManagedMappingProvider.carWithDateMapping() 164| 1| mapping.ignoreMissingFields = true 165| 1| let car = EKManagedObjectMapper.object(fromExternalRepresentation: info, 166| 1| with: mapping, 167| 1| in: context) as? ManagedCar 168| 1| 169| 1| XCTAssertEqual(car?.carID, old.carID) 170| 1| XCTAssertNil(car?.model) 171| 1| XCTAssertEqual(car?.year, old.year) 172| 1| XCTAssertNil(car?.createdAt) 173| 1| XCTAssertEqual(numberOfObjects(ManagedCar.self), 1) 174| 1| } 175| | 176| 1| func testHasOneMapping() { 177| 1| let expected = insert(ManagedCar.self) 178| 1| expected.model = "i30" 179| 1| expected.year = "2013" 180| 1| 181| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 182| 1| 183| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: info, 184| 1| with: ManagedMappingProvider.personMapping(), 185| 1| in: context) as! ManagedPerson 186| 1| 187| 1| XCTAssertEqual(person.car.model, expected.model) 188| 1| XCTAssertEqual(person.car.year, expected.year) 189| 1| } 190| | 191| 1| func testHasOneMappingWithSeveralNonNestedKeys() { 192| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonNonNested.json") 193| 1| ManagedPerson.register(ManagedMappingProvider.personNonNestedMapping()) 194| 1| 195| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: info, 196| 1| with: ManagedMappingProvider.personNonNestedMapping(), 197| 1| in: context) as? ManagedPerson 198| 1| 199| 1| XCTAssertEqual(person?.name, "Lucas") 200| 1| XCTAssertEqual(person?.car.carID, 3) 201| 1| XCTAssertEqual(person?.car.model, "i30") 202| 1| XCTAssertEqual(person?.car.year, "2013") 203| 1| } 204| | 205| 1| func testHasManyMapping() { 206| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 207| 1| 208| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: info, 209| 1| with: ManagedMappingProvider.personMapping(), 210| 1| in: context) as? ManagedPerson 211| 1| 212| 1| XCTAssertEqual(person?.phones.count, 2) 213| 1| XCTAssertEqual(numberOfObjects(ManagedPerson.self), 1) 214| 1| XCTAssertEqual(numberOfObjects(ManagedPhone.self), 2) 215| 1| } 216| | 217| 1| func testArrayOfObjects() { 218| 1| let info = FixtureLoader.array(fromFileNamed: "Cars.json") 219| 1| 220| 1| let cars = EKManagedObjectMapper.arrayOfObjects(fromExternalRepresentation: info, 221| 1| with: ManagedMappingProvider.carMapping(), 222| 1| in: context) 223| 2| cars.forEach { XCTAssert($0 is ManagedCar) } 224| 1| XCTAssertEqual(cars.count, info.count) 225| 1| } 226| | 227| 1| func testArrayOfObjectsWithSameObjects() { 228| 1| let info = FixtureLoader.array(fromFileNamed: "PersonsWithSamePhones.json") 229| 1| 230| 1| let people = EKManagedObjectMapper.arrayOfObjects(fromExternalRepresentation: info, 231| 1| with: ManagedMappingProvider.personWithPhonesMapping(), 232| 1| in: context) as? [ManagedPerson] 233| 1| let phone = people?.first?.phones.first 234| 1| let phone2 = people?.last?.phones.first 235| 1| 236| 1| XCTAssertEqual(phone, phone2) 237| 1| } 238| | 239| 1| func testRecursiveMappings() { 240| 1| let info = FixtureLoader.dictionary(fromFileNamed: "RecursiveDuplicates.json") 241| 1| 242| 1| let recursive = EKManagedObjectMapper.object(fromExternalRepresentation: info, 243| 1| with: Recursive.objectMapping(), 244| 1| in: context) as? NSManagedObject 245| 1| 246| 1| XCTAssertEqual(recursive?.value(forKey: "id") as? String, "1") 247| 1| XCTAssertEqual((recursive?.value(forKey: "link") as? NSManagedObject)?.value(forKey: "id") as? String, "2") 248| 1| 249| 1| XCTAssertEqual( 250| 1| ((recursive?.value(forKey: "link") as? NSManagedObject)? 251| 1| .value(forKey: "link") as? NSManagedObject)? 252| 1| .value(forKey: "id") as? String,"1" 253| 1| ) 254| 1| } 255| | 256| 1| func testSyncArrayFromExternalRepresentationSamePhones() { 257| 1| let phones = FixtureLoader.dictionary(fromFileNamed: "Person.json")["phones"] as? [[String:Any]] ?? [] 258| 1| let zeroPhones = FixtureLoader.dictionary(fromFileNamed: "PersonWithZeroPhones.json")["phones"] as? [[String:Any]] ?? [] 259| 1| 260| 1| let request = NSFetchRequest(entityName: "ManagedPhone") 261| 1| var phonesArray = EKManagedObjectMapper.syncArrayOfObjects(fromExternalRepresentation: phones, with: ManagedMappingProvider.phoneMapping(), fetchRequest: request, in: Storage.shared.context) 262| 1| 263| 1| XCTAssertEqual(phonesArray.count, 2) 264| 1| XCTAssertEqual(numberOfObjects(ManagedPhone.self), 2) 265| 1| 266| 1| phonesArray = EKManagedObjectMapper.syncArrayOfObjects(fromExternalRepresentation: zeroPhones, 267| 1| with: ManagedMappingProvider.phoneMapping(), 268| 1| fetchRequest: request, 269| 1| in: Storage.shared.context) 270| 1| XCTAssertEqual(phonesArray.count, 0) 271| 1| XCTAssertEqual(numberOfObjects(ManagedPhone.self), 0) 272| 1| } 273| |} 274| | 275| |class EKManagedObjectMapperIncrementalDataTests: ManagedTestCase { 276| | 277| 1| func testHasManyMappingIncrementalData() { 278| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 279| 1| let mapping = ManagedMappingProvider.personMapping() 280| 1| mapping.incrementalData = true 281| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: info, 282| 1| with: mapping, 283| 1| in: context) as? ManagedPerson 284| 1| 285| 1| XCTAssertEqual(person?.phones.count, 2) 286| 1| XCTAssertEqual(numberOfObjects(ManagedPerson.self), 1) 287| 1| XCTAssertEqual(numberOfObjects(ManagedPhone.self), 2) 288| 1| } 289| | 290| 1| func testHasManyMappingAndNoIncrementalData() { 291| 1| let personInfo = FixtureLoader.dictionary(fromFileNamed: "Person.json") 292| 1| let personWithPhones = FixtureLoader.dictionary(fromFileNamed: "PersonWithOtherPhones.json") 293| 1| let mapping = ManagedMappingProvider.personMapping() 294| 1| 295| 1| var person = EKManagedObjectMapper.object(fromExternalRepresentation: personInfo, 296| 1| with: mapping, 297| 1| in: context) as? ManagedPerson 298| 1| person = EKManagedObjectMapper.object(fromExternalRepresentation: personWithPhones, 299| 1| with: mapping, 300| 1| in: context) as? ManagedPerson 301| 1| 302| 1| XCTAssertEqual(person?.phones.count, 2) 303| 1| } 304| | 305| 1| func testHasManyMappingAndIncrementalData() { 306| 1| let personInfo = FixtureLoader.dictionary(fromFileNamed: "Person.json") 307| 1| let personWithPhones = FixtureLoader.dictionary(fromFileNamed: "PersonWithOtherPhones.json") 308| 1| let mapping = ManagedMappingProvider.personMapping() 309| 1| mapping.incrementalData = true 310| 1| 311| 1| var person = EKManagedObjectMapper.object(fromExternalRepresentation: personInfo, 312| 1| with: mapping, 313| 1| in: context) as? ManagedPerson 314| 1| person = EKManagedObjectMapper.object(fromExternalRepresentation: personWithPhones, 315| 1| with: mapping, 316| 1| in: context) as? ManagedPerson 317| 1| 318| 1| XCTAssertEqual(person?.phones.count, 4) 319| 1| } 320| | 321| 1| func testHasManyMappingWithEmptyArrayAndNoIncrementalData() { 322| 1| let personInfo = FixtureLoader.dictionary(fromFileNamed: "Person.json") 323| 1| let personWithPhones = FixtureLoader.dictionary(fromFileNamed: "PersonWithZeroPhones.json") 324| 1| let mapping = ManagedMappingProvider.personMapping() 325| 1| 326| 1| var person = EKManagedObjectMapper.object(fromExternalRepresentation: personInfo, 327| 1| with: mapping, 328| 1| in: context) as? ManagedPerson 329| 1| person = EKManagedObjectMapper.object(fromExternalRepresentation: personWithPhones, 330| 1| with: mapping, 331| 1| in: context) as? ManagedPerson 332| 1| 333| 1| XCTAssertEqual(person?.phones.count, 0) 334| 1| } 335| | 336| 1| func testHasManyMappingWithEmptyArrayAndIncrementalData() { 337| 1| let personInfo = FixtureLoader.dictionary(fromFileNamed: "Person.json") 338| 1| let personWithPhones = FixtureLoader.dictionary(fromFileNamed: "PersonWithZeroPhones.json") 339| 1| let mapping = ManagedMappingProvider.personMapping() 340| 1| mapping.incrementalData = true 341| 1| 342| 1| var person = EKManagedObjectMapper.object(fromExternalRepresentation: personInfo, 343| 1| with: mapping, 344| 1| in: context) as? ManagedPerson 345| 1| person = EKManagedObjectMapper.object(fromExternalRepresentation: personWithPhones, 346| 1| with: mapping, 347| 1| in: context) as? ManagedPerson 348| 1| 349| 1| XCTAssertEqual(person?.phones.count, 2) 350| 1| } 351| | 352| 1| func testIncrementalDataWithRecursiveMappings() { 353| 1| let personRecursive = FixtureLoader.dictionary(fromFileNamed: "PersonRecursive.json") 354| 1| let mapping = ManagedMappingProvider.personMapping() 355| 1| mapping.incrementalData = true 356| 1| 357| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: personRecursive, 358| 1| with: mapping, 359| 1| in: context) as? ManagedPerson 360| 1| 361| 1| XCTAssertEqual(person?.relative.name, "Loreen") 362| 1| XCTAssertEqual(person?.relative.email, "loreen@gmail.com") 363| 1| XCTAssertEqual(person?.relative.gender, "female") 364| 1| XCTAssertEqual(person?.children.count, 2) 365| 2| person?.children.forEach({ child in 366| 2| if child.name == "Masha" { 367| 1| XCTAssertEqual(child.relative.name, "Alexey") 368| 1| XCTAssertEqual(child.children.count, 0) 369| 2| } else if child.name == "Elena" { 370| 1| XCTAssertNil(child.relative) 371| 1| XCTAssertEqual(child.children.count, 0) 372| 2| } else { XCTFail() } 373| 2| }) 374| 1| } 375| |} 376| | 377| |class EKManagedObjectMapperIgnoreMissingFieldsTestCase : ManagedTestCase 378| |{ 379| 1| func testIgnoreMissingFields() { 380| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 381| 1| let infoPartial = FixtureLoader.dictionary(fromFileNamed: "PersonWithoutRelations.json") 382| 1| let mapping = ManagedMappingProvider.personMapping() 383| 1| 384| 1| var person = EKManagedObjectMapper.object(fromExternalRepresentation: info, 385| 1| with: mapping, 386| 1| in: context) as? ManagedPerson 387| 1| // Check default behaviour 388| 1| XCTAssertNotNil(person?.car) 389| 1| XCTAssertNotNil(person?.phones) 390| 1| 391| 1| EKManagedObjectMapper.fillObject(person!, 392| 1| fromExternalRepresentation: infoPartial, 393| 1| with: mapping, 394| 1| in: context) 395| 1| XCTAssertNil(person?.car) 396| 1| XCTAssertEqual(person?.phones.count, 0) 397| 1| 398| 1| // Check behaviour with set ignoreMissingFields property 399| 1| person = EKManagedObjectMapper.object(fromExternalRepresentation: info, 400| 1| with: mapping, 401| 1| in: context) as? ManagedPerson 402| 1| XCTAssertNotNil(person?.car) 403| 1| XCTAssertNotNil(person?.phones) 404| 1| 405| 1| mapping.ignoreMissingFields = true 406| 1| 407| 1| EKManagedObjectMapper.fillObject(person!, 408| 1| fromExternalRepresentation: infoPartial, 409| 1| with: mapping, 410| 1| in: context) 411| 1| XCTAssertNotNil(person?.car) 412| 1| XCTAssertNotNil(person?.phones) 413| 1| } 414| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKManagedObjectMappingTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| |import EasyMapping 26| | 27| |class EKManagedObjectMappingTestCase: XCTestCase { 28| | 29| 1| func testMappingWithEntityName() { 30| 1| let mapping = EKManagedObjectMapping(entityName: "Car") 31| 1| XCTAssertEqual(mapping.entityName, "Car") 32| 1| } 33| | 34| 1| func testMappingForEntityNameWithBlock() { 35| 1| let mapping = EKManagedObjectMapping(forEntityName: "Car") { _ in 36| 1| } 37| 1| XCTAssertEqual(mapping.entityName, "Car") 38| 1| } 39| | 40| 1| func testMappingForClassWithRootPath() { 41| 1| let mapping = EKManagedObjectMapping(entityName: "Car", withRootPath: "car") 42| 1| XCTAssertEqual(mapping.entityName, "Car") 43| 1| XCTAssertEqual(mapping.rootPath, "car") 44| 1| } 45| | 46| 1| func testMappingForClassWithRootPathWithBlock() { 47| 1| let mapping = EKManagedObjectMapping(forEntityName: "Car", withRootPath: "car", with: { _ in }) 48| 1| 49| 1| XCTAssertEqual(mapping.entityName, "Car") 50| 1| XCTAssertEqual(mapping.rootPath, "car") 51| 1| } 52| | 53| 1| func testMapKeyPathToProperty() { 54| 1| let mapping = EKManagedObjectMapping(entityName: "Car") 55| 1| mapping.mapKeyPath("created_at", toProperty: "createdAt") 56| 1| 57| 1| let property = mapping.propertyMappings["created_at"] as? EKPropertyMapping 58| 1| 59| 1| XCTAssertEqual(property?.keyPath, "created_at") 60| 1| XCTAssertEqual(property?.property, "createdAt") 61| 1| } 62| | 63| 1| func testMapKeyPathToPropertyWithValueBlock() { 64| 1| let mapping = EKManagedObjectMapping(entityName: "ManagedCar") 65| 1| mapping.mapKeyPath("id", toProperty: "identifier") { key, value, context in 66| 1| return (Int(value as? String ?? "") ?? 0) + 1 67| 1| } 68| 1| 69| 1| let property = mapping.propertyMappings["id"] as? EKPropertyMapping 70| 1| 71| 1| XCTAssertEqual(property?.keyPath, "id") 72| 1| XCTAssertEqual(property?.property, "identifier") 73| 1| XCTAssertEqual(property?.managedValueBlock?("id","3",Storage.shared.context) as? Int, 4) 74| 1| } 75| | 76| 1| func testMapPropertiesFromArray() { 77| 1| let mapping = EKManagedObjectMapping(forEntityName: "Car") { 78| 1| $0.mapProperties(from: ["name","email"]) 79| 1| } 80| 1| 81| 1| let name = mapping.propertyMappings["name"] as? EKPropertyMapping 82| 1| let email = mapping.propertyMappings["email"] as? EKPropertyMapping 83| 1| 84| 1| XCTAssertEqual(name?.keyPath, "name") 85| 1| XCTAssertEqual(name?.property, "name") 86| 1| XCTAssertEqual(email?.keyPath, "email") 87| 1| XCTAssertEqual(email?.property, "email") 88| 1| } 89| | 90| 1| func testMapPropertiesFromDictionary() { 91| 1| let mapping = EKManagedObjectMapping(forEntityName: "Car") { 92| 1| $0.mapProperties(from: ["id":"identifier","contact.email":"email"]) 93| 1| } 94| 1| let id = mapping.propertyMappings["id"] as? EKPropertyMapping 95| 1| let contact = mapping.propertyMappings["contact.email"] as? EKPropertyMapping 96| 1| 97| 1| XCTAssertEqual(id?.keyPath, "id") 98| 1| XCTAssertEqual(id?.property, "identifier") 99| 1| XCTAssertEqual(contact?.keyPath, "contact.email") 100| 1| XCTAssertEqual(contact?.property, "email") 101| 1| } 102| | 103| 1| func testMapKeyPathToPropertyWithDateFormatter() { 104| 1| let mapping = EKManagedObjectMapping(forEntityName: "Car") { 105| 1| $0.mapKeyPath("birthdate", toProperty: "birthday", with: DateFormatter()) 106| 1| } 107| 1| let birthday = mapping.propertyMappings["birthdate"] as? EKPropertyMapping 108| 1| 109| 1| XCTAssertEqual(birthday?.keyPath, "birthdate") 110| 1| XCTAssertEqual(birthday?.property, "birthday") 111| 1| XCTAssertNotNil(birthday?.managedValueBlock) 112| 1| XCTAssertNotNil(birthday?.managedReverseBlock) 113| 1| } 114| | 115| 1| func testHasOneMappingForKeyPath() { 116| 1| let mapping = ManagedMappingProvider.personMapping() 117| 1| 118| 1| XCTAssertEqual(mapping.hasOneMappings.count, 2) 119| 1| XCTAssertEqual((mapping.hasOneMappings.firstObject as? EKRelationshipMapping)?.keyPath, "car") 120| 1| XCTAssertEqual((mapping.hasOneMappings.lastObject as? EKRelationshipMapping)?.keyPath, "relative") 121| 1| 122| 1| XCTAssertEqual(mapping.hasManyMappings.count, 2) 123| 1| XCTAssertEqual((mapping.hasManyMappings.firstObject as? EKRelationshipMapping)?.keyPath, "children") 124| 1| XCTAssertEqual((mapping.hasManyMappings.lastObject as? EKRelationshipMapping)?.keyPath, "phones") 125| 1| } 126| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKManagedObjectModelTestCase.swift: 1| |// 2| |// EKManagedObjectModelTestCase.swift 3| |// EasyMapping 4| |// 5| |// Created by Денис Тележкин on 06.05.17. 6| |// Copyright © 2017 EasyMapping. All rights reserved. 7| |// 8| | 9| |import XCTest 10| | 11| |fileprivate class TestManagedObjectModel : EKManagedObjectModel { 12| | @NSManaged var foo: String 13| | 14| 1| override static func objectMapping() -> EKManagedObjectMapping { 15| 1| let mapping = super.objectMapping() 16| 1| mapping.mapKeyPath("bar", toProperty: "foo") 17| 1| return mapping 18| 1| } 19| |} 20| | 21| |class EKManagedObjectModelTestCase: XCTestCase { 22| | 23| 1| func testObjectMapping() { 24| 1| let mapping = TestManagedObjectModel.objectMapping() 25| 1| 26| 1| XCTAssert(mapping.entityName.contains("TestManagedObjectModel")) 27| 1| } 28| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKMapperTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| | 26| |class EKMapperBaseTestCase : XCTestCase { 27| 28| override func setUp() { 28| 28| super.setUp() 29| 28| Car.register(MappingProvider.carMapping()) 30| 28| Phone.register(MappingProvider.phoneMapping()) 31| 28| Person.register(MappingProvider.personMapping()) 32| 28| } 33| | 34| 28| override func tearDown() { 35| 28| super.tearDown() 36| 28| Car.register(nil) 37| 28| Phone.register(nil) 38| 28| Person.register(nil) 39| 28| } 40| |} 41| | 42| |class EKMapperTestCase: EKMapperBaseTestCase { 43| | 44| 1| func testSimpleObject() { 45| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Car.json") 46| 1| let car = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.carMapping()) as? Car 47| 1| 48| 1| XCTAssertNotNil(car?.model) 49| 1| XCTAssertNotNil(car?.year) 50| 1| XCTAssertEqual(car?.model, info["model"] as? String) 51| 1| XCTAssertEqual(car?.year, info["year"] as? String) 52| 1| } 53| | 54| 0| func simpleObjectWithRootPath() { 55| 0| let info = FixtureLoader.dictionary(fromFileNamed: "CarWithRoot.json") 56| 0| let car = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.carWithRootKeyMapping()) as? Car 57| 0| 58| 0| XCTAssertNotNil(car?.model) 59| 0| XCTAssertNotNil(car?.year) 60| 0| XCTAssertEqual(car?.model, info["model"] as? String) 61| 0| XCTAssertEqual(car?.year, info["year"] as? String) 62| 0| XCTAssertEqual(car?.carId, 1) 63| 0| } 64| | 65| 1| func testWithNestedInformation() { 66| 1| let info = FixtureLoader.dictionary(fromFileNamed: "CarWithNestedAttributes.json") 67| 1| let car = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.carNestedAttributesMapping()) as? Car 68| 1| 69| 1| XCTAssertNotNil(car?.model) 70| 1| XCTAssertNotNil(car?.year) 71| 1| XCTAssertEqual(car?.model, info["model"] as? String) 72| 1| XCTAssertEqual(car?.year, (info["information"] as? [String:Any])?["year"] as? String) 73| 1| } 74| | 75| 1| func testWithDateFormattter() { 76| 1| let info = FixtureLoader.dictionary(fromFileNamed: "CarWithDate.json") 77| 1| let car = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.carWithDateMapping()) as? Car 78| 1| 79| 1| XCTAssertNotNil(car?.model) 80| 1| XCTAssertNotNil(car?.year) 81| 1| XCTAssertEqual(car?.model, info["model"] as? String) 82| 1| XCTAssertEqual(car?.year, info["year"] as? String) 83| 1| let formatter = MappingProvider.iso8601DateFormatter() 84| 1| let expected = formatter.date(from: info["created_at"] as? String ?? "") 85| 1| XCTAssertEqual(car?.createdAt, expected) 86| 1| } 87| | 88| 1| func testWithValueBlock() { 89| 1| let male = EKMapper.object(fromExternalRepresentation: FixtureLoader.dictionary(fromFileNamed: "Male.json"), 90| 1| with: MappingProvider.personWithOnlyValueBlockMapping()) as? Person 91| 1| let female = EKMapper.object(fromExternalRepresentation: FixtureLoader.dictionary(fromFileNamed: "Female.json"), 92| 1| with: MappingProvider.personWithOnlyValueBlockMapping()) as? Person 93| 1| 94| 1| XCTAssert(male?.gender == .male) 95| 1| XCTAssert(female?.gender == .female) 96| 1| } 97| | 98| 1| func testWithCustomObjectInValueBlock() { 99| 1| let address = EKMapper.object(fromExternalRepresentation: FixtureLoader.dictionary(fromFileNamed: "Address.json"), with: MappingProvider.addressMapping()) as? Address 100| 1| 101| 1| XCTAssertNotNil(address?.location) 102| 1| } 103| | 104| 1| func testUsingMappingBlocks() { 105| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 106| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.personMapping()) as? Person 107| 1| XCTAssertEqual(person?.socialURL, URL(string: "https://www.twitter.com/EasyMapping")) 108| 1| } 109| | 110| 1| func testDateMappingNull() { 111| 1| let info = FixtureLoader.dictionary(fromFileNamed: "CarWithDate.json") 112| 1| var car = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.carWithDateMapping()) as? Car 113| 1| 114| 1| let infoRemovedAttributes = FixtureLoader.dictionary(fromFileNamed: "CarWithAttributesRemoved.json") 115| 1| let mapping = MappingProvider.carWithDateMapping() 116| 1| mapping.ignoreMissingFields = true 117| 1| car = EKMapper.fillObject(car!, fromExternalRepresentation: infoRemovedAttributes, with: mapping) as? Car 118| 1| 119| 1| XCTAssertNotNil(car?.year) 120| 1| XCTAssertNil(car?.model) 121| 1| XCTAssertNil(car?.createdAt) 122| 1| } 123| | 124| 1| func testHasOneMapping() { 125| 1| let expected = Car.i30 126| 1| let person = EKMapper.object(fromExternalRepresentation: FixtureLoader.dictionary(fromFileNamed: "Person.json"), with: MappingProvider.personMapping()) as? Person 127| 1| 128| 1| XCTAssertEqual(person?.car.model, expected.model) 129| 1| XCTAssertEqual(person?.car.year, expected.year) 130| 1| } 131| | 132| 1| func testHasOneMappingWithDifferentNaming() { 133| 1| let expected = Car.i30 134| 1| let mapping = EKObjectMapping(objectClass: Person.self) 135| 1| mapping.hasOne(Car.self, forKeyPath: "vehicle", forProperty: "car") 136| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonWithDifferentNaming.json") 137| 1| 138| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Person 139| 1| 140| 1| XCTAssertNotNil(person?.car) 141| 1| XCTAssertEqual(person?.car.model, expected.model) 142| 1| XCTAssertEqual(person?.car.year, expected.year) 143| 1| } 144| | 145| 1| func testHasOneMappingWithNull() { 146| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonWithNullCar.json") 147| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.personMapping()) as? Person 148| 1| 149| 1| XCTAssertNotNil(person?.phones) 150| 1| XCTAssertNil(person?.car) 151| 1| } 152| | 153| 1| func testHasManyMapping() { 154| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 155| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.personMapping()) as? Person 156| 1| 157| 1| XCTAssertEqual(person?.phones.count, 2) 158| 1| } 159| | 160| 1| func testHasManyMappingWithDifferentNaming() { 161| 1| let mapping = EKObjectMapping(objectClass: Person.self) 162| 1| mapping.hasMany(Phone.self, forKeyPath: "cellphones", forProperty: "phones") 163| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonWithDifferentNaming.json") 164| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Person 165| 1| 166| 1| XCTAssertEqual(person?.phones.count, 2) 167| 1| XCTAssertEqual(person?.phones.last?.number, "2222-222") 168| 1| } 169| | 170| 1| func testHasManyMappingWithNull() { 171| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonWithNullPhones.json") 172| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.personMapping()) as? Person 173| 1| 174| 1| XCTAssertNil(person?.phones) 175| 1| XCTAssertNotNil(person) 176| 1| XCTAssertNotNil(person?.car) 177| 1| } 178| | 179| 1| func testWithNativeProperties() { 180| 1| let mapping = Native.objectMapping() 181| 1| let native = EKMapper.object(fromExternalRepresentation: FixtureLoader.dictionary(fromFileNamed: "Native.json"), with: mapping) as? Native 182| 1| 183| 1| XCTAssertEqual(native?.charProperty, 99) 184| 1| XCTAssertEqual(native?.unsignedCharProperty, 117) 185| 1| 186| 1| XCTAssertEqual(native?.shortProperty, 1) 187| 1| XCTAssertEqual(native?.unsignedShortProperty, 2) 188| 1| XCTAssertEqual(native?.intProperty, 3) 189| 1| XCTAssertEqual(native?.unsignedIntProperty, 4) 190| 1| XCTAssertEqual(native?.integerProperty, 5) 191| 1| XCTAssertEqual(native?.unsignedIntegerProperty, 6) 192| 1| XCTAssertEqual(native?.longProperty, 7) 193| 1| XCTAssertEqual(native?.unsignedLongProperty, 8) 194| 1| XCTAssertEqual(native?.longLongProperty, 9) 195| 1| XCTAssertEqual(native?.unsignedLongLongProperty, 10) 196| 1| 197| 1| XCTAssertEqual(native?.floatProperty, 11.1) 198| 1| XCTAssertEqual(native?.cgFloatProperty, 12.2) 199| 1| XCTAssertEqual(native?.doubleProperty, 13.3) 200| 1| 201| 1| XCTAssertEqual(native?.boolProperty, true) 202| 1| XCTAssertEqual(native?.smallBoolProperty, true) 203| 1| } 204| | 205| 1| func testWithNativePropertyThatIsNull() { 206| 1| let mapping = MappingProvider.nativeMappingWithNullPropertie() 207| 1| let values = ["age":NSNull()] 208| 1| let cat = EKMapper.object(fromExternalRepresentation: values, with: mapping) as? Cat 209| 1| 210| 1| XCTAssertNotNil(cat) 211| 1| XCTAssertEqual(cat?.age, 0) 212| 1| } 213| | 214| 1| func testArrayOfObjects() { 215| 1| let info = FixtureLoader.array(fromFileNamed: "Cars.json") 216| 1| let cars = EKMapper.arrayOfObjects(fromExternalRepresentation: info, with: MappingProvider.carMapping()) as? [Car] 217| 1| 218| 1| XCTAssertEqual(cars?.count, 2) 219| 1| } 220| | 221| 1| func testArrayOfObjectsWithNullItems() { 222| 1| let info = FixtureLoader.optionalArray(fromFileNamed: "CarsWithNullItem.json") 223| 2| let cars = EKMapper.arrayOfObjects(fromExternalRepresentation: info.map { $0 as Any }, with: MappingProvider.carMapping()) as? [Car] 224| 1| 225| 1| XCTAssertEqual(cars?.count, info.count - 1) 226| 1| } 227| | 228| 1| func testDifferentSetRepresentations() { 229| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Plane.json") 230| 1| let mapping = EKObjectMapping(for: Plane.self) { 231| 1| $0.hasMany(Person.self, forKeyPath: "persons") 232| 1| $0.hasMany(Person.self, forKeyPath: "pilots") 233| 1| $0.hasMany(Person.self, forKeyPath: "stewardess") 234| 1| $0.hasMany(Person.self, forKeyPath: "stars") 235| 1| } 236| 1| let plane = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Plane 237| 1| 238| 1| XCTAssertEqual(plane?.persons.count, 3) 239| 1| XCTAssertEqual(plane?.pilots.count, 2) 240| 1| XCTAssertEqual(plane?.stewardess.count, 1) 241| 1| XCTAssertEqual(plane?.stars.count, 1) 242| 1| XCTAssert(plane?.persons is Set) 243| 1| } 244| | 245| 1| func testHasManyMappingWithDifferentKeyName() { 246| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Plane.json") 247| 1| let mapping = EKObjectMapping(for: Seaplane.self) { 248| 1| $0.hasMany(Person.self, forKeyPath: "persons", forProperty: "passengers") 249| 1| } 250| 1| let plane = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Seaplane 251| 1| 252| 1| XCTAssertEqual(plane?.passengers.count, 3) 253| 1| } 254| | 255| 1| func testHasManyMappingWithMutableArray() { 256| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Alien.json") 257| 1| let alien = EKMapper.object(fromExternalRepresentation: info, with: Alien.objectMapping()) as? Alien 258| 1| 259| 1| XCTAssertEqual(alien?.fingers.count, 2) 260| 1| } 261| | 262| 1| func testRecursiveHasManyMapping() { 263| 1| let info = FixtureLoader.dictionary(fromFileNamed: "CommentsRecursive.json")["comments"] as? [[String:Any]] ?? [] 264| 1| let comments = EKMapper.arrayOfObjects(fromExternalRepresentation: info, with: CommentObject.objectMapping()) as? [CommentObject] 265| 1| 266| 1| XCTAssertEqual(comments?.count, 2) 267| 1| XCTAssertEqual(comments?.first?.subComments.count, 1) 268| 1| 269| 1| let firstSubSubComment = comments?.first?.subComments.first?.subComments.first 270| 1| 271| 1| XCTAssertEqual(comments?.first?.subComments?.first?.subComments.count, 1) 272| 1| XCTAssertEqual(firstSubSubComment?.name, "Bob") 273| 1| XCTAssertEqual(firstSubSubComment?.message, "It's a TRAP!") 274| 1| XCTAssertNil(firstSubSubComment?.subComments) 275| 1| } 276| | 277| 1| func testRecursiveHasOneMapping() { 278| 1| Person.register(MappingProvider.personWithRelativeMapping()) 279| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonRecursive.json") 280| 1| 281| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.personWithRelativeMapping()) as? Person 282| 1| 283| 1| XCTAssertEqual(person?.relative.name, "Loreen") 284| 1| XCTAssertEqual(person?.relative.email, "loreen@gmail.com") 285| 1| XCTAssert(person?.relative.gender == .female) 286| 1| XCTAssertEqual(person?.children.count, 2) 287| 1| 288| 1| XCTAssertEqual(person?.children.first?.relative.name, "Alexey") 289| 1| } 290| | 291| 1| func testHasOneMappingWithSeveralNonNestedKeys() { 292| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonNonNested.json") 293| 1| Person.register(MappingProvider.personNonNestedMapping()) 294| 1| 295| 1| let person = EKMapper.object(fromExternalRepresentation: info, 296| 1| with: MappingProvider.personNonNestedMapping()) as? Person 297| 1| 298| 1| XCTAssertEqual(person?.name, "Lucas") 299| 1| XCTAssertEqual(person?.car.carId, 3) 300| 1| XCTAssertEqual(person?.car.model, "i30") 301| 1| XCTAssertEqual(person?.car.year, "2013") 302| 1| } 303| | 304| 1| func testMapKeypathToPropertyShouldConvertPropertiesToMutableIfTheyAreMutableByDefinition() { 305| 1| let info = FixtureLoader.dictionary(fromFileNamed: "MutableFoundationClass.json") 306| 1| let instance = MutableFoundationClass(properties: info) 307| 1| 308| 1| XCTAssert(instance.array.isKind(of: NSMutableArray.self)) 309| 1| XCTAssertEqual(instance.array as NSArray as? [Int] ?? [], [2,4]) 310| 1| 311| 1| XCTAssert(instance.dictionary.isKind(of: NSMutableDictionary.self)) 312| 1| XCTAssertEqual(instance.dictionary as? [String:String] ?? [:], ["foo":"bar"]) 313| 1| 314| 1| XCTAssert(instance.mutableSet.isKind(of: NSMutableSet.self)) 315| 1| XCTAssertEqual(instance.mutableSet as NSSet as? Set, Set(["1"])) 316| 1| 317| 1| XCTAssert(instance.mutableOrderedSet.isKind(of: NSMutableOrderedSet.self)) 318| 1| XCTAssertEqual(instance.mutableOrderedSet as NSOrderedSet, NSOrderedSet(array: [3])) 319| 1| 320| 1| XCTAssertEqual(instance.set.count, 3) 321| 1| 322| 1| XCTAssert(instance.orderedSet.isKind(of: NSOrderedSet.self)) 323| 1| XCTAssertEqual(instance.mutableOrderedSet as NSOrderedSet, NSOrderedSet(array: [3])) 324| 1| } 325| |} 326| | 327| |class EKMapperIncrementalDataTestCase: EKMapperBaseTestCase 328| |{ 329| 1| func testHasManyMappingWithoutIncrementalData() { 330| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 331| 1| let mapping = MappingProvider.personMapping() 332| 1| var person = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Person 333| 1| let otherInfo = FixtureLoader.dictionary(fromFileNamed: "PersonWithOtherPhones.json") 334| 1| person = EKMapper.fillObject(person!, fromExternalRepresentation: otherInfo, with: mapping) as? Person 335| 1| 336| 1| XCTAssertEqual(person?.phones.count, 2) 337| 1| } 338| 1| func testHasManyMappingWithIncrementalData() { 339| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 340| 1| let mapping = MappingProvider.personMapping() 341| 1| mapping.incrementalData = true 342| 1| var person = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Person 343| 1| let otherInfo = FixtureLoader.dictionary(fromFileNamed: "PersonWithOtherPhones.json") 344| 1| person = EKMapper.fillObject(person!, fromExternalRepresentation: otherInfo, with: mapping) as? Person 345| 1| 346| 1| XCTAssertEqual(person?.phones.count, 4) 347| 1| } 348| | 349| 1| func testHasManyMappingEmptyAndNoIncrementalData() { 350| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 351| 1| let mapping = MappingProvider.personMapping() 352| 1| var person = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Person 353| 1| let otherInfo = FixtureLoader.dictionary(fromFileNamed: "PersonWithZeroPhones.json") 354| 1| person = EKMapper.fillObject(person!, fromExternalRepresentation: otherInfo, with: mapping) as? Person 355| 1| 356| 1| XCTAssertNotNil(person?.phones) 357| 1| XCTAssertEqual(person?.phones.count, 0) 358| 1| } 359| | 360| 1| func testHasManyMappingEmptyAndIncrementalData() { 361| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 362| 1| let mapping = MappingProvider.personMapping() 363| 1| mapping.incrementalData = true 364| 1| var person = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Person 365| 1| let otherInfo = FixtureLoader.dictionary(fromFileNamed: "PersonWithZeroPhones.json") 366| 1| person = EKMapper.fillObject(person!, fromExternalRepresentation: otherInfo, with: mapping) as? Person 367| 1| 368| 1| XCTAssertEqual(person?.phones.count, 2) 369| 1| } 370| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKMappingBlocksTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| |import EasyMapping 26| | 27| |class EKMappingBlocksTestCase: XCTestCase { 28| | 29| 1| func testBlockShouldConvertFromStringToURL() { 30| 1| let string = "http://www.google.com" 31| 1| let url = EKMappingBlocks.urlMappingBlock()("foo", string) as? URL 32| 1| 33| 1| XCTAssertEqual(url?.absoluteString, string) 34| 1| } 35| | 36| 1| func testShouldReturnNilOnNonStringValue() { 37| 1| let number = 6 38| 1| let nilURL = EKMappingBlocks.urlMappingBlock()("foo", number) 39| 1| 40| 1| XCTAssertNil(nilURL) 41| 1| } 42| | 43| 1| func testShouldReverseConvertURLToString() { 44| 1| let url = URL(string: "http://www.google.com") 45| 1| let string = EKMappingBlocks.urlReverseMappingBlock()(url) as? String 46| 1| 47| 1| XCTAssertEqual(string, url?.absoluteString) 48| 1| } 49| | 50| 1| func testURLStringShouldBeNilIfURLIsNil() { 51| 1| let url : URL? = nil 52| 1| let string = EKMappingBlocks.urlReverseMappingBlock()(url) 53| 1| 54| 1| XCTAssertNil(string) 55| 1| } 56| | 57| 1| func testCoreDataReverseMappingBlocks() { 58| 1| ManagedCar.register(ManagedMappingProvider.carMapping()) 59| 1| ManagedPhone.register(ManagedMappingProvider.phoneMapping()) 60| 1| defer { 61| 1| ManagedCar.register(nil) 62| 1| ManagedPhone.register(nil) 63| 1| } 64| 1| 65| 1| let context = Storage.shared.context 66| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 67| 1| let mapping = ManagedMappingProvider.personWithReverseBlocksMapping() 68| 1| 69| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: info, 70| 1| with: mapping, 71| 1| in: context) as! ManagedPerson 72| 1| let sut = EKSerializer.serializeObject(person, with: mapping, from: context) 73| 1| 74| 1| 75| 1| XCTAssertEqual(person.gender, "husband") 76| 1| XCTAssertEqual(sut["gender"] as? String, "male") 77| 1| } 78| | 79| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKObjectMappingTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| |import EasyMapping 26| | 27| |class EKObjectMappingTestCase: XCTestCase { 28| | 29| 1| func testMappingForClassConstructor() { 30| 1| let mapping = EKObjectMapping(objectClass: Car.self) 31| 1| 32| 1| XCTAssert(mapping.objectClass == Car.self) 33| 1| } 34| | 35| 1| func testMappingForClassWithRootPathConstructor() { 36| 1| let mapping = EKObjectMapping(objectClass: Car.self, withRootPath: "car") 37| 1| 38| 1| XCTAssert(mapping.objectClass == Car.self) 39| 1| XCTAssertEqual(mapping.rootPath, "car") 40| 1| } 41| | 42| 1| func testMappingForClassWithBlockConstructor() { 43| 1| let mapping = EKObjectMapping(for: Car.self) { _ in } 44| 1| 45| 1| XCTAssert(mapping.objectClass == Car.self) 46| 1| } 47| | 48| 1| func testMappingForClassWithBlockAndRootPathConstructor() { 49| 1| let mapping = EKObjectMapping(for: Car.self, withRootPath: "car", with: { _ in }) 50| 1| 51| 1| XCTAssert(mapping.objectClass == Car.self) 52| 1| XCTAssertEqual(mapping.rootPath, "car") 53| 1| } 54| | 55| |} 56| | 57| |class EKObjectMappingPropertyMappingTestCase : XCTestCase { 58| | var mapping : EKObjectMapping! 59| | 60| 9| override func setUp() { 61| 9| super.setUp() 62| 9| mapping = EKObjectMapping(objectClass: Car.self) 63| 9| } 64| | 65| 1| func testMapKeyPathToProperty() { 66| 1| mapping.mapKeyPath("created_at", toProperty: "createdAt") 67| 1| 68| 1| let sut = mapping.propertyMappings["created_at"] as? EKPropertyMapping 69| 1| 70| 1| XCTAssertEqual(sut?.keyPath, "created_at") 71| 1| XCTAssertEqual(sut?.property, "createdAt") 72| 1| } 73| | 74| 1| func testMapPropertiesFromArray() { 75| 1| mapping.mapProperties(from: ["name","email"]) 76| 1| 77| 1| let name = mapping.propertyMappings["name"] as? EKPropertyMapping 78| 1| let email = mapping.propertyMappings["email"] as? EKPropertyMapping 79| 1| 80| 1| XCTAssertEqual(name?.keyPath, "name") 81| 1| XCTAssertEqual(name?.property, "name") 82| 1| 83| 1| XCTAssertEqual(email?.keyPath, "email") 84| 1| XCTAssertEqual(email?.property, "email") 85| 1| } 86| | 87| 1| func testMapPropertiesFromArrayToPascalCase() { 88| 1| mapping.mapPropertiesFromArray(toPascalCase: ["name","email"]) 89| 1| 90| 1| let name = mapping.propertyMappings["Name"] as? EKPropertyMapping 91| 1| let email = mapping.propertyMappings["Email"] as? EKPropertyMapping 92| 1| 93| 1| XCTAssertEqual(name?.keyPath, "Name") 94| 1| XCTAssertEqual(name?.property, "name") 95| 1| 96| 1| XCTAssertEqual(email?.keyPath, "Email") 97| 1| XCTAssertEqual(email?.property, "email") 98| 1| } 99| | 100| 1| func testMapPropertiesFromUnderscoreToCamelCase() { 101| 1| mapping.mapPropertiesFromUnderscore(toCamelCase: ["model","year","created_at","car_id"]) 102| 1| 103| 1| let createdAt = mapping.propertyMappings["created_at"] as? EKPropertyMapping 104| 1| let carID = mapping.propertyMappings["car_id"] as? EKPropertyMapping 105| 1| let model = mapping.propertyMappings["model"] as? EKPropertyMapping 106| 1| 107| 1| XCTAssertEqual(createdAt?.keyPath, "created_at") 108| 1| XCTAssertEqual(createdAt?.property, "createdAt") 109| 1| 110| 1| XCTAssertEqual(carID?.keyPath, "car_id") 111| 1| XCTAssertEqual(carID?.property, "carId") 112| 1| 113| 1| XCTAssertEqual(model?.keyPath, "model") 114| 1| XCTAssertEqual(model?.property, "model") 115| 1| } 116| | 117| 1| func testMapPropertiesFromDictionary() { 118| 1| mapping.mapProperties(from: [ 119| 1| "id":"identifier", 120| 1| "contact.email":"email" 121| 1| ]) 122| 1| 123| 1| let id = mapping.propertyMappings["id"] as? EKPropertyMapping 124| 1| let email = mapping.propertyMappings["contact.email"] as? EKPropertyMapping 125| 1| 126| 1| XCTAssertEqual(id?.keyPath, "id") 127| 1| XCTAssertEqual(id?.property, "identifier") 128| 1| 129| 1| XCTAssertEqual(email?.keyPath, "contact.email") 130| 1| XCTAssertEqual(email?.property, "email") 131| 1| } 132| | 133| 1| func testMapKeyPathToPropertyWithDateFormatter() { 134| 1| let formatter = DateFormatter() 135| 1| formatter.dateFormat = "dd MMM yyyy" 136| 1| formatter.timeZone = TimeZone(secondsFromGMT: 0) 137| 1| formatter.locale = Locale(identifier: "en_US") 138| 1| let date = Date(timeIntervalSince1970: 0) 139| 1| let string = formatter.string(from: date) 140| 1| 141| 1| mapping.mapKeyPath("birthdate", toProperty: "birthdate", with: formatter) 142| 1| 143| 1| let sut = mapping.propertyMappings["birthdate"] as? EKPropertyMapping 144| 1| 145| 1| XCTAssertEqual(sut?.keyPath, "birthdate") 146| 1| XCTAssertEqual(sut?.property, "birthdate") 147| 1| 148| 1| XCTAssertEqual(sut?.valueBlock?("birthdate", string) as? Date, date) 149| 1| XCTAssertNil(sut?.valueBlock?("birthdate", nil)) 150| 1| XCTAssertNil(sut?.valueBlock?("birthdate", 5)) 151| 1| 152| 1| XCTAssertEqual(sut?.reverseBlock?(date) as? String, "01 Jan 1970") 153| 1| XCTAssertNil(sut?.reverseBlock?(nil)) 154| 1| XCTAssertNil(sut?.reverseBlock?(5)) 155| 1| } 156| | 157| 1| func testMapKeyPathToPropertyWithValueBlock() { 158| 1| let genders = ["male": Gender.male, "female":Gender.female] 159| 1| mapping.mapKeyPath("gender", toProperty: "gender") { key, value in 160| 1| return genders[value as? String ?? ""] 161| 1| } 162| 1| 163| 1| let sut = mapping.propertyMappings["gender"] as? EKPropertyMapping 164| 1| 165| 1| XCTAssert(sut?.valueBlock?("gender","male") as? Gender == Gender.male) 166| 1| } 167| | 168| 1| func testMapKeypathToPropertyWithValueBlockReverseBlock() { 169| 1| let genders = ["male": Gender.male, "female":Gender.female] 170| 1| mapping.mapKeyPath("gender", toProperty: "gender", withValueBlock: { _, value in 171| 1| return genders[value as? String ?? ""] 172| 2| }, reverse: { gender in 173| 4| return genders.filter({ key,value in 174| 4| value == gender as? Gender 175| 4| }).map { $0.0 }.first 176| 2| }) 177| 1| 178| 1| let sut = mapping.propertyMappings["gender"] as? EKPropertyMapping 179| 1| 180| 1| XCTAssert(sut?.valueBlock?("gender","male") as? Gender == Gender.male) 181| 1| XCTAssertEqual(sut?.reverseBlock?(Gender.male) as? String, "male") 182| 1| XCTAssertEqual(sut?.reverseBlock?(Gender.female) as? String, "female") 183| 1| } 184| | 185| 1| func testMapPropertiesFromMappingObject() { 186| 1| let ufo = EKObjectMapping(objectClass: ColoredUFO.self) 187| 1| ufo.mapProperties(fromMappingObject: UFO.objectMapping()) 188| 1| 189| 1| let shape = ufo.propertyMappings["shape"] as? EKPropertyMapping 190| 1| let captain = ufo.hasOneMappings.firstObject as? EKRelationshipMapping 191| 1| let crew = ufo.hasManyMappings.firstObject as? EKRelationshipMapping 192| 1| 193| 1| XCTAssertEqual(shape?.keyPath, "shape") 194| 1| XCTAssertEqual(shape?.property, "shape") 195| 1| 196| 1| XCTAssertEqual(captain?.keyPath, "captain") 197| 1| XCTAssertEqual(captain?.property, "captain") 198| 1| 199| 1| XCTAssertEqual(crew?.keyPath, "crew") 200| 1| XCTAssertEqual(crew?.property, "crew") 201| 1| } 202| |} 203| | 204| |class EKObjectMappingRelationshipsMappingTestCase : XCTestCase { 205| | var sut : EKObjectMapping! 206| | 207| 4| override func setUp() { 208| 4| super.setUp() 209| 4| sut = MappingProvider.personMapping() 210| 4| } 211| | 212| 1| func testHasOneMappingForKey() { 213| 1| XCTAssertEqual(sut.hasOneMappings.count, 1) 214| 1| 215| 1| let car = sut.hasOneMappings.firstObject as? EKRelationshipMapping 216| 1| 217| 1| XCTAssertEqual(car?.keyPath, "car") 218| 1| XCTAssertEqual(car?.property, "car") 219| 1| } 220| | 221| 1| func testHasOneMappingForKeypathForProperty() { 222| 1| sut.hasOneMappings.removeAllObjects() 223| 1| 224| 1| sut.hasOne(Car.self, forKeyPath: "car", forProperty:"personCar") 225| 1| 226| 1| let car = sut.hasOneMappings.firstObject as? EKRelationshipMapping 227| 1| 228| 1| XCTAssertEqual(car?.keyPath, "car") 229| 1| XCTAssertEqual(car?.property, "personCar") 230| 1| } 231| | 232| 1| func testHasManyMappingForKeypathForProperty() { 233| 1| sut.hasManyMappings.removeAllObjects() 234| 1| 235| 1| sut.hasMany(Phone.self, forKeyPath: "phones", forProperty:"personPhones") 236| 1| 237| 1| let car = sut.hasManyMappings.firstObject as? EKRelationshipMapping 238| 1| 239| 1| XCTAssertEqual(car?.keyPath, "phones") 240| 1| XCTAssertEqual(car?.property, "personPhones") 241| 1| } 242| | 243| 1| func testHasManyMappingForKey() { 244| 1| XCTAssertEqual(sut.hasManyMappings.count, 1) 245| 1| let phones = sut.hasManyMappings.firstObject as? EKRelationshipMapping 246| 1| 247| 1| XCTAssertEqual(phones?.keyPath, "phones") 248| 1| XCTAssertEqual(phones?.property, "phones") 249| 1| } 250| |} 251| | 252| |class EKObjectMappingCustomRElationshipsMappingTestCase : XCTestCase { 253| | var person : EKObjectMapping! 254| | var phone : EKObjectMapping! 255| | 256| 2| override func setUp() { 257| 2| super.setUp() 258| 2| person = EKObjectMapping(objectClass: Person.self) 259| 2| phone = Phone.objectMapping() 260| 2| } 261| | 262| 1| func testHasOneCarMappingWithPhoneSubstitution() { 263| 1| person.hasOne(Car.self, forKeyPath: "phone", forProperty: "car", with: phone) 264| 1| 265| 1| let sut = person.hasOneMappings.firstObject as? EKRelationshipMapping 266| 1| 267| 1| XCTAssert(sut?.mapping(for: sut as Any) === phone) 268| 1| XCTAssertEqual(sut?.keyPath, "phone") 269| 1| XCTAssertEqual(sut?.property, "car") 270| 1| } 271| | 272| 1| func testHasManyPhoneMappingWithCarSubstitution() { 273| 1| person.hasMany(Car.self, forKeyPath: "phone", forProperty: "car", with: phone) 274| 1| 275| 1| let sut = person.hasManyMappings.firstObject as? EKRelationshipMapping 276| 1| 277| 1| XCTAssert(sut?.mapping(for: sut as Any) === phone) 278| 1| XCTAssertEqual(sut?.keyPath, "phone") 279| 1| XCTAssertEqual(sut?.property, "car") 280| 1| } 281| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKObjectModelTestCase.swift: 1| |// 2| |// EKObjectModelTestCase.swift 3| |// EasyMapping 4| |// 5| |// Created by Денис Тележкин on 06.05.17. 6| |// Copyright © 2017 EasyMapping. All rights reserved. 7| |// 8| | 9| |import XCTest 10| | 11| |fileprivate final class TestObjectModel: EKObjectModel { 12| | @objc var foo: String! 13| | 14| 5| override static func objectMapping() -> EKObjectMapping { 15| 5| let mapping = super.objectMapping() 16| 5| mapping.mapKeyPath("bar", toProperty: "foo") 17| 5| return mapping 18| 5| } 19| |} 20| | 21| |class EKObjectModelTestCase: XCTestCase { 22| | 23| 1| func testObjectClass() { 24| 1| let mapping = TestObjectModel.objectMapping() 25| 1| 26| 1| XCTAssert(mapping.objectClass == TestObjectModel.self) 27| 1| } 28| | 29| 1| func testObjectWithProperties() { 30| 1| let object = TestObjectModel.object(withProperties: ["bar":"123"]) 31| 1| 32| 1| XCTAssertEqual(object.foo, "123") 33| 1| } 34| | 35| 1| func testInitWithProperties() { 36| 1| let object = TestObjectModel(properties: ["bar":"123"]) 37| 1| 38| 1| XCTAssertEqual(object.foo, "123") 39| 1| } 40| | 41| 1| func testSerializedObject() { 42| 1| let object = TestObjectModel(properties: ["bar":"123"]) 43| 1| let serialized = object.serializedObject() 44| 1| 45| 1| XCTAssertEqual(serialized["bar"] as? String, "123") 46| 1| } 47| | 48| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKPropertyHelperTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| |@testable import EasyMapping 26| | 27| |class EKPropertyHelperTestCase: XCTestCase { 28| | 29| | var sut: Native! 30| | 31| 3| override func setUp() { 32| 3| super.setUp() 33| 3| let json = FixtureLoader.dictionary(fromFileNamed: "Native.json") 34| 3| sut = EKMapper.object(fromExternalRepresentation: json, with: Native.objectMapping()) as? Native 35| 3| } 36| | 37| 1| func testNativePropertiesAreDetected() { 38| 1| let mapping = Native.objectMapping() 39| 1| let properties = mapping.propertyMappings as? [String:EKPropertyMapping] ?? [:] 40| 18| for property in properties.values { 41| 18| XCTAssert(EKPropertyHelper.propertyNameIsNativeProperty(property.property, from: sut as Any)) 42| 18| } 43| 1| 44| 1| XCTAssert(EKPropertyHelper.propertyNameIsNativeProperty("boolProperty", from: sut as Any)) 45| 1| } 46| | 47| 1| func testIdIdentification() { 48| 1| let object = MutableFoundationClass() 49| 1| XCTAssertFalse(EKPropertyHelper.propertyNameIsNativeProperty("idObject", from: object)) 50| 1| 51| 1| let id = EKPropertyHelper.propertyRepresentation([1,2,3], for: object, withPropertyName: "idObject") 52| 1| 53| 1| XCTAssertNotNil(id) 54| 1| } 55| | 56| 1| func testAddSetObjectsOnNSObject() { 57| 1| let object = MutableFoundationClass() 58| 1| object.mutableSet = NSMutableSet(array: [1,2,3]) 59| 1| EKPropertyHelper.addValue(Set([4,5]), on: object, forKeyPath: "mutableSet") 60| 1| 61| 1| XCTAssertEqual(object.mutableSet.count, 5) 62| 7| XCTAssertEqual(object.mutableSet.allObjects.compactMap { $0 as? Int }.sorted(by: { $0 < $1 }), [1,2,3,4,5]) 63| 1| } 64| |} 65| | 66| |class EKPropertyHelperManagedTestCase : ManagedTestCase { 67| 1| func testRespectPropertyRepresentationForManagedType() { 68| 1| let withoutPhones = FixtureLoader.dictionary(fromFileNamed: "PersonWithoutPhones.json") 69| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 70| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: withoutPhones, 71| 1| with: ManagedMappingProvider.personMapping(), 72| 1| in: Storage.shared.context) as! ManagedPerson 73| 1| let mapping = ManagedMappingProvider.personMapping() 74| 1| mapping.respectPropertyFoundationTypes = true 75| 1| EKManagedObjectMapper.fillObject(person, fromExternalRepresentation: info, with: mapping, in: Storage.shared.context) 76| 1| XCTAssertEqual(person.phones.count, 2) 77| 1| } 78| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKPropertyMappingTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| |import EasyMapping 26| | 27| |class EKPropertyMappingTestCase: XCTestCase { 28| | 29| | var sut : EKPropertyMapping! 30| | 31| 1| override func setUp() { 32| 1| super.setUp() 33| 1| sut = EKPropertyMapping(keyPath: "foo", forProperty: "bar") 34| 1| } 35| | 36| 1| func testVariables() { 37| 1| XCTAssertEqual(sut.keyPath, "foo") 38| 1| XCTAssertEqual(sut.property, "bar") 39| 1| } 40| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKRelationshipMappingTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| |import EasyMapping 26| | 27| |class EKRelationshipMappingTestCase: XCTestCase { 28| | 29| | var sut: EKRelationshipMapping! 30| | 31| 4| override func setUp() { 32| 4| super.setUp() 33| 4| sut = EKRelationshipMapping(forClass: EKObjectModel.self, withKeyPath: "foo", forProperty: "bar") 34| 4| } 35| | 36| 1| func testPerformanceExample() { 37| 1| XCTAssert(sut.objectClass == EKObjectModel.self) 38| 1| XCTAssertEqual(sut.keyPath, "foo") 39| 1| XCTAssertEqual(sut.property, "bar") 40| 1| } 41| | 42| 1| func testPersonMappingIncludesAnimals() { 43| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonWithAnimals.json") 44| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: MappingProvider.personWithPetsMapping()) as? Person 45| 1| 46| 1| XCTAssertEqual(person?.pets.count, 4) 47| 1| let dog = person?.pets.first as? Dog 48| 1| let wolf = person?.pets.last as? Wolf 49| 1| 50| 1| XCTAssertEqual(dog?.family, "Macintosh") 51| 1| XCTAssertEqual(wolf?.pack, "Bronzebeard") 52| 1| } 53| | 54| 1| func testConditionalHasOneMapping() { 55| 1| Car.register(MappingProvider.carMapping()) 56| 1| defer { Car.register(nil) } 57| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 58| 1| let mapping = MappingProvider.personMapping() 59| 1| let relationship = mapping.hasOneMappings.lastObject as? EKRelationshipMapping 60| 1| relationship?.condition = { _ in 61| 1| false 62| 1| } 63| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Person 64| 1| 65| 1| XCTAssertNil(person?.car) 66| 1| } 67| | 68| 1| func testConditionalHasManyMapping() { 69| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonWithAnimals.json") 70| 1| let mapping = MappingProvider.personWithPetsMapping() 71| 1| let relationship = mapping.hasManyMappings.lastObject as? EKRelationshipMapping 72| 1| relationship?.condition = { representation in 73| 1| return false 74| 1| } 75| 1| 76| 1| let person = EKMapper.object(fromExternalRepresentation: info, 77| 1| with: mapping) as? Person 78| 1| 79| 1| XCTAssertNil(person?.pets) 80| 1| } 81| | 82| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKSerializerTestCase.swift: 1| |// 2| |// EasyMapping 3| |// 4| |// Copyright (c) 2012-2017 Lucas Medeiros. 5| |// 6| |// Permission is hereby granted, free of charge, to any person obtaining a copy 7| |// of this software and associated documentation files (the "Software"), to deal 8| |// in the Software without restriction, including without limitation the rights 9| |// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10| |// copies of the Software, and to permit persons to whom the Software is 11| |// furnished to do so, subject to the following conditions: 12| |// 13| |// The above copyright notice and this permission notice shall be included in 14| |// all copies or substantial portions of the Software. 15| |// 16| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18| |// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19| |// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20| |// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21| |// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22| |// THE SOFTWARE. 23| | 24| |import XCTest 25| |import EasyMapping 26| | 27| |extension Car { 28| 10| static var i30 : Car { 29| 10| let car = Car() 30| 10| car.carId = 3 31| 10| car.model = "i30" 32| 10| car.year = "2013" 33| 10| car.createdAt = Date() 34| 10| return car 35| 10| } 36| |} 37| | 38| |extension Phone { 39| 3| static var one: Phone { 40| 3| let phone = Phone() 41| 3| phone.ddd = "85" 42| 3| phone.ddi = "55" 43| 3| phone.number = "1111-1111" 44| 3| return phone 45| 3| } 46| | 47| 3| static var two: Phone { 48| 3| let phone = Phone() 49| 3| phone.ddd = "11" 50| 3| phone.ddi = "55" 51| 3| phone.number = "2222-2222" 52| 3| return phone 53| 3| } 54| |} 55| | 56| |extension Person { 57| 6| static var socialPerson: Person { 58| 6| let person = antiSocialPerson 59| 6| person.socialURL = URL(string: "https://www.twitter.com/EasyMapping") 60| 6| return person 61| 6| } 62| | 63| 12| static var antiSocialPerson : Person { 64| 12| let person = Person() 65| 12| person.name = "Lucas" 66| 12| person.email = "lucastoc@gmail.com" 67| 12| person.gender = .male 68| 12| return person 69| 12| } 70| | 71| 4| static var driver : Person { 72| 4| let person = antiSocialPerson 73| 4| person.car = Car.i30 74| 4| return person 75| 4| } 76| | 77| 1| static var woman : Person { 78| 1| let person = Person() 79| 1| person.name = "Jane" 80| 1| person.email = "air@gmail.com" 81| 1| person.gender = .female 82| 1| return person 83| 1| } 84| | 85| 3| static var withDualSim: Person { 86| 3| let person = socialPerson 87| 3| person.phones = [Phone.one, Phone.two] 88| 3| return person 89| 3| } 90| | 91| 1| static var withAnimals: Person { 92| 1| let person = socialPerson 93| 1| person.pets = [Dog.fido, Dog.fifi, Wolf.alaska, Wolf.blizzard] 94| 1| return person 95| 1| } 96| |} 97| | 98| |extension Address { 99| 1| static var simple : Address { 100| 1| let address = Address() 101| 1| address.street = "A street" 102| 1| address.location = CLLocation(latitude: -30.12345, longitude: -3.12345) 103| 1| return address 104| 1| } 105| |} 106| | 107| |extension Dog { 108| 2| static var fido: Dog { 109| 2| let dog = Dog() 110| 2| dog.family = "Teckel" 111| 2| return dog 112| 2| } 113| | 114| 2| static var fifi: Dog { 115| 2| let dog = Dog() 116| 2| dog.family = "Bulldog" 117| 2| return dog 118| 2| } 119| |} 120| | 121| |extension Wolf { 122| 2| static var alaska: Wolf { 123| 2| let wolf = Wolf() 124| 2| wolf.pack = "Arctic" 125| 2| return wolf 126| 2| } 127| 2| static var blizzard: Wolf { 128| 2| let wolf = Wolf() 129| 2| wolf.pack = "Gray" 130| 2| return wolf 131| 2| } 132| |} 133| | 134| |class EKSerializerTestCase: XCTestCase { 135| | 136| 1| func testSerializerSerializesProperties() { 137| 1| let car = Car.i30 138| 1| let sut = EKSerializer.serializeObject(car, with: MappingProvider.carMapping()) 139| 1| 140| 1| XCTAssertEqual(sut["model"] as? String, "i30") 141| 1| XCTAssertEqual(sut["year"] as? String, "2013") 142| 1| } 143| | 144| 1| func testSerializerSerializesObjectWithRootPath() { 145| 1| let sut = EKSerializer.serializeObject(Car.i30, with: MappingProvider.carWithRootKeyMapping()) 146| 1| XCTAssertNotNil(sut) 147| 1| 148| 1| let data = sut["data"] as? [String:Any] 149| 1| let car = data?["car"] as? [String:Any] 150| 1| 151| 1| XCTAssertEqual(car?["model"] as? String, "i30") 152| 1| XCTAssertEqual(car?["year"] as? String, "2013") 153| 1| } 154| | 155| 1| func testSerializesManagedObjectWithRootPath() { 156| 1| ManagedPhone.register(ManagedMappingProvider.phoneMapping()) 157| 1| ManagedCar.register(ManagedMappingProvider.carMapping()) 158| 1| ManagedPerson.register(ManagedMappingProvider.personMapping()) 159| 1| defer { 160| 1| ManagedCar.register(nil) 161| 1| ManagedPerson.register(nil) 162| 1| ManagedPhone.register(nil) 163| 1| } 164| 1| 165| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 166| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: info, with: ManagedMappingProvider.personMapping(), in: Storage.shared.context) as? ManagedPerson 167| 1| 168| 1| let serialized = EKSerializer.serializeObject(person!.car!, with: ManagedMappingProvider.carWithRootKeyMapping(), from: Storage.shared.context) 169| 1| 170| 1| let data = serialized["data"] as? [String:Any] 171| 1| let car = data?["car"] as? [String:Any] 172| 1| 173| 1| XCTAssertEqual(car?["model"] as? String, "i30") 174| 1| XCTAssertEqual(car?["year"] as? String, "2013") 175| 1| } 176| | 177| 1| func testSerializerShouldSerializeNestedKeypaths() { 178| 1| let sut = EKSerializer.serializeObject(Car.i30, with: MappingProvider.carNestedAttributesMapping()) 179| 1| 180| 1| XCTAssertEqual(sut["model"] as? String, "i30") 181| 1| XCTAssertEqual((sut["information"] as? [String:Any])?["year"] as? String, "2013") 182| 1| } 183| | 184| 1| func testSerializerSupportsDates() { 185| 1| let formatter = DateFormatter() 186| 1| formatter.dateFormat = "yyyy-MM-dd" 187| 1| formatter.locale = Locale.current 188| 1| let dateString = formatter.string(from: Date()) 189| 1| 190| 1| let sut = EKSerializer.serializeObject(Car.i30, with: MappingProvider.carWithDateMapping()) 191| 1| 192| 1| XCTAssertEqual(sut["model"] as? String, "i30") 193| 1| XCTAssertEqual(sut["created_at"] as? String, dateString) 194| 1| } 195| | 196| 1| func testSerializeObjectUsingEKMappingBlocks() { 197| 1| let sut = EKSerializer.serializeObject(Person.socialPerson, with: MappingProvider.personMapping()) 198| 1| 199| 1| XCTAssertEqual(sut["socialURL"] as? String, "https://www.twitter.com/EasyMapping") 200| 1| } 201| | 202| 1| func testSerializerObjectUsingEKMappingBlocksAndNilValue() { 203| 1| let sut = EKSerializer.serializeObject(Person.antiSocialPerson, with: MappingProvider.personMapping()) 204| 1| 205| 1| XCTAssertNil(sut["socialURL"]) 206| 1| } 207| | 208| 1| func testSerializerIsAbleToSkipNilledOutFields() { 209| 1| let sut = EKSerializer.serializeObject(Person.socialPerson, with: MappingProvider.personMappingThatIgnoresSocialUrlDuringSerialization()) 210| 1| 211| 1| XCTAssertNil(sut["socialURL"]) 212| 1| } 213| | 214| 1| func testReverseMappingIsAbleToSerializeEnums() { 215| 1| let sut = EKSerializer.serializeObject(Person.antiSocialPerson, with: MappingProvider.personWithOnlyValueBlockMapping()) 216| 1| 217| 1| XCTAssertEqual(sut["gender"] as? String, "male") 218| 1| } 219| | 220| 1| func testAllEnumCasesAreSerializable() { 221| 1| let sut = EKSerializer.serializeObject(Person.woman, with: MappingProvider.personWithOnlyValueBlockMapping()) 222| 1| 223| 1| XCTAssertEqual(sut["gender"] as? String, "female") 224| 1| } 225| | 226| 1| func testReverseBlockWithCustomObject() { 227| 1| let sut = EKSerializer.serializeObject(Address.simple, with: MappingProvider.addressMapping()) 228| 1| 229| 1| XCTAssertEqual(sut["location"] as? [Double] ?? [], [-30.12345,-3.12345]) 230| 1| } 231| | 232| 1| func testNativePropertiesSerialization() { 233| 1| let dictionary = FixtureLoader.dictionary(fromFileNamed: "Native.json") 234| 1| let native = EKMapper.object(fromExternalRepresentation: dictionary, with: Native.objectMapping()) as! Native 235| 1| let sut = EKSerializer.serializeObject(native, with: Native.objectMapping()) 236| 1| 237| 1| XCTAssertEqual(sut["charProperty"] as? Int, 99) 238| 1| XCTAssertEqual(sut["unsignedCharProperty"] as? Int, 117) 239| 1| 240| 1| XCTAssertEqual(sut["shortProperty"] as? Int, 1) 241| 1| XCTAssertEqual(sut["unsignedShortProperty"] as? Int, 2) 242| 1| XCTAssertEqual(sut["intProperty"] as? Int, 3) 243| 1| XCTAssertEqual(sut["unsignedIntProperty"] as? Int, 4) 244| 1| XCTAssertEqual(sut["integerProperty"] as? Int, 5) 245| 1| XCTAssertEqual(sut["unsignedIntegerProperty"] as? Int, 6) 246| 1| XCTAssertEqual(sut["longProperty"] as? Int, 7) 247| 1| XCTAssertEqual(sut["unsignedLongProperty"] as? Int, 8) 248| 1| XCTAssertEqual(sut["longLongProperty"] as? Int, 9) 249| 1| XCTAssertEqual(sut["unsignedLongLongProperty"] as? Int, 10) 250| 1| 251| 1| XCTAssertEqual(sut["floatProperty"] as? Float, 11.1) 252| 1| XCTAssertEqual(sut["cgFloatProperty"] as? CGFloat, 12.2) 253| 1| XCTAssertEqual(sut["doubleProperty"] as? Double, 13.3) 254| 1| 255| 1| XCTAssertEqual(sut["boolProperty"] as? Bool, true) 256| 1| XCTAssertEqual(sut["smallBoolProperty"] as? Bool, true) 257| 1| } 258| | 259| 1| func testNativePropertiesSerializationInSubclasses() { 260| 1| let dictionary = FixtureLoader.dictionary(fromFileNamed: "NativeChild.json") 261| 1| let native = EKMapper.object(fromExternalRepresentation: dictionary, with: NativeChild.objectMapping()) as! Native 262| 1| let sut = EKSerializer.serializeObject(native, with: NativeChild.objectMapping()) 263| 1| 264| 1| XCTAssertEqual(sut["intProperty"] as? Int, 777) 265| 1| XCTAssertEqual(sut["boolProperty"] as? Bool, true) 266| 1| XCTAssertEqual(sut["childProperty"] as? String, "Hello") 267| 1| } 268| |} 269| | 270| |class EKSerializerRelationshipsTestCase: XCTestCase { 271| | var mapping : EKObjectMapping! 272| | 273| 11| override func setUp() { 274| 11| super.setUp() 275| 11| mapping = EKObjectMapping(objectClass: Person.self) 276| 11| Phone.register(MappingProvider.phoneMapping()) 277| 11| Car.register(MappingProvider.carMapping()) 278| 11| } 279| | 280| 11| override func tearDown() { 281| 11| super.tearDown() 282| 11| Phone.register(nil) 283| 11| Car.register(nil) 284| 11| } 285| | 286| 1| func testHasOneMappingWithDifferentNaming() { 287| 1| mapping.hasOne(Car.self, forKeyPath: "vehicle", forProperty: "car") 288| 1| 289| 1| let sut = EKSerializer.serializeObject(Person.driver, with: mapping) 290| 1| 291| 1| guard let car = sut["vehicle"] as? [String:Any] else { XCTFail(); return } 292| 1| XCTAssertEqual(car["model"] as? String, "i30") 293| 1| } 294| | 295| 1| func testHasOneRelationSerialization() { 296| 1| let sut = EKSerializer.serializeObject(Person.driver, with: MappingProvider.personWithCarMapping()) 297| 1| 298| 1| guard let car = sut["car"] as? [String:Any] else { XCTFail(); return } 299| 1| XCTAssertEqual(car["model"] as? String, "i30") 300| 1| XCTAssertEqual(car["year"] as? String, "2013") 301| 1| } 302| | 303| 1| func testHasManyRelationship() { 304| 1| let sut = EKSerializer.serializeObject(Person.withDualSim, with: MappingProvider.personWithPhonesMapping()) 305| 1| 306| 1| guard let phones = sut["phones"] as? [[String:Any]] else { XCTFail(); return } 307| 1| 308| 1| XCTAssertEqual(phones.count, 2) 309| 1| XCTAssertEqual(phones.first?["number"] as? String, "1111-1111") 310| 1| XCTAssertEqual(phones.last?["number"] as? String, "2222-2222") 311| 1| } 312| | 313| 1| func testHasManyWithDifferentNaming() { 314| 1| mapping.hasMany(Phone.self, forKeyPath: "cellphones", forProperty: "phones") 315| 1| 316| 1| let sut = EKSerializer.serializeObject(Person.withDualSim, with: mapping) 317| 1| guard let phones = sut["cellphones"] as? [[String:Any]] else { XCTFail(); return } 318| 1| 319| 1| XCTAssertEqual(phones.count, 2) 320| 1| XCTAssertEqual(phones.last?["ddd"] as? String, "11") 321| 1| XCTAssertEqual(phones.last?["number"] as? String, "2222-2222") 322| 1| } 323| | 324| 1| func testHasOneRelationWithNullObject() { 325| 1| let sut = EKSerializer.serializeObject(Person.withDualSim, with: MappingProvider.personMapping()) 326| 1| 327| 1| XCTAssertNil(sut["car"]) 328| 1| XCTAssertEqual((sut["phones"] as? [[String:Any]])?.count, 2) 329| 1| } 330| | 331| 1| func testHasManyRelationWithNullObject() { 332| 1| let sut = EKSerializer.serializeObject(Person.driver, with: MappingProvider.personMapping()) 333| 1| 334| 1| XCTAssertNil(sut["phones"]) 335| 1| XCTAssertNotNil(sut["car"]) 336| 1| } 337| | 338| 1| func testSerializationOfNonNestedObjects() { 339| 1| let sut = EKSerializer.serializeObject(Person.driver, with: MappingProvider.personNonNestedMapping()) 340| 1| 341| 1| XCTAssertEqual(sut["carId"] as? Int, 3) 342| 1| XCTAssertEqual(sut["carModel"] as? String, "i30") 343| 1| XCTAssertEqual(sut["carYear"] as? String, "2013") 344| 1| 345| 1| XCTAssertEqual(sut["name"] as? String, "Lucas") 346| 1| XCTAssertEqual(sut["email"] as? String, "lucastoc@gmail.com") 347| 1| XCTAssertEqual(sut["gender"] as? String, "male") 348| 1| } 349| | 350| 1| func testSerializationOfNonNestedManagedObjects() { 351| 1| ManagedCar.register(ManagedMappingProvider.carMapping()) 352| 1| ManagedPhone.register(ManagedMappingProvider.phoneMapping()) 353| 1| ManagedPerson.register(ManagedMappingProvider.personMapping()) 354| 1| defer { 355| 1| ManagedCar.register(nil) 356| 1| ManagedPhone.register(nil) 357| 1| ManagedPerson.register(nil) 358| 1| } 359| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 360| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: info, 361| 1| with: ManagedMappingProvider.personMapping(), 362| 1| in: Storage.shared.context) as? ManagedPerson 363| 1| let sut = EKSerializer.serializeObject(person!, with: ManagedMappingProvider.personNonNestedMapping(), from: Storage.shared.context) 364| 1| 365| 1| XCTAssertEqual(sut["carId"] as? Int, 3) 366| 1| XCTAssertEqual(sut["carModel"] as? String, "i30") 367| 1| XCTAssertEqual(sut["carYear"] as? String, "2013") 368| 1| 369| 1| XCTAssertEqual(sut["name"] as? String, "Lucas") 370| 1| XCTAssertEqual(sut["email"] as? String, "lucastoc@gmail.com") 371| 1| XCTAssertEqual(sut["gender"] as? String, "male") 372| 1| } 373| | 374| 1| func testSerializeCollectionOfHasManyObjects() { 375| 1| ManagedCar.register(ManagedMappingProvider.carMapping()) 376| 1| ManagedPhone.register(ManagedMappingProvider.phoneMapping()) 377| 1| ManagedPerson.register(ManagedMappingProvider.personMapping()) 378| 1| defer { 379| 1| ManagedCar.register(nil) 380| 1| ManagedPhone.register(nil) 381| 1| ManagedPerson.register(nil) 382| 1| } 383| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 384| 1| let person = EKManagedObjectMapper.object(fromExternalRepresentation: info, 385| 1| with: ManagedMappingProvider.personMapping(), 386| 1| in: Storage.shared.context) as? ManagedPerson 387| 1| let sut = EKSerializer.serializeObject(person!, 388| 1| with: ManagedMappingProvider.personMapping(), 389| 1| from: Storage.shared.context) 390| 1| 391| 1| guard let phones = sut["phones"] as? [[String:Any]] else { XCTFail(); return } 392| 1| 393| 1| XCTAssertEqual(phones.count, 2) 394| 2| let numbers = phones.map { $0["number"] as? String } 395| 1| XCTAssert(numbers.contains(where: { $0 == "1111-1111"})) 396| 2| XCTAssert(numbers.contains(where: { $0 == "2222-222" })) 397| 1| } 398| | 399| 1| func testSerializationResolver() { 400| 1| let person = EKSerializer.serializeObject(Person.withAnimals, with: MappingProvider.personWithPetsMapping()) 401| 1| guard let animals = person["animals"] as? [[String:Any]] else { XCTFail(); return } 402| 1| 403| 4| let dogs = animals.compactMap { $0["family"] as? String } 404| 4| let wolfs = animals.compactMap { $0["pack"] as? String } 405| 1| XCTAssertEqual(dogs.count, 2) 406| 1| XCTAssertEqual(wolfs.count, 2) 407| 1| 408| 1| XCTAssertEqual(dogs.first, "Teckel") 409| 1| XCTAssertEqual(dogs.last, "Bulldog") 410| 1| 411| 1| XCTAssertEqual(wolfs.first, "Arctic") 412| 1| XCTAssertEqual(wolfs.last, "Gray") 413| 1| } 414| | 415| 1| func testSerializeCollection() { 416| 1| let collection = [Dog.fido, Dog.fifi, Wolf.alaska, Wolf.blizzard] 417| 1| 418| 1| let array = EKSerializer.serializeCollection(collection, withRelationship: MappingProvider.animalCollectionRelationship()) 419| 1| 420| 1| XCTAssertEqual(array.count, 4) 421| 1| XCTAssertEqual(array[0]["family"] as? String, "Teckel") 422| 1| XCTAssertEqual(array.last?["pack"] as? String, "Gray") 423| 1| } 424| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EasyMappingPerfomanceTests.swift: 1| |// 2| |// EasyMappingPerfomanceTests.swift 3| |// EasyMapping 4| |// 5| |// Created by Denys Telezhkin on 28.04.17. 6| |// Copyright © 2017 EasyMapping. All rights reserved. 7| |// 8| | 9| |import XCTest 10| | 11| |class EasyMappingNSObjectPerfomanceTests: XCTestCase { 12| | 13| 13| override func setUp() { 14| 13| super.setUp() 15| 13| Car.register(MappingProvider.carMapping()) 16| 13| Phone.register(MappingProvider.phoneMapping()) 17| 13| Person.register(MappingProvider.personMapping()) 18| 13| } 19| | 20| 13| override func tearDown() { 21| 13| super.tearDown() 22| 13| Car.register(nil) 23| 13| Phone.register(nil) 24| 13| Person.register(nil) 25| 13| } 26| | 27| 130| func benchmark(fixture: String, mapping: EKObjectMapping, times: Int) { 28| 130| let info = FixtureLoader.dictionary(fromFileNamed: fixture) 29| 130| 30| 130k| for _ in 0...times { 31| 130k| _ = EKMapper.object(fromExternalRepresentation: info, with: mapping) 32| 130k| } 33| 130| } 34| | 35| 1| func testCar() { 36| 10| measure { 37| 10| self.benchmark(fixture: "Car.json", mapping: MappingProvider.carMapping(), times: 1000) 38| 10| } 39| 1| } 40| | 41| 1| func testCarWithRoot() { 42| 10| measure { 43| 10| self.benchmark(fixture: "CarWithRoot.json", mapping: MappingProvider.carWithRootKeyMapping(), times: 1000) 44| 10| } 45| 1| } 46| | 47| 1| func testCarWithNestedAttributes() { 48| 10| measure { 49| 10| self.benchmark(fixture: "CarWithNestedAttributes.json", mapping: MappingProvider.carNestedAttributesMapping(), times: 1000) 50| 10| } 51| 1| } 52| | 53| 1| func testCarWithDate() { 54| 10| measure { 55| 10| self.benchmark(fixture: "CarWithDate.json", mapping: MappingProvider.carWithDateMapping(), times: 1000) 56| 10| } 57| 1| } 58| | 59| 1| func testPerson() { 60| 10| measure { 61| 10| self.benchmark(fixture: "Person.json", mapping: MappingProvider.personMapping(), times: 1000) 62| 10| } 63| 1| } 64| | 65| 1| func testPersonWithNullPhones() { 66| 10| measure { 67| 10| self.benchmark(fixture: "PersonWithNullPhones.json", mapping: MappingProvider.personWithCarMapping(), times: 1000) 68| 10| } 69| 1| } 70| | 71| 1| func testPersonWithNullCar() { 72| 10| measure { 73| 10| self.benchmark(fixture: "PersonWithNullCar.json", mapping: MappingProvider.personWithPhonesMapping(), times: 1000) 74| 10| } 75| 1| } 76| | 77| 1| func testMale() { 78| 10| measure { 79| 10| self.benchmark(fixture: "Male.json", mapping: MappingProvider.personWithOnlyValueBlockMapping(), times: 1000) 80| 10| } 81| 1| } 82| | 83| 1| func testAddress() { 84| 10| measure { 85| 10| self.benchmark(fixture: "Address.json", mapping: MappingProvider.addressMapping(), times: 1000) 86| 10| } 87| 1| } 88| | 89| 1| func testNative() { 90| 10| measure { 91| 10| self.benchmark(fixture: "Native.json", mapping: Native.objectMapping(), times: 1000) 92| 10| } 93| 1| } 94| | 95| 1| func testPlane() { 96| 10| measure { 97| 10| self.benchmark(fixture: "Plane.json", mapping: Plane.objectMapping(), times: 1000) 98| 10| } 99| 1| } 100| | 101| 1| func testAlien() { 102| 10| measure { 103| 10| self.benchmark(fixture: "Alien.json", mapping: Alien.objectMapping(), times: 1000) 104| 10| } 105| 1| } 106| | 107| 1| func testNativeChild() { 108| 10| measure { 109| 10| self.benchmark(fixture: "NativeChild.json", mapping: NativeChild.objectMapping(), times: 1000) 110| 10| } 111| 1| } 112| |} 113| | 114| |class EasyMappingCoreDataPerfomanceTests: XCTestCase { 115| 9| override func setUp() { 116| 9| super.setUp() 117| 9| ManagedCar.register(ManagedMappingProvider.carMapping()) 118| 9| ManagedPhone.register(ManagedMappingProvider.phoneMapping()) 119| 9| ManagedPerson.register(ManagedMappingProvider.personMapping()) 120| 9| 121| 9| EKCoreDataManager.sharedInstance().deleteAllObjectsInCoreData() 122| 9| } 123| | 124| 9| override func tearDown() { 125| 9| super.tearDown() 126| 9| ManagedCar.register(nil) 127| 9| ManagedPhone.register(nil) 128| 9| ManagedPerson.register(nil) 129| 9| } 130| | 131| 80| func benchmark(fixture: String, mapping: EKManagedObjectMapping, times: Int) { 132| 80| let info = FixtureLoader.dictionary(fromFileNamed: fixture) 133| 80| 134| 8.08k| for _ in 0...times { 135| 8.08k| _ = EKManagedObjectMapper.object(fromExternalRepresentation: info, with: mapping, in: EKCoreDataManager.sharedInstance().managedObjectContext) 136| 8.08k| _ = try? EKCoreDataManager.sharedInstance().managedObjectContext.save() 137| 8.08k| } 138| 80| } 139| | 140| 1| func testCar() { 141| 10| measure { 142| 10| self.benchmark(fixture: "Car.json", mapping: ManagedMappingProvider.carMapping(), times: 100) 143| 10| } 144| 1| } 145| | 146| 1| func testCarWithRoot() { 147| 10| measure { 148| 10| self.benchmark(fixture: "CarWithRoot.json", mapping: ManagedMappingProvider.carWithRootKeyMapping(), times: 100) 149| 10| } 150| 1| } 151| | 152| 1| func testCarWithNestedAttributes() { 153| 10| measure { 154| 10| self.benchmark(fixture: "CarWithNestedAttributes.json", mapping: ManagedMappingProvider.carNestedAttributesMapping(), times: 100) 155| 10| } 156| 1| } 157| | 158| 1| func testCarWithDate() { 159| 10| measure { 160| 10| self.benchmark(fixture: "CarWithDate.json", mapping: ManagedMappingProvider.carWithDateMapping(), times: 100) 161| 10| } 162| 1| } 163| | 164| 1| func testPerson() { 165| 10| measure { 166| 10| self.benchmark(fixture: "Person.json", mapping: ManagedMappingProvider.personMapping(), times: 100) 167| 10| } 168| 1| } 169| | 170| 1| func testPersonWithNullPhones() { 171| 10| measure { 172| 10| self.benchmark(fixture: "PersonWithNullPhones.json", mapping: ManagedMappingProvider.personWithCarMapping(), times: 100) 173| 10| } 174| 1| } 175| | 176| 1| func testPersonWithNullCar() { 177| 10| measure { 178| 10| self.benchmark(fixture: "PersonWithNullCar.json", mapping: ManagedMappingProvider.personWithPhonesMapping(), times: 100) 179| 10| } 180| 1| } 181| | 182| 1| func testMale() { 183| 10| measure { 184| 10| self.benchmark(fixture: "Male.json", mapping: ManagedMappingProvider.personWithOnlyValueBlockMapping(), times: 100) 185| 10| } 186| 1| } 187| | 188| 10| var importData : [[String:Any]] { 189| 50.0k| return (0...5000).map { index in 190| 50.0k| [ 191| 50.0k| "id":index, 192| 50.0k| "name":"Name \(index)", 193| 50.0k| "email":"\(index)@email.com", 194| 50.0k| "phones": [ 195| 50.0k| [ 196| 50.0k| "id":index*5, 197| 50.0k| "number":"11111", 198| 50.0k| "ddi":"ddivalue \(index*5)", 199| 50.0k| "ddd":"dddvalue" ], 200| 50.0k| [ 201| 50.0k| "id":index*5+1, 202| 50.0k| "number":"11111", 203| 50.0k| "ddi":"ddivalue \(index*5 + 1)", 204| 50.0k| "ddd":"dddvalue" 205| 50.0k| ], 206| 50.0k| [ 207| 50.0k| "id":index*5+2, 208| 50.0k| "number":"11111", 209| 50.0k| "ddi":"ddivalue \(index*5 + 2)", 210| 50.0k| "ddd":"dddvalue" 211| 50.0k| ], 212| 50.0k| [ 213| 50.0k| "id":index*5+3, 214| 50.0k| "number":"11111", 215| 50.0k| "ddi":"ddivalue \(index*5 + 3)", 216| 50.0k| "ddd":"dddvalue" 217| 50.0k| ], 218| 50.0k| [ 219| 50.0k| "id":index*5+4, 220| 50.0k| "number":"11111", 221| 50.0k| "ddi":"ddivalue \(index*5 + 4)", 222| 50.0k| "ddd":"dddvalue" 223| 50.0k| ] 224| 50.0k| ] 225| 50.0k| ] 226| 50.0k| } 227| 10| } 228| | 229| 1| func testCoreDataImport() { 230| 1| measure { 231| 1| EKManagedObjectMapper.arrayOfObjects(fromExternalRepresentation: self.importData, 232| 1| with: ManagedMappingProvider.personWithPhonesMapping(), 233| 1| in: EKCoreDataManager.sharedInstance().managedObjectContext) 234| 1| } 235| 1| } 236| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EasyMappingTests.swift: 1| |// 2| |// EasyMappingTests.swift 3| |// EasyMapping 4| |// 5| |// Created by Lucas Medeiros on {TODAY}. 6| |// Copyright © 2017 EasyMapping. All rights reserved. 7| |// 8| | 9| |import Foundation 10| |import XCTest 11| |import EasyMapping 12| | 13| |class EasyMappingTests: XCTestCase { 14| 1| func testExample() { 15| 1| // This is an example of a functional test case. 16| 1| // Use XCTAssert and related functions to verify your tests produce the correct results. 17| 1| //// XCTAssertEqual(EasyMapping().text, "Hello, World!") 18| 1| } 19| | 20| | static var allTests = [ 21| 0| ("testExample", testExample), ------------------ | Unexecuted instantiation: $s5Tests011EasyMappingA0C03allA0SaySS_yycACctGvpZfiyycACcfu_ ------------------ | Unexecuted instantiation: $s5Tests011EasyMappingA0C03allA0SaySS_yycACctGvpZfiyycACcfu_yycfu0_ ------------------ 22| | ] 23| |} /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/XCTestEasyMappingSupportTestCase.swift: 1| |// 2| |// XCTestEasyMappingSupportTestCase.swift 3| |// EasyMappingExample 4| |// 5| |// Created by Денис Тележкин on 27.04.17. 6| |// Copyright © 2017 EasyKit. All rights reserved. 7| |// 8| | 9| |import XCTest 10| |import EasyMapping 11| | 12| |class XCTestEasyMappingSupportTestCase: XCTestCase { 13| | 14| 7| override func setUp() { 15| 7| super.setUp() 16| 7| Car.register(MappingProvider.carMapping()) 17| 7| Person.register(MappingProvider.personMapping()) 18| 7| Phone.register(MappingProvider.phoneMapping()) 19| 7| } 20| | 21| 7| override func tearDown() { 22| 7| super.tearDown() 23| 7| Car.register(nil) 24| 7| Person.register(nil) 25| 7| Phone.register(nil) 26| 7| } 27| | 28| 1| func testSimpleMapping() { 29| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Car.json") 30| 1| 31| 1| let car = Car() 32| 1| car.carId = info["id"] as? Int ?? 0 33| 1| car.model = info["model"] as? String 34| 1| car.year = info["year"] as? String 35| 1| 36| 1| testObject(fromExternalRepresentation: info, 37| 1| with: Car.objectMapping(), 38| 1| expectedObject: car) 39| 1| } 40| | 41| 1| func testNonNestedMapping() { 42| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonNonNested.json") 43| 1| Person.register(MappingProvider.personNonNestedMapping()) 44| 1| let person = Person() 45| 1| let car = Car() 46| 1| car.carId = info["carId"] as? Int ?? 0 47| 1| car.model = info["carModel"] as? String 48| 1| car.year = info["carYear"] as? String 49| 1| person.car = car 50| 1| person.name = info["name"] as? String 51| 1| person.email = info["email"] as? String 52| 1| person.gender = .male 53| 1| 54| 1| testObject(fromExternalRepresentation: info, 55| 1| with: Person.objectMapping(), 56| 1| expectedObject: person) 57| 1| } 58| | 59| 1| func testSimpleSerialization() { 60| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Car.json") 61| 1| let car = Car() 62| 1| car.carId = info["id"] as? Int ?? 0 63| 1| car.model = info["model"] as? String 64| 1| car.year = info["year"] as? String 65| 1| 66| 1| testSerializeObject(car, 67| 1| with: Car.objectMapping(), 68| 1| expectedRepresentation: info) 69| 1| } 70| | 71| 1| func testNonNestedSerialization() { 72| 1| let info = FixtureLoader.dictionary(fromFileNamed: "PersonNonNested.json") 73| 1| Person.register(MappingProvider.personNonNestedMapping()) 74| 1| let person = Person() 75| 1| let car = Car() 76| 1| car.carId = info["carId"] as? Int ?? 0 77| 1| car.model = info["model"] as? String 78| 1| car.year = info["year"] as? String 79| 1| person.car = car 80| 1| person.name = info["name"] as? String 81| 1| person.email = info["email"] as? String 82| 1| person.gender = .male 83| 1| 84| 1| testSerializeObject(person, 85| 1| with: Person.objectMapping(), 86| 1| expectedRepresentation: info) 87| 1| } 88| | 89| 1| func testNestedSerialization() { 90| 1| Phone.register(nil) 91| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 92| 1| let person = Person() 93| 1| let car = Car() 94| 1| car.carId = 3 95| 1| car.model = "i30" 96| 1| car.year = "2013" 97| 1| person.car = car 98| 1| person.name = info["name"] as? String 99| 1| person.email = info["email"] as? String 100| 1| person.gender = .male 101| 1| 102| 1| testSerializeObject(person, with: Person.objectMapping(), expectedRepresentation: info, skippingKeyPaths: ["phones","socialURL"]) 103| 1| } 104| | 105| 1| func testIgnoreMissingFieldsProperty() { 106| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 107| 1| let withoutRelations = FixtureLoader.dictionary(fromFileNamed: "PersonWithoutRelations.json") 108| 1| 109| 1| let mapping = Person.objectMapping() 110| 1| var person = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Person 111| 1| 112| 1| XCTAssertNotNil(person?.car) 113| 1| XCTAssertNotNil(person?.phones) 114| 1| EKMapper.fillObject(person!, fromExternalRepresentation: withoutRelations, with: mapping) 115| 1| 116| 1| XCTAssertNil(person?.car) 117| 1| XCTAssertNil(person?.phones) 118| 1| 119| 1| person = EKMapper.fillObject(person!, fromExternalRepresentation: info, with: mapping) as? Person 120| 1| 121| 1| mapping.ignoreMissingFields = true 122| 1| 123| 1| XCTAssertNotNil(person?.car) 124| 1| XCTAssertNotNil(person?.phones) 125| 1| 126| 1| EKMapper.fillObject(person!, fromExternalRepresentation: withoutRelations, with: mapping) 127| 1| 128| 1| XCTAssertNotNil(person?.car) 129| 1| XCTAssertNotNil(person?.phones) 130| 1| } 131| | 132| 1| func testIgnoreMissingFieldsWorksForProperties() { 133| 1| let info = FixtureLoader.dictionary(fromFileNamed: "Person.json") 134| 1| Person.register(MappingProvider.personMappingThatAssertsOnNilInValueBlock()) 135| 1| let mapping = Person.objectMapping() 136| 1| 137| 1| let person = EKMapper.object(fromExternalRepresentation: info, with: mapping) as? Person 138| 1| 139| 1| mapping.ignoreMissingFields = true 140| 1| XCTAssertNotNil(person?.car) 141| 1| XCTAssertNotNil(person?.phones) 142| 1| 143| 1| EKMapper.fillObject(person!, fromExternalRepresentation: ["id":23,"name":"Lucas"], with: mapping) 144| 1| 145| 1| XCTAssertEqual(person?.gender, .male) 146| 1| XCTAssertEqual(person?.socialURL.absoluteString, "https://www.twitter.com/EasyMapping") 147| 1| } 148| | 149| |} <<<<<< EOF # path=fixes /Users/runner/work/EasyMapping/EasyMapping/Example/FixtureLoader/FixtureLoader.swift:8,10,13,17,19,20,22,23 /Users/runner/work/EasyMapping/EasyMapping/Example/Specs/CarTestCase.swift:8,10,12,14,17,21,22,25,26,29,30,31 /Users/runner/work/EasyMapping/EasyMapping/Example/Specs/PersonTestCase.swift:8,10,12,14,17,20,21,26,27 /Users/runner/work/EasyMapping/EasyMapping/Example/Specs/PhoneTestCase.swift:8,10,12,14,17,19,22,23,28,29 /Users/runner/work/EasyMapping/EasyMapping/Example/Models/Person.swift:8,14,15,19,21,25,26,27 /Users/runner/work/EasyMapping/EasyMapping/Example/Models/Car.swift:8,13,14,20,21 /Users/runner/work/EasyMapping/EasyMapping/Example/Models/Phone.swift:8,13,14,17,19,22,24,25 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKRelationshipMappingTestCase.swift:23,26,28,30,34,35,40,41,45,49,52,53,62,64,66,67,74,75,78,80,81,82 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/LinuxMain.swift:3,8 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKManagedObjectMapperTestCase.swift:23,25,28,34,35,38,42,46,47,51,52,56,57,58,60,66,69,70,77,80,81,84,88,91,92,95,99,102,106,108,109,115,117,119,123,129,130,137,139,146,152,153,161,168,174,175,180,182,186,189,190,194,198,203,204,207,211,215,216,219,225,226,229,235,237,238,241,245,248,254,255,259,262,265,272,273,274,276,284,288,289,294,301,303,304,310,317,319,320,325,332,334,335,341,348,350,351,356,360,374,375,376,378,383,390,397,404,406,413,414 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKObjectModelTestCase.swift:8,10,13,18,19,20,22,25,27,28,31,33,34,37,39,40,44,46,47,48 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/XCTestEasyMappingSupportTestCase.swift:8,11,13,19,20,26,27,30,35,39,40,53,57,58,65,69,70,83,87,88,101,103,104,108,111,115,118,120,122,125,127,130,131,136,138,142,144,147,148,149 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKManagedObjectModelTestCase.swift:8,10,13,18,19,20,22,25,27,28 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKPropertyMappingTestCase.swift:23,26,28,30,34,35,39,40 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKPropertyHelperTestCase.swift:23,26,28,30,35,36,42,43,45,46,50,52,54,55,60,63,64,65,77,78 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EasyMappingPerfomanceTests.swift:8,10,12,18,19,25,26,29,32,33,34,38,39,40,44,45,46,50,51,52,56,57,58,62,63,64,68,69,70,74,75,76,80,81,82,86,87,88,92,93,94,98,99,100,104,105,106,110,111,112,113,120,122,123,129,130,133,137,138,139,143,144,145,149,150,151,155,156,157,161,162,163,167,168,169,173,174,175,179,180,181,185,186,187,226,227,228,234,235,236 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKMapperTestCase.swift:23,25,32,33,39,40,41,43,47,52,53,57,63,64,68,73,74,78,86,87,93,96,97,100,102,103,108,109,113,118,122,123,127,130,131,137,139,143,144,148,151,152,156,158,159,165,168,169,173,177,178,182,185,196,200,203,204,209,212,213,217,219,220,224,226,227,235,237,243,244,249,251,253,254,258,260,261,265,268,270,275,276,280,282,287,289,290,294,297,302,303,307,310,313,316,319,321,324,325,326,328,335,337,345,347,348,355,358,359,367,369,370 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKSerializerTestCase.swift:23,26,35,36,37,45,46,53,54,55,61,62,69,70,75,76,83,84,89,90,95,96,97,104,105,106,112,113,118,119,120,126,131,132,133,135,139,142,143,147,150,153,154,163,164,167,169,172,175,176,179,182,183,189,191,194,195,198,200,201,204,206,207,210,212,213,216,218,219,222,224,225,228,230,231,236,239,250,254,257,258,263,267,268,269,272,278,279,284,285,288,290,293,294,297,301,302,305,307,311,312,315,318,322,323,326,329,330,333,336,337,340,344,348,349,358,364,368,372,373,382,390,392,397,398,402,407,410,413,414,417,419,423,424 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKManagedObjectMappingTestCase.swift:23,26,28,32,33,36,38,39,44,45,48,51,52,56,58,61,62,67,68,70,74,75,79,80,83,88,89,93,96,101,102,106,108,113,114,117,121,125,126 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKMappingBlocksTestCase.swift:23,26,28,32,34,35,39,41,42,46,48,49,53,55,56,63,64,68,73,74,77,78,79 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKObjectMappingTestCase.swift:23,26,28,31,33,34,37,40,41,44,46,47,50,53,54,55,56,59,63,64,67,69,72,73,76,79,82,85,86,89,92,95,98,99,102,106,109,112,115,116,122,125,128,131,132,140,142,144,147,151,155,156,161,162,164,166,167,177,179,183,184,188,192,195,198,201,202,203,206,210,211,214,216,219,220,223,225,227,230,231,234,236,238,241,242,246,249,250,251,255,260,261,264,266,270,271,274,276,280,281 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EKCoreDataImporterTestCase.swift:23,26,28,31,35,36,42,43,46,48,49,52,54,55,63,66,69,71,72,75,77,78,81,83,85,86,89,93,95,96,99,103,109,110,115,119,126,127,130,134,140,141,144,148,154,155 /Users/runner/work/EasyMapping/EasyMapping/Tests/EasyMappingTests/EasyMappingTests.swift:8,12,18,19,23 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/EKCoreDataManager.h:8,11,13,17,19,21,23 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Providers/MappingProvider.h:8,11,13,15,34,36 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Providers/ManagedMappingProvider.m:8,13,15,20,21,23,30,31,33,41,42,52,53,55,65,66,68,76,77,79,90,91,93,97,102,103,105,116,117,119,124,126,128,130,134,136,138,140,143,145,146,148,156,157,159,167,168,170,177,178,180,185,186 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Providers/ManagedMappingProvider.h:8,12,14,16,28,31,33,35 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Providers/MappingProvider.m:8,24,26,31,32,34,39,40,42,47,48,50,57,58,67,68,70,75,76,78,86,87,89,98,102,103,105,120,121,123,139,140,142,147,148,150,155,156,158,168,169,171,183,184,186,197,198,200,204,205,207,211,212,222,229,232,233,235,241,242 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/ManagedCar.m:8,10,11,13,19,21,23,25,26,28,30,31 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/ManagedPerson.m:8,11,12,14,23,25,27,29,30,32,34,35 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/ManagedPhone.m:8,11,12,14,19,21,23,25,26,28,30,31 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/BaseManagedTestModel.m:8,10,12,14,15,16,18,20,21 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/ManagedCar.h:8,12,14,20 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/ManagedPhone.h:8,12,14,16,21 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/ManagedPerson.h:8,12,15,17,22,25,29,31,36 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/CoreData/BaseManagedTestModel.h:8,12,14,16 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/CommentObject.h:8,11,13,17 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Person.h:8,11,18,19,20,22,32 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Finger.h:8,11,13,15 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Phone.h:8,11,13,17 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/BaseTestModel.m:8,10,12,14,16,18,19,21,23,24 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Native.h:8,13,15,34,36,38,40 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Recursive.h:8,11,13,16 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Alien.m:8,11,13,15,20,21 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Address.h:8,12,14,17 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Car.h:8,11,13 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Cat.m:8,10,12,14,16,18,19,21,23,24 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/UFO.h:8,12,14,18,20,21,23,25 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Plane.h:8,10,12,18,20,22,25 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Phone.m:8,10,12,14,16,18,19,21,23,24 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Finger.m:8,10,12,14,18,19 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Person.m:8,10,12,14,16,18,19,21,23,24 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/CommentObject.m:8,10,12,14,23,24 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Recursive.m:8,10,12,15,17,19,22,24,25 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Native.m:8,10,12,14,23,24,26,28,30,34,35 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/BaseTestModel.h:8,12,14,16 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/UFO.m:8,10,12,14,20,21,23,24,26,28,33,34 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Cat.h:8,11,13,15 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Car.m:8,10,12,14,16,18,19,21,23,24,26,29,32,36,37 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Alien.h:8,11,13,16 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Address.m:8,10,12,14,16,18,19,21,23,24 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/TestModels/Models/NSObject/Plane.m:8,11,13,15,20,21,23,25,27,29,31,32,34,36,37 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/EKCoreDataManager.m:8,10,16,20,22,29,30,32,35,39,40,42,45,48,51,54,57,58,61,62,65,66,67,68,70,72,75,76,78,81,82,87,89,90,92,95,96,98,102,105,106,108,109,111,113,114,116,118,121,122,124,127,128,133,134,138,140,145,149,154,158,161,162,163,167,170,172,174,175,178,181,182,191,194,196,197,199,203,204,206 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Tests-Bridging-Header.h:4,16,20,28,30 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Utilities/Storage.swift:8,10,13,15,18,25,26,29,32,33,36,37,39,44,45,47,48,49,51,53,58,61,71,72,75,81,84,91,93,96,97,103,104,105,114,115,117,118,125,133,136,137,138,139,140,141 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Utilities/FixtureLoader.swift:23,25,31,34,35,37,38,41,42,45,46,49,50 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Utilities/EKCoreDataImporter+SwiftExtensions.h:23,25 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/Numbers.h:8,10,12,15,17,19,21,23,25,27,29,32 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/MutableFoundationClass.h:8,11,13,21 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/Wolf.m:8,10,12,14,19,20 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/Dog.h:8,10,12,14 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/Numbers.m:8,10,12,14,16,18,20,22,23,25,27,29,31,33,35,37,38,40,42,45,47,49,52,54,55 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/Wolf.h:8,10,12,14 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/MutableFoundationClass.m:8,10,12,14,16,23,24 /Users/runner/work/EasyMapping/EasyMapping/TestFixtures/Fixtures/FixtureClasses/Dog.m:8,10,12,14,19,20 /Users/runner/work/EasyMapping/EasyMapping/Package.swift:2,4 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping+XCTestCase/XCTestCase+EasyMapping.h:8,10,12,14,16,20,25,29,34,35,37 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping+XCTestCase/XCTestCase+EasyMapping.m:8,15,17,19,21,22,24,28,29,31,36,42,43,48,55,56,61,72,73,74,76,78,79,81,85,86,88,93,98,99,105,112,115,116,117,122,133,134,135,137,139,146,147,149,150,152,155,158,161,162,163 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKMapper.m:23,28,30,32,36,37,40,53,54,55,57,59,61,62,68,69,70,72,76,77,78,81,83,84,93,96,99,100,102,103,106,110,111,117,118,120,121,122,125,129,130,136,137,139,140 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKSerializer.m:23,28,30,32,34,38,41,45,47,49,51,52,55,56,57,58,60,66,67,68,73,75,76,78,80,84,85,87,88,91,95,96,98,99,101,103,110,112,114,120,122,124,125,128,129,130,131,133,140,141,142,147,149,150,152,154,158,159,161,162,164,166,170,171,173,174,177,179,181,184,186,187,188,190,192,194,197,199,200,201,210,217,219,221,222,223,224 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKRelationshipMapping.h:8,12,14,17,19,21,23,25,27,29,31,33,35,37,39,41,45,47 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKManagedObjectMapping.h:23,26,28,30,34,36,41,46,48,52,55,57,59,64,67,69,71,73,79,82,84,88,91,93,95,99,102,106,108,113,118,123,130 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKCoreDataImporter.m:23,28,30,32,34,37,40,42,44,48,50,54,58,60,61,63,65,68,70,72,73,75,77,79,82,84,88,89,90,92,95,97,101,102,103,104,106,108,111,113,118,120,121,126,130,132,135,137,138,139,141,144,146,147,148,150,153,161,165,166,167,172,173,174,176,178,180,187,191,192,197,198,199,200,202,207,208,210,212,215,220,224,226,227,229,230,232,235,238,239,241,242,244,246,251,253,254,256,259,263,264 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKPropertyMapping.m:23,25,27,33,34,36,41,43,44 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/NSArray+FlattenArray.m:23,25,27,35,36,38,39 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKObjectModel.h:8,11,13,18,21,23,27,28,31,33,37,40,44,46 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKMappingBlocks.m:23,25,27,29,32,34,37,38,40,43,45,48,49 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/NSDateFormatter+EasyMappingAdditions.h:25,27,29,33,34 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKObjectMapping.h:23,25,29,31,35,37,42,47,50,54,59,64,69,74,79,82,84,86,91,94,96,98,100,105,108,110,114,117,119,121,125,128,130,134,137,139,141,145,148,152,155,159,162,166,169,173,178,181,183,185,190,193,195,197,199,206,209,211,213,217,220,222,224,226,230,233,235,237,239,241,243,250,253,255,257,259,261,265,266,269,271,275,278,280,282,284,288,291,293,295,297,299,303,305 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKManagedObjectModel.m:8,13,15,17,19,23,24,26,28,32,33,35,37,39,40 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKManagedObjectMapper.h:23,27,29,34,37,39,41,43,49,52,54,56,58,60,63,68,71,73,75,77,83,89,91,93,95,97,105 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKPropertyHelper.h:23,29,31,36,38,40,46,53,56,60,62,64,67,69,71 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKManagedObjectMapping.m:23,25,27,32,34,37,39,41,42,44,47,49,51,52,54,57,62,64,65,67,70,72,74,75,77,80,83,86,89,90,92,96,100,101,103,108,113,114,116,118,119 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKRelationshipMapping.m:8,10,12,16,18,19,23,25,26,28,30,32,35,37,40,42,43,45,46,47,54,55,57,62,64,65 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKSerializer.h:23,27,29,34,37,39,41,45,48,50,52,58,61,63,65,70,73,75,77,79,85,88,90,92,94,101,104,106,108,110,116,118 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKMapper.h:23,25,27,31,33,36,38,40,45,48,50,52,54,60,63,65,67,72,74 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKMappingBlocks.h:23,26,28,30,33,36,38,41,43,45 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKObjectModel.m:8,12,14,16,18,21,22,24,26,30,32,33,35,37,40,41,43,45,47,48 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/NSArray+FlattenArray.h:23,25,27,29,31,33 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKPropertyMapping.h:23,25,27,31,33,38,43,44,46,49,54,59,64,69,71 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKCoreDataImporter.h:23,26,28,31,35,38,40,45,50,55,58,60,62,64,70,73,75,77,81,83,85 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EasyMapping.h:23 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKManagedObjectMapper.m:23,28,31,33,35,37,39,43,44,47,52,55,67,69,70,73,77,85,86,90,96,98,104,105,106,107,108,112,118,120,121,123,131,134,137,138,139,140,143,146,149,151,152,155,156,159,162,164,165,169,172,177,180,186,191,202,203,209,211,212,213,218,222,225,231,232,237,240,255,256,260,263,267,270,271,276,279,286,287 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKMappingProtocol.h:8,12,14,17,21,24,28,30,33,37,40,44,46 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKManagedObjectModel.h:8,11,13,18,21,23,25,27,32,35,37,41,43 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKObjectMapping.m:23,30,32,34,37,39,41,42,44,47,49,51,52,54,61,63,64,66,70,72,73,75,78,81,82,84,88,97,98,100,102,105,106,107,109,113,115,116,117,119,122,124,125,126,128,130,134,135,137,139,142,143,146,147,150,151,152,155,159,163,164,167,172,177,178,180,182,183,185,187,188,190,194,197,206,208,209,211,215,218,228,230,231,233,235,236,238,240,241,243,247,250,259,261,262,264,266,267,272,275,276,281,284,285 /Users/runner/work/EasyMapping/EasyMapping/Sources/EasyMapping/EKPropertyHelper.m:23,27,37,39,41,43,46,50,51,53,65,66,68,70,72,73,76,80,83,86,89,94,95,97,98,100,103,110,114,117,118,119,120,127,136,140,143,144,145,146,148,150,153,156,157,160,161,162,164,166,168,173,174,184,185,186,187,189,191,196,198,201,202,203,207,209,214,216,219,220,221,224,227,229,230,243,244,246 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/ext/json/ext/fbuffer/fbuffer.h:1,4,6,10,14,24,33,40,45,52,54,59,72,74,81,82,84,87,88,90,92,93,95,97,101,102,104,108,109,110,112,117,118,119,122,125,127,129,131,133,137,138,141,143,146,147,148,150,154,160,161,163,167,168,170,173,177,178,180,185 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/ext/json/ext/parser/parser.h:3,5,9,15,17,19,23,29,47,54,57,77,81,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/ext/json/ext/parser/parser.c:5,11,14,18,20,27,29,46,48,64,65,67,88,90,91,95,101,102,104,105,106,111,113,114,116,117,119,123,126,127,129,130,132,134,135,137,139,143,161,167,173,185,196,212,238,247,258,260,261,274,287,298,314,330,346,372,388,404,420,429,456,459,460,462,470,475,476,477,481,482,483,484,485,490,492,493,495,496,498,500,501,503,505,506,508,510,514,532,544,547,551,560,561,567,571,575,579,583,587,592,593,597,602,603,607,609,613,615,619,621,634,645,661,677,693,835,865,868,869,871,876,877,878,879,884,886,887,889,890,892,894,895,897,899,900,903,905,909,914,954,959,962,963,965,975,976,977,978,983,985,986,988,989,991,995,998,999,1001,1002,1004,1006,1007,1009,1011,1012,1015,1017,1021,1026,1050,1066,1090,1108,1123,1127,1137,1140,1141,1143,1158,1159,1163,1164,1165,1166,1167,1172,1174,1175,1177,1178,1180,1183,1186,1188,1189,1191,1193,1194,1196,1198,1202,1228,1237,1247,1249,1250,1263,1284,1298,1314,1330,1346,1372,1388,1397,1414,1417,1418,1420,1426,1427,1428,1430,1434,1478,1487,1488,1491,1496,1501,1502,1505,1506,1507,1512,1514,1515,1517,1518,1521,1527,1529,1530,1532,1535,1537,1539,1541,1542,1545,1547,1551,1566,1572,1580,1581,1652,1660,1663,1664,1666,1675,1676,1677,1682,1687,1688,1689,1701,1703,1709,1713,1716,1717,1746,1749,1752,1773,1776,1782,1788,1794,1799,1805,1811,1817,1823,1830,1832,1842,1849,1850,1851,1856,1858,1859,1861,1862,1870,1875,1876,1878,1880,1881,1885,1887,1891,1909,1921,1924,1935,1946,1962,1978,1994,2003,2014,2017,2018,2020,2026,2027,2028,2030,2038,2039,2041,2045,2046,2048,2051,2052,2063,2065,2070,2071,2079,2082,2083,2085,2099,2102,2105,2108,2129,2130 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/ext/json/ext/generator/generator.c:3,8,20,26,48,66,74,86,95,103,104,106,109,110,113,115,120,121,126,129,130,134,138,145,149,160,162,186,207,208,209,223,224,226,227,233,241,272,284,291,295,296,298,301,302,307,309,310,317,318,330,335,340,345,350,355,360,365,370,375,380,385,390,395,400,410,412,413,424,425,433,435,436,444,446,447,454,456,458,465,467,468,477,478,487,489,490,500,507,508,516,520,521,529,534,535,542,544,545,552,554,555,562,564,565,574,581,582,584,595,596,598,610,611,622,624,628,629,637,650,658,666,674,682,692,693,703,704,713,714,720,721,723,731,732,733,741,756,757,764,770,771,772,779,781,788,790,791,798,801,806,818,822,826,827,828,836,841,844,845,847,856,860,862,868,875,876,877,879,880,882,895,903,904,906,913,914,915,917,918,921,925,927,929,934,940,942,943,945,947,948,950,952,953,955,957,958,960,962,963,965,968,969,972,977,980,991,992,994,995,997,1026,1027,1028,1030,1034,1039,1045,1049,1054,1058,1059,1061,1066,1067,1076,1081,1082,1104,1112,1113,1121,1123,1128,1139,1140,1149,1157,1158,1159,1166,1169,1170,1177,1187,1192,1194,1195,1203,1206,1207,1215,1225,1230,1232,1233,1240,1243,1244,1251,1261,1266,1268,1269,1277,1280,1281,1289,1298,1303,1305,1306,1313,1316,1317,1324,1333,1338,1340,1341,1342,1350,1353,1354,1362,1365,1366,1374,1378,1379,1387,1390,1391,1399,1402,1403,1410,1413,1414,1422,1427,1428,1435,1438,1439,1447,1454,1456,1457,1462,1465,1469,1474,1506,1538,1569 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.1/ext/json/ext/generator/generator.h:3,6,8,14,18,22,24,26,28,32,38,43,45,48,55,57,78,81,85,90,97,157,161,170 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/ext/json/ext/fbuffer/fbuffer.h:1,4,6,10,14,24,33,40,45,52,54,59,72,74,81,82,84,87,88,90,92,93,95,97,101,102,104,108,109,110,112,117,118,119,122,125,127,129,131,133,137,138,141,143,146,147,148,150,154,160,161,163,167,168,170,173,177,178,180,185 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/ext/json/ext/parser/parser.h:3,5,9,15,17,19,23,29,47,54,57,77,81,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/ext/json/ext/parser/parser.c:1,5,11,14,18,20,27,29,46,48,64,65,67,88,90,91,95,101,102,104,105,106,111,113,114,116,117,119,123,126,127,129,130,132,134,135,137,139,143,161,167,173,185,196,212,238,247,257,259,260,273,286,297,313,329,345,371,387,403,419,428,455,458,459,461,469,474,475,476,480,481,482,483,484,489,491,492,494,495,497,499,500,502,504,505,507,509,513,531,543,546,550,559,560,566,570,574,578,582,586,591,592,596,601,602,606,608,612,614,618,620,633,644,660,676,692,834,864,867,868,870,875,876,877,878,883,885,886,888,889,891,893,894,896,898,899,902,904,908,913,953,958,961,962,964,974,975,976,977,982,984,985,987,988,990,994,997,998,1000,1001,1003,1005,1006,1008,1010,1011,1014,1016,1020,1025,1049,1065,1089,1107,1122,1126,1136,1139,1140,1142,1157,1158,1162,1163,1164,1165,1166,1171,1173,1174,1176,1177,1179,1182,1185,1187,1188,1190,1192,1193,1195,1197,1201,1227,1236,1246,1248,1249,1262,1283,1297,1313,1329,1345,1371,1387,1396,1413,1416,1417,1419,1425,1426,1427,1429,1433,1477,1486,1487,1490,1495,1500,1501,1504,1505,1506,1511,1513,1514,1516,1517,1520,1526,1528,1529,1531,1534,1536,1538,1540,1541,1544,1546,1550,1565,1571,1579,1580,1651,1659,1662,1663,1665,1674,1675,1676,1681,1686,1687,1688,1700,1702,1708,1712,1715,1716,1745,1748,1751,1772,1775,1781,1787,1793,1798,1804,1810,1816,1822,1829,1831,1841,1848,1849,1850,1855,1857,1858,1860,1861,1869,1874,1875,1877,1879,1880,1884,1886,1890,1908,1920,1923,1934,1945,1961,1977,1993,2002,2013,2016,2017,2019,2025,2026,2027,2029,2037,2038,2040,2044,2045,2047,2050,2051,2062,2064,2069,2070,2078,2081,2082,2084,2098,2101,2104,2107,2128,2129 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/ext/json/ext/generator/generator.c:3,8,20,26,48,66,74,86,95,103,104,106,109,110,113,115,120,121,126,129,130,134,138,145,149,160,162,186,207,208,209,223,224,226,227,233,241,272,284,291,295,296,298,301,302,307,309,310,317,318,330,340,342,343,354,355,363,365,366,374,376,377,384,386,388,395,397,398,407,408,417,419,420,430,437,438,446,450,451,459,464,465,472,474,475,482,484,485,492,494,495,504,511,512,514,525,526,528,540,541,552,554,558,559,567,580,588,596,604,612,622,623,633,634,643,644,650,651,653,661,662,663,671,686,687,694,700,701,702,709,711,718,720,721,728,731,736,748,752,756,757,758,766,771,774,775,777,786,790,792,798,805,806,807,809,810,812,825,833,834,836,843,844,845,847,848,851,855,857,859,864,870,872,873,875,877,878,880,882,883,885,887,888,890,892,893,895,898,899,902,907,910,921,922,924,925,927,956,957,958,960,964,969,975,979,984,988,989,991,996,997,1006,1011,1012,1034,1042,1043,1051,1053,1058,1069,1070,1079,1087,1088,1089,1096,1099,1100,1107,1117,1122,1124,1125,1133,1136,1137,1145,1155,1160,1162,1163,1170,1173,1174,1181,1191,1196,1198,1199,1207,1210,1211,1219,1228,1233,1235,1236,1243,1246,1247,1254,1263,1268,1270,1271,1272,1280,1283,1284,1292,1295,1296,1304,1308,1309,1317,1320,1321,1329,1332,1333,1340,1343,1344,1352,1357,1358,1365,1368,1369,1377,1384,1386,1387,1392,1395,1399,1404,1436,1468,1499 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/json-2.3.0/ext/json/ext/generator/generator.h:3,6,8,14,18,22,24,26,28,32,38,43,45,48,55,57,78,81,85,90,97,157,161,170 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/simctl-1.6.8/spec/SampleApp/SampleApp/AppDelegate.h:8,10,12,14,15,17 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/simctl-1.6.8/spec/SampleApp/SampleApp/main.m:8,11,13,16,17 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/simctl-1.6.8/spec/SampleApp/SampleApp/AppDelegate.m:8,10,12,14,16 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/terminal-notifier-2.0.0/vendor/terminal-notifier/Terminal Notifier/AppDelegate.h:2 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/terminal-notifier-2.0.0/vendor/terminal-notifier/Terminal Notifier/main.m:2,4,6 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/terminal-notifier-2.0.0/vendor/terminal-notifier/Terminal Notifier/AppDelegate.m:4,7,9,11,13,15,20,21,22,24,27,33,35,36,39,43,45,47,48,50,52,54,58,61,62,64,105,106,108,112,113,115,119,124,125,129,130,135,136,138,144,150,151,155,156,160,161,168,169,170,171,176,177,178,186,194,195,196,199,200,206,207,208,209,211,216,218,219,227,232,233,239,242,248,252,255,256,259,260,263,264,268,269,271,278,279,280,281,283,285,295,296,297,302,303,304,305,306,308,310,315,324,329,331,332,334,339,343,344,345,347,350,357,362,363,367,368,371,373,374,378,380,381 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/snapshot/lib/assets/SnapfileTemplate.swift:2,14,21,22,25,28,31,35,38,41 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/snapshot/lib/assets/SnapshotHelper.swift:7,14,17,20,23,24,30,31,32,38,39,43,50,51,52,53,61,62,64,67,76,77,78,83,84,86,93,94,95,100,101,103,109,110,113,114,117,118,119,124,125,128,135,139,140,141,145,146,148,151,152,157,158,161,165,166,169,175,181,183,184,189,193,194,198,199,210,216,217,218,222,225,227,228,231,233,234,238,241,243,244,245,250,252,253,255,256,260,261,263,266,268,269,271,272,273,277,278,279 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/snapshot/lib/assets/SnapshotHelperXcode8.swift:7,14,17,20,24,25,28,29,32,33,35,40,41,45,46,48,55,56,57,61,62,64,70,73,75,76,80,81,84,91,95,96,97,101,102,104,106,114,115,120,122,126,127,128,137,138,142,143,149,153,157,158,159,165,167,168,169 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/match/lib/assets/MatchfileTemplate.swift:6,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/deliver/lib/assets/DeliverfileDefault.swift:4,7,9,13 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/scan/lib/assets/ScanfileTemplate.swift:3,6,8,13 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/LaneFileProtocol.swift:7,14,16,20,25,26,33,34,38,42,43,46,47,50,51,62,63,65,66,80,81,82,84,85,92,93,94,98,103,104,107,114,116,119,123,124,127,130,135,136,137 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/RubyCommand.swift:7,14,16,19,23,28,29,30,31,35,40,41,44,45,53,54,71,75,76,77,78,84,89,90,93,94,97,99,100,107,108,112,113,117,119,120,126,127,132,138,139,142,146,147,151,152,154,156,157,158 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Fastlane.swift:4,9,11,17,22,23,26,28,30,36,37,40,46,47,50,61,81,92,93,96,106,118,128,129,132,142,155,165,166,169,178,180,190,199,200,203,216,218,232,245,246,249,270,281,282,285,332,380,427,428,431,493,495,561,623,624,627,636,641,642,645,676,692,693,696,706,708,719,729,730,733,739,740,743,756,763,764,767,780,798,811,812,815,822,831,838,839,842,856,858,873,887,888,891,937,939,986,1032,1033,1036,1079,1081,1125,1168,1169,1172,1216,1218,1263,1307,1308,1311,1350,1370,1371,1374,1421,1445,1446,1449,1540,1586,1587,1590,1681,1727,1728,1731,1776,1799,1800,1803,1817,1833,1847,1848,1851,1864,1866,1880,1893,1894,1897,1903,1910,1916,1917,1920,1938,1940,1959,1977,1978,1981,1983,1985,1991,1992,1995,2001,2002,2005,2007,2013,2014,2017,2023,2024,2027,2034,2043,2050,2051,2058,2059,2062,2076,2091,2105,2106,2109,2118,2121,2133,2142,2143,2146,2155,2173,2182,2183,2186,2192,2200,2206,2207,2210,2223,2239,2252,2253,2256,2266,2277,2287,2288,2291,2312,2336,2357,2358,2361,2384,2396,2397,2400,2415,2431,2446,2447,2450,2463,2478,2491,2492,2499,2500,2507,2508,2511,2515,2520,2524,2525,2528,2590,2592,2658,2720,2721,2724,2735,2748,2759,2760,2763,2765,2771,2772,2775,2777,2785,2786,2789,2802,2825,2838,2839,2842,2854,2867,2879,2880,2883,2888,2894,2899,2900,2903,2909,2910,2913,2920,2921,2924,2926,2932,2933,2936,2938,2945,2946,2949,2953,2960,2964,2965,2968,2976,2986,2994,2995,2998,3002,3010,3014,3015,3018,3027,3032,3033,3036,3042,3050,3056,3057,3060,3067,3068,3071,3076,3082,3087,3088,3091,3110,3131,3150,3151,3154,3173,3194,3213,3214,3217,3223,3224,3227,3231,3237,3241,3242,3245,3247,3249,3257,3258,3261,3275,3291,3305,3306,3309,3315,3363,3369,3370,3373,3377,3382,3386,3387,3390,3394,3396,3401,3405,3406,3409,3413,3415,3423,3427,3428,3431,3454,3456,3480,3503,3504,3507,3523,3550,3566,3567,3570,3575,3581,3586,3587,3590,3599,3604,3605,3608,3614,3615,3618,3629,3635,3636,3639,3646,3650,3651,3654,3661,3665,3666,3669,3674,3680,3685,3686,3689,3701,3703,3718,3730,3731,3734,3744,3746,3757,3767,3768,3771,3781,3783,3794,3804,3805,3808,3822,3824,3839,3853,3854,3857,3903,3905,3952,3998,3999,4002,4008,4009,4012,4019,4035,4042,4043,4046,4052,4053,4056,4060,4065,4069,4070,4073,4086,4100,4113,4114,4117,4146,4149,4180,4209,4210,4213,4220,4228,4235,4236,4239,4247,4256,4264,4265,4268,4272,4277,4281,4282,4285,4290,4292,4299,4304,4305,4308,4314,4321,4327,4328,4331,4333,4335,4341,4342,4345,4352,4356,4357,4360,4373,4380,4381,4384,4413,4428,4429,4432,4438,4439,4442,4448,4449,4452,4467,4475,4476,4479,4486,4487,4490,4496,4497,4500,4502,4509,4510,4513,4523,4525,4537,4547,4548,4551,4562,4568,4569,4572,4607,4625,4626,4629,4633,4638,4642,4643,4646,4688,4731,4773,4774,4777,4784,4785,4788,4795,4803,4810,4811,4814,4851,4870,4871,4874,4891,4900,4901,4904,4925,4936,4937,4944,4945,4948,4950,4952,4958,4959,4962,4983,5005,5026,5027,5030,5040,5051,5061,5062,5065,5071,5072,5075,5083,5084,5087,5103,5130,5146,5147,5150,5186,5224,5260,5261,5264,5273,5278,5279,5282,5304,5327,5349,5350,5353,5380,5394,5395,5398,5407,5419,5428,5429,5432,5441,5443,5453,5462,5463,5466,5472,5473,5476,5497,5521,5542,5543,5546,5553,5563,5570,5571,5574,5579,5585,5590,5591,5594,5604,5616,5626,5627,5630,5636,5637,5640,5642,5651,5652,5655,5661,5662,5665,5672,5682,5689,5690,5693,5701,5712,5720,5721,5724,5731,5744,5751,5752,5755,5762,5766,5767,5770,5795,5808,5809,5812,5818,5819,5822,5828,5829,5836,5837,5840,5845,5851,5856,5857,5864,5865,5868,5875,5876,5879,5944,6010,6075,6076,6079,6097,6118,6136,6137,6140,6147,6151,6152,6155,6220,6286,6351,6352,6355,6370,6378,6379,6382,6429,6453,6454,6457,6461,6468,6472,6473,6476,6485,6497,6506,6507,6510,6522,6525,6540,6552,6553,6556,6569,6576,6577,6580,6586,6593,6599,6600,6603,6607,6616,6620,6621,6624,6626,6636,6637,6640,6653,6677,6690,6691,6694,6696,6705,6706,6709,6714,6716,6723,6728,6729,6732,6755,6757,6781,6804,6805,6808,6814,6815,6818,6833,6849,6864,6865,6868,6874,6875,6877,6882,6883,6886,6897,6903,6904,6907,6940,6975,7008,7009,7012,7103,7149,7150,7153,7170,7172,7191,7208,7209,7212,7219,7227,7234,7235,7238,7259,7270,7271,7274,7295,7306,7307,7310,7318,7327,7335,7336,7339,7377,7416,7454,7455,7458,7489,7505,7506,7509,7551,7594,7636,7637,7644,7645,7652,7653,7656,7671,7687,7702,7703,7706,7742,7780,7816,7817,7820,7829,7839,7848,7849,7852,7859,7867,7874,7875,7882,7883,7886,7892,7900,7906,7907,7910,7914,7919,7923,7924,7927,7932,7938,7943,7944,7947,7958,7960,7972,7983,7984,7987,7991,7993,7995,8004,8009,8013,8014,8017,8021,8026,8030,8031,8034,8042,8051,8059,8060,8063,8067,8072,8076,8077,8080,8084,8089,8093,8094,8097,8106,8111,8112,8115,8124,8139,8148,8149,8152,8157,8163,8168,8169,8172,8180,8189,8197,8198,8201,8206,8213,8218,8219,8222,8233,8245,8256,8257,8260,8269,8271,8281,8290,8291,8294,8356,8358,8424,8486,8487,8490,8528,8567,8605,8606,8609,8620,8622,8634,8645,8646,8649,8685,8723,8759,8760,8763,8769,8776,8782,8783,8786,8796,8807,8817,8818,8821,8827,8828,8831,8833,8839,8840,8843,8850,8861,8868,8869,8872,8879,8883,8884,8891,8892,8899,8900,8907,8908,8915,8916,8919,8924,8926,8932,8937,8938,8941,8950,8951,8954,8964,8977,8987,8988,8991,8997,8998,9001,9031,9063,9093,9094,9101,9102,9105,9113,9114,9117,9119,9125,9126,9129,9136,9144,9151,9152,9161,9164,9165,9168,9169,9172,9173,9182,9185,9186,9190,9191,9195,9196,9204 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Fastfile.swift:5,7,9 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/ControlCommand.swift:6,13,15,19,22,27,34,35,36,37,40,47,48,49,50,56,59,62,63,67,68,72,73,74 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/ScanfileProtocol.swift:4,7,10,13,16,19,22,25,28,31,34,37,40,43,46,49,52,55,58,61,64,67,70,73,76,79,82,85,88,91,94,97,100,103,106,109,112,115,118,121,124,127,130,133,136,139,142,145,148,151,154,157,160,163,166,169,172,175,178,181,184,187,190,191,256,257 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Snapshotfile.swift:2,10,15,16 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Runner.swift:7,14,16,20,24,27,28,37,42,52,53,58,59,60,67,70,71,73,74,75,86,91,93,98,99,100,101,106,108,113,114,117,120,126,127,128,133,136,137,141,142,145,146,154,155,156,157,168,171,172,180,187,191,192,193,197,198,199,204,211,213,214,215,216,228,229,230,233,234,236,240,241,246,247,248,249,252,253,256,257,272,274,275,276 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/ScreengrabfileProtocol.swift:4,7,10,13,16,19,22,25,28,31,34,37,40,43,46,49,52,55,58,61,64,67,68,92,93 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/RubyCommandable.swift:7,14,16,20,27,28,29,30,35,36,42,43,44 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Plugins.swift:2,10,12 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/GymfileProtocol.swift:4,7,10,13,16,19,22,25,28,31,34,37,40,43,46,49,52,55,58,61,64,67,70,73,76,79,82,85,88,91,94,97,100,103,106,109,112,115,118,121,124,127,130,133,134,180,181 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/SocketResponse.swift:7,14,16,23,28,29,36,40,45,46,49,51,52,53,55,60,61,65,66,68,69,70,78,79,81,82,83 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/SnapshotfileProtocol.swift:4,7,10,13,16,19,22,25,28,31,34,37,40,43,46,49,52,55,58,61,64,67,70,73,76,79,82,85,88,91,94,97,100,103,106,109,112,115,118,121,124,127,130,133,134,180,181 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/ArgumentProcessor.swift:7,14,16,22,27,29,32,33,36,37,39,44,45,48,50,55,56,59,63,64,68,69,75,76,77,82,86,88,89,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Scanfile.swift:2,10,15,16 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Gymfile.swift:2,10,15,16 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/DeliverfileProtocol.swift:4,7,10,13,16,19,22,25,28,31,34,37,40,43,46,49,52,55,58,61,64,67,70,73,76,79,82,85,88,91,94,97,100,103,106,109,112,115,118,121,124,127,130,133,136,139,142,145,148,151,154,157,160,163,166,169,172,175,178,181,182,244,245 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/PrecheckfileProtocol.swift:4,7,10,13,16,19,22,23,32,33 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/SocketClientDelegateProtocol.swift:7,14,16,21,22 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/RunnerArgument.swift:7,14,16,20,21 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Precheckfile.swift:2,10,15,16 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Appfile.swift:5,8,11,14 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/main.swift:7,14,16,19,23,26,30,31,33,34,39,40,41,44,47,48 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Deliverfile.swift:2,10,15,16 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/MatchfileProtocol.swift:4,7,10,13,16,19,22,25,28,31,34,37,40,43,46,49,52,55,58,61,64,67,70,73,76,79,82,85,88,91,94,97,100,103,106,109,112,115,118,121,122,164,165 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Screengrabfile.swift:2,10,15,16 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Matchfile.swift:2,10,15,16 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/Actions.swift:2,10,12 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/swift/SocketClient.swift:7,14,17,27,28,33,34,39,47,53,55,57,59,71,72,76,79,82,85,88,89,93,94,98,99,102,105,107,111,112,115,116,121,122,125,126,133,136,138,139,140,143,144,147,148,152,153,163,165,166,167,174,175,178,179,181,182,185,187,190,191,194,195,198,199,203,204,205,214,215,220,224,227,231,235,238,239,244,248,252,256,259,260,261,262,273,277,278,281,282,283,288,289,295,297,298,307,308,313,314,319,320,324,325,326,327,328 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/lib/assets/DefaultFastfileTemplate.swift:8,10,13 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/fastlane/lib/assets/AppfileTemplate.swift:3,5 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/gym/lib/assets/GymfileTemplate.swift:3,6,8,13 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/precheck/lib/assets/PrecheckfileTemplate.swift:3,6,9,10,14,17 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.155.3/screengrab/lib/assets/ScreengrabfileTemplate.swift:2,5,12,15 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/snapshot/lib/assets/SnapfileTemplate.swift:2,14,21,22,25,28,31,35,38,41 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/snapshot/lib/assets/SnapshotHelper.swift:7,14,17,20,23,24,30,31,32,38,39,43,50,51,52,53,61,62,64,67,76,77,78,83,84,86,93,94,95,100,101,103,109,110,113,114,117,118,119,124,125,128,135,139,140,141,145,146,148,151,152,157,158,161,165,166,169,175,181,183,184,189,193,194,198,199,210,216,217,218,222,225,227,228,231,233,234,238,241,243,244,245,250,252,253,255,256,260,261,263,266,268,269,271,272,273,277,278,279 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/snapshot/lib/assets/SnapshotHelperXcode8.swift:7,14,17,20,24,25,28,29,32,33,35,40,41,45,46,48,55,56,57,61,62,64,70,73,75,76,80,81,84,91,95,96,97,101,102,104,106,114,115,120,122,126,127,128,137,138,142,143,149,153,157,158,159,165,167,168,169 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/match/lib/assets/MatchfileTemplate.swift:6,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/deliver/lib/assets/DeliverfileDefault.swift:4,7,9,13 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/scan/lib/assets/ScanfileTemplate.swift:3,6,8,13 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/LaneFileProtocol.swift:7,14,16,20,26,27,35,36,40,45,46,49,50,53,54,65,66,68,69,83,84,85,87,88,95,96,97,101,106,107,110,117,119,122,126,127,130,133,138,139,140 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/RubyCommand.swift:7,14,16,19,23,28,29,30,31,35,40,41,44,45,54,55,72,76,77,78,79,80,85,92,93,97,98,102,103,106,107,112,118,119,122,126,127,131,132,134,136,137,138 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Fastlane.swift:4,9,11,21,22,25,27,29,35,36,39,45,46,49,60,90,91,94,104,125,126,129,139,161,162,165,174,176,194,195,198,211,213,239,240,243,274,275,278,325,419,420,423,485,487,614,615,618,631,632,635,681,682,685,695,697,717,718,721,727,728,731,750,751,754,767,797,798,801,808,823,824,827,841,843,871,872,875,921,923,1015,1016,1019,1062,1064,1150,1151,1154,1198,1200,1288,1289,1292,1350,1351,1354,1424,1425,1428,1558,1559,1562,1692,1693,1696,1760,1761,1764,1778,1807,1808,1811,1824,1826,1852,1853,1856,1862,1874,1875,1878,1896,1898,1934,1935,1938,1940,1942,1948,1949,1952,1958,1959,1962,1964,1970,1971,1974,1980,1981,1984,1991,2006,2007,2014,2015,2018,2032,2060,2061,2064,2073,2076,2096,2097,2100,2109,2135,2136,2139,2145,2158,2159,2162,2175,2203,2204,2207,2217,2237,2238,2241,2262,2306,2307,2310,2344,2345,2348,2363,2393,2394,2397,2410,2437,2438,2445,2446,2453,2454,2457,2461,2469,2470,2473,2535,2537,2664,2665,2668,2679,2702,2703,2706,2708,2714,2715,2718,2720,2728,2729,2732,2745,2780,2781,2784,2796,2820,2821,2824,2829,2839,2840,2843,2849,2850,2853,2860,2861,2864,2866,2872,2873,2876,2878,2885,2886,2889,2893,2903,2904,2907,2915,2932,2933,2936,2940,2951,2952,2955,2968,2969,2972,2977,2988,2989,2992,2999,3000,3003,3008,3018,3019,3022,3041,3080,3081,3084,3103,3142,3143,3146,3152,3153,3156,3160,3169,3170,3173,3175,3177,3185,3186,3189,3203,3232,3233,3236,3242,3295,3296,3299,3303,3311,3312,3315,3319,3321,3329,3330,3333,3337,3339,3350,3351,3354,3377,3379,3425,3426,3429,3445,3487,3488,3491,3496,3506,3507,3510,3523,3524,3527,3533,3534,3537,3553,3554,3557,3563,3564,3567,3577,3578,3581,3586,3596,3597,3600,3612,3614,3640,3641,3644,3654,3656,3676,3677,3680,3694,3696,3724,3725,3728,3774,3776,3868,3869,3872,3878,3879,3882,3889,3911,3912,3915,3921,3922,3925,3929,3937,3938,3941,3954,3980,3981,3984,4013,4016,4075,4076,4079,4086,4100,4101,4104,4112,4128,4129,4132,4136,4144,4145,4148,4153,4155,4166,4167,4170,4176,4188,4189,4192,4194,4196,4202,4203,4206,4216,4217,4220,4239,4240,4243,4286,4287,4290,4296,4297,4300,4306,4307,4310,4332,4333,4336,4343,4344,4347,4353,4354,4357,4359,4366,4367,4370,4380,4382,4403,4404,4407,4423,4424,4427,4479,4480,4483,4487,4495,4496,4499,4538,4616,4617,4620,4627,4628,4631,4638,4652,4653,4656,4711,4712,4715,4740,4741,4744,4775,4776,4783,4784,4787,4789,4791,4797,4798,4801,4822,4864,4865,4868,4878,4898,4899,4902,4908,4909,4912,4920,4921,4924,4940,4982,4983,4986,5021,5092,5093,5096,5109,5110,5113,5135,5179,5180,5183,5220,5221,5224,5233,5253,5254,5257,5266,5268,5286,5287,5290,5296,5297,5300,5321,5365,5366,5369,5376,5392,5393,5396,5401,5411,5412,5415,5425,5446,5447,5450,5456,5457,5460,5462,5471,5472,5475,5481,5482,5485,5492,5508,5509,5512,5520,5538,5539,5542,5549,5568,5569,5572,5582,5583,5586,5623,5624,5627,5633,5634,5637,5643,5644,5651,5652,5655,5660,5670,5671,5678,5679,5682,5689,5690,5693,5758,5888,5889,5892,5910,5948,5949,5952,5962,5963,5966,6031,6161,6162,6165,6187,6188,6191,6261,6262,6265,6269,6279,6280,6283,6292,6312,6313,6316,6328,6331,6357,6358,6361,6380,6381,6384,6390,6402,6403,6406,6410,6422,6423,6426,6428,6438,6439,6442,6455,6491,6492,6495,6497,6506,6507,6510,6515,6517,6528,6529,6532,6555,6557,6603,6604,6607,6613,6614,6617,6632,6662,6663,6666,6672,6673,6675,6680,6681,6684,6700,6701,6704,6736,6801,6802,6805,6935,6936,6939,6956,6958,6993,6994,6997,7004,7018,7019,7022,7053,7054,7057,7085,7086,7089,7097,7113,7114,7117,7154,7228,7229,7232,7278,7279,7282,7321,7399,7400,7407,7408,7415,7416,7419,7434,7464,7465,7468,7503,7574,7575,7578,7587,7605,7606,7609,7616,7630,7631,7638,7639,7642,7648,7661,7662,7665,7669,7677,7678,7681,7686,7696,7697,7700,7711,7713,7735,7736,7739,7743,7745,7747,7756,7764,7765,7768,7772,7780,7781,7784,7792,7808,7809,7812,7816,7824,7825,7828,7832,7840,7841,7844,7857,7858,7861,7870,7893,7894,7897,7902,7912,7913,7916,7924,7940,7941,7944,7949,7960,7961,7964,7974,7994,7995,7998,8007,8009,8027,8028,8031,8093,8095,8222,8223,8226,8263,8337,8338,8341,8352,8354,8376,8377,8380,8415,8486,8487,8490,8496,8508,8509,8512,8522,8542,8543,8546,8552,8553,8556,8558,8564,8565,8568,8575,8592,8593,8596,8606,8607,8614,8615,8622,8623,8630,8631,8638,8639,8642,8647,8649,8659,8660,8663,8672,8673,8676,8686,8708,8709,8712,8718,8719,8722,8752,8813,8814,8821,8822,8825,8833,8834,8837,8839,8845,8846,8849,8856,8870,8871,8872,8881,8884,8885,8888,8889,8892,8893,8902,8905,8906,8910,8911,8915,8916,8924 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Fastfile.swift:5,7,9 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/ControlCommand.swift:6,13,15,19,22,27,34,35,36,37,40,47,48,49,50,55,58,61,62,66,67,71,72,73 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/ScanfileProtocol.swift:2,5,8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,56,59,62,65,68,71,74,77,80,83,86,89,92,95,98,101,104,107,110,113,116,119,122,125,128,131,134,137,140,143,146,149,152,155,158,161,164,167,170,173,176,179,182,185,188,191,192,257,258 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Snapshotfile.swift:2,10,15,16,17,18,19,20 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Runner.swift:7,14,16,20,24,27,28,36,41,50,51,56,57,58,59,64,66,71,74,80,81,82,87,90,91,95,96,99,100,108,109,110,111,121,122,127,131,134,135,136,140,141,142,151,153,154,155,156,168,169,172,173,175,179,180,185,186,187,188,191,192,195,196,200 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/ScreengrabfileProtocol.swift:2,5,8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,56,59,62,65,68,69,93,94 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/RubyCommandable.swift:7,14,16,20,27,28,29,30,34,35,39,40,41 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Plugins.swift:2,10,12 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/GymfileProtocol.swift:2,5,8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,56,59,62,65,68,71,74,77,80,83,86,89,92,95,98,101,104,107,110,113,116,119,122,125,128,131,134,135,181,182 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/SocketResponse.swift:7,14,16,23,28,29,35,39,44,45,48,50,51,52,54,59,60,64,65,67,68,69,77,78,80,81,82 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/SnapshotfileProtocol.swift:2,5,8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,56,59,62,65,68,71,74,77,80,83,86,89,92,95,98,101,104,107,110,113,116,119,122,125,128,129,173,174 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/ArgumentProcessor.swift:7,14,16,22,27,29,32,33,36,37,39,44,45,48,50,55,56,59,63,64,68,69,75,76,77,82,86,88,89,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Scanfile.swift:2,10,15,16,17,18,19,20 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Gymfile.swift:2,10,15,16,17,18,19,20 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/DeliverfileProtocol.swift:2,5,8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,56,59,62,65,68,71,74,77,80,83,86,89,92,95,98,101,104,107,110,113,116,119,122,125,128,131,134,137,140,143,146,149,152,155,158,161,164,167,170,173,176,179,182,183,245,246 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/PrecheckfileProtocol.swift:2,5,8,11,14,17,20,23,24,33,34 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/SocketClientDelegateProtocol.swift:7,14,16,21,22 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/RunnerArgument.swift:7,14,16,20,21 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Precheckfile.swift:2,10,15,16,17,18,19,20 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Appfile.swift:5,8,11,14 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/main.swift:7,14,16,19,23,26,30,31,33,34,39,40,41,44,47,48,52 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Deliverfile.swift:2,10,15,16,17,18,19,20 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/MatchfileProtocol.swift:2,5,8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,56,59,62,65,68,71,74,77,80,83,86,89,92,95,98,101,104,107,110,113,114,153,154 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Screengrabfile.swift:2,10,15,16,17,18,19,20 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Matchfile.swift:2,10,15,16,17,18,19,20 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/Actions.swift:2,10,12 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/swift/SocketClient.swift:7,14,16,26,27,29,33,34,39,45,49,51,53,55,65,66,70,73,76,79,82,83,87,88,92,93,96,99,101,105,106,109,110,114,115,118,119,126,129,131,132,133,136,137,140,141,146,147,148,152,157,159,160,167,168,171,172,174,175,178,180,183,184,187,188,189,198,199,204,208,211,215,219,222,223,228,233,237,241,244,245,246,247,257,258,259,261,262,267,268,273,275,276,284,288,292,297,298,300,301,302 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/lib/assets/DefaultFastfileTemplate.swift:8,10,13 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/fastlane/lib/assets/AppfileTemplate.swift:3,5 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/gym/lib/assets/GymfileTemplate.swift:3,6,8,13 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/precheck/lib/assets/PrecheckfileTemplate.swift:3,6,9,10,14,17 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/fastlane-2.149.1/screengrab/lib/assets/ScreengrabfileTemplate.swift:2,5,12,15 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/xcpretty-0.3.0/spec/fixtures/NSStringTests.m:8,11,13,15,17,20,22,24,26,30,34,38,42,44,48,53,55,59,61,62,63 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Type.h:33,36,39,43,45,47,52,55,57,59,61 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/rbffi_endian.h:3,7,9,22,35,47,53,57,59 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/MappedType.h:29,32,33,35,39,40,46,48,50,52,53,55,57,59 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Thread.c:29,37,50,59,61,64,71,72,75,78,87,88,91,97,98,101,104,107,108,111,113,115,117,118,121,123,125,128,134 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Buffer.c:30,43,47,54,60,62,65,68,72,74,75,78,82,83,85,86,98,102,104,108,114,115,118,121,122,126,127,130,131,133,134,142,145,150,155,156,160,163,165,166,169,171,172,175,179,182,189,191,192,201,204,206,208,209,219,221,222,230,233,235,237,239,240,241,247,260,262,270,273,278,281,282,286,290,291,293,294,295,299,301,306,307,309,310,313,315,316,319,321,328,334,356,364,365 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Types.h:30,33,37,61,64,67,70,73,77,80,83,85,87,89 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/LastError.h:29,32,36,37,39,41,43,45,47 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/ArrayType.h:29,32,36,40,41,49,52,53,55,57,59 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/DynamicLibrary.c:29,47,49,55,61,64,65,69,71,83,86,89,90,101,103,104,115,118,120,123,131,139,143,144,147,151,154,156,157,164,168,169,172,177,180,181,185,191,192,193,196,199,201,204,210,212,213,214,223,226,227,230,233,240,242,243,246,249,250,258,261,266,267,270,284,317,322,337,338,339 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Variadic.c:29,34,44,48,57,62,69,70,75,77,78,81,84,89,91,92,95,99,100,103,112,115,121,129,134,135,137,139,145,149,153,154,160,162,163,166,179,182,191,194,197,199,213,218,221,222,223,227,229,230,234,235,238,253,254,257,259,269,273,274,276,278,281,282,284,285,286,289,292,294,297,298 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/StructByValue.h:29,32,35,39,45,47,49,51,53,55 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/AbstractMemory.h:29,32,40,43,47,48,54,56,61,80,87,88,91,93,95,97,100,104,105,106,109,112,113,114,117,120,121,122,125,161,162,163,167,168,169,171,173,175 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/ffi.c:30,34,36,53,55,57,59,62,70,72,75,93 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/ClosurePool.h:28,31,34,42,44,48,50,53,55,57 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Pointer.c:29,43,45,48,51,54,57,60,61,68,70,71,74,77,81,83,84,98,102,104,115,116,124,126,130,136,138,139,141,143,144,157,160,166,167,171,172,176,177,182,183,189,192,194,195,198,202,205,207,213,215,216,226,229,231,233,234,245,247,248,256,259,261,267,268,270,271,280,282,284,286,287,296,298,300,303,304,306,307,315,317,319,321,322,328,340,342,350,353,358,361,362,366,370,371,373,374,375,376,384,386,388,393,395,398,400,401,403,404,407,409,411,413,414,423,425,428,430,431,439,441,443,445,446,447,450,454,456,457,460,462,463,466,469,484,501,507,508 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/MemoryPointer.c:30,44,45,50,52,54,57,59,60,63,68,70,71,82,85,88,91,92,94,95,98,101,103,105,110,117,120,121,123,124,127,129,131,136,138,139,141,142,145,149,151,152,161,166,168,169,172,174,176,192,196,197 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Call.h:32,35,37,41,47,51,73,75,79,82,84,86,89,98,101,103,105,107 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Platform.c:29,45,49,51,54,70,71,74,83 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/LongDouble.c:5,9,13,16,20,21,25,26,29,30,33,36,37,40,41,47,48,51,52,53,56,59,60,63,65 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/MethodHandle.h:29,32,36,39,40,44,45,50,52,54,56 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Function.c:29,38,51,57,60,74,84,93,95,96,101,104,106,110,112,129,130,141,142,145,148,150,156,158,159,162,166,167,170,173,174,177,178,180,181,198,199,204,206,215,225,226,231,233,235,236,244,247,248,251,253,254,257,260,267,268,269,273,274,285,286,288,289,292,294,296,298,300,306,312,313,314,318,320,326,330,331,333,335,336,345,347,349,351,352,362,365,367,371,372,376,377,380,381,387,390,391,394,396,397,406,408,410,412,414,415,418,420,422,424,425,433,435,437,440,441,444,446,447,450,452,458,460,466,470,473,479,482,487,491,495,497,504,506,511,512,513,519,522,525,527,534,535,536,538,539,543,545,547,549,554,555,559,560,562,564,565,568,570,575,576,580,582,584,586,589,590,594,595,597,599,600,603,605,610,612,615,617,619,629,631,632,634,637,640,641,644,646,656,662,666,667,717,723,727,728,733,734,736,737,739,745,746,787,789,793,797,799,802,804,808,810,814,817,820,821,824,826,830,831,833,834,837,839,842,844,845,848,851,856,857,859,860,863,869,872,892,902 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Struct.h:30,33,38,42,48,52,54,58,61,64,72,78,83,86,91,96,100,106,108,110,112 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/rbffi.h:29,32,34,38,40,42,50,52,54 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Thread.h:29,32,41,45,46,52,63,71,75,77,79,81 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/MappedType.c:29,31,34,37,38,43,45,48,50,52,58,60,61,70,72,75,76,79,80,83,84,89,90,94,96,97,100,103,104,112,115,117,118,125,127,129,131,132,139,141,143,145,146,149,154,156,160,167,168 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Type.c:29,33,41,42,47,49,51,56,59,62,65,67,68,77,80,82,91,92,94,95,103,105,107,109,110,118,120,122,124,125,133,136,138,141,143,144,147,150,152,156,158,159,162,165,166,174,177,181,183,184,187,189,192,203,206,207,208,211,214,215,216,219,228,230,232,233,236,237,240,249,260,304,311,317,321,324,332,337,347,378,379 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Types.c:31,42,44,45,48,62,73,78,81,88,94,95,100,105,107,108,116,119,120,124,126,127,131,132,133,136,138,139 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/compat.h:29,32,34,38,42,46,50,54,58,66,70,77,81 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/StructLayout.c:30,32,54,56,60,65,67,68,71,74,78,80,81,84,87,88,99,103,105,107,111,112,114,118,119,126,133,140,141,143,144,152,156,157,165,169,170,178,182,183,191,194,196,197,205,209,210,219,221,226,227,229,230,240,242,247,248,250,252,253,262,264,266,268,269,281,284,286,293,294,296,298,299,302,305,306,315,319,322,325,328,329,339,342,343,346,349,352,359,366,369,370,377,378,381,384,385,387,391,395,396,400,403,404,407,411,412,414,415,416,419,422,431,433,434,445,449,463,470,471,474,476,479,482,483,487,488,491,492,493,498,499,502,503,505,506,515,521,523,528,529,533,534,539,542,543,545,546,549,551,553,555,556,564,566,568,570,571,579,581,583,585,586,594,596,598,600,601,604,612,613,616,621,622,623,626,628,636,643,650,657,664,671,678,688,691,694,702,703,704 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/DynamicLibrary.h:28,31,35,40,44,48,52,57,61,65,69,73,78,82,86,90,92,94,96,98 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/ArrayType.c:29,33,38,40,43,46,48,55,57,58,61,63,64,67,71,72,73,83,86,88,92,97,100,101,103,104,112,114,116,118,119,127,129,131,133,134,137,139,141,156,161,162 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/win32/stdbool.h:3,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/win32/stdint.h:8,15,21,25,29,33,37,41,50,59,62,65,68,71,76,83,87,94,98,105,110,116,120,124,132,135,143,146,149,153,157,161,165,173,177,180,185,187,190,196 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/LastError.c:30,44,46,51,57,64,68,70,72,75,77,79,81,82,83,86,89,90,93,95,96,99,102,105,108,110,111,114,116,119,120,122,123,125,126,134,136,137,146,148,150,151,160,161,167,169,170,180,183,185,186,189,196,201,203,204,207,214,217,222,228,229 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Struct.c:30,53,57,65,66,73,75,78,81,84,86,87,90,93,96,98,99,109,113,115,117,123,124,127,128,130,136,137,139,140,148,151,156,157,160,173,174,178,179,181,182,185,189,190,194,195,197,198,201,205,206,210,211,213,214,217,220,223,224,227,228,230,231,234,237,240,241,243,244,247,252,253,254,257,260,261,262,265,269,275,276,277,279,280,281,284,287,294,298,299,301,302,310,313,315,319,322,327,328,329,339,342,344,348,350,352,360,361,364,365,367,368,377,381,386,387,388,392,396,397,401,403,404,412,414,416,418,419,428,431,436,437,440,442,443,451,453,455,457,458,466,468,470,472,473,479,481,485,490,492,493,494,497,500,504,506,507,510,513,514,524,526,530,535,539,540,542,544,545,553,555,557,559,560,563,566,567,569,570,578,580,582,591,592,597,600,603,604,605,614,616,618,623,626,630,634,635,638,642,644,648,651,652,654,655,662,664,666,668,671,672,674,675,683,687,690,691,694,695,697,698,707,710,712,716,717,720,722,723,731,733,735,738,739,740,743,745,747,767,773,780,781,786,793,796,799,803,813,816,824,825 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Platform.h:29,32,36,38,39,41,43,45 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Call.c:31,65,70,80,82,88,91,93,98,102,108,109,110,112,116,117,122,123,126,128,135,136,140,145,148,149,153,158,161,162,166,170,174,181,182,186,193,194,198,205,206,210,217,218,222,229,230,234,241,242,246,253,254,258,265,266,270,277,278,282,289,290,294,295,299,302,303,307,315,316,324,327,331,334,335,336,337,340,343,345,346,349,351,353,354,357,361,362,365,371,373,376,387,391,395,397,400,404,408,409,412,413,416,417,420,422,423,426,428,430,432,435,437,439,441,443,445,449,451,452,455,456,459,461,462,463,466,470,471,477,478,481,483,484,485,488,492,493 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Function.h:29,32,36,42,44,46,50,55,74,76,81,83,85,87 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/MethodHandle.c:28,52,56,64,65,67,71,79,80,81,84,88,89,93,95,96,99,105,106,111,113,114,117,120,121,122,124,126,127,130,132,134,137,139,148,149,151,152,153,156,158,159,166,169,177,179,180,182,183,184,187,189,192,217,220,223,226,228,229,231,235,262,265,268,269,271,275,277,280,285,286,287,289,290,293,297,298,302,303,305,306,309,314,316,317,320,322,323,325,326,329,333,335,339,344,349,350,352 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/LongDouble.h:29,32,34,38,41,43,45,47 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/AbstractMemory.c:31,41,44,51,60,65,68,73,75,77,133,179,180,185,187,188,191,193,194,201,211,214,216,217,220,222,223,226,228,229,232,234,235,242,250,264,267,282,283,284,286,289,291,292,295,297,298,300,301,309,313,314,322,324,326,328,329,340,344,347,350,353,355,360,361,362,372,376,379,382,385,388,393,394,395,407,413,418,422,423,435,440,445,448,451,453,457,458,465,467,468,469,471,472,482,485,489,490,492,493,494,507,510,514,517,520,522,523,535,538,541,544,546,547,563,568,570,576,581,582,585,587,589,590,600,602,603,615,618,622,623,625,626,634,636,638,640,641,651,654,656,658,660,661,664,666,667,670,672,674,676,678,679,682,687,688,691,692,695,703,704,705,708,710,715,716,718,719,722,724,725,727,728,747,750,786,790,791,810,816,834,839,1082,1090,1093,1100,1104,1105 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/MemoryPointer.h:30,33,40,44,49,51,53 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/include/ffi_common.h:5,9,12,16,18,49,58,62,67,76,81,86,87,92,101,105,108,113,140,142,148,150,152 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/include/ffi_cfi.h:3,6,9,11,31,33,53 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/err_bad_typedef.c:6,8,10,12,15,17,19,21,24,26 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float3.c:6,8,11,13,15,17,18,20,22,23,25,30,34,41,45,49,51,53,55,62,66,68,70,72,74 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/strlen4.c:6,8,10,12,14,15,17,31,35,41,47,53,55 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/many2.c:6,8,10,12,14,21,23,24,28,30,31,34,41,44,47,49,52,54,57 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_fl3.c:6,9,11,13,15,29,37,42 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct5.c:6,10,14,16,19,21,22,24,30,32,36,44,49,52,57,59,62,63,66 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct1.c:6,9,11,16,18,22,24,25,27,33,35,39,48,51,55,59,61,64,67 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct10.c:6,9,12,18,25,26,37,42,46,49,52,57 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/align_stdcall.c:6,8,10,15,17,18,20,32,36,38,40,46 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/align_mixed.c:6,8,10,15,17,18,20,32,36,38,40,46 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/ffitest.h:7,11,15,17,19,34,39,44,53,55,57,63,65,74,88,93,115,124,135 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/strlen3.c:6,8,10,12,14,15,17,28,32,37,42,47,49 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/va_struct3.c:6,9,12,14,18,20,27,30,35,48,49,52,56,59,62,66,69,74,78,83,90,96,98,101,107,110,112,118,123,125 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float4.c:6,9,12,14,18,20,22,24,25,27,34,37,41,43,47,49,53,55,59,61,62 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct6.c:6,10,14,16,19,21,22,24,30,32,36,44,47,50,53,56,58,61,64 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_uc.c:6,9,11,13,14,16,21,23,26,30,33,36,38 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/strlen.c:6,9,11,13,14,16,22,25,29,33,37,41,43,44 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/pyobjc-tc.c:6,9,14,19,24,26,30,31,32,34,42,46,54,62,70,80,85,86,87,89,90,97,104,107,109,111,112,114 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_sl.c:6,10,12,13,15,21,26,29,32,36,38 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct8.c:6,10,16,18,23,25,26,28,34,36,40,50,53,56,61,66,68,73,78,81 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct2.c:6,9,11,15,17,20,22,23,25,32,36,44,47,50,53,56,58,61,64,67 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_ll1.c:6,11,13,14,16,23,30,34,38,43 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_ldl.c:7,9,11,13,15,20,23,27,29,32,34 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float1.c:6,10,12,14,18,20,22,24,25,27,34,37,41,43,47,49,51,53,57,59,60 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_ll.c:6,10,12,13,15,21,24,28,30,33,34,36,39,41 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_dbl.c:6,9,11,14,16,21,24,28,30,34,36 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_dbl2.c:6,9,11,13,15,29,37,42 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/many.c:6,9,13,15,22,24,25,27,34,36,40,41,45,47,54,59 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/many_mixed.c:6,9,13,33,35,36,38,46,48,53,58,59,60,64,66,78 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/va_struct2.c:6,9,12,14,18,20,27,30,35,46,47,50,54,57,60,64,67,72,76,81,88,94,96,99,105,108,110,116,121,123 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/strlen2.c:6,8,10,12,14,15,17,28,32,37,42,47,49 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/offsets.c:6,10,12,18,21,25,31,36,44,46 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct7.c:6,10,15,17,21,23,24,26,32,34,38,47,50,53,57,61,63,67,71,74 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/negint.c:6,8,10,12,13,15,16,18,23,27,34,38,42,44,46,48,50,52 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_sc.c:6,9,11,13,15,21,24,28,31,34,36 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float_va.c:6,9,11,13,15,20,24,27,29,32,36,38,40,42,43,45,47,53,62,68,77,84,92,105,107 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/pr1172638.c:5,8,13,20,25,27,32,34,35,37,44,49,53,61,71,80,83,109,120,122,124,127 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_fl1.c:6,9,11,13,15,20,25,31,36 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float.c:6,8,10,12,14,16,18,19,21,26,31,40,44,49,51,53,55,57,59 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct3.c:6,9,11,14,16,18,20,21,23,30,34,41,44,48,51,53,55,57,60 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_ul.c:6,10,12,13,15,21,26,29,32,36,38 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct9.c:6,9,11,15,17,20,22,23,25,31,33,37,45,48,51,54,57,59,62,65,68 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_fl.c:6,9,11,13,15,20,23,27,29,33,35 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/va_1.c:6,9,12,14,18,20,27,30,45,50,53,56,59,62,66,77,78,81,85,88,91,95,98,109,114,118,123,130,146,148,151,157,160,162,173,189,194,196 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float2.c:7,10,12,14,16,17,19,26,29,33,35,42,45,52,59,61 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/va_struct1.c:6,9,12,14,18,20,27,30,35,44,45,48,52,55,58,62,65,70,74,79,86,92,94,97,103,106,108,114,119,121 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_dbl1.c:6,9,11,13,15,30,38,43 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_fl2.c:6,9,12,14,17,19,25,34,42,45,49 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/promotion.c:6,11,13,15,16,18,28,37,41,44,51,56,59 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct4.c:6,9,11,16,18,20,22,23,25,31,33,37,46,49,52,56,58,60,61,64 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/uninitialized.c:3,5,10,12,16,18,19,21,27,37,42,45,49,53,55,58,61 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/many_double.c:6,9,13,27,34,36,37,39,46,48,52,53,57,59,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex_float.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1_float.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex_double.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va_longdouble.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2_longdouble.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/complex_float.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1_double.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct_longdouble.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex_longdouble.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct_double.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2_float.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va_double.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_float.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/complex_int.c:6,8,12,14,19,20,41,42,48,50,54,60,67,71,76,84,86 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex_float.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex_longdouble.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct_float.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex_double.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/complex_double.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/complex_longdouble.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_longdouble.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex_float.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va_float.c:6,8,14 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex_double.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_double.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex_longdouble.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2_double.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1_longdouble.c:6,8 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct9.c:8,11,16,21,26,28,30,34,38,40,41,45,49,53,55,56,58,68,72,74,79,84,89,93,97,101,102,107,110,115,121,123,129,131 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_struct_va1.c:6,10,12,16,18,25,29,34,39,40,43,48,50,53,56,60,62,67,71,76,83,89,92,96,99,105,107,112,114 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_4byte.c:7,9,11,16,19,21,24,26,28,29,33,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_uint32.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_20byte.c:7,10,16,19,21,25,29,30,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_3float.c:7,9,11,17,20,22,26,29,31,32,36,38,41,43,44,46,54,58,63,68,72,75,79,84,87,93,95 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct3.c:8,11,16,21,23,25,29,33,35,36,40,43,46,48,49,51,60,63,65,70,75,79,83,84,88,91,95,101,102,104,111 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_7_1_byte.c:7,10,20,23,25,33,38,40,41,45,46,48,51,53,54,56,64,68,73,82,86,89,93,99,107,109,115,117 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/err_bad_abi.c:6,8,10,15,17,22,24,27,30,32,34,36 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_6_1_byte.c:7,10,19,22,24,31,36,38,39,43,44,46,49,51,52,54,62,66,71,79,83,86,90,96,103,105,111,113 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ulong_va.c:6,8,10,12,15,17,19,20,22,24,30,34,38,45 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ushort.c:6,9,12,14,17,19,21,27,30,34,36,41,43 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_4_1byte.c:8,11,18,21,23,28,32,34,35,39,40,42,45,47,48,50,58,62,67,73,77,80,84,89,91,96,98 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct7.c:8,11,16,21,23,25,29,33,35,36,40,43,46,48,49,51,60,63,65,70,75,79,83,84,88,91,95,101,103,109,111 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_schar.c:6,7,8,11,14,18,20,22,28,31,35,37,42,44 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_6byte.c:7,8,11,18,21,23,28,32,34,35,39,40,42,45,47,48,50,58,62,67,73,77,80,84,89,91,96,97,99 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_sint.c:6,9,12,16,18,20,26,29,33,35,40,42 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_2byte.c:8,11,16,19,21,24,26,28,29,33,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn2.c:8,11,14,24,35,36,40,42,48,66,70,73,81 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn6.c:7,10,14,27,40,41,42,49,51,57,75,79,82,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_sshortchar.c:6,9,12,14,16,18,20,21,22,25,28,33,35,36,37,40,42,51,56,62,68,72,77,79,84,86 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_float.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct.c:7,10,16,22,27,31,33,40,48,50,51,55,59,63,64,66,67,69,79,85,90,95,100,105,110,114,115,120,123,128,137,139,152 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_24byte.c:7,10,17,22,24,29,36,38,39,43,45,50,52,53,55,63,69,74,80,86,89,95,100,102,111,113 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uchar.c:6,9,12,16,18,20,26,29,33,35,40,42 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_19byte.c:7,10,18,21,23,29,30,36,37,41,43,46,48,49,51,59,63,68,75,79,82,86,92,94,100,102 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct10.c:8,11,16,22,27,29,31,36,40,42,43,47,51,55,57,58,60,70,74,76,81,86,91,95,100,104,105,110,113,118,124,126,132,134 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_7byte.c:7,10,17,20,22,27,31,33,34,38,39,41,44,46,47,49,57,61,66,72,76,79,83,88,90,95,97 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_sshort.c:6,9,12,16,18,20,26,29,33,35,40,42 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_double.c:6,9,12,14,17,19,21,27,30,34,36,41,43 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/ffitest.h:7,11,15,17,19,34,39,44,53,55,57,63,65,74,88,93,115,124,135 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct4.c:8,11,16,21,23,25,29,33,35,36,40,43,46,48,49,51,60,63,65,70,75,79,83,84,88,91,95,101,103,109,111 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_5byte.c:7,10,16,19,21,25,29,31,32,36,37,39,42,44,45,47,55,59,64,69,73,76,80,85,89,91,96,98 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_64byte.c:8,11,22,27,29,38,41,43,44,48,50,55,57,58,60,68,74,79,89,95,98,104,110,112,122,124 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_sint32.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/huge_struct.c:7,11,13,66,119,130,151,153,154,157,208,215,216,219,222,226,230,243,245,250,263,265,290,293,295,311,313,339,341 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/problem1.c:6,9,15,17,22,23,26,28,29,32,35,38,40,41,42,44,52,56,61,66,70,73,81,83,88,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/stret_large2.c:8,11,14,32,38,40,56,60,62,63,66,68,73,75,76,78,86,92,97,114,120,123,129,136,138,146,148 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn1.c:8,11,12,15,25,36,37,42,48,66,70,73,81 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_18byte.c:7,10,17,20,22,27,28,33,34,38,40,43,45,46,48,56,60,65,71,75,78,82,87,89,94,96 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_pointer.c:6,9,15,18,20,24,30,32,33,37,38,40,43,45,46,48,56,60,65,70,74,77,81,86,88,93,95 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uint.c:6,9,12,14,17,19,21,27,30,34,36,41,43 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn5.c:8,11,15,28,47,48,49,58,60,66,69,73,76,80,83,90,92 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_20byte1.c:7,8,9,12,18,21,23,27,31,32,36,38,41,43,44,46,54,58,63,68,72,75,79,84,86,91,93 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_9byte2.c:9,12,17,20,22,25,28,30,31,34,36,39,41,42,44,52,56,61,65,69,72,76,81,82,84,89,91 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_loc_fn0.c:8,9,10,11,14,18,29,41,42,43,48,50,56,74,78,82,85,87,95 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_longdouble.c:6,11,13,23,25,28,30,31,35,44,47,48,50,57,66,76,79,89,94,96,103,105 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_double_va.c:6,10,12,16,19,21,22,24,30,34,38,42,46,51,54,59,61 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_16byte.c:7,10,16,19,21,25,28,30,31,34,36,39,41,42,44,52,56,61,66,70,73,77,82,86,88,93,95 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_3_1byte.c:8,11,17,20,22,26,30,32,33,37,38,40,43,45,46,48,56,60,65,70,74,77,81,86,88,93,95 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct1.c:7,10,16,22,27,32,34,41,50,52,53,57,62,67,68,70,71,73,83,90,95,100,105,110,115,119,120,126,129,135,144,146,161 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct11.c:9,12,17,22,27,29,35,37,44,46,47,49,51,56,58,62,65,70,75,80,84,88,92,101,112,121 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_longdouble_split.c:6,9,11,21,25,27,35,41,43,44,47,49,57,62,64,65,69,71,74,76,77,79,87,91,96,105,109,112,116,122,124,130,132 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_sint16.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_3byte1.c:8,11,16,19,21,24,26,28,29,33,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct5.c:8,11,16,21,23,25,29,33,35,36,40,43,46,48,49,51,60,63,65,70,75,79,83,84,88,91,95,101,102,104,110,112 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_sshort.c:6,9,11,13,15,17,19,20,21,24,26,29,31,32,33,35,37,45,48,52,56,60,65,67,72,74 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/stret_medium2.c:8,12,24,30,32,42,45,47,48,51,53,58,60,61,63,71,77,82,93,99,102,108,114,116,123,125 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn0.c:8,9,10,11,14,18,29,41,42,43,48,50,56,74,78,81,89 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_float.c:6,9,12,14,17,18,20,22,28,31,35,42 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_longdouble_va.c:6,10,12,16,19,21,22,24,30,34,38,42,46,51,54,59,61 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/stret_medium.c:8,11,23,29,31,41,44,46,47,50,52,57,59,60,62,70,76,81,92,98,101,107,113,115,122,124 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_uint64.c:6,7,11,17,20,22,26,28,30,31,35,36,38,41,43,44,46,54,58,63,68,72,75,79,84,86,91,93 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_12byte.c:6,9,15,18,20,24,27,29,30,33,35,38,40,41,43,51,55,60,65,69,72,76,81,83,87,92,94 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_5_1_byte.c:7,10,18,21,23,29,34,36,37,41,42,44,47,49,50,52,60,64,69,76,80,83,87,93,99,101,107,109 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_dbls_struct.c:6,8,10,15,18,20,21,25,27,28,30,32,36,39,41,46,50,52,56,58,61,64,66 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_longdouble_split2.c:7,10,12,22,26,28,36,42,44,45,49,51,54,56,57,59,67,71,76,85,89,92,96,102,104,110,112,113,114,115 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/testclosure.c:6,9,16,18,23,24,28,30,32,34,35,36,38,45,47,52,58,61,64,66,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn4.c:8,10,12,16,29,48,49,50,59,61,67,70,73,77,80,87,89 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct2.c:8,11,16,21,23,25,29,32,34,35,39,42,45,47,48,50,59,62,64,69,74,78,82,83,87,90,94,100,102,108,110 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct8.c:8,11,16,21,26,28,30,34,38,40,41,45,49,53,55,56,58,68,72,74,79,84,89,93,97,101,102,107,110,115,121,123,129,131 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/stret_large.c:8,11,14,31,37,39,54,58,60,61,64,66,71,73,74,76,84,90,95,111,117,120,126,133,135,143,145 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_uchar.c:6,9,12,14,16,18,20,21,22,25,27,32,34,35,36,39,42,46,48,56,61,67,73,77,82,84,89,91 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uchar_va.c:6,9,11,14,16,18,19,21,23,29,33,37,44 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_9byte1.c:9,12,17,20,22,25,28,30,31,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_ushort.c:6,9,11,13,15,17,19,20,21,24,26,29,31,32,33,35,37,45,48,52,56,60,65,67,72,74 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_uint16.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_many_mixed_float_double.c:6,11,13,16,21,26,28,30,32,34,42,43,55 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_longdouble.c:6,8,10,16,19,21,25,27,29,30,34,35,37,40,42,43,45,53,57,62,67,71,74,78,83,85,90,92 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct6.c:8,11,16,21,26,28,30,34,38,40,41,45,49,53,55,56,58,68,72,74,79,84,89,93,97,101,102,107,110,115,121,123,129,131 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_3byte2.c:8,11,16,19,21,24,26,28,29,33,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uint_va.c:6,8,10,12,15,17,19,20,22,24,30,34,38,45 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_many_mixed_args.c:6,11,13,16,21,23,26,28,31,33,35,39,41,49,51,56,57,61,63,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_ushortchar.c:6,9,12,14,16,18,20,21,22,25,28,33,35,36,37,40,42,51,56,62,68,72,77,79,84,86 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_sint64.c:6,10,16,19,21,25,27,29,30,34,35,37,40,42,43,45,53,57,62,67,71,74,78,83,85,90,92 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn3.c:8,11,14,24,35,36,37,41,43,49,67,71,74,82 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ushort_va.c:6,9,11,14,16,18,19,21,23,29,33,37,44 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_pointer_stack.c:6,9,11,17,19,20,22,32,35,37,42,44,45,47,57,60,62,67,69,71,72,76,79,88,91,93,94,96,103,108,112,116,119,123,126,131,133,135,140,142 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_schar.c:6,9,11,13,15,17,19,20,21,24,26,29,31,32,33,35,37,45,48,52,56,60,65,67,72,74 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_1_1byte.c:8,9,10,13,17,20,22,24,26,28,29,33,34,36,39,41,42,44,52,56,61,64,68,71,75,80,82,87,89 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_simple.c:6,9,12,17,22,23,24,26,28,34,40,44,47,50,53,55 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_double.c:6,7,8,11,17,20,22,26,28,30,31,35,36,38,41,43,44,46,54,58,63,68,72,75,79,84,86,91,93 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_pointer.c:6,9,11,13,18,20,21,25,28,30,31,33,40,45,49,53,56,60,65,67,72,74 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ulonglong.c:6,10,13,15,18,20,22,28,31,40,45,47 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_8byte.c:7,10,15,18,20,23,25,27,28,32,33,35,38,40,41,43,51,55,60,64,68,71,75,81,86,88 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.go/closure1.c:2,4,6,10,11,13,15,19,22,24,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.go/aa-direct.c:2,4,6,8,13,16,17,19,22,24,26,28,30,31 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.bhaible/test-call.c:4,9,14,18,20,27,36,39,41,55,56,58,60,64,66,70,75,78,85,104,105,108,112,115,117,118,121,124,132,135,138,139,143,149,153,157,158,162,168,172,176,177,181,187,191,195,196,200,206,210,214,215,219,225,229,233,234,238,240,243,245,251,255,258,259,263,269,273,276,277,281,287,291,294,295,299,305,309,312,313,317,323,327,330,331,335,341,345,348,349,353,356,358,360,365,369,372,373,377,383,387,390,391,395,401,405,408,409,413,419,423,426,427,431,437,441,444,445,450,453,455,461,465,472,473,478,481,487,495,499,504,505,509,517,521,524,525,529,535,539,542,543,547,553,557,560,561,565,571,575,578,579,583,589,593,598,599,603,611,615,618,619,623,629,633,636,637,641,647,651,654,655,659,665,669,672,673,677,683,687,690,691,695,701,705,708,709,713,719,723,726,727,731,737,741,744,745,749,755,759,762,763,767,773,777,780,781,785,791,795,798,799,803,809,813,816,817,821,827,831,834,835,839,845,849,852,853,857,863,867,870,871,875,881,885,888,889,893,899,903,906,907,911,917,921,924,925,930,933,935,940,949,951,952,955,958,963,972,974,975,978,981,986,995,997,998,1001,1004,1009,1018,1020,1021,1024,1027,1032,1041,1043,1044,1047,1050,1055,1064,1066,1067,1070,1073,1078,1087,1089,1090,1093,1096,1101,1110,1112,1113,1116,1119,1124,1133,1135,1136,1139,1141,1144,1154,1160,1170,1173,1174,1183,1193,1196,1197,1206,1216,1219,1220,1229,1239,1242,1243,1252,1262,1265,1266,1275,1285,1288,1289,1299,1309,1313,1314,1323,1333,1336,1337,1342,1344,1345,1348,1357,1362,1367,1373,1377,1380,1381,1390,1394,1397,1398,1407,1411,1414,1415,1424,1428,1431,1432,1441,1445,1448,1449,1458,1462,1465,1466,1475,1479,1482,1483,1492,1496,1499,1500,1509,1513,1516,1517,1526,1530,1533,1534,1543,1547,1550,1551,1560,1564,1567,1568,1577,1581,1584,1585,1594,1598,1601,1602,1611,1615,1618,1619,1628,1632,1635,1636,1645,1649,1652,1653,1662,1666,1669,1670,1679,1683,1686,1687,1696,1700,1703,1704,1713,1717,1720,1721,1726,1727,1730,1733,1743,1745 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.bhaible/alignof.h:3,8,13,16,19,21,35,49 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.bhaible/test-callback.c:18,20,27,36,39,41,55,56,58,60,64,66,70,75,78,83,96,97,99,102,106,107,110,118,125,127,137,149,165,189,192,201,211,223,239,263,294,297,306,316,328,344,367,370,381,384,396,408,421,433,444,456,469,480,490,501,513,526,542,559,580,602,612,623,635,648,664,681,702,723,726,734,742,750,758,766,774,782,790,797,800,812,824,836,848,860,873,885,901,904,914,925,937,950,964,979,995,1024,1053,1065,1078,1092,1107,1123,1140,1152,1165,1179,1194,1210,1226,1227,1253,1254,1256,1266,1269,1275,1280,1283,1286,1293,1298,1303,1310,1316,1321,1328,1334,1339,1346,1352,1357,1364,1370,1375,1382,1388,1393,1394,1397,1404,1410,1415,1422,1428,1433,1440,1446,1451,1458,1464,1469,1476,1482,1487,1494,1500,1505,1506,1507,1510,1517,1523,1528,1535,1541,1546,1553,1559,1564,1571,1577,1582,1589,1595,1600,1601,1604,1611,1617,1622,1623,1630,1637,1643,1648,1655,1661,1666,1673,1679,1684,1691,1697,1702,1709,1715,1720,1727,1733,1738,1745,1751,1756,1763,1769,1774,1781,1787,1792,1799,1805,1810,1817,1823,1828,1835,1841,1846,1853,1859,1864,1871,1877,1882,1889,1895,1900,1907,1913,1918,1925,1931,1936,1943,1949,1954,1961,1967,1972,1979,1985,1990,1997,2003,2008,2015,2021,2026,2033,2039,2044,2045,2048,2054,2065,2069,2071,2073,2079,2090,2094,2096,2098,2104,2115,2119,2121,2123,2129,2140,2144,2146,2148,2154,2165,2169,2171,2173,2179,2190,2194,2196,2198,2204,2215,2219,2221,2223,2229,2240,2244,2246,2248,2254,2265,2269,2271,2272,2283,2290,2302,2307,2314,2326,2331,2338,2350,2355,2362,2374,2379,2386,2398,2403,2410,2422,2427,2435,2447,2452,2460,2472,2479,2480,2481,2483,2492,2497,2502,2509,2515,2520,2527,2533,2538,2545,2551,2556,2563,2569,2574,2581,2587,2592,2599,2605,2610,2617,2623,2628,2635,2641,2646,2653,2659,2664,2671,2677,2682,2689,2695,2700,2707,2713,2718,2725,2731,2736,2743,2749,2754,2761,2767,2772,2779,2785,2790,2797,2803,2808,2815,2821,2826,2833,2839,2844,2851,2857,2862,2869,2875,2880,2881,2882,2884,2885 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.bhaible/testcases.c:18,21,23,25,30,66,78,83,90,107,118,122,125,128,129,132,137,139,144,146,151,153,158,160,165,168,174,175,178,183,185,190,192,197,200,205,208,213,217,222,223,226,231,233,238,240,245,248,253,257,262,263,266,271,272,275,280,282,287,289,294,296,301,303,308,310,315,316,318,323,325,330,331,333,338,340,345,347,352,354,359,362,367,370,375,378,383,386,391,392,394,399,401,406,408,413,415,420,423,428,431,436,440,445,449,454,455,458,462,464,468,470,474,476,480,482,486,488,492,494,498,500,504,506,510,511,514,520,522,528,530,536,538,544,546,552,554,560,562,568,570,579,580,585,587,592,594,599,601,606,608,613,615,620,622,627,629,634,642,647,652,657,658,660,665,667,672,674,679,681,686,688,693,695,700,701,703,708,710,715,717,722,724,729,731,736,738,743 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/msvc_build/aarch64/aarch64_include/fficonfig.h:3,6,11,14,17,20,23,26,29,32,35,38,42,45,48,51,55,58,61,64,67,70,73,76,79,82,85,88,91,94,97,100,103,109,112,115,118,121,124,127,131,134,137,140,143,146,149,152,155,158,161,164,172,175,178,182,185,197,200,201,219 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/msvc_build/aarch64/aarch64_include/ffi.h:4,12,15,24,26,29,34,36,38,40,43,46,50,55,57,59,61,65,68,72,74,99,102,104,110,128,136,144,154,167,175,185,199,205,216,222,234,236,244,248,256,270,271,277,281,285,291,298,300,302,321,327,330,342,349,361,363,367,370,372,375,377,385,387,389,393,396,398,401,403,409,416,422,429,431,433,439,442,445,447,449,456,464,470,474,477,479,481,505,506,508,510 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m68k/ffitarget.h:5,13,16,25,27,30,34,38,46,48,52,54 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m68k/ffi.c:3,6,9,23,32,35,38,44,46,56,58,62,65,67,69,73,77,81,85,96,99,101,103,105,109,110,113,114,116,117,128,132,135,139,143,146,147,149,175,177,181,185,195,199,204,208,212,216,217,219,220,223,225,228,231,238,240,245,249,250,251,254,259,262,264,266,272,274,276,281,283,285,289,291,293,295,297,301,302,305,306,307,310,313,316,318,320,322,323,330,333,337,347,356,360,362 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/moxie/ffitarget.h:4,12,15,24,26,29,31,35,43,45,48,51 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/moxie/ffi.c:3,5,13,16,26,29,31,34,36,42,45,47,50,51,55,57,59,61,64,66,69,73,77,81,85,88,89,91,93,95,97,101,102,104,105,108,113,115,117,118,124,129,131,134,137,140,142,145,147,155,156,157,160,166,170,173,176,181,187,192,193,196,198,219,225,227,229,232,234,241,242,245,247,249,254,255,256,263,267,270,272,279,283,285 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/avr32/ffitarget.h:5,13,16,25,27,30,34,38,46,48,50,54 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/avr32/ffi.c:4,6,14,17,27,30,35,37,42,44,47,52,56,58,59,66,68,76,78,81,84,85,88,93,96,98,100,103,105,107,110,113,115,117,120,122,125,126,127,128,130,133,134,137,139,154,155,157,158,162,167,168,170,172,174,175,178,183,186,189,212,223,230,231,233,234,236,238,241,244,247,250,256,258,266,267,268,271,278,282,284,286,289,292,293,295,297,300,302,305,307,309,312,314,316,319,322,324,326,329,331,334,335,336,337,339,342,343,346,351,352,354,355,359,361,363,364,366,369,374,376,379,381,386,388,390,392,393,397,400,416,420,422,423 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m88k/ffitarget.h:23,27,30,34,42,44,48 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m88k/ffi.c:23,45,48,51,60,63,67,70,73,81,85,91,93,95,98,102,111,116,118,120,123,126,127,132,133,136,139,140,142,146,150,154,158,166,173,176,177,181,183,187,190,193,194,196,197,201,204,208,216,222,226,227,229,230,233,235,238,241,249,251,255,259,260,261,265,269,275,277,279,281,284,288,297,302,304,306,309,312,313,318,319,322,325,326,331,335,337,341,344,347,348,349,353,356,359,361,363,365,366,371,374,376,381,392,394,398,400 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/ia64/ffitarget.h:5,13,16,25,27,30,34,38,46,48,55 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/ia64/ia64_flags.h:3,5,7,15,18,28,32,35 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/ia64/ffi.c:5,7,15,18,28,31,35,37,42,47,50,51,53,55,60,61,63,66,72,73,78,81,84,87,90,93,95,104,105,106,109,112,114,126,127,128,131,134,136,138,143,145,150,152,157,160,161,162,166,169,171,173,180,186,194,196,198,200,204,209,210,212,215,216,218,219,220,222,225,227,235,239,246,248,251,253,257,259,262,263,265,268,270,272,273,276,279,280,285,288,289,291,294,298,300,304,307,311,313,336,340,344,348,350,356,365,367,371,375,377,381,385,391,392,393,396,398,401,402,403,405,406,413,421,423,430,434,438,440,445,448,451,454,461,463,464,465,469,474,479,484,487,490,510,513,519,524,527,533,538,543,549,554,556,560,564,566,571,573,577,583,584,588,591,593,595,598,599,600,602,604 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/xtensa/ffitarget.h:4,12,15,25,28,32,36,44,46,48,52 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/xtensa/ffi.c:3,5,13,16,26,29,42,44,46,47,49,50,54,56,81,83,87,88,93,95,96,98,102,115,118,121,124,126,127,131,133,161,163,166,169,172,177,181,182,185,186,187,188,189,191,196,199,205,207,210,212,214,215,218,220,223,224,227,234,238,242,247,248,249,252,257,261,263,266,269,270,274,276,279,283,285,289,290,293,294,296,298 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/closures.c:6,8,16,19,29,33,37,41,45,48,53,55,58,63,67,71,74,80,86,91,92,98,99,102,105,111,113,133,142,144,146,148,156,158,161,163,167,172,176,178,182,185,188,191,200,207,219,222,223,229,233,235,239,242,243,245,247,248,251,255,258,261,265,266,269,274,276,280,283,287,288,293,295,296,302,304,312,314,315,318,320,322,326,331,336,338,340,346,348,349,351,354,355,357,359,361,369,372,375,378,382,385,401,406,410,412,415,420,428,436,440,441,445,446,449,451,453,455,459,461,464,473,476,481,485,486,490,492,494,497,499,503,520,526,529,531,534,536,539,543,546,550,552,558,561,563,564,568,575,581,589,591,594,597,600,602,603,608,610,613,615,616,624,627,629,632,634,639,640,643,645,649,652,657,659,662,663,665,669,684,687,693,696,701,704,705,707,708,713,715,717,720,723,726,727,729,731,732,742,744,748,751,753,758,759,761,762,770,772,774,780,781,783,786,789,793,795,798,800,804,805,807,811,813,815,818,822,824,825,827,829,831,832,838,840,845,847,850,851,853,855,859,863,864,866,870,872,873,875,876,881,890,892,896,897,899,900,905,913,914,916,918,924,926,929,931,933,935,937,938,940,941,944,954,955,962,965,969,971,972,974,977,979,982,985,987,988,991,993,994,997,999,1000,1003 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi_sysv.c:8,10,18,21,30,32,36,37,42,43,48,50,53,55,58,59,61,65,72,80,82,86,88,89,93,101,104,107,110,121,123,125,140,148,154,157,164,168,169,176,178,180,182,186,191,199,202,206,213,224,236,243,249,252,256,264,280,283,284,285,292,296,299,302,305,308,310,311,314,316,320,323,327,331,336,341,342,344,345,348,350,369,371,374,377,379,386,389,394,401,405,408,415,429,441,448,452,458,460,462,465,470,472,481,483,487,493,495,500,505,509,512,518,525,529,532,533,535,538,541,542,544,548,554,556,565,567,572,574,578,591,596,598,605,606,607,616,617,619,622,630,631,638,640,643,655,658,662,664,665,672,681,686,694,697,699,702,709,713,714,718,722,725,727,734,744,746,749,751,754,758,760,765,767,771,775,777,783,787,792,796,798,802,804,809,813,815,818,821,826,830,832,835,838,843,847,849,852,854,859,863,865,868,870,882,884,888,892,894,900,902,905,906,908,909,911,922 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffitarget.h:5,7,15,18,27,29,32,36,38,55,59,62,68,74,84,107,117,136,139,141,152,155,160,166,169,172,179,193,203 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi_linux64.c:8,10,18,21,30,32,36,37,45,46,51,53,56,58,61,62,64,65,70,72,77,80,86,89,96,98,102,118,121,122,125,126,127,128,132,138,154,160,167,171,178,182,185,196,205,210,214,216,219,227,231,232,234,236,238,242,249,251,254,264,267,274,280,285,289,293,295,298,300,319,320,321,328,336,337,346,349,352,354,355,358,363,369,374,375,380,385,391,399,400,401,404,406,435,437,440,443,445,453,456,463,468,473,478,494,513,521,525,537,539,541,545,559,561,564,570,578,584,593,602,608,616,623,627,633,635,637,643,649,652,657,661,662,665,673,678,680,689,691,695,697,707,712,715,724,732,734,737,742,744,746,757,758,760,780,790,791,792,796,797,798,801,804,812,814,815,822,825,828,840,843,849,853,855,856,857,866,872,879,881,886,889,890,899,902,904,906,914,922,930,937,940,946,949,959,967,972,979,985,987,994,996,1000,1002,1004,1007,1012,1014,1016,1018,1020,1023,1028,1030,1037,1039,1048,1051,1055,1064,1066,1068,1071,1073,1075,1080,1082,1085,1094,1096,1099,1104,1110,1116,1118,1124,1127,1130,1131,1133,1134,1136,1139,1148,1152 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi_powerpc.h:8,10,18,21,30,38,42,44,53,55,59,67,72,85,90 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi.c:8,10,18,21,30,34,39,47,49,53,59,60,65,71,72,79,83,86,92,95,103,110,113,132,133,134,137,139,140,144,146,147,154,160,161,166,175 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/asm.h:3,5,13,16,25,27,28,36,42,76,83,92,114,117,123 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi_darwin.c:3,7,9,17,20,29,32,34,37,48,50,56,63,65,68,70,72,95,97,103,105,108,115,118,123,126,136,141,145,148,151,153,171,187,189,255,266,271,282,288,293,302,303,304,310,311,313,319,321,323,325,328,341,342,343,344,347,349,351,357,359,361,388,391,393,394,398,400,402,406,411,416,421,423,424,428,432,435,442,444,467,470,473,474,480,483,485,488,494,501,503,506,508,513,514,516,517,520,523,526,533,535,541,544,549,552,556,559,563,566,568,569,571,575,578,580,583,586,589,609,610,612,620,621,624,627,629,632,635,638,645,646,648,655,656,660,668,672,674,678,679,681,685,686,689,691,712,713,720,727,735,738,741,751,753,757,758,763,767,777,781,782,790,793,805,819,836,864,870,871,872,875,888,899,902,905,907,908,911,914,917,920,922,925,928,931,933,936,938,950,951,952,956,958,961,964,967,969,972,974,982,983,984,987,990,995,998,1000,1002,1036,1038,1045,1049,1051,1053,1055,1067,1085,1088,1090,1092,1095,1097,1105,1109,1111,1112,1117,1119,1121,1123,1128,1133,1135,1136,1139,1149,1150,1153,1159,1160,1162,1166,1170,1174,1181,1187,1191,1193,1195,1199,1208,1210,1212,1215,1219,1222,1225,1230,1231,1235,1238,1240,1250,1260,1271,1277,1281,1285,1286,1288,1294,1316,1330,1335,1340,1342,1344,1347,1352,1355,1357,1359,1366,1368,1372,1375,1377,1379,1382,1384,1390,1393,1398,1404,1406,1408,1415,1417,1418,1420,1423,1424,1428,1431,1432,1436,1439,1440 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m32r/ffitarget.h:5,13,16,24,26,29,33,35,39,41,48,52 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m32r/ffi.c:4,6,14,17,26,29,31,34,36,43,46,48,51,52,55,59,61,65,67,71,73,75,79,83,87,91,100,103,104,106,108,110,112,114,117,119,122,123,125,128,129,132,133,134,136,137,141,144,148,152,155,159,165,170,171,173,174,177,179,181,184,189,191,194,196,201,204,206,209,211,213,215,217,220,223,224,225,227,231,232 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/or1k/ffitarget.h:3,5,13,16,26,29,33,35,39,47,49,53,56,58 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/or1k/ffi.c:3,5,13,16,26,29,32,34,40,44,46,50,52,53,56,59,61,64,68,72,76,80,84,91,94,97,101,102,107,109,110,117,118,120,124,126,128,136,137,141,144,145,150,152,159,160,161,162,165,168,171,175,178,186,188,190,193,194,197,198,201,204,206,208,213,218,225,229,232,240,243,246,249,250,252,255,260,261,262,263,270,274,277,281,287,292,295,298,300,301,302,304,306,313,315,317,318,319,322,324,328 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/tile/ffitarget.h:4,12,15,25,28,32,34,36,39,47,50,64 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/tile/ffi.c:3,5,13,16,26,35,36,39,47,51,52,55,61,66,69,70,71,75,77,81,85,89,93,103,107,112,115,117,119,128,132,136,140,141,142,143,146,154,156,161,164,165,167,171,179,181,184,187,190,191,194,196,198,199,200,204,207,208,209,212,213,220,227,230,232,236,242,245,250,252,254,259,262,265,268,272,275,277,278,279,288,299,302,306,310,312,316,317,320,324,332,336,340,341,345,346,349,351,354,355 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/s390/ffitarget.h:5,13,16,25,27,30,34,40,42,46,54,57,59,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/s390/internal.h:7,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/s390/ffi.c:4,6,14,17,30,35,37,42,45,52,55,57,62,64,71,74,77,79,88,91,93,99,103,106,109,115,121,124,125,128,129,131,139,142,147,150,152,154,159,166,171,175,188,204,208,209,211,215,217,223,226,231,236,237,240,243,250,257,262,274,277,284,285,286,289,291,293,294,296,304,311,320,322,325,330,331,333,340,342,347,349,355,360,363,370,375,379,384,387,412,429,434,441,443,451,459,470,474,475,476,478,479,482,484,485,489,491,492,494,502,510,512,516,520,523,526,532,535,538,544,547,552,557,558,561,567,568,571,579,586,603,612,620,628,632,633,638,639,640,643,646,655,660,664,676,683,690,694,695,696,698,706,713,723,725,728,732,736,738,739,741,743,747,750,754,756 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/prep_cif.c:4,12,15,25,29,31,33,36,38,40,43,46,48,51,53,57,60,65,68,70,71,80,87,92,93,98,101,104,107,108,114,118,122,125,130,138,143,150,167,169,170,175,183,185,189,193,197,203,205,207,208,210,216,218,220,223,225,226,233,235,236,238,244,246,247,249,252,257,261,263 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/cris/ffitarget.h:5,13,16,25,27,30,34,38,46,48,55 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/cris/ffi.c:6,8,16,19,28,31,33,36,38,40,44,46,48,52,54,56,59,61,62,67,68,71,77,79,81,84,86,88,90,93,96,98,101,103,111,113,117,119,123,128,132,137,140,142,148,151,152,154,155,161,165,170,175,177,181,183,185,189,191,195,197,200,202,207,208,211,212,214,216,217,220,222,231,235,236,238,239,244,247,249,252,254,256,259,261,269,270,271,274,278,283,288,295,298,305,311,314,317,320,322,325,327,329,333,334,339,342,343,344,347,353,358,360,362,363,365,372,384,386 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/debug.c:3,11,14,24,29,31,33,37,38,40,42,46,47,49,51,53,63,64 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/mips/ffitarget.h:5,13,16,25,27,30,34,47,57,71,82,84,87,94,98,113,123,146,193,203,226,230,232,236,242,244 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/mips/ffi.c:5,7,15,18,28,31,34,40,48,54,62,66,67,70,75,80,92,94,100,104,105,107,109,112,117,119,122,123,126,129,135,138,140,149,150,152,156,160,164,168,172,183,188,193,194,196,200,203,206,210,212,218,219,221,225,226,227,229,235,239,242,244,247,249,253,260,264,267,269,270,273,277,284,287,290,292,297,299,306,308,312,315,319,321,322,324,327,330,335,337,339,341,346,349,350,352,356,358,363,366,367,368,369,370,371,373,375,377,382,388,393,394,396,399,406,411,415,416,418,421,427,431,433,435,437,440,443,445,448,451,453,455,458,460,469,470,472,484,486,488,495,497,504,508,509,511,512,515,517,519,523,525,530,532,533,537,544,547,550,558,563,566,568,573,578,579,581,583,584,586,588,589,593,595,596,601,606,609,611,614,617,623,625,633,639,644,650,654,660,665,668,672,673,674,677,679,680,684,686,687,688,697,704,708,725,773,775,779,786,787,811,816,819,822,824,828,829,833,835,842,849,851,853,858,863,868,873,877,879,882,883,886,888,890,897,898,900,902,903,904,906,911,914,920,926,929,931,936,942,943,944,966,973,978,980,982,989,990,994,996,1000,1003,1006,1013,1015,1017,1020,1022,1027,1030,1032,1037,1042,1047,1052,1057,1062,1065,1071,1073,1078,1079,1082,1083,1086,1088,1089,1091,1099,1103,1105,1122,1126,1128,1129 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sh/ffitarget.h:5,13,16,25,27,30,34,36,40,48,52,54 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sh/ffi.c:4,6,14,17,27,30,32,37,43,47,52,54,55,58,60,63,66,68,76,79,80,81,84,87,89,92,98,101,102,103,104,106,107,110,112,123,126,128,132,135,140,142,144,147,150,153,157,161,165,169,173,176,178,180,183,186,189,192,195,198,205,208,220,221,222,229,231,233,236,239,242,246,250,254,258,262,265,267,269,272,275,278,281,284,287,289,293,296,299,302,305,308,311,315,316,317,319,320,323,331,333,336,339,342,350,359,369,370,373,383,385,388,392,400,404,405,407,408,411,413,416,419,422,428,430,433,435,443,444,449,450,455,462,465,468,474,484,488,493,495,496,504,512,517,526,529,533,536,539,543,546,548,551,554,557,562,567,571,574,576,578,581,586,589,594,595,598,607,610,622,623,624,629,631,633,636,639,642,647,652,656,659,661,663,666,669,672,675,678,681,683,687,690,693,696,699,702,706,710,711,712,714,717 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sh64/ffitarget.h:5,13,16,25,27,30,34,36,40,47,50,52,56,58 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sh64/ffi.c:4,6,14,17,27,30,32,35,38,39,42,52,54,55,58,60,66,68,70,73,74,77,79,82,86,88,92,96,100,104,108,111,113,115,117,122,129,133,135,139,142,144,146,149,150,151,153,154,157,164,168,170,173,180,183,188,193,196,200,215,216,217,220,224,232,236,237,239,240,250,255,258,261,264,270,272,275,277,285,286,291,292,295,302,304,307,329,333,337,339,340,348,352,359,362,366,369,372,376,379,382,385,387,389,401,404,405,407,409,411,413,416,418,427,428,435,443,445,449,452,454,456,458,461,462,463,465,468,469 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/frv/ffitarget.h:5,13,16,25,27,30,34,36,40,48,50,53,61 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/frv/ffi.c:5,7,15,18,28,31,33,36,38,44,47,51,53,55,57,60,62,64,68,73,76,80,84,88,92,95,96,98,100,102,104,108,109,111,112,115,120,122,124,125,131,136,138,141,144,147,149,152,153,155,163,164,165,168,174,179,183,189,192,194,216,218,223,224,227,233,235,239,245,246,247,254,262,264,281,285,290,292 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/pa/ffitarget.h:5,13,16,25,27,30,34,36,40,43,49,55,64,66,68,72 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/pa/ffi.c:6,9,17,20,30,33,36,38,42,51,53,55,57,63,82,83,85,100,106,112,116,121,124,127,130,133,138,141,143,150,153,156,158,160,162,166,170,174,178,186,193,199,205,207,214,218,220,228,230,234,237,240,242,246,250,253,254,258,259,261,263,266,269,271,272,274,276,277,279,283,285,287,289,295,302,305,306,307,314,316,317,320,323,329,336,345,350,354,355,359,363,367,368,370,371,375,377,379,382,385,393,395,398,399,401,407,411,412,413,420,433,435,441,445,447,449,451,461,467,477,482,486,492,495,499,506,512,515,517,521,525,528,529,532,533,536,539,542,565,569,573,577,585,590,593,596,601,602,605,608,610,614,619,621,622,626,628,635,637,641,645,647,652,655,658,661,667,671,673 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/metag/ffitarget.h:4,12,15,24,26,29,33,37,45,47,51,53 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/metag/ffi.c:3,12,15,24,27,29,31,36,38,43,45,50,51,53,56,58,62,65,69,86,91,92,93,97,98,101,104,108,112,116,118,119,122,126,129,130,132,159,161,162,164,174,176,180,182,187,194,202,203,206,207,209,212,214,217,219,234,235,236,237,239,246,248,253,258,262,264,265,266,273,276,279,288,290,292,293,297,302,305,310,311,313,317,323,328,330 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/ffitarget.h:5,7,15,18,27,29,32,36,38,41,46,51,56,58,79,91,100,126,128,131,136,149,158,160 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/internal.h:17,20,24 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/ffi64.c:6,8,16,19,29,32,37,39,42,54,56,61,63,70,73,76,82,86,99,101,103,107,110,113,117,124,128,136,146,149,150,156,162,164,175,177,179,182,184,187,189,193,195,198,201,218,224,228,231,235,239,240,243,245,247,252,256,257,259,260,262,269,273,274,277,282,288,292,293,298,302,303,305,307,310,321,325,328,338,339,340,342,343,347,351,355,359,363,382,383,386,388,389,391,396,399,405,412,414,418,462,468,470,472,478,489,490,494,519,523,524,529,533,535,538,541,543,546,547,550,553,555,556,560,566,569,574,579,580,585,587,589,594,597,599,601,606,608,612,617,619,623,625,627,638,651,663,664,665,666,668,671,672,677,680,683,686,689,690,696,700,703,706,709,710,711,714,723,730,743,750,755,758,762,764,765,773,779,784,786,793,794,797,800,805,807,811,816,822,825,828,830,833,834,837,840,843,848,849,850,851,854,857,858,861,867,871,878,884,886,887 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/ffi.c:8,10,18,21,31,38,49,53,60,64,67,69,80,81,83,131,134,144,147,151,173,177,179,181,183,186,188,190,191,194,196,205,211,214,215,216,218,226,228,234,245,255,257,261,268,273,276,278,292,293,294,301,306,309,313,317,323,324,327,332,334,336,340,343,345,348,349,351,354,363,373,375,380,382,386,387,388,390,392,393,396,398,399,403,405,406,408,412,414,421,424,432,440,442,445,450,457,458,461,464,469,471,475,478,480,483,484,486,489,493,502,504,509,511,515,516,517,519,520,522,527,528,535,539,541,558,559,562,566,570,574,576,577,581,585,587,589,605,606,610,612,613,615,617,620,627,631,638,642,643,645,654,655,659,663,667,669,670,673,680,684,687,689,703,704,705,712,716,719,723,727,734,735,738,742,744,748,750,754,757,760,762 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/ffiw64.c:4,6,14,17,27,33,39,41,48,51,54,56,58,64,65,68,81,94,96,98,106,108,109,113,118,120,123,127,132,133,138,142,145,148,149,151,153,169,170,171,173,174,177,179,180,184,186,187,188,191,198,210,212,218,219,222,226,228,229,233,235,241,242,246,248,249,251,257,267,271,275,281,285,286,288,292,294,299,304,306,307,311,312 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/asmnames.h:3,11,17,23,29 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/internal64.h:17,19 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/types.c:3,5,13,16,26,30,33,35,46,47,62,63,68,77,79,82,88,101 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/microblaze/ffitarget.h:3,5,13,16,26,29,33,37,45,47,50,52 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/microblaze/ffi.c:3,5,13,16,26,29,33,35,39,43,48,51,52,54,57,64,65,68,69,72,78,81,83,121,124,134,135,136,137,139,142,147,149,150,152,156,163,164,166,174,175,176,180,184,195,200,202,207,208,213,214,217,219,243,245,261,263,264,274,275,276,281,286,290,292,295,301,307,315,319,321 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/arm/ffitarget.h:5,7,15,18,27,29,32,36,40,53,58,63,65,69,71,78,88 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/arm/ffi.c:7,9,17,20,30,38,43,45,49,57,61,64,75,76,79,81,83,96,106,114,120,125,128,129,131,132,135,143,146,148,151,152,154,158,159,160,164,170,175,179,182,183,185,189,192,196,199,206,212,217,223,224,229,230,231,235,238,245,248,252,263,268,275,279,281,289,290,298,301,303,306,307,312,316,319,321,322,327,331,333,334,336,338,345,350,354,360,363,371,373,376,379,382,385,388,391,392,394,398,402,404,407,409,412,413,416,417,420,422,423,427,429,430,434,437,439,442,444,447,448,450,453,457,458,460,461,465,471,474,476,479,480,482,486,488,491,493,495,497,501,505,510,513,515,518,520,521,522,527,528,530,531,533,538,544,550,551,557,563,564,569,571,577,579,581,585,588,594,601,617,621,623,624,628,630,632,636,639,643,645,646,648,652,655,658,661,664,668,670,671,673,674,677,680,683,686,689,692,695,696,698,699,703,706,709,713,717,732,733,738,743,745,749,750,751,755,768,771,774,777,780,783,784,788,789,792,795,798,802,804,807,810,813,814,818,821,826,829,834,835,838,845,847,851,852,853 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/arc/ffitarget.h:5,13,16,24,26,29,33,35,39,41,48,52 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/arc/ffi.c:3,5,13,16,25,28,31,33,41,44,47,52,54,56,59,60,62,65,68,71,75,78,80,82,86,90,94,98,102,105,106,108,110,112,114,116,118,121,122,125,126,128,129,133,136,140,144,150,155,156,158,159,163,166,168,171,175,177,180,182,187,191,192,193,197,203,205,208,211,212,214,217,220,223,227,231,232,234,236,237,239,244,246,248,255,258,259,264,266 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/riscv/ffitarget.h:3,5,13,16,25,27,30,34,38,40,43,53,56,58,60,67,69 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/riscv/ffi.c:6,8,16,19,29,32,35,43,47,49,57,59,65,73,78,84,93,95,96,105,110,120,125,126,128,130,147,162,163,168,169,170,184,185,190,191,205,206,207,211,220,221,222,226,228,237,243,244,250,251,252,257,266,267,268,272,274,285,291,292,299,300,301,307,309,311,312,317,318,320,324,325,329,333,342,354,355,358,363,367,371,373,377,378,381,383,384,388,390,391,393,395,398,401,404,415,419,421,423,424,426,430,433,437,439,440,449,460,464,470,474,476,480,481 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/dlmalloc.c:6,8,12,14,20,34,36,43,48,54,57,66,79,90,100,106,116,125,129,131,137,150,157,162,167,170,182,185,192,194,201,203,207,211,218,222,225,230,235,238,243,254,265,276,283,287,290,303,311,317,327,331,335,343,350,354,359,364,370,376,391,414,438,440,445,466,474,482,486,489,587,594,598,600,612,623,625,629,632,645,648,652,654,656,675,676,682,692,701,708,714,718,720,723,727,731,733,738,743,747,754,767,774,785,798,803,817,824,827,836,843,848,854,860,862,875,878,881,889,895,900,906,910,914,917,928,929,933,939,940,947,950,959,966,970,973,981,986,998,1002,1007,1009,1011,1017,1030,1038,1049,1055,1059,1065,1069,1076,1082,1088,1095,1102,1108,1114,1115,1123,1129,1135,1140,1142,1146,1154,1156,1158,1162,1164,1208,1255,1257,1261,1271,1274,1277,1282,1284,1290,1291,1295,1302,1306,1328,1330,1332,1340,1341,1343,1358,1360,1361,1365,1367,1372,1373,1379,1380,1395,1397,1398,1404,1410,1416,1419,1422,1423,1425,1427,1430,1437,1441,1449,1453,1455,1465,1471,1483,1484,1485,1488,1489,1498,1504,1512,1520,1521,1523,1526,1530,1538,1543,1545,1565,1567,1595,1600,1604,1615,1620,1628,1633,1635,1647,1656,1658,1665,1672,1674,1676,1682,1687,1691,1697,1701,1705,1709,1710,1712,1720,1724,1727,1732,1735,1739,1743,1746,1750,1754,1758,1761,1765,1772,1774,1778,1781,1797,1802,1825,1833,1840,1848,1856,1863,1870,1875,1879,1882,1884,1892,1906,1914,1921,1926,1939,1947,1949,1954,1957,1959,1968,1974,1978,1982,1985,1988,1990,1994,2003,2010,2020,2026,2039,2043,2048,2051,2054,2058,2063,2073,2094,2096,2098,2104,2113,2115,2121,2123,2125,2129,2133,2136,2141,2145,2149,2154,2158,2167,2168,2169,2178,2179,2180,2186,2194,2195,2197,2203,2205,2208,2212,2216,2220,2222,2230,2232,2235,2238,2241,2243,2247,2251,2253,2255,2257,2264,2272,2286,2288,2293,2297,2312,2330,2332,2336,2341,2346,2347,2349,2352,2357,2361,2363,2370,2371,2375,2387,2390,2393,2396,2399,2400,2402,2412,2428,2438,2445,2452,2453,2464,2466,2468,2470,2475,2480,2484,2486,2490,2494,2499,2504,2508,2510,2512,2517,2525,2527,2536,2540,2543,2544,2554,2556,2567,2572,2574,2590,2592,2593,2606,2614,2615,2616,2619,2624,2625,2638,2639,2652,2653,2663,2664,2682,2685,2686,2687,2699,2700,2701,2714,2726,2738,2743,2746,2747,2751,2752,2762,2763,2784,2785,2786,2787,2800,2801,2811,2818,2819,2820,2822,2823,2840,2845,2848,2850,2851,2853,2854,2864,2870,2871,2877,2878,2882,2884,2886,2906,2908,2910,2911,2919,2920,2922,2924,2926,2938,2946,2948,2949,2950,2954,2956,2957,2958,2960,2967,2985,2986,3005,3006,3022,3023,3035,3036,3038,3089,3090,3093,3107,3177,3178,3180,3184,3188,3189,3191,3206,3208,3218,3233,3241,3242,3244,3245,3269,3276,3277,3279,3280,3282,3289,3296,3297,3305,3306,3307,3309,3324,3326,3336,3340,3347,3352,3359,3363,3364,3367,3368,3369,3386,3389,3398,3408,3410,3418,3419,3421,3422,3424,3430,3432,3438,3439,3456,3462,3475,3476,3477,3486,3487,3488,3501,3502,3503,3504,3508,3511,3512,3514,3515,3525,3526,3527,3528,3543,3544,3545,3546,3547,3549,3552,3565,3566,3567,3580,3595,3598,3599,3600,3610,3611,3612,3615,3616,3618,3638,3641,3648,3651,3652,3653,3656,3658,3659,3664,3671,3682,3683,3684,3689,3697,3698,3700,3701,3702,3708,3709,3710,3714,3718,3719,3721,3722,3724,3732,3744,3752,3754,3755,3756,3764,3765,3766,3772,3774,3775,3789,3791,3792,3794,3796,3797,3805,3808,3814,3815,3816,3828,3830,3831,3832,3835,3836,3838,3843,3850,3852,3866,3867,3878,3879,3884,3885,3887,3891,3894,3901,3903,3904,3906,3907,3909,3919,3920,3924,3925,3934,3954,3958,3963,3965,3966,3976,3977,3978,3985,3988,3990,3991,3993,3994,3996,4005,4010,4022,4029,4036,4037,4042,4048,4049,4051,4064,4068,4070,4073,4074,4083,4084,4096,4100,4101,4102,4108,4111,4113,4116,4118,4121,4122,4123,4125,4127,4148,4151,4161,4173,4174,4196,4200,4201,4205,4206,4207,4215,4216,4217,4226,4232,4236,4237,4248,4249,4251,4255,4256,4258,4259,4266,4274,4291,4299,4304,4305,4308,4309,4310,4320,4324,4330,4339,4340,4341,4347,4348,4353,4354,4358,4359,4368,4373,4374,4382,4392,4395,4396,4397,4400,4401,4406,4407,4411,4412,4418,4419,4425,4426,4432,4434,4435,4438,4439,4442,4443,4447,4449,4452,4453,4459,4461,4462,4465,4466,4468,4470,4472,4491,4492,4497,4507,4508,4510,4511,4516,4522,4524,4525,4539,4540,4543,4545,4546,4551,4552,4558,4568,4580,4581,4603,4607,4608,4612,4613,4614,4622,4623,4624,4633,4639,4643,4644,4655,4656,4658,4662,4663,4665,4666,4678,4692,4700,4705,4706,4709,4710,4711,4721,4725,4731,4740,4741,4742,4748,4749,4754,4755,4756,4757,4765,4771,4776,4777,4785,4797,4799,4800,4801,4807,4809,4810,4818,4820,4821,4828,4830,4831,4839,4840,4843,4845,4846,4851,4854,4855,4856,4862,4865,4866,4867,4873,4876,4877,4878,4884,4886,4888,4891,4892,4894,4896,4899,4918,4925,4927,4930,4935,4937,4940,4942,4948,4950,4957,4959,4962,4964,4966,4967,4968,4971,4973,4975,4978,4981,4982,4983,4985,4986,5001,5004,5008,5024,5027,5040,5064,5080,5083,5092,5113,5124,5128,5132,5134,5143,5152,5161,5165 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/alpha/ffitarget.h:5,13,16,25,27,30,34,38,46,49,51,56 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/alpha/internal.h:7,19 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/alpha/ffi.c:4,6,14,17,27,32,43,49,53,57,58,61,63,64,67,71,74,77,80,97,103,111,114,115,116,120,160,173,177,179,187,189,190,193,195,204,209,215,221,224,225,226,230,235,240,245,249,252,254,259,261,277,283,290,295,302,305,306,307,310,311,314,316,317,321,323,324,331,333,336,343,347,349,352,355,357,358,363,366,370,372,373,379,383,387,391,394,395,397,400,405,407,420,426,431,434,437,443,450,454,459,472,477,480,486,493,497,499,502,505,508,511,512,514,515,518,521 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/aarch64/ffitarget.h:2,10,13,21,24,28,43,45,52,54,57,59,66,71,75,77,86,91 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/aarch64/internal.h:9,12,20,24,30,37,42,47,52,56,58,61,64 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/aarch64/ffi.c:2,10,13,21,33,44,46,50,52,55,57,61,63,70,72,76,79,89,90,92,96,99,102,105,108,112,114,115,117,118,121,124,127,130,133,136,139,140,142,143,148,151,154,158,162,173,179,183,184,189,194,196,200,201,202,206,224,227,230,233,236,239,240,244,245,248,251,253,257,262,266,273,274,279,281,291,294,296,297,300,302,324,325,326,332,335,382,384,390,392,395,399,420,423,427,448,453,455,457,461,466,469,472,473,476,480,482,512,520,523,526,533,535,538,539,542,545,546,553,555,556,562,566,568,572,578,585,590,596,599,604,610,613,618,621,625,639,644,655,656,658,664,666,669,673,675,680,683,685,688,693,697,699,701,709,711,714,721,723,730,731,733,735,738,739,742,746,748,749,751,754,755,758,760,761,766,768,770,772,775,782,785,787,792,809,811,813,815,826,830,832,833,837,841,843,846,851,855,857,859,861,868,871,875,882,886,888,890,894,896,900,913,921,925,927,930,939,941,946,947,949,952,956,958,962,964,966,968,974,976,979,982,984,988,989,991,994,995,998,1002,1004,1005,1009,1011,1013,1014 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sparc/ffitarget.h:5,13,16,25,27,30,34,36,42,46,59,62,67,69,73,79,81 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sparc/internal.h:12,21,25 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sparc/ffi64.c:4,6,14,17,27,32,43,45,49,53,56,59,61,64,70,72,74,77,80,98,100,101,104,106,107,110,113,117,123,126,130,132,133,134,136,139,143,149,152,156,158,159,161,164,169,172,185,189,192,194,199,201,205,207,212,213,216,225,226,228,253,256,257,260,264,266,271,274,286,289,290,295,298,301,305,306,309,312,313,316,319,320,323,326,329,333,335,337,342,344,347,348,349,355,358,361,365,367,394,400,404,410,413,414,415,417,418,422,424,426,429,431,432,435,437,438,442,444,445,449,451,455,458,465,468,471,480,484,486,488,489,493,496,500,502,503,509,513,518,520,524,528,531,534,539,542,549,552,555,559,560,562,577,595,598,600,601,604,607 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sparc/ffi.c:4,6,14,17,27,32,34,45,49,54,57,97,126,130,132,135,139,141,148,154,157,159,160,165,168,171,175,177,178,181,184,188,190,192,197,199,202,203,204,208,214,217,222,224,230,237,245,258,265,268,270,273,275,278,279,280,282,283,287,289,291,297,299,300,303,305,306,310,312,313,317,321,325,328,335,339,342,347,351,353,355,356,360,363,367,369,370,376,380,385,390,394,395,398,401,406,408,415,420,425,428,443,454,457,460,461,464,467 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/java_raw_api.c:3,5,8,10,18,21,31,37,41,43,46,49,51,53,68,69,70,72,73,74,77,80,82,84,86,91,96,105,109,113,118,119,120,122,124,127,141,147,148,152,154,155,158,161,163,165,173,181,189,197,205,213,217,226,230,239,240,241,242,244,247,250,256,266,270,273,275,276,279,282,288,295,299,302,304,305,312,315,320,321,323,327,330,334,335,342,344,351,354,355,357,358,362,368,370,371 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/vax/ffitarget.h:23,27,30,34,42,44,48 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/vax/ffi.c:23,30,33,36,41,45,49,52,58,60,66,68,72,74,77,79,83,87,91,95,99,102,104,106,108,112,113,116,117,119,120,123,126,130,134,137,138,150,157,158,160,161,164,166,169,172,179,181,185,189,190,191,195,199,202,206,208,210,212,215,219,222,223,224,227,230,233,235,237,239,240,245,248,250,258,264,270,274,276 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/bfin/ffitarget.h:3,5,13,16,26,29,33,41,43 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/bfin/ffi.c:4,6,14,17,29,32,35,44,49,54,56,61,62,66,68,104,109,111,112,121,127,135,136,137,138,145,164,170,184,189,192,193,194,195,196 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/raw_api.c:3,5,13,16,26,28,31,33,36,39,41,43,50,51,53,54,55,58,61,63,65,67,72,77,84,90,94,98,102,103,104,106,108,111,114,116,120,122,124,127,128,129,133,135,136,139,142,144,146,150,154,158,162,167,172,178,182,186,190,191,192,193,195,196,203,205,209,210,212,216,219,222,223,230,232,239,242,243,245,246,249,251,255,261,263,264,266 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/nios2/ffitarget.h:2,4,12,15,23,24,27,31,35,43,47,51 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/nios2/ffi.c:2,4,12,15,23,24,27,29,32,37,41,44,48,49,51,57,59,61,70,72,73,74,80,82,85,90,93,94,96,101,105,109,112,116,120,124,128,132,135,136,142,143,144,145,149,151,152,155,161,164,171,173,179,195,196,197,201,205,212,218,221,224,227,230,234,238,242,243,247,248,249,258,261,264,279,291,297,301,303,304 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/FunctionInfo.c:29,35,42,45,49,55,60,62,65,68,76,78,79,82,88,89,90,93,100,102,103,117,126,132,133,135,145,149,153,154,158,159,162,163,168,169,174,175,178,179,182,190,202,203,205,207,208,216,218,220,222,223,231,233,235,237,238,241,243,245,263,268,269,270 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/Pointer.h:29,32,38,42,44,49,57,59,61,63 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/ClosurePool.c:28,53,60,66,68,69,73,79,88,90,94,99,101,107,109,110,113,115,122,124,125,128,133,134,135,136,139,147,152,154,155,161,165,166,172,175,176,177,180,181,187,192,195,201,202,203,206,207,210,220,221,222,223,226,228,229,230,233,241,242,245,252,253,256,262,263,266,273,274,277,279,280 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/ffi-1.13.1/ext/ffi_c/StructByValue.c:29,44,48,52,54,59,61,64,66,68,72,77,79,80,83,87,91,92,97,100,102,103,106,109,110,113,116,117,118,121,123,126,127,130,132,134,136,137,140,144,149,150 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/rake-13.0.1/doc/example/a.c:2,4,6 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/rake-13.0.1/doc/example/main.c:2,5,7,11 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/rake-13.0.1/doc/example/b.c:2,4,6 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_genibus/crc16_genibus.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_genibus/crc16_genibus.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_genibus/crc16_genibus_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16/crc16.h:3,6,8,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16/crc16_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16/crc16.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32c/crc32c.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32c/crc32c_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32c/crc32c.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc64_jones/crc64_jones.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc64_jones/crc64_jones.c:16,18,88,90,93,95,99,100,102 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc64_jones/crc64_jones_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/compat/ruby.h:3,5,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_modbus/crc16_modbus.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_modbus/crc16_modbus_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_modbus/crc16_modbus.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_bzip2/crc32_bzip2.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_bzip2/crc32_bzip2.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_bzip2/crc32_bzip2_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc12_3gpp/crc12_3gpp.c:16,18,40,42,45,47,50,51,53,54,56,59,61,65,66,68 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc12_3gpp/crc12_3gpp.h:3,6,8,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc12_3gpp/crc12_3gpp_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_zmodem/crc16_zmodem_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_zmodem/crc16_zmodem.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_zmodem/crc16_zmodem.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_xfer/crc32_xfer.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_xfer/crc32_xfer_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_xfer/crc32_xfer.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_x_25/crc16_x_25.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_x_25/crc16_x_25_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_x_25/crc16_x_25.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_kermit/crc16_kermit_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_kermit/crc16_kermit.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_kermit/crc16_kermit.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc8/crc8.h:3,6,8,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc8/crc8_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc8/crc8.c:16,18,40,42,45,47,51,52,54 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc64_xz/crc64_xz.c:16,18,88,90,93,95,99,100,102 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc64_xz/crc64_xz.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc64_xz/crc64_xz_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_usb/crc16_usb.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_usb/crc16_usb_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_usb/crc16_usb.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32/crc32.c:17,55,57,60,62,66,67,69 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32/crc32_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32/crc32.h:3,6,8,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_xmodem/crc16_xmodem.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_xmodem/crc16_xmodem_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_xmodem/crc16_xmodem.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc15/crc15.h:3,6,8,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc15/crc15_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc15/crc15.c:16,18,40,42,45,47,51,52,54 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc24/crc24_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc24/crc24.h:3,6,8,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc24/crc24.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_dnp/crc16_dnp_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_dnp/crc16_dnp.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_dnp/crc16_dnp.c:2,40,42,45,47,51,52,54 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_posix/crc32_posix.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_posix/crc32_posix_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_posix/crc32_posix.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_jam/crc32_jam.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_jam/crc32_jam.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_jam/crc32_jam_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_mpeg/crc32_mpeg.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_mpeg/crc32_mpeg_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc32_mpeg/crc32_mpeg.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc64/crc64.h:3,6,8,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc64/crc64_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc64/crc64.c:16,18,88,90,93,95,99,100,102 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc8_1wire/crc8_1wire.c:16,18,40,42,45,47,51,52,54 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc8_1wire/crc8_1wire_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc8_1wire/crc8_1wire.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_ccitt/crc16_ccitt.h:3,5,7 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_ccitt/crc16_ccitt.c:16,18,56,58,61,63,67,68,70 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc16_ccitt/crc16_ccitt_ext.c:3,6,8,12,15,17,20,21,23,26,28 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc5/crc5.h:3,6,8,10 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc5/crc5_ext.c:3,5,7,11,14,16,19,20,22,25,27 /Users/runner/work/EasyMapping/EasyMapping/vendor/bundle/ruby/2.6.0/gems/digest-crc-0.6.1/ext/digest/crc5/crc5.c:16,18,40,42,45,47,51,52,54 <<<<<< EOF