Skip to content

Commit

Permalink
rec.la => loopback.dev and fixing browser tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Perki committed Feb 27, 2024
1 parent d202d04 commit 52e7be8
Show file tree
Hide file tree
Showing 33 changed files with 1,093 additions and 883 deletions.
2 changes: 1 addition & 1 deletion components/pryv-monitor/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@pryv/monitor",
"version": "2.3.7",
"version": "2.3.8",
"description": "Extends `pryv` with event-driven notifications for changes on a Pryv.io account",
"keywords": [
"Pryv",
Expand Down
2 changes: 1 addition & 1 deletion components/pryv-monitor/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ module.exports = function (pryv) {
*/

/**
* A scope corresponding to EventGetParameters @see https://l.rec.la:4443/reference#get-events
* A scope corresponding to EventGetParameters @see https://l.backloop.dev:4443/reference#get-events
* Property `limit` cannot be specified;
* @typedef {Object} pryv.Monitor.Scope
* @property {timestamp} [fromTime=TIMERANGE_MIN] (in seconds)
Expand Down
4 changes: 2 additions & 2 deletions components/pryv-socket.io/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Once the add-on is loaded, `pryv.Connection` instances expose the `socket` prope
const pryv = require('pryv');
require('@pryv/socket.io')(pryv);

const apiEndpoint = 'https://{token}@my-computer.rec.la:4443/{username}/';
const apiEndpoint = 'https://{token}@my-computer.backloop.dev:4443/{username}/';
(async () => {
const conn = new pryv.Connection(apiEndpoint);
try {
Expand All @@ -77,7 +77,7 @@ const apiEndpoint = 'https://{token}@my-computer.rec.la:4443/{username}/';
<script src="https://api.pryv.com/lib-js-socket.io/pryv-socket.io.js"></script>

<script>
const apiEndpoint = 'https://{token}@my-computer.rec.la:4443/{username}/';
const apiEndpoint = 'https://{token}@my-computer.backloop.dev:4443/{username}/';
(async function () { 
try {
await conn.socket.open();
Expand Down
2 changes: 1 addition & 1 deletion components/pryv-socket.io/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@pryv/socket.io",
"version": "2.3.7",
"version": "2.3.8",
"description": "Extends `pryv` with Socket.IO transport",
"keywords": [
"Pryv",
Expand Down
8 changes: 5 additions & 3 deletions components/pryv/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -648,11 +648,11 @@ There is a possibility that you would like to register the user in another page.

You can find HTML examples in the [`./examples`](https://github.com/pryv/lib-js/blob/master/examples) directory. You can run them in two ways:

1. With [rec.la](https://github.com/pryv/rec.la), which allows to run local code with a valid SSL certificate (you must have run `just build` beforehand):
1. With [backloop.dev](https://github.com/pryv/backloop.dev), which allows to run local code with a valid SSL certificate (you must have run `just build` beforehand):
```
just serve
```
then open the desired example page (e.g. [https://l.rec.la:9443/examples/auth.html](https://l.rec.la:9443/examples/auth.html)
then open the desired example page (e.g. [https://l.backloop.dev:9443/examples/auth.html](https://l.backloop.dev:9443/examples/auth.html)
2. As a simple HTML file, passing service information as JSON to avoid CORS issues


Expand All @@ -676,6 +676,8 @@ The project is structured as a monorepo with components (a.k.a. workspaces in NP
- `pryv-socket.io`: Socket.IO add-on
- `pryv-monitor`: Monitor add-on



The code follows the [Semi-Standard](https://github.com/standard/semistandard) style.

### Building for the browser
Expand Down Expand Up @@ -707,7 +709,7 @@ TEST_PRYVLIB_SERVICEINFO_URL="https://reg.${DOMAIN}/service/info" just test all
To run the tests against _in-development_ API server components (e.g. open-source or Entreprise), set `TEST_PRYVLIB_DNSLESS_URL`; for example:

```bash
TEST_PRYVLIB_DNSLESS_URL="http://l.rec.la:3000/ just test all
TEST_PRYVLIB_DNSLESS_URL="http://l.backloop.dev:3000/ just test all
```
#### Browser
Expand Down
2 changes: 1 addition & 1 deletion components/pryv/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "pryv",
"version": "2.3.7",
"version": "2.3.8",
"description": "Pryv JavaScript library",
"keywords": [
"Pryv",
Expand Down
2 changes: 1 addition & 1 deletion components/pryv/test/browser-index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

<body>
<div id="mocha"></div>
<script src="https://unpkg.com/chai/chai.js"></script>
<script src="https://unpkg.com/chai@4.3.7/chai.js"></script>
<script src="https://unpkg.com/mocha/mocha.js"></script>

<script class="mocha-init">
Expand Down
2 changes: 1 addition & 1 deletion examples/auth-with-redirection.html
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ <h1>Example: Auth with redirection</h1>
level: 'read',
}],
// the login page where user will be redirected
returnURL: 'https://l.rec.la:9443/demos/auth-with-redirection.html#'
returnURL: 'https://l.backloop.dev:9443/demos/auth-with-redirection.html#'
}
};

Expand Down
10 changes: 5 additions & 5 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -60,13 +60,13 @@ test-cover component *params:

# Run browser tests (assumes browser files are built)
test-browser:
(sleep 1 && open https://l.rec.la:8443/?pryvServiceInfoUrl=https://zou.zou/service/info) &
rec.la ./test-browser 8443
(sleep 1 && open https://l.backloop.dev:8443/?pryvServiceInfoUrl=https://zou.zou/service/info) &
backloop.dev ./test-browser 8443

# Start a `rec.la` web server on `dist/`
# Start a `backloop.dev` web server on `dist/`
serve:
(sleep 1 && open https://l.rec.la:9443/) &
rec.la ./dist 9443
(sleep 1 && open https://l.backloop.dev:9443/) &
backloop.dev ./dist 9443

# –––––––––––––----------------------------------------------------------------
# Misc. utils
Expand Down
Loading

0 comments on commit 52e7be8

Please sign in to comment.