This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Route("api")] | |
public class ActionsController : Controller | |
{ | |
.... | |
// POST endpoint for all actions | |
[HttpPost("v1")] | |
public IApuxActionResult ExecuteAction([FromBody] ApuxActionRequest actionRequest) | |
{ | |
.... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"type": "PRODUCT_GET_BY_ID", | |
"payload": 3 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ApuxAction<T> : IApuxAction | |
{ | |
[JsonProperty(PropertyName = "type")] | |
public string Type { get; set; } | |
[JsonProperty(PropertyName = "payload")] | |
public T Payload { get; set; } | |
[JsonIgnore] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public interface IApuxAction | |
{ | |
string Type { get; set; } | |
JToken BasePayload { get; set; } | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// --------------------------- | |
// Website.js | |
// This is the app container (for the website) | |
// As an example you'll eventually want something that looks like this | |
// --------------------------- | |
class Website extends Component { | |
render() { | |
return ( | |
<ThemeProvider theme={theme}> | |
<Header /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
+ plugins: [ | |
+ { | |
+ package: "protractor-console-plugin", | |
+ failOnWarning: false, | |
+ failOnError: true, | |
+ logWarnings: true | |
+ } | |
+ ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
onPrepare() { | |
... | |
+ jasmine.getEnv().addReporter( | |
+ new jasmineReporters.JUnitXmlReporter({ | |
+ consolidateAll: true, | |
+ savePath: "e2e/results", | |
+ filePrefix: "e2e-results-junit" | |
+ }) | |
+ ); | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
capabilities: { | |
browserName: "chrome", | |
+ chromeOptions: { | |
+ binary: process.env.CHROME_BIN | |
+ } | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { SpecReporter } = require("jasmine-spec-reporter"); | |
+ const jasmineReporters = require("jasmine-reporters"); | |
+ process.env.CHROME_BIN = process.env.CHROME_BIN || require("puppeteer").executablePath(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { SpecReporter } = require("jasmine-spec-reporter"); | |
const jasmineReporters = require("jasmine-reporters"); | |
process.env.CHROME_BIN = process.env.CHROME_BIN || require("puppeteer").executablePath(); | |
exports.config = { | |
allScriptsTimeout: 11000, | |
specs: ["./e2e/**/*.e2e-spec.ts"], | |
capabilities: { | |
browserName: "chrome", | |
chromeOptions: { |
NewerOlder