mirror of
https://github.com/finos/SymphonyElectron.git
synced 2025-02-25 18:55:29 -06:00
update test for build server (#24)
This commit is contained in:
parent
d4ef876828
commit
1c078fb2f8
@ -1,11 +1,17 @@
|
||||
const path = require('path');
|
||||
|
||||
// use config provided by test framework
|
||||
function pathToConfigDir() {
|
||||
return path.join(__dirname, '..');
|
||||
return path.join(__dirname, '/../fixtures');
|
||||
}
|
||||
const app = {
|
||||
getAppPath: pathToConfigDir,
|
||||
getPath: pathToConfigDir
|
||||
getPath: function(type) {
|
||||
if (type === 'exe') {
|
||||
return path.join(pathToConfigDir(), '/Symphony.exe');
|
||||
}
|
||||
return pathToConfigDir();
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
|
3
tests/fixtures/config/Symphony.config
vendored
Normal file
3
tests/fixtures/config/Symphony.config
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
{
|
||||
"url": "https://my.symphony.com"
|
||||
}
|
@ -10,6 +10,6 @@ jest.mock('../js/utils', function() {
|
||||
|
||||
test('getConfig should have proper url', function() {
|
||||
return getConfig(false).then(function(result) {
|
||||
expect(result.url).toBe('https://foundation-dev.symphony.com');
|
||||
expect(result.url).toBe('https://my.symphony.com');
|
||||
});
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user