summaryrefslogtreecommitdiffstats
path: root/portal-FE-os/e2e
diff options
context:
space:
mode:
Diffstat (limited to 'portal-FE-os/e2e')
-rw-r--r--portal-FE-os/e2e/protractor.conf.js28
-rw-r--r--portal-FE-os/e2e/src/app.e2e-spec.ts14
-rw-r--r--portal-FE-os/e2e/src/app.po.ts11
-rw-r--r--portal-FE-os/e2e/tsconfig.e2e.json13
4 files changed, 66 insertions, 0 deletions
diff --git a/portal-FE-os/e2e/protractor.conf.js b/portal-FE-os/e2e/protractor.conf.js
new file mode 100644
index 00000000..86776a39
--- /dev/null
+++ b/portal-FE-os/e2e/protractor.conf.js
@@ -0,0 +1,28 @@
+// Protractor configuration file, see link for more information
+// https://github.com/angular/protractor/blob/master/lib/config.ts
+
+const { SpecReporter } = require('jasmine-spec-reporter');
+
+exports.config = {
+ allScriptsTimeout: 11000,
+ specs: [
+ './src/**/*.e2e-spec.ts'
+ ],
+ capabilities: {
+ 'browserName': 'chrome'
+ },
+ directConnect: true,
+ baseUrl: 'http://localhost:4200/',
+ framework: 'jasmine',
+ jasmineNodeOpts: {
+ showColors: true,
+ defaultTimeoutInterval: 30000,
+ print: function() {}
+ },
+ onPrepare() {
+ require('ts-node').register({
+ project: require('path').join(__dirname, './tsconfig.e2e.json')
+ });
+ jasmine.getEnv().addReporter(new SpecReporter({ spec: { displayStacktrace: true } }));
+ }
+}; \ No newline at end of file
diff --git a/portal-FE-os/e2e/src/app.e2e-spec.ts b/portal-FE-os/e2e/src/app.e2e-spec.ts
new file mode 100644
index 00000000..5bd43732
--- /dev/null
+++ b/portal-FE-os/e2e/src/app.e2e-spec.ts
@@ -0,0 +1,14 @@
+import { AppPage } from './app.po';
+
+describe('workspace-project App', () => {
+ let page: AppPage;
+
+ beforeEach(() => {
+ page = new AppPage();
+ });
+
+ it('should display welcome message', () => {
+ page.navigateTo();
+ expect(page.getTitleText()).toEqual('Welcome to portal-FE-os!');
+ });
+});
diff --git a/portal-FE-os/e2e/src/app.po.ts b/portal-FE-os/e2e/src/app.po.ts
new file mode 100644
index 00000000..72e463a3
--- /dev/null
+++ b/portal-FE-os/e2e/src/app.po.ts
@@ -0,0 +1,11 @@
+import { browser, by, element } from 'protractor';
+
+export class AppPage {
+ navigateTo() {
+ return browser.get('/');
+ }
+
+ getTitleText() {
+ return element(by.css('app-root h1')).getText();
+ }
+}
diff --git a/portal-FE-os/e2e/tsconfig.e2e.json b/portal-FE-os/e2e/tsconfig.e2e.json
new file mode 100644
index 00000000..a6dd6220
--- /dev/null
+++ b/portal-FE-os/e2e/tsconfig.e2e.json
@@ -0,0 +1,13 @@
+{
+ "extends": "../tsconfig.json",
+ "compilerOptions": {
+ "outDir": "../out-tsc/app",
+ "module": "commonjs",
+ "target": "es5",
+ "types": [
+ "jasmine",
+ "jasminewd2",
+ "node"
+ ]
+ }
+} \ No newline at end of file