forked from mirrors/gecko-dev
		
	 4a06c925ac
			
		
	
	
		4a06c925ac
		
	
	
	
	
		
			
			# ignore-this-changeset Differential Revision: https://phabricator.services.mozilla.com/D36052 --HG-- extra : source : b5be5b4f4b47c256e28a29f665dc754f6407ee7f
		
			
				
	
	
		
			17 lines
		
	
	
	
		
			453 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			17 lines
		
	
	
	
		
			453 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| function fileURL(filename) {
 | |
|   let ifile = getChromeDir(getResolvedURI(gTestPath));
 | |
|   ifile.append(filename);
 | |
|   return Services.io.newFileURI(ifile).spec;
 | |
| }
 | |
| 
 | |
| function httpURL(filename, host = "https://example.com/") {
 | |
|   let root = getRootDirectory(gTestPath).replace(
 | |
|     "chrome://mochitests/content/",
 | |
|     host
 | |
|   );
 | |
|   return root + filename;
 | |
| }
 | |
| 
 | |
| function add307(url, host = "https://example.com/") {
 | |
|   return httpURL("307redirect.sjs?" + url, host);
 | |
| }
 |