From d51cc97aa42025807febbc1203bd21ee722bd476 Mon Sep 17 00:00:00 2001 From: Javier Cicchelli Date: Tue, 11 Apr 2023 15:57:38 +0000 Subject: [PATCH] [Bugfix] Location library naming (#8) This PR contains a bugfix that appeared while I started working on the app itself. Basically, the app was not building as the compiler was complaining about duplicated files in the project, but given that I couldn't find any, then I found out that the compiler doesn't like that a library name and an app target share the same name. So I renamed the `Locations` library in the **Libraries** package as `Remote` (for the lack of a better word...) to fix this issue that was stopping me from continue working on implementing the app. Co-authored-by: Javier Cicchelli Reviewed-on: https://repo.rock-n-code.com/rock-n-code/deep-linking-assignment/pulls/8 --- Apps/Locations/Libraries/Package.swift | 28 +++++++++---------- .../Clients/LocationsClient.swift | 0 .../Endpoints/GetLocationsEndpoint.swift | 0 .../Extensions/String+Constants.swift | 0 .../Models/Location.swift | 0 .../Services/LocationsService.swift | 0 .../Clients/LocationsClientTests.swift | 0 .../Endpoints/GetLocationsEndpointTests.swift | 0 .../Helpers/Data+Constants.swift | 0 .../Services/LocationsServiceTests.swift | 0 10 files changed, 14 insertions(+), 14 deletions(-) rename Apps/Locations/Libraries/Sources/{Locations => Remote}/Clients/LocationsClient.swift (100%) rename Apps/Locations/Libraries/Sources/{Locations => Remote}/Endpoints/GetLocationsEndpoint.swift (100%) rename Apps/Locations/Libraries/Sources/{Locations => Remote}/Extensions/String+Constants.swift (100%) rename Apps/Locations/Libraries/Sources/{Locations => Remote}/Models/Location.swift (100%) rename Apps/Locations/Libraries/Sources/{Locations => Remote}/Services/LocationsService.swift (100%) rename Apps/Locations/Libraries/Tests/{LocationsTests => RemoteTests}/Clients/LocationsClientTests.swift (100%) rename Apps/Locations/Libraries/Tests/{LocationsTests => RemoteTests}/Endpoints/GetLocationsEndpointTests.swift (100%) rename Apps/Locations/Libraries/Tests/{LocationsTests => RemoteTests}/Helpers/Data+Constants.swift (100%) rename Apps/Locations/Libraries/Tests/{LocationsTests => RemoteTests}/Services/LocationsServiceTests.swift (100%) diff --git a/Apps/Locations/Libraries/Package.swift b/Apps/Locations/Libraries/Package.swift index 16ba787..301153d 100644 --- a/Apps/Locations/Libraries/Package.swift +++ b/Apps/Locations/Libraries/Package.swift @@ -13,8 +13,8 @@ let package = Package( targets: [ "Core", "Dependency", - "Locations", - "Persistence" + "Persistence", + "Remote" ] ), ], @@ -33,15 +33,15 @@ let package = Package( dependencies: [] ), .target( - name: "Locations", + name: "Persistence", + dependencies: [] + ), + .target( + name: "Remote", dependencies: [ "APICore" ] ), - .target( - name: "Persistence", - dependencies: [] - ), .testTarget( name: "APICoreTests", dependencies: [ @@ -60,18 +60,18 @@ let package = Package( "Dependency" ] ), - .testTarget( - name: "LocationsTests", - dependencies: [ - "APICore", - "Locations" - ] - ), .testTarget( name: "PersistenceTests", dependencies: [ "Persistence" ] ), + .testTarget( + name: "RemoteTests", + dependencies: [ + "APICore", + "Remote" + ] + ), ] ) diff --git a/Apps/Locations/Libraries/Sources/Locations/Clients/LocationsClient.swift b/Apps/Locations/Libraries/Sources/Remote/Clients/LocationsClient.swift similarity index 100% rename from Apps/Locations/Libraries/Sources/Locations/Clients/LocationsClient.swift rename to Apps/Locations/Libraries/Sources/Remote/Clients/LocationsClient.swift diff --git a/Apps/Locations/Libraries/Sources/Locations/Endpoints/GetLocationsEndpoint.swift b/Apps/Locations/Libraries/Sources/Remote/Endpoints/GetLocationsEndpoint.swift similarity index 100% rename from Apps/Locations/Libraries/Sources/Locations/Endpoints/GetLocationsEndpoint.swift rename to Apps/Locations/Libraries/Sources/Remote/Endpoints/GetLocationsEndpoint.swift diff --git a/Apps/Locations/Libraries/Sources/Locations/Extensions/String+Constants.swift b/Apps/Locations/Libraries/Sources/Remote/Extensions/String+Constants.swift similarity index 100% rename from Apps/Locations/Libraries/Sources/Locations/Extensions/String+Constants.swift rename to Apps/Locations/Libraries/Sources/Remote/Extensions/String+Constants.swift diff --git a/Apps/Locations/Libraries/Sources/Locations/Models/Location.swift b/Apps/Locations/Libraries/Sources/Remote/Models/Location.swift similarity index 100% rename from Apps/Locations/Libraries/Sources/Locations/Models/Location.swift rename to Apps/Locations/Libraries/Sources/Remote/Models/Location.swift diff --git a/Apps/Locations/Libraries/Sources/Locations/Services/LocationsService.swift b/Apps/Locations/Libraries/Sources/Remote/Services/LocationsService.swift similarity index 100% rename from Apps/Locations/Libraries/Sources/Locations/Services/LocationsService.swift rename to Apps/Locations/Libraries/Sources/Remote/Services/LocationsService.swift diff --git a/Apps/Locations/Libraries/Tests/LocationsTests/Clients/LocationsClientTests.swift b/Apps/Locations/Libraries/Tests/RemoteTests/Clients/LocationsClientTests.swift similarity index 100% rename from Apps/Locations/Libraries/Tests/LocationsTests/Clients/LocationsClientTests.swift rename to Apps/Locations/Libraries/Tests/RemoteTests/Clients/LocationsClientTests.swift diff --git a/Apps/Locations/Libraries/Tests/LocationsTests/Endpoints/GetLocationsEndpointTests.swift b/Apps/Locations/Libraries/Tests/RemoteTests/Endpoints/GetLocationsEndpointTests.swift similarity index 100% rename from Apps/Locations/Libraries/Tests/LocationsTests/Endpoints/GetLocationsEndpointTests.swift rename to Apps/Locations/Libraries/Tests/RemoteTests/Endpoints/GetLocationsEndpointTests.swift diff --git a/Apps/Locations/Libraries/Tests/LocationsTests/Helpers/Data+Constants.swift b/Apps/Locations/Libraries/Tests/RemoteTests/Helpers/Data+Constants.swift similarity index 100% rename from Apps/Locations/Libraries/Tests/LocationsTests/Helpers/Data+Constants.swift rename to Apps/Locations/Libraries/Tests/RemoteTests/Helpers/Data+Constants.swift diff --git a/Apps/Locations/Libraries/Tests/LocationsTests/Services/LocationsServiceTests.swift b/Apps/Locations/Libraries/Tests/RemoteTests/Services/LocationsServiceTests.swift similarity index 100% rename from Apps/Locations/Libraries/Tests/LocationsTests/Services/LocationsServiceTests.swift rename to Apps/Locations/Libraries/Tests/RemoteTests/Services/LocationsServiceTests.swift