 		km.person
 
 	@test.assertEquals originalPerson, newPerson, 'Person is persistent in localStorage'
+
+casper.then ->
+	originalPerson = @evaluate ->
+		km = new window.AnonKissmetricsClient 'abc123',
+			storage: 'localStorage'
+			storageKey: 'customKey'
+		km.person
+
+	newPerson = @evaluate ->
+		km = new window.AnonKissmetricsClient 'abc123',
+			storage: 'localStorage'
+			storageKey: 'customKey'
+		km.person
+
+	@test.assertEquals originalPerson, newPerson, 'Person is persistent in localStorage with custom storage key'
 
 
 # Record


casper.then ->
	originalPerson = @evaluate ->
		km = new window.AnonKissmetricsClient 'abc123', {storage: 'localStorage'}
		km.person


	@test.assertTruthy ID, 'ID is stored in localStorage'

casper.then ->
	ID = @evaluate ->
		new window.AnonKissmetricsClient 'abc123', {storageKey: 'customKey'}
		window.localStorage.getItem 'customKey'

	@test.assertTruthy ID, 'ID is stored in localStorage with custom storage key'

casper.then ->
	data = @evaluate ->
		km = new window.AnonKissmetricsClient 'abc123', {storage: 'cookie'}
		{cookies: document.cookie, person: km.person}
