This project is a first template using the Webcom tools in the field of IoT. This project is an example of web application that uses webcom and angularjs together.
This application is used to manage connected objects. It is based on AngularJs framework and Webcom SDK JS, and it is tested by using KARMA framework.
In this application you can access to several pages:
In order to use the application on your development environment (Ubuntu), you have to install some tools.
$ sudo apt-get update
$ sudo apt-get install nodejs npm
In order to get a development environment running on your computer, you have to clone the project before:
- Defining the namespace by changing the variable "datasyncUri" in the config-service.js file
- Installing all the project dependencies mentionned in the file : package.json
$ cd iot-dashboard/
$ npm install
- Launching the development environment
[still in the iot-dashboard/ folder]
$ npm run dev
After launching the development environment, you have to open, in the browser of your choice, this link: http://localhost:8080
These tests test three things:
- Application services (AngularJs)
- Application modules (AngularJs)
- Security rules (Webcom)
In order to run the auomated tests, you have to define the admin credentials in the tools.js file. After this, you have to define the namespace for tests, by changing the two variables "datasyncUri" and "WebcomAppName" in the testConfig.js file. In the end, you have to use this command.
[still in the iot-dashboard/ folder]
$ npm test
To do parallel tests on differents browsers, you have to modify the karma.conf.js file by adding the name of the browser, separated by a comma, to the variable "browsers" and the corresponding plugin to the variable "plugins".
To deploy the application, you have to use the command below:
[still in the iot-dashboard/ folder]
$ npm start
After launching the development environment, you have to open, in the browser of your choice, this link: http://localhost:8080
- NodeJs - v6.11.3
- Webcom SDK - v1.3.2
- AngularJs - v1.6.6
- KARMA - v0.13.22
- webpack - v2.7.1
- BOUCHTAOUI Otmane - Trainee - otmane.bouchtaoui@orange.com
- BOUHLEL Aymen - Trainee - aymen.bouhlel@orange.com