-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix importing. Use .xcdatamodeld for coredata
- Loading branch information
1 parent
815a345
commit 33fe8e8
Showing
15 changed files
with
138 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
__author__ = 'rudy' | ||
from signals.main import run_signals | ||
|
||
__all__ = ['run_signals'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,4 @@ | ||
import signals.main | ||
signals.main.main() | ||
|
||
if __name__ == '__main__': | ||
signals.main.main() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>_XCCurrentVersionName</key> | ||
<string>dummy 2.xcdatamodel</string> | ||
</dict> | ||
</plist> |
File renamed without changes.
24 changes: 24 additions & 0 deletions
24
tests/files/doubledummy.xcdatamodeld/dummy.xcdatamodel/contents
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<model userDefinedModelVersionIdentifier="" macOSVersion="Automatic" minimumToolsVersion="Xcode 4.3" documentVersion="1.0" lastSavedToolsVersion="7549" systemVersion="14D136" type="com.apple.IDECoreDataModeler.DataModel" iOSVersion="Automatic"> | ||
<entity name="LoginResponse" representedClassName="LoginResponse"> | ||
<attribute name="clientSecret" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="clientId" optional="NO" attributeType="String" syncable="YES"/> | ||
</entity> | ||
<entity name="SignUpRequest" representedClassName="SignUpRequest"> | ||
<attribute name="username" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="fullname" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="password" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="email" optional="YES" attributeType="String" syncable="YES"/> | ||
</entity> | ||
<entity name="SignUpResponse" representedClassName="SignUpResponse"> | ||
<attribute name="username" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="clientSecret" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="fullname" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="email" optional="YES" attributeType="String" syncable="YES"/> | ||
<attribute name="clientId" optional="NO" attributeType="String" syncable="YES"/> | ||
</entity> | ||
<elements> | ||
<element name="LoginResponse" positionX="0" positionY="0" width="128" height="600"/> | ||
<element name="SignUpResponse" positionX="0" positionY="0" width="128" height="600"/> | ||
<element name="SignUpRequest" positionX="0" positionY="0" width="128" height="600"/> | ||
</elements> | ||
</model> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<model userDefinedModelVersionIdentifier="" macOSVersion="Automatic" minimumToolsVersion="Xcode 4.3" documentVersion="1.0" lastSavedToolsVersion="7549" systemVersion="14D136" type="com.apple.IDECoreDataModeler.DataModel" iOSVersion="Automatic"> | ||
<entity name="LoginResponse" representedClassName="LoginResponse"> | ||
<attribute name="clientSecret" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="clientId" optional="NO" attributeType="String" syncable="YES"/> | ||
</entity> | ||
<entity name="SignUpRequest" representedClassName="SignUpRequest"> | ||
<attribute name="username" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="fullname" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="password" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="email" optional="YES" attributeType="String" syncable="YES"/> | ||
</entity> | ||
<entity name="SignUpResponse" representedClassName="SignUpResponse"> | ||
<attribute name="username" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="clientSecret" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="fullname" optional="NO" attributeType="String" syncable="YES"/> | ||
<attribute name="email" optional="YES" attributeType="String" syncable="YES"/> | ||
<attribute name="clientId" optional="NO" attributeType="String" syncable="YES"/> | ||
</entity> | ||
<elements> | ||
<element name="LoginResponse" positionX="0" positionY="0" width="128" height="600"/> | ||
<element name="SignUpResponse" positionX="0" positionY="0" width="128" height="600"/> | ||
<element name="SignUpRequest" positionX="0" positionY="0" width="128" height="600"/> | ||
</elements> | ||
</model> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import unittest | ||
from signals.generators.ios.core_data import get_current_version, get_core_data_from_folder | ||
|
||
|
||
class CoreDataTestCase(unittest.TestCase): | ||
def test_get_current_version(self): | ||
version_name = get_current_version('./tests/files/doubledummy.xcdatamodeld') | ||
self.assertEqual(version_name, 'dummy 2.xcdatamodel') | ||
version_name = get_current_version('./tests/files/dummy.xcdatamodeld') | ||
self.assertEqual(version_name, 'dummy.xcdatamodel') | ||
|
||
def test_get_core_data_from_folder(self): | ||
xcdatamodeld_path = './tests/files/doubledummy.xcdatamodeld' | ||
contents_path = xcdatamodeld_path + '/dummy 2.xcdatamodel/contents' | ||
self.assertEqual(get_core_data_from_folder(xcdatamodeld_path), contents_path) | ||
|
||
xcdatamodeld_path = './tests/files/dummy.xcdatamodeld' | ||
contents_path = xcdatamodeld_path + '/dummy.xcdatamodel/contents' | ||
self.assertEqual(get_core_data_from_folder(xcdatamodeld_path), contents_path) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters