Skip to content

3.0 Development Branch#80

Merged
dfed merged 78 commits intomasterfrom
develop/3.0
Mar 3, 2018
Merged

3.0 Development Branch#80
dfed merged 78 commits intomasterfrom
develop/3.0

Conversation

@EricMuller22
Copy link
Copy Markdown
Collaborator

@EricMuller22 EricMuller22 commented Jun 16, 2016

The one where emuller flails around making things Schwifty
schwifty

cc @dfed @emish @brianpartridge
#84

@danielribeiro
Copy link
Copy Markdown
Contributor

xcodebuild: error: The project named "Valet" does not contain a scheme named "Valet Mac". The "-list" option can be used to find the names of the schemes in the project.

Maybe forgot to mark as a shared scheme?

.travis.yml Outdated
@@ -1,10 +1,9 @@
language: objective-c
osx_image: xcode6.4
osx_image: xcode7.3
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since we're going to be using Swift 3, we'll need to go to xcode8

Gemfile Outdated
source 'https://rubygems.org'

gem 'cocoapods', '0.39.0'
gem 'cocoapods', '1.0.1'
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you'll need 1.1.0.rc.2 at a minimum to support Swift 3

@dfed
Copy link
Copy Markdown
Collaborator

dfed commented Sep 16, 2017

After a way-too-long hiatus, Eric and I are back and working on this PR. There's a lot to do, but we're starting with getting our Swift Valet tests up and running on Xcode 9 GM Seed using Swift 3.2. Once we're building with Swift 3.2, we'll likely change the tests to Swift 4.

Our high-level plan is still the same as we outlined in #84.

@EricMuller22 EricMuller22 force-pushed the develop/3.0 branch 3 times, most recently from 7586397 to a08298f Compare September 17, 2017 22:18
@dfed dfed force-pushed the develop/3.0 branch 4 times, most recently from 522b3e1 to bf651bc Compare September 18, 2017 16:09
import Foundation


public enum SynchronizableAccessibility: CustomStringConvertible {
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

possible to protocolize instead?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also, possibly better spot (maybe not): internal enums to the two classes where we can only expose a subset like this? (synchronizable, secureenclave)

import Foundation


@available(iOS 7.0.3, macOS 10.9, *)
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💀



@available(iOS 7.0.3, macOS 10.9, *)
/// Reads and writes keychain elements that are synchronized with iCloud (supported on devices on iOS 7.0.3 and later).
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comment also outdated 😂


@available(iOS 7.0.3, macOS 10.9, *)
/// Reads and writes keychain elements that are synchronized with iCloud (supported on devices on iOS 7.0.3 and later).
public final class SynchronizableValet: NSObject, KeychainQueryConvertible {
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

devil's advocate - could we de-duplicate some of this?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

now that we've done this, subclass feels more valid. or.... base Valet but with a different flavor/accessibility

// The iPhone simulator fakes entitlements, allowing us to test the iCloud Keychain (VALSynchronizableValet) code without writing a signed host app.
#if (arch(i386) || arch(x86_64)) && os(iOS)
// Until we can write a signed host app on macOS, we can only test the iCloud Keychain (SynchronizableValet) code on iOS.
#if os(iOS)
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm a bit nervous about removal of the simulator #if logic here - e.g. I think unit tests can be run on device and these will fail unless the build is signed

}
}

class func iCloudPermutations(_ identifier: Identifier, shared: Bool = false) -> [Valet] {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would use with identifier rather than just _ identifier. Unnamed vars confuse me

valet.removeAllObjects()
let identifier = SynchronizableTests.identifier
let allPermutations = Valet.iCloudPermutations(identifier) + Valet.iCloudPermutations(identifier, shared: true)
_ = allPermutations.map { testValet in testValet.removeAllObjects() }
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you're looking for forEach

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lol

@dfed dfed merged commit acab210 into master Mar 3, 2018
@dfed dfed deleted the develop/3.0 branch March 3, 2018 02:19
@gfontenot
Copy link
Copy Markdown
Contributor

🎉 ✨ 🕺

@AndrewSB
Copy link
Copy Markdown

AndrewSB commented Mar 3, 2018

🎈🎉🔒

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants