How can I test my web pages in Microsoft Internet Explorer on a Mac?
Asked Answered
J

14

35

I want to test the web pages I create in all the modern versions of Internet Explorer (6, 7 and 8 beta) but I work mainly on a Mac and often don't have direct access to a PC.

Jamesjamesian answered 11/9, 2008 at 0:53 Comment(1)
(posted here and self answered because it's helpful info assembled from various tutorials and some trial and error and (a) I want to be able to find it again and (b) others might find it handy)Jamesjamesian
J
59

Update: Microsoft now provide virtual machine images for various versions of IE that are ready to use on all of the major OS X virtualisation platforms (VirtualBox, VMWare Fusion, and Parallels).

Download the appropriate image from: https://developer.microsoft.com/en-us/microsoft-edge/tools/vms/


On an Intel based Mac you can run Windows within a virtual machine. You will need one virtual machine for each version of IE you want to test against.

The instructions below include free and legal virtualisation software and Windows disk images.

  1. Download some virtual machine software. The developer disk images we're going to use are will work with either VMWare Fusion or Sun Virtual Box. VMWare has more features but costs $80, Virtual Box on the other hand is more basic but is free for most users (see Virtual Box licensing FAQ for details).
  2. Download the IE developer disk images, which are free from Microsoft: http://www.microsoft.com/downloads/...
  3. Extract the disk images using cabextract which is available from MacPorts or as source code (Thanks to Clinton).
  4. Download Q.app from http://www.kju-app.org/ and put it in your /Applications folder (you will need it to convert the disk images into a format VMWare/Virtual Box can use)

At this point, the process depends on which VM software you're using.

Virtual Box users

  1. Open a Terminal.app on your Mac (you can find it in /Applications/Utilities) and run the following sequence of commands, replacing input.vhd with the name of the VHD file you're starting from and output.vdi with the name you want your final disk image to have:

    /Applications/Q.app/Contents/MacOS/qemu-img convert -O raw -f vpc "input.vhd" temp.bin
    VBoxManage convertdd temp.bin "output.vdi"
    rm temp.bin
    mv "output.vdi" ~/Library/VirtualBox/VDI/
    VBoxManage modifyvdi "output.vdi" compact
    
  2. Start Virtual Box and create a new virtual machine
  3. Select the new VDI file you've just created as the boot hard disk

VMWare fusion users

  1. Open a Terminal.app on your Mac (you can find it in /Applications/Utilities) and run the following commands, replacing input.vhd and output.vmdk with the name of the VHD file you're working on and the name you want your resulting disk image to have:

    /Applications/Q.app/Contents/MacOS/qemu-img convert -O vmdk -f vpc "input.vhd" "output.vmdk"
    mv "output.vmdk" ~/Documents/Virtual\ Machines.localized/
    

    This will probably take a while (It takes around 30 minutes per disk image on my 2.4GHz Core 2 Duo MacBook w/ 2Gb RAM).

  2. Start VMWare Fusion and create a new virtual machine
  3. In the advanced disk options select "use and existing disk" and find the VMDK file you just created
Jamesjamesian answered 11/9, 2008 at 0:53 Comment(5)
The MS developer disk images are self-extracting EXEs. If you don't have Windows to extract them on, you can use cabextract, which you can get from MacPorts or compile from source.Exemplification
Great tutorial. Really appreciate it!Jeseniajesh
As of the August version of the VPC images, you can no longer convert the VPC images to other formats otherwise it will ask you to activate windows. My previous images expired today so I went to download the new ones and went through the conversion to VDI, I am now presented with activation messages and a warning that I have 3 days to activate. VirtualBox thread on this change in the EULA: forums.virtualbox.org/viewtopic.php?f=2&t=21712Bassesalpes
This answer has been rendered useless by Microsoft's EULA change. You can no longer use these images in Virtualbox without obtaining a Windows licence. It appears the VHD's will only work on Virtual PC. Thanks to Microsoft for missing the point (again) and not giving web devs the opportunity to test against their shitty browsers.Wits
I couldnt extract using cabextract, used unrar instead. unrar e filaname.part01.exe workedFading
R
8

There's three different methods that I recommend:

Cloud-based interactive virtual machines

Use something like SauceLabs or BrowserStack. You'll be able to pick a browser of choice, enter a url and use a real OS with the real browser and test and interact as much as you need. Both of these also support setting up a tunnel to/from your own machine so any local hostnames will work fine.

There is also CrossBrowserTesting, browserling/testling, which seem to have similar services although I haven't used these myself.

Local virtualization

You can use VirtualBox (free and open-source, similar to VMWare or Parallels) to create one or more virtual machines on your computer. You may or may not know this, but you do not need to get an official copy of Microsoft Windows for these virtual machines. Microsoft offers free VM images of simplified Windows installations for the purposes of testing Internet Explorer and Microsoft Edge (download). Check one of these articles to get that up and running:

In the past, there were also native Mac applications (such as ies4osx), or as a Windows application which requires a VM if you don't have Windows (such as IETester or MultipleIEs). The downside is that these emulations are often less stable than the real client, and are even harder to debug with because they don't run in the natural environment of the browser. Sometimes causing errors that don't occur in the real browser, and maybe not having bugs that the real browser would have.

Cloud-based screenshots factory

If you don't need interactivity and or need a cheaper solution (note that this method may not always be cheaper, do a little research before making assumptions) there are also services online that, like the previous one, have access to real browser/OS environments. But contrary to the previous, don't grant interactive access to the actual machines but only to get screenshots. This has both an upside and a downside. The downside is that you can't interact with it. The upside however is that most of these allow easy summarizing of screenshots so you don't have to start session after another and get screenshots.

Some I've used:

  • BrowserShots (free and used to be my favorite, although the slowness made alternatives more attractive)
  • Adobe BrowserLab (also free, requires an Adobe ID. Not as much options and coverage as BrowserShots, but: no delay, instant screenshots, compare views and ability to let the screenshot be taken after a given number of seconds instead of right away (to test asynchronous stuff).
  • CrossBrowserTesting (not free, but also has an interactive environment (see previous method) and a screenshot factory that is like your own private "BrowserShots" site)
Reckless answered 30/4, 2012 at 17:28 Comment(0)
I
7

Once you've virtualized Windows on your Mac, you can also try the Mutiple IE installer to get a variety of flavors of Internet Explorer without having to create separate VM instances.

If you're just wanting to see a simple screenshot of how the page will render in various browsers, you can try the free service browsershots or there are a number of services that will automatically test your pages in multiple browsers.

Interphone answered 11/9, 2008 at 0:59 Comment(0)
E
3

Litmus is another web-based alternative.

Ean answered 11/9, 2008 at 5:11 Comment(1)
This looks like it tests for email clients. Does it test for IE?Stokehole
M
2

Browsershots is another option if you just want to get screenshots..

Mayne answered 11/9, 2008 at 1:1 Comment(0)
A
2

There is an issue with the latest release (January 2009) of the VHDs. The VHD sees there are hardware changes and prompts for a license key, evenutally locking users out. As yet there is no known workaround.

Andersonandert answered 1/9, 2009 at 11:55 Comment(0)
C
1

If you don't have a copy of Windows that you could run in a virtual machine (VMware also isn't free), you can try IEs4Linux. It will require you configure some open source stuff on your Mac, but it is all free. You'll at least need fink, wine, and cabextract. See the link above for some specific command line directions. It's not that hard!

Coppersmith answered 11/9, 2008 at 1:5 Comment(2)
The original answer included links to free VM software (Virtual Box) and free Windows disk images (from Microsoft, for web developers). While IEs4Linux is also an option, you can also run Windows in a VM without spending anything.Jamesjamesian
The virtual PC images that microsoft let you download WERE free, but now they just built in protection so you can no longer convert the images to VMWare or VirtualBox images.Bassesalpes
P
1

I've used Codeweavers Crossover product for doing this from time to time.

http://www.codeweavers.com/products/cxmac/

It's a different option to virtualisation, and gives you a little more control than some of the hosted solutions. That said, it's based on WINE, and so you can potentially get all the problems and issues that come with doing it that way. That said, for basic testing without plugins, etc, it works great.

I'm not 100% sure about support for IE8, you'd need to check that out, but it definitely gives you native support for 6 and 7.

Passed answered 11/9, 2008 at 7:49 Comment(0)
S
1

You could use Spoon Browsers (web-based) once it becomes available for Mac.

Stokehole answered 27/1, 2011 at 18:6 Comment(0)
I
1

OSX Daily explains how to install Windows VMs with a single terminal command (assuming you already have VirtualBox installed). To summarize:

IE 7:

curl -s https://raw.github.com/xdissent/ievms/master/ievms.sh | IEVMS_VERSIONS="7" bash

IE 8:

curl -s https://raw.github.com/xdissent/ievms/master/ievms.sh | IEVMS_VERSIONS="8" bash

IE 9:

curl -s https://raw.github.com/xdissent/ievms/master/ievms.sh | IEVMS_VERSIONS="9" bash

ALL THE IEs!:

curl -s https://raw.github.com/xdissent/ievms/master/ievms.sh | bash
Ideational answered 25/2, 2012 at 2:31 Comment(0)
S
0

There's a OSX distribution of IEs4 Linux called ies4osx, which has worked fine for me without any configuration.

Spirillum answered 15/9, 2008 at 12:34 Comment(0)
H
0

Browsershots is nice, but useless if you need to test functionality rather than just overall visual rendering.

IEs4OSX and IEs4Linux have serious drawbacks. They have no real support for plugins and extensions like Flash and Silverlight. Rendering isn't precise and they're highly unstable. For testing you really need an actual version of IE running on Windows, but you don't need to have a dedicated box.

IE images on VirtualBox is really the best, and easiest way to go.

I have a screencast here if anyone's looking for a visual walk-through.

Heel answered 21/1, 2009 at 4:25 Comment(1)
Microsoft images are no longer allowed to be converted from VPC to any other image, it will prompt you for windows activation.Bassesalpes
I
0

Yet another Web based alternative (although as Jeff said, not much use for testing functionality) is http://www.browsercam.com

Illusory answered 21/1, 2009 at 17:47 Comment(1)
Looks like they are shutting it down: browsercam.com/important-messageVerina
P
-1

If this is a business web site (or a serious site where it is important that it actually works on IE), then don't take the cheap route - invest in a Windows machine or two. Your customers will thank you.

Otherwise, virtualize.

Phyfe answered 15/9, 2008 at 19:24 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.