Skip to content

Commit

Permalink
Merge pull request telefonicaid#1499 from telefonicaid/fix/test_stati…
Browse files Browse the repository at this point in the history
…c_multientity_jexl

fix multientity jexl and static test: replace static -> staticAttributes
  • Loading branch information
mapedraza authored Oct 9, 2023
2 parents 14d065c + e3645e6 commit 979a99b
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{
"actionType": "append",
"entities": [
{
"id": "ws9",
"type": "WeatherStation",
"st1": {
"value": 1,
"type": "Number"
},
"st2": {
"value": 2,
"type": "Number"
},
"vol": {
"type": "Number",
"value": 0
}
},
{
"vol": {
"type": "Number",
"value": 100
},
"type": "WeatherStation",
"id": "WeatherStation1"
},
{
"vol": {
"type": "Number",
"value": 200
},
"type": "WeatherStation",
"id": "WeatherStation2"
}
]
}
12 changes: 6 additions & 6 deletions test/unit/ngsiv2/expressions/jexlBasedTransformations-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ const iotAgentConfig = {
commands: [],
type: 'GPS',
lazy: [],
static: [
staticAttributes: [
{
name: 'color',
type: 'string',
Expand All @@ -309,7 +309,7 @@ const iotAgentConfig = {
commands: [],
type: 'GPS',
lazy: [],
static: [
staticAttributes: [
{
name: 'color',
type: 'string',
Expand All @@ -333,7 +333,7 @@ const iotAgentConfig = {
commands: [],
type: 'GPS',
lazy: [],
static: [
staticAttributes: [
{
name: 'color',
type: 'string',
Expand All @@ -357,7 +357,7 @@ const iotAgentConfig = {
commands: [],
type: 'GPS',
lazy: [],
static: [
staticAttributes: [
{
name: 'lat',
type: 'string',
Expand All @@ -382,7 +382,7 @@ const iotAgentConfig = {
commands: [],
type: 'GPS',
lazy: [],
static: [
staticAttributes: [
{
name: 'lat',
type: 'Number',
Expand All @@ -407,7 +407,7 @@ const iotAgentConfig = {
commands: [],
type: 'GPS',
lazy: [],
static: [
staticAttributes: [
{
name: 'color',
type: 'string',
Expand Down
6 changes: 3 additions & 3 deletions test/unit/ngsiv2/plugins/multientity-plugin_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ const iotAgentConfig = {
commands: [],
type: 'WeatherStation',
lazy: [],
static: [
staticAttributes: [
{
name: 'st1',
type: 'Number',
Expand Down Expand Up @@ -570,7 +570,7 @@ const iotAgentConfig = {
object_id: 'y'
}
],
static: [
staticAttributes: [
{
name: 'bar',
type: 'text',
Expand Down Expand Up @@ -1126,7 +1126,7 @@ describe('NGSI-v2 - Multi-entity plugin', function () {
.post(
'/v2/op/update',
utils.readExampleFile(
'./test/unit/ngsiv2/examples/contextRequests/updateContextMultientityPlugin10.json'
'./test/unit/ngsiv2/examples/contextRequests/updateContextMultientityPlugin10b.json'
)
)
.reply(204);
Expand Down

0 comments on commit 979a99b

Please sign in to comment.