Fix test for RN asset
Reviewed By: cpojer, rafeca Differential Revision: D5777553 fbshipit-source-id: 3bc8559076435c6254972552095967b88acb0576
This commit is contained in:
parent
165f876730
commit
33bbfb7125
|
@ -5,14 +5,14 @@ exports[`renders assets based on relative path 1`] = `
|
|||
<Image
|
||||
source={
|
||||
Object {
|
||||
"testUri": "Libraries/Image/__tests__/img/img1.png",
|
||||
"testUri": "../Libraries/Image/__tests__/img/img1.png",
|
||||
}
|
||||
}
|
||||
/>
|
||||
<Image
|
||||
source={
|
||||
Object {
|
||||
"testUri": "Libraries/Image/__tests__/img/img2.png",
|
||||
"testUri": "../Libraries/Image/__tests__/img/img2.png",
|
||||
}
|
||||
}
|
||||
/>
|
||||
|
|
|
@ -20,7 +20,7 @@ module.exports = {
|
|||
// the Jest snapshot.
|
||||
process: (_, filename) =>
|
||||
`module.exports = {
|
||||
testUri: ${JSON.stringify(path.relative('.', filename))}
|
||||
testUri: ${JSON.stringify(path.relative(__dirname, filename))}
|
||||
};`,
|
||||
getCacheKey: createCacheKeyFunction([__filename]),
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue