mirror of
https://github.com/sstent/alex_app1.git
synced 2026-01-26 17:12:37 +00:00
lots of work so far-- mostly tidying
This commit is contained in:
1
node_modules/formidable/test/fixture/file/funkyfilename.txt
generated
vendored
Normal file
1
node_modules/formidable/test/fixture/file/funkyfilename.txt
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
I am a text file with a funky name!
|
||||
1
node_modules/formidable/test/fixture/file/plain.txt
generated
vendored
Normal file
1
node_modules/formidable/test/fixture/file/plain.txt
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
I am a plain text file
|
||||
3
node_modules/formidable/test/fixture/http/special-chars-in-filename/info.md
generated
vendored
Normal file
3
node_modules/formidable/test/fixture/http/special-chars-in-filename/info.md
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
* Opera does not allow submitting this file, it shows a warning to the
|
||||
user that the file could not be found instead. Tested in 9.8, 11.51 on OSX.
|
||||
Reported to Opera on 08.09.2011 (tracking email DSK-346009@bugs.opera.com).
|
||||
3
node_modules/formidable/test/fixture/js/no-filename.js
generated
vendored
Normal file
3
node_modules/formidable/test/fixture/js/no-filename.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
module.exports['generic.http'] = [
|
||||
{type: 'file', name: 'upload', filename: '', fixture: 'plain.txt'},
|
||||
];
|
||||
21
node_modules/formidable/test/fixture/js/special-chars-in-filename.js
generated
vendored
Normal file
21
node_modules/formidable/test/fixture/js/special-chars-in-filename.js
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
var properFilename = 'funkyfilename.txt';
|
||||
|
||||
function expect(filename) {
|
||||
return [
|
||||
{type: 'field', name: 'title', value: 'Weird filename'},
|
||||
{type: 'file', name: 'upload', filename: filename, fixture: properFilename},
|
||||
];
|
||||
};
|
||||
|
||||
var webkit = " ? % * | \" < > . ? ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt";
|
||||
var ffOrIe = " ? % * | \" < > . ☃ ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt";
|
||||
|
||||
module.exports = {
|
||||
'osx-chrome-13.http' : expect(webkit),
|
||||
'osx-firefox-3.6.http' : expect(ffOrIe),
|
||||
'osx-safari-5.http' : expect(webkit),
|
||||
'xp-chrome-12.http' : expect(webkit),
|
||||
'xp-ie-7.http' : expect(ffOrIe),
|
||||
'xp-ie-8.http' : expect(ffOrIe),
|
||||
'xp-safari-5.http' : expect(webkit),
|
||||
};
|
||||
72
node_modules/formidable/test/fixture/multipart.js
generated
vendored
Normal file
72
node_modules/formidable/test/fixture/multipart.js
generated
vendored
Normal file
@@ -0,0 +1,72 @@
|
||||
exports['rfc1867'] =
|
||||
{ boundary: 'AaB03x',
|
||||
raw:
|
||||
'--AaB03x\r\n'+
|
||||
'content-disposition: form-data; name="field1"\r\n'+
|
||||
'\r\n'+
|
||||
'Joe Blow\r\nalmost tricked you!\r\n'+
|
||||
'--AaB03x\r\n'+
|
||||
'content-disposition: form-data; name="pics"; filename="file1.txt"\r\n'+
|
||||
'Content-Type: text/plain\r\n'+
|
||||
'\r\n'+
|
||||
'... contents of file1.txt ...\r\r\n'+
|
||||
'--AaB03x--\r\n',
|
||||
parts:
|
||||
[ { headers: {
|
||||
'content-disposition': 'form-data; name="field1"',
|
||||
},
|
||||
data: 'Joe Blow\r\nalmost tricked you!',
|
||||
},
|
||||
{ headers: {
|
||||
'content-disposition': 'form-data; name="pics"; filename="file1.txt"',
|
||||
'Content-Type': 'text/plain',
|
||||
},
|
||||
data: '... contents of file1.txt ...\r',
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
exports['noTrailing\r\n'] =
|
||||
{ boundary: 'AaB03x',
|
||||
raw:
|
||||
'--AaB03x\r\n'+
|
||||
'content-disposition: form-data; name="field1"\r\n'+
|
||||
'\r\n'+
|
||||
'Joe Blow\r\nalmost tricked you!\r\n'+
|
||||
'--AaB03x\r\n'+
|
||||
'content-disposition: form-data; name="pics"; filename="file1.txt"\r\n'+
|
||||
'Content-Type: text/plain\r\n'+
|
||||
'\r\n'+
|
||||
'... contents of file1.txt ...\r\r\n'+
|
||||
'--AaB03x--',
|
||||
parts:
|
||||
[ { headers: {
|
||||
'content-disposition': 'form-data; name="field1"',
|
||||
},
|
||||
data: 'Joe Blow\r\nalmost tricked you!',
|
||||
},
|
||||
{ headers: {
|
||||
'content-disposition': 'form-data; name="pics"; filename="file1.txt"',
|
||||
'Content-Type': 'text/plain',
|
||||
},
|
||||
data: '... contents of file1.txt ...\r',
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
exports['emptyHeader'] =
|
||||
{ boundary: 'AaB03x',
|
||||
raw:
|
||||
'--AaB03x\r\n'+
|
||||
'content-disposition: form-data; name="field1"\r\n'+
|
||||
': foo\r\n'+
|
||||
'\r\n'+
|
||||
'Joe Blow\r\nalmost tricked you!\r\n'+
|
||||
'--AaB03x\r\n'+
|
||||
'content-disposition: form-data; name="pics"; filename="file1.txt"\r\n'+
|
||||
'Content-Type: text/plain\r\n'+
|
||||
'\r\n'+
|
||||
'... contents of file1.txt ...\r\r\n'+
|
||||
'--AaB03x--\r\n',
|
||||
expectError: true,
|
||||
};
|
||||
Reference in New Issue
Block a user