test: make test apps' name prefixed with electron-test- (#33511)

This commit is contained in:
Cheng Zhao 2022-03-31 02:17:34 +09:00 committed by GitHub
parent a508dce1bf
commit 929fc8bea5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
23 changed files with 26 additions and 50 deletions

View file

@ -90,9 +90,9 @@ describe('app module', () => {
it('overrides the name', () => { it('overrides the name', () => {
expect(app.name).to.equal('Electron Test Main'); expect(app.name).to.equal('Electron Test Main');
app.name = 'test-name'; app.name = 'electron-test-name';
expect(app.name).to.equal('test-name'); expect(app.name).to.equal('electron-test-name');
app.name = 'Electron Test Main'; app.name = 'Electron Test Main';
}); });
}); });
@ -104,9 +104,9 @@ describe('app module', () => {
it('overrides the name', () => { it('overrides the name', () => {
expect(app.getName()).to.equal('Electron Test Main'); expect(app.getName()).to.equal('Electron Test Main');
app.setName('test-name'); app.setName('electron-test-name');
expect(app.getName()).to.equal('test-name'); expect(app.getName()).to.equal('electron-test-name');
app.setName('Electron Test Main'); app.setName('Electron Test Main');
}); });
}); });

View file

@ -1130,7 +1130,7 @@ describe('session module', () => {
session.defaultSession.setCodeCachePath(''); session.defaultSession.setCodeCachePath('');
}).to.throw('Absolute path must be provided to store code cache.'); }).to.throw('Absolute path must be provided to store code cache.');
expect(() => { expect(() => {
session.defaultSession.setCodeCachePath(path.join(app.getPath('userData'), 'test-code-cache')); session.defaultSession.setCodeCachePath(path.join(app.getPath('userData'), 'electron-test-code-cache'));
}).to.not.throw(); }).to.not.throw();
}); });
}); });

View file

@ -1,4 +1,4 @@
{ {
"name": "context-bridge-mutability", "name": "electron-test-context-bridge-mutability",
"main": "main.js" "main": "main.js"
} }

View file

@ -1,4 +1,4 @@
{ {
"name": "electron-safe-storage", "name": "electron-test-safe-storage",
"main": "main.js" "main": "main.js"
} }

View file

@ -1,4 +1,4 @@
{ {
"name": "electron-safe-storage", "name": "electron-test-safe-storage",
"main": "main.js" "main": "main.js"
} }

View file

@ -1,4 +1,4 @@
{ {
"name": "background-color-transparent", "name": "electron-test-background-color-transparent",
"main": "main.js" "main": "main.js"
} }

View file

@ -1,4 +1,4 @@
{ {
"name": "electron-xwindow-icon", "name": "electron-test-xwindow-icon",
"main": "main.js" "main": "main.js"
} }

View file

@ -1,5 +1,5 @@
{ {
"name": "electron-test-initial-app", "name": "electron-test-check-with-headers",
"version": "1.0.0", "version": "1.0.0",
"main": "./index.js" "main": "./index.js"
} }

View file

@ -1,5 +1,5 @@
{ {
"name": "electron-test-initial-app", "name": "electron-test-check",
"version": "1.0.0", "version": "1.0.0",
"main": "./index.js" "main": "./index.js"
} }

View file

@ -1,5 +1,5 @@
{ {
"name": "initial-app", "name": "electron-test-update-json",
"version": "1.0.0", "version": "1.0.0",
"main": "./index.js" "main": "./index.js"
} }

View file

@ -1,5 +1,5 @@
{ {
"name": "initial-app", "name": "electron-test-update",
"version": "1.0.0", "version": "1.0.0",
"main": "./index.js" "main": "./index.js"
} }

View file

@ -1,4 +1,4 @@
{ {
"name": "electron-cookie-app", "name": "electron-test-cookie-app",
"main": "main.js" "main": "main.js"
} }

View file

@ -1 +0,0 @@
!node_modules

View file

@ -1,14 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title></title>
<script>
require('foo').bar()
require('electron').ipcRenderer.send('answer')
</script>
</head>
<body>
</body>
</html>

View file

@ -1,4 +0,0 @@
{
"name": "electron",
"main": "index.js"
}

View file

@ -1 +0,0 @@
exports.bar = function () {};

View file

@ -1,4 +0,0 @@
{
"name": "foo",
"main": "index.js"
}

View file

@ -1,5 +1,5 @@
{ {
"name": "electron-app-mixed-sandbox", "name": "electron-test-mixed-sandbox",
"main": "main.js" "main": "main.js"
} }

View file

@ -1,4 +1,4 @@
{ {
"name": "electron-quit-app", "name": "electron-test-quit-app",
"main": "main.js" "main": "main.js"
} }

View file

@ -1,5 +1,5 @@
{ {
"name": "electron-app-relaunch", "name": "electron-test-relaunch",
"main": "main.js" "main": "main.js"
} }

View file

@ -1,5 +1,5 @@
{ {
"name": "electron-app-singleton-data", "name": "electron-test-singleton-data",
"main": "main.js" "main": "main.js"
} }

View file

@ -1,5 +1,5 @@
{ {
"name": "electron-app-singleton", "name": "electron-test-singleton",
"main": "main.js" "main": "main.js"
} }