Skip to content

Commit

Permalink
Merge branch 'develop' into feature/getVariableCategoryName
Browse files Browse the repository at this point in the history
  • Loading branch information
mikepsinn authored May 26, 2020
2 parents adf83bf + 3750bb4 commit 50b1e06
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 18 deletions.
1 change: 1 addition & 0 deletions .idea/dictionaries/m.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

39 changes: 21 additions & 18 deletions src/js/qmHelpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -9002,25 +9002,28 @@ var qm = {
name: user.displayName,
})
}
if(typeof LogRocket !== "undefined" && qm.appMode.isProduction()){
LogRocket.init('zi2x4l/quantimodo');
LogRocket.identify(user.id, {
name: user.displayName,
email: user.email,
upgraded: user.stripeActive,
// Add your own custom user variables here, ie:
subscriptionType: 'pro'
});
if(typeof drift !== "undefined"){
LogRocket.getSessionURL(function(sessionURL){
drift.track('LogRocket', {sessionURL: sessionURL});
if(typeof LogRocket !== "undefined"){
var record = qm.appMode.isProduction() || qm.urlHelper.getParam('logrocket');
if(record){
LogRocket.init('zi2x4l/quantimodo');
LogRocket.identify(user.id, {
name: user.displayName,
email: user.email,
upgraded: user.stripeActive,
// Add your own custom user variables here, ie:
subscriptionType: 'pro'
});
}
if(typeof Bugsnag !== "undefined"){
Bugsnag.beforeNotify = function(data){
data.metaData.sessionURL = LogRocket.sessionURL;
return data;
};
if(typeof drift !== "undefined"){
LogRocket.getSessionURL(function(sessionURL){
drift.track('LogRocket', {sessionURL: sessionURL});
});
}
if(typeof Bugsnag !== "undefined"){
Bugsnag.beforeNotify = function(data){
data.metaData.sessionURL = LogRocket.sessionURL;
return data;
};
}
}
}
},
Expand Down

1 comment on commit 50b1e06

@mikepsinn
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

View recording of ionic_measurements_spec.js
Cypress Dashboard{
"startedTestsAt": "2020-05-26T22:22:47.800Z",
"endedTestsAt": "2020-05-26T22:23:27.255Z",
"totalDuration": 39455,
"totalSuites": 1,
"totalTests": 4,
"totalFailed": 1,
"totalPassed": 1,
"totalPending": 2,
"totalSkipped": 0,
"runs": [
{
"stats": {
"suites": 1,
"tests": 4,
"passes": 1,
"pending": 2,
"skipped": 0,
"failures": 1,
"wallClockStartedAt": "2020-05-26T22:22:47.800Z",
"wallClockEndedAt": "2020-05-26T22:23:27.255Z",
"wallClockDuration": 39455
},
"reporter": "cypress-multi-reporters",
"reporterStats": {
"suites": 1,
"tests": 4,
"passes": 1,
"pending": 2,
"failures": 1,
"start": "2020-05-26T22:22:47.813Z",
"end": "2020-05-26T22:23:27.274Z",
"duration": 39461,
"testsRegistered": 4,
"passPercent": 50,
"pendingPercent": 50,
"other": 0,
"hasOther": false,
"skipped": 0,
"hasSkipped": false
},
"hooks": [
{
"hookId": "h1",
"hookName": "before each",
"title": [
""before each" hook"
],
"body": "function () {\n // runs before each test in the block\n var url = Cypress.config('baseUrl');\n\n if (!url) {\n debugger;\n throw "baseUrl not set!";\n }\n\n cy.log("baseUrl is ".concat(url));\n cy.log("API_HOST is ".concat(Cypress.env('API_HOST')));\n}"
}
],
"tests": [
{
"testId": "r3",
"title": [
"Measurements",
"Goes to edit measurement from history page"
],
"state": "passed",
"body": "function () {\n cy.loginWithAccessTokenIfNecessary('/#/app/history-all-category/Anything');\n cy.get('#historyItemTitle', {\n timeout: 30000\n }).click({\n force: true\n });\n cy.clickActionSheetButtonContaining('Edit');\n cy.wait(2000);\n cy.url().should('include', 'measurement-add');\n }",
"stack": null,
"error": null,
"timings": {
"lifecycle": 11,
"before each": [
{
"hookId": "h1",
"fnDuration": 12,
"afterFnDuration": 1
}
],
"test": {
"fnDuration": 17365,
"afterFnDuration": 2
}
},
"failedFromHookId": null,
"wallClockStartedAt": "2020-05-26T22:22:49.558Z",
"wallClockDuration": 17417,
"videoTimestamp": 5120
},
{
"testId": "r4",
"title": [
"Measurements",
"Records, edits, and deletes a mood measurement"
],
"state": "failed",
"body": "function () {\n cy.loginWithAccessTokenIfNecessary('/#/app/measurement-add-search');\n var variableName = 'Overall Mood';\n cy.searchAndClickTopResult(variableName, true);\n var d = new Date();\n var seconds = d.getSeconds();\n var initialMoodValue = seconds % 5 + 1;\n recordMeasurementAndCheckHistoryPage(initialMoodValue); // cy.get('#hidden-measurement-id').then(($el) => {\n // let measurementId = $el.text();\n // cy.get(\n // '.list > [id="historyItem-0"].item.item-avatar.item-button-right:nth-of-type(1) > .buttons >\n // button.button.button-dark') .click({force: true}); cy.clickActionSheetButtonContaining('Edit'); let\n // newMoodValue = ((initialMoodValue % 5) + 1);\n // cy.visit(/#/app/measurement-add?measurementId=${measurementId});\n // recordMeasurementAndCheckHistoryPage(newMoodValue); cy.get("#hidden-measurement-id").then(($el) => { let\n // editedMeasurementId = $el.text(); cy.visit(/#/app/measurement-add?measurementId=${editedMeasurementId});\n // cy.get('#deleteButton').click({force: true}); cy.wait(10000); cy.visit(/#/app/history-all-variable/Overall\n // Mood); cy.get("#hidden-measurement-id").should('not.contain', editedMeasurementId); }); });\n }",
"stack": "CypressError: Timed out retrying: Expected to find element: '.primary-outcome-variable-history > img:nth-of-type(3)', but never found it.\n at cypressErr (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:138036:9)\n at throwErr (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:137969:11)\n at Object.throwErrByPath (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:138017:3)\n at retry (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:132299:19)\n at onFailFn (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:120514:16)\n at tryCatcher (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:164895:23)\n at Promise._settlePromiseFromHandler (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:162831:31)\n at Promise._settlePromise (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:162888:18)\n at Promise._settlePromise0 (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:162933:10)\n at Promise._settlePromises (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:163008:18)\n at Async../node_modules/bluebird/js/release/async.js.Async._drainQueue (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:159620:16)\n at Async../node_modules/bluebird/js/release/async.js.Async._drainQueues (https://medimodo.herokuapp.com/__cypress/runner/cypress_runner.js:159630:10)\n at Async.drainQueues (https://medimodo.herokuapp.com/cypress/runner/cypress_runner.js:159504:14)",
"error": "Timed out retrying: Expected to find element: '.primary-outcome-variable-history > img:nth-of-type(3)', but never found it.",
"timings": {
"lifecycle": 309,
"before each": [
{
"hookId": "h1",
"fnDuration": 11,
"afterFnDuration": 0
}
],
"test": {
"fnDuration": 19590,
"afterFnDuration": 292
}
},
"failedFromHookId": null,
"wallClockStartedAt": "2020-05-26T22:23:06.985Z",
"wallClockDuration": 20228,
"videoTimestamp": 22547
},
{
"testId": "r5",
"title": [
"Measurements",
"Record, edit, and delete a treatment measurement"
],
"state": "pending",
"body": "",
"stack": null,
"error": null,
"timings": null,
"failedFromHookId": null,
"wallClockStartedAt": null,
"wallClockDuration": null,
"videoTimestamp": null
},
{
"testId": "r6",
"title": [
"Measurements",
"Records a treatment measurement and checks history"
],
"state": "pending",
"body": "",
"stack": null,
"error": null,
"timings": null,
"failedFromHookId": null,
"wallClockStartedAt": null,
"wallClockDuration": null,
"videoTimestamp": null
}
],
"error": null,
"video": "/jenkins/workspace/cypress-tests/cypress/videos/ionic_measurements_spec.js.mp4",
"screenshots": [
{
"screenshotId": "ozdsb",
"name": null,
"testId": "r4",
"takenAt": "2020-05-26T22:23:26.921Z",
"path": "/jenkins/workspace/cypress-tests/mochawesome-report/assets/ionic_measurements_spec.js/Measurements -- Records, edits, and deletes a mood measurement (failed).png",
"height": 720,
"width": 1280
}
],
"spec": {
"name": "ionic_measurements_spec.js",
"relative": "cypress/integration/ionic_measurements_spec.js",
"absolute": "/jenkins/workspace/cypress-tests/cypress/integration/ionic_measurements_spec.js"
},
"shouldUploadVideo": true
}
],
"browserPath": "",
"browserName": "electron",
"browserVersion": "78.0.3904.130",
"osName": "linux",
"osVersion": "Ubuntu Linux - 18.04",
"cypressVersion": "4.1.0",
"runUrl": "https://dashboard.cypress.io/projects/ee8wan/runs/91",
"config": {
"chromeWebSecurity": false,
"baseUrl": "https://app.quantimo.do",
"projectId": "ee8wan",
"pageLoadTimeout": 60000,
"videoCompression": false,
"videoUploadOnPasses": false,
"video": true,
"env": {
"API_HOST": "app.quantimo.do",
"OAUTH_APP_HOST": "medimodo.herokuapp.com",
"BUILDER_HOST": "builder.quantimo.do",
"abort_strategy": true,
"BROWSER": "electron",
"RECORD_KEY": "64dd3...5da65"
},
"reporter": "cypress-multi-reporters",
"reporterOptions": {
"configFile": "reporterOpts.json"
},
"screenshotsFolder": "/jenkins/workspace/cypress-tests/mochawesome-report/assets",
"projectRoot": "/jenkins/workspace/cypress-tests",
"projectName": "cypress-tests",
"morgan": false,
"isTextTerminal": true,
"socketId": "vb3du",
"report": true,
"browsers": [
{
"name": "firefox",
"family": "firefox",
"channel": "stable",
"displayName": "Firefox",
"version": "76.0.1",
"path": "firefox",
"info": "Firefox support is currently in beta! You can help us continue to improve the Cypress + Firefox experience by reporting any issues you find.",
"majorVersion": 76,
"warning": "Your project has set the configuration option: chromeWebSecurity: false\n\nThis option will not have an effect in Firefox. Tests that rely on web security being disabled will not run as expected."
},
{
"name": "electron",
"channel": "stable",
"family": "chromium",
"displayName": "Electron",
"version": "78.0.3904.130",
"path": "",
"majorVersion": 78,
"info": "Electron is the default browser that comes with Cypress. This is the default browser that runs in headless mode. Selecting this browser is useful when debugging. The version number indicates the underlying Chromium version that Electron uses."
}
],
"port": 38251,
"hosts": null,
"userAgent": null,
"blacklistHosts": null,
"clientRoute": "/
/",
"xhrRoute": "/xhrs/",
"socketIoRoute": "/__socket.io",
"socketIoCookie": "__socket.io",
"reporterRoute": "/__cypress/reporter",
"ignoreTestFiles": ".hot-update.js",
"testFiles": "**/
.",
"defaultCommandTimeout": 4000,
"requestTimeout": 5000,
"responseTimeout": 30000,
"execTimeout": 60000,
"taskTimeout": 60000,
"modifyObstructiveCode": true,
"waitForAnimations": true,
"animationDistanceThreshold": 5,
"numTestsKeptInMemory": 0,
"watchForFileChanges": false,
"trashAssetsBeforeRuns": true,
"autoOpen": false,
"viewportWidth": 1000,
"viewportHeight": 660,
"fileServerFolder": "/jenkins/workspace/cypress-tests",
"videosFolder": "/jenkins/workspace/cypress-tests/cypress/videos",
"supportFile": "/jenkins/workspace/cypress-tests/cypress/support/index.js",
"fixturesFolder": "/jenkins/workspace/cypress-tests/cypress/fixtures",
"integrationFolder": "/jenkins/workspace/cypress-tests/cypress/integration",
"namespace": "__cypress",
"pluginsFile": "/jenkins/workspace/cypress-tests/cypress/plugins/index.js",
"nodeVersion": "default",
"configFile": "cypress.json",
"firefoxGcInterval": {
"runMode": 1,
"openMode": null
},
"javascripts": [],
"cypressEnv": "production",
"resolved": {
"animationDistanceThreshold": {
"value": 5,
"from": "default"
},
"fileServerFolder": {
"value": "",
"from": "default"
},
"baseUrl": {
"value": "https://app.quantimo.do",
"from": "config"
},
"fixturesFolder": {
"value": "cypress/fixtures",
"from": "default"
},
"blacklistHosts": {
"value": null,
"from": "default"
},
"chromeWebSecurity": {
"value": false,
"from": "config"
},
"modifyObstructiveCode": {
"value": true,
"from": "default"
},
"integrationFolder": {
"value": "cypress/integration",
"from": "default"
},
"env": {
"API_HOST": {
"value": "app.quantimo.do",
"from": "config"
},
"OAUTH_APP_HOST": {
"value": "medimodo.herokuapp.com",
"from": "config"
},
"BUILDER_HOST": {
"value": "builder.quantimo.do",
"from": "config"
},
"abort_strategy": {
"value": true,
"from": "config"
},
"BROWSER": {
"value": "electron",
"from": "env"
},
"RECORD_KEY": {
"value": "64dd3...5da65",
"from": "env"
}
},
"pluginsFile": {
"value": "cypress/plugins",
"from": "default"
},
"hosts": {
"value": null,
"from": "default"
},
"screenshotsFolder": {
"value": "mochawesome-report/assets",
"from": "config"
},
"numTestsKeptInMemory": {
"value": 0,
"from": "config"
},
"supportFile": {
"value": "cypress/support",
"from": "default"
},
"port": {
"value": null,
"from": "default"
},
"projectId": {
"value": "ee8wan",
"from": "config"
},
"videosFolder": {
"value": "cypress/videos",
"from": "default"
},
"reporter": {
"value": "cypress-multi-reporters",
"from": "config"
},
"reporterOptions": {
"value": {
"configFile": "reporterOpts.json"
},
"from": "config"
},
"ignoreTestFiles": {
"value": "
.hot-update.js",
"from": "default"
},
"testFiles": {
"value": "**/.",
"from": "default"
},
"defaultCommandTimeout": {
"value": 4000,
"from": "default"
},
"trashAssetsBeforeRuns": {
"value": true,
"from": "default"
},
"execTimeout": {
"value": 60000,
"from": "default"
},
"userAgent": {
"value": null,
"from": "default"
},
"pageLoadTimeout": {
"value": 60000,
"from": "default"
},
"viewportWidth": {
"value": 1000,
"from": "default"
},
"requestTimeout": {
"value": 5000,
"from": "default"
},
"viewportHeight": {
"value": 660,
"from": "default"
},
"responseTimeout": {
"value": 30000,
"from": "default"
},
"video": {
"value": true,
"from": "default"
},
"taskTimeout": {
"value": 60000,
"from": "default"
},
"videoCompression": {
"value": false,
"from": "config"
},
"videoUploadOnPasses": {
"value": false,
"from": "config"
},
"watchForFileChanges": {
"value": false,
"from": "config"
},
"waitForAnimations": {
"value": true,
"from": "default"
},
"nodeVersion": {
"value": "default",
"from": "default"
},
"firefoxGcInterval": {
"value": {
"runMode": 1,
"openMode": null
},
"from": "default"
},
"browsers": {
"value": [
{
"name": "firefox",
"family": "firefox",
"channel": "stable",
"displayName": "Firefox",
"version": "76.0.1",
"path": "firefox",
"info": "Firefox support is currently in beta! You can help us continue to improve the Cypress + Firefox experience by reporting any issues you find.",
"majorVersion": 76,
"warning": "Your project has set the configuration option: chromeWebSecurity: false\n\nThis option will not have an effect in Firefox. Tests that rely on web security being disabled will not run as expected."
},
{
"name": "electron",
"channel": "stable",
"family": "chromium",
"displayName": "Electron",
"version": "78.0.3904.130",
"path": "",
"majorVersion": 78,
"info": "Electron is the default browser that comes with Cypress. This is the default browser that runs in headless mode. Selecting this browser is useful when debugging. The version number indicates the underlying Chromium version that Electron uses.",
"isHeadless": true,
"isHeaded": false
}
],
"from": "default"
}
},
"parentTestsFolder": "/jenkins/workspace/cypress-tests/cypress",
"parentTestsFolderDisplay": "cypress-tests/cypress",
"supportFolder": "/jenkins/workspace/cypress-tests/cypress/support",
"integrationExampleName": "examples",
"integrationExamplePath": "/jenkins/workspace/cypress-tests/cypress/integration/examples",
"scaffoldedFiles": [
{
"name": "cypress",
"children": [
{
"name": "integration",
"children": [
{
"name": "examples",
"children": [
{
"name": "actions.spec.js"
},
{
"name": "aliasing.spec.js"
},
{
"name": "assertions.spec.js"
},
{
"name": "connectors.spec.js"
},
{
"name": "cookies.spec.js"
},
{
"name": "cypress_api.spec.js"
},
{
"name": "files.spec.js"
},
{
"name": "local_storage.spec.js"
},
{
"name": "location.spec.js"
},
{
"name": "misc.spec.js"
},
{
"name": "navigation.spec.js"
},
{
"name": "network_requests.spec.js"
},
{
"name": "querying.spec.js"
},
{
"name": "spies_stubs_clocks.spec.js"
},
{
"name": "traversal.spec.js"
},
{
"name": "utilities.spec.js"
},
{
"name": "viewport.spec.js"
},
{
"name": "waiting.spec.js"
},
{
"name": "window.spec.js"
}
]
}
]
},
{
"name": "fixtures",
"children": [
{
"name": "example.json"
}
]
},
{
"name": "support",
"children": [
{
"name": "commands.js"
},
{
"name": "index.js"
}
]
},
{
"name": "plugins",
"children": [
{
"name": "index.js"
}
]
}
]
}
],
"resolvedNodeVersion": "12.8.1",
"state": {},
"proxyUrl": "http://localhost:38251",
"browserUrl": "https://app.quantimo.do/__/",
"reporterUrl": "https://app.quantimo.do/__cypress/reporter",
"xhrUrl": "__cypress/xhrs/"
}
}

ionic_measurements-ionic

BUILD LOG

Please sign in to comment.