notebooks/components/crud-web-apps/common/frontend/kubeflow-common-lib
Orfeas Kourkakis cf5301b10a vwa(front): Add UI tests with Cypress (kubeflow/kubeflow#6862)
* web-apps(front): Remove Protractor files

Remove Protractor files since it's not used anywhere in the common
code.

Signed-off-by: Orfeas Kourkakis <orfeas@arrikto.com>

* web-apps(front): Add Cypress attributes

Add more attributes and modify some existing ones for elements to be
selectable during UI tests with Cypress.

Signed-off-by: Orfeas Kourkakis <orfeas@arrikto.com>

* vwa(front): Install Cypress

 - Install Cypress & npm scripts for UI tests
 - Remove Protractor files
 - Update README.md with UI tests instructions

Signed-off-by: Orfeas Kourkakis <orfeas@arrikto.com>

* vwa(front): Add UI tests with Cypress

 - Add Cypress attributes for elements to be selectable during
   UI tests.
 - Add UI tests with Cypress to check that:
    * New Volume form dialog has proper values
    * Index page table contains all PVC names received
    * Index page table status icons are correctly shown
    * Index page table browse buttons are correctly shown

Signed-off-by: Orfeas Kourkakis <orfeas@arrikto.com>

* gh-actions(vwa): Add UI tests to VWA's frontend workflow

Add UI tests to VWA's frontend workflow. These tests should run in
Ubuntu 20.04 since Ubuntu 20.04 includes both Chrome and Firefox
installations by default.

Signed-off-by: Orfeas Kourkakis <orfeas@arrikto.com>

* vwa(front): Fix formatting errors

Signed-off-by: Orfeas Kourkakis <orfeas@arrikto.com>

* web-apps(front): Fix format errors

Signed-off-by: Orfeas Kourkakis <orfeas@arrikto.com>

Signed-off-by: Orfeas Kourkakis <orfeas@arrikto.com>
2023-01-03 13:11:24 +00:00
..
projects/kubeflow vwa(front): Add UI tests with Cypress (kubeflow/kubeflow#6862) 2023-01-03 13:11:24 +00:00
scripts web-apps(front): Install prettier and create a frontend workflow (kubeflow/kubeflow#6853) 2022-12-23 13:49:14 +00:00
.editorconfig Create an Angular Library with common frontend code (kubeflow/kubeflow#5252) 2020-08-28 05:14:53 -07:00
.eslintrc.json Fix ng lint (kubeflow/kubeflow#6586) 2022-07-21 12:30:17 +00:00
.gitignore Create an Angular Library with common frontend code (kubeflow/kubeflow#5252) 2020-08-28 05:14:53 -07:00
README.md web-apps(front): Update the README (kubeflow/kubeflow#5481) 2020-12-23 02:42:28 -08:00
angular.json web-apps: Ensure in-flight requests are cancelled (kubeflow/kubeflow#6718) 2022-11-10 14:37:00 +00:00
package-lock.json vwa(front): Add UI tests with Cypress (kubeflow/kubeflow#6862) 2023-01-03 13:11:24 +00:00
package.json vwa(front): Add UI tests with Cypress (kubeflow/kubeflow#6862) 2023-01-03 13:11:24 +00:00
tsconfig.json web-apps: Common code for all-namespaces (kubeflow/kubeflow#6730) 2022-11-14 16:22:26 +00:00

README.md

Kubeflow Common Frontend Library

This code provides a common library of reusable Angular Components that can be used from our different Kubeflow web apps. This library aims to:

  • Enforce a common UX throughout the different apps
  • Reduce the development effort required to propagate changes to all the web apps
  • Minimize the code duplication between our Kubeflow web apps

This project was generated with Angular CLI version 8.3.20, which is required to build and run the unit tests.

Local development

In order to use this library while developing locally your Angular app you will need to:

  1. Build the kubeflow node module from this source code
  2. Link the produced module to your global npm modules
  3. Link the kubeflow module in the npm modules of you app

Building the library locally

# build the npm module
npm run build

# might need sudo, depending on where you global folder lives
# https://nodejs.dev/learn/where-does-npm-install-the-packages
npm link dist/kubeflow

Linking it to the app

cd ${APP_DIR}
npm install
npm link kubeflow

Running unit tests

Run ng test to execute the unit tests via Karma.

Contributor Guidelines

Unit tests

  1. Any new component added to this library should also include some basic unit tests
  2. The unit tests should be passing at any point of time

Git commits

Git commits that modify this code should be prefixed with web-apps(front).