假时区用于Web应用程序测试 [英] Fake time zone for web app testing
问题描述
我有一个Web应用程序,亚洲一些人看到程序中的日期存在一些奇怪的时区问题.有没有办法伪造chrome,firefox或IE,就像我的计算机所在的时区一样,这样我就可以轻松调试问题了?
I have a web app and some people in Asia are seeing some weird time zone issues with the dates in the program. Is there a way to fake chrome or firefox or IE to pretend like my computer's timezone is like theirs so I can debug the issues easily?
推荐答案
确定:使用自定义的TZ
环境变量从命令行启动浏览器,而不是通常的运行方式:
Sure: launch the browser from the command line with a customized TZ
environment variable instead of the way you normally run it:
TZ=Japan firefox &
确保像这样启动firefox时它尚未运行,因为如果它已经在运行,则它可能只是在浏览器的现有实例下打开一个新窗口,而不是启动一个新实例.
Make sure firefox isn't already running when you launch it like this because if it is already running then it will probably just open a new window under the existing instance of the browser instead of starting a new instance.
这篇关于假时区用于Web应用程序测试的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!