Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
LavrovArtem committed Sep 5, 2017
1 parent 30c4782 commit 34557f8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ test('url in stylesheet properties', function () {
el.style[prop] = value;

var controlValue = el.style[propForChecking];
var proxiedValue = controlValue.replace(url, proxyUrl);
var proxiedValue = controlValue && controlValue.replace(url, proxyUrl);

eval(processScript('el.style["' + prop + '"]="' + value + '"'));
strictEqual(getProperty(el.style, propForChecking), controlValue, prop);
Expand Down
7 changes: 5 additions & 2 deletions test/server/script-processor-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,13 @@ function testProcessing (testCases) {

function testPropertyProcessing (templates) {
INSTRUMENTED_PROPERTIES.forEach(propName => {
if (propName.indexOf('-') !== -1)
return;

const testCases = templates.map(template => {
return {
src: template.src.replace(/\{0\}/g, propName),
expected: template.expected.replace(/\{0\}/g, propName)
src: template.src.replace(/\{0}/g, propName),
expected: template.expected.replace(/\{0}/g, propName)
};
});

Expand Down

0 comments on commit 34557f8

Please sign in to comment.