Skip to content

Commit

Permalink
Allow download of json and txt extensions for win builds (mozilla#119)
Browse files Browse the repository at this point in the history
  • Loading branch information
Nebelhom committed Oct 20, 2013
1 parent b7530d0 commit cc8ec8b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
8 changes: 4 additions & 4 deletions mozdownload/scraper.py
Original file line number Diff line number Diff line change
Expand Up @@ -443,8 +443,8 @@ def binary_regex(self):
'linux64': r'\.%(EXT)s$',
'mac': r'\.%(EXT)s$',
'mac64': r'\.%(EXT)s$',
'win32': r'(\.installer)%(STUB)s\.%(EXT)s$',
'win64': r'(\.installer)%(STUB)s\.%(EXT)s$'}
'win32': r'(\.installer)?%(STUB)s\.%(EXT)s$',
'win64': r'(\.installer)?%(STUB)s\.%(EXT)s$'}
regex = regex_base_name + regex_suffix[self.platform]

return regex % {'APP': self.application,
Expand Down Expand Up @@ -701,8 +701,8 @@ def binary_regex(self):
'linux64': r'.*\.%(EXT)s$',
'mac': r'.*\.%(EXT)s$',
'mac64': r'.*\.%(EXT)s$',
'win32': r'.*(\.installer)\.%(EXT)s$',
'win64': r'.*(\.installer)\.%(EXT)s$'}
'win32': r'.*(\.installer)?\.%(EXT)s$',
'win64': r'.*(\.installer)?\.%(EXT)s$'}

regex = regex_base_name + regex_suffix[self.platform]

Expand Down
2 changes: 2 additions & 0 deletions tests/test_cases.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ mozdownload -a firefox -t candidate -p linux -v 21.0
mozdownload -a firefox -t candidate -p linux64 -v 21.0
mozdownload -a firefox -t candidate -p mac -v 21.0
mozdownload -a firefox -t candidate -p win32 -v 21.0
mozdownload -a firefox -t candidate -p win32 -v 21.0 --extension=txt
mozdownload -a firefox -t candidate -p win32 -v 21.0 -d firefox-candidate-builds
mozdownload -a firefox -t candidate -p win32 -v 21.0 -l cs
mozdownload -a firefox -t candidate -p win32 -v 21.0 -l en-GB
Expand All @@ -36,6 +37,7 @@ mozdownload -a firefox -t tinderbox -p mac64 --branch=mozilla-central
mozdownload -a firefox -t tinderbox -p win32 --branch=mozilla-central
mozdownload -a firefox -t tinderbox -p win64 --branch=mozilla-central
mozdownload -a firefox -t tinderbox -p linux --branch=mozilla-central --extension=txt
mozdownload -a firefox -t tinderbox -p linux --branch=mozilla-central --extension=json
mozdownload -a firefox -t tinderbox -p win32 --branch=mozilla-central --debug-build
mozdownload -a firefox -t tinderbox -p win32 --branch=mozilla-central -d firefox-tinderbox-builds
mozdownload -a firefox -t tinderbox -p win32 --branch=mozilla-central -l el
Expand Down

0 comments on commit cc8ec8b

Please sign in to comment.