-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Mono repos support * use bash to run system tests * Remove comment
- Loading branch information
Showing
15 changed files
with
110 additions
and
5 deletions.
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
#!/bin/bash | ||
|
||
echo "▶ Running system tests..." | ||
|
||
if [[ "$(docker images -q codeclimate/codeclimate-eslint 2> /dev/null)" == "" ]]; then | ||
echo "▶ Building image..." | ||
make image | ||
fi | ||
|
||
SOURCE="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | ||
|
||
for d in system-tests/*/ ; do | ||
echo "" | ||
echo "▶ Running $d ..." | ||
echo "${SOURCE}"/"${d}" | ||
cd "${SOURCE}"/"${d}" || exit | ||
output=$(docker run \ | ||
--interactive --tty --rm \ | ||
--env CODECLIMATE_CODE="$PWD" \ | ||
--volume "$PWD":/code \ | ||
--volume /var/run/docker.sock:/var/run/docker.sock \ | ||
--volume /tmp/cc:/tmp/cc \ | ||
codeclimate/codeclimate analyze --dev) | ||
|
||
if [[ -f "${SOURCE}/${d}snapshot" ]]; then | ||
count=$(cat "${SOURCE}"/"${d}"snapshot) | ||
issues=$(echo ${output} | sed -E "s/.*Found ([0-9]+).*/\1/") | ||
|
||
if [[ "$issues" -ne "$count" ]]; then | ||
echo -e "FAIL It should have $count issues but found $issues"; | ||
exit 1 | ||
else | ||
echo -e "PASS Found $issues issues" | ||
fi | ||
fi | ||
|
||
if [[ "$?" -ne 0 ]]; then | ||
break | ||
fi | ||
done |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
version: "2" | ||
plugins: | ||
eslint: | ||
enabled: 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module.exports = { | ||
extends: ['./eslint-config-frontier-react.js'], | ||
plugins: ['prettier'], | ||
ignorePatterns: [ | ||
"fle-b.js" | ||
], | ||
}; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
let a; | ||
const foo = function () { | ||
console.log('hey') | ||
} | ||
|
||
console.log('hello') | ||
console.log('world') | ||
|
||
foo() |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
let b; | ||
console.log("helper"); | ||
console.log("world"); |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
module.exports = { | ||
ignorePatterns: [ | ||
"file-a.js" | ||
], | ||
}; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
let d; | ||
console.log("helper"); | ||
console.log("world"); |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
let c; | ||
const foo = function () { | ||
console.log('hey') | ||
} | ||
|
||
console.log('hello') | ||
console.log('world') | ||
|
||
foo() |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
version: "2" | ||
plugins: | ||
eslint: | ||
enabled: 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
let a; | ||
const foo = function () { | ||
console.log('hey') | ||
} | ||
|
||
console.log('hello') | ||
console.log('world') | ||
|
||
foo() |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
let b; | ||
console.log("helper"); | ||
console.log("world"); |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2 |