Changeset 42315 in webkit for trunk/JavaScriptCore/API/tests/testapi.c
- Timestamp:
- Apr 8, 2009, 12:06:14 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/API/tests/testapi.c
r41931 r42315 119 119 } 120 120 121 static bool timeZoneIsPST() 122 { 123 char timeZoneName[70]; 124 struct tm gtm; 125 memset(>m, 0, sizeof(gtm)); 126 strftime(timeZoneName, sizeof(timeZoneName), "%Z", >m); 127 128 return 0 == strcmp("PST", timeZoneName); 129 } 130 121 131 static JSValueRef jsGlobalValue; // non-stack value for testing JSValueProtect() 122 132 … … 1059 1069 JSValueRef argumentsDateValues[] = { JSValueMakeNumber(context, 0) }; 1060 1070 o = JSObjectMakeDate(context, 1, argumentsDateValues, NULL); 1061 assertEqualsAsUTF8String(o, "Wed Dec 31 1969 16:00:00 GMT-0800 (PST)"); 1071 if (timeZoneIsPST()) 1072 assertEqualsAsUTF8String(o, "Wed Dec 31 1969 16:00:00 GMT-0800 (PST)"); 1062 1073 1063 1074 string = JSStringCreateWithUTF8CString("an error message");
Note:
See TracChangeset
for help on using the changeset viewer.