From 633c604ef9f176abe0202c3c776fbf983a1fdfd0 Mon Sep 17 00:00:00 2001 From: Hemanth Nandish Date: Sun, 11 Sep 2022 02:13:18 -0600 Subject: [PATCH 01/10] Update finder-test.sh (#4) * Update finder-test.sh Modify WRITEDIR to ensure writer.sh creates missing directories * Update finder-test.sh Modify WRITEDIR to ensure writer.sh creates missing directories * finder-test.sh: update to remove /tmp/aeld-data directories * finder-test.sh: update to remove /tmp/aeld-data directories --- finder-app/finder-test.sh | 30 ++++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/finder-app/finder-test.sh b/finder-app/finder-test.sh index 81d16c4..acd0bac 100755 --- a/finder-app/finder-test.sh +++ b/finder-app/finder-test.sh @@ -10,7 +10,7 @@ WRITESTR=AELD_IS_FUN WRITEDIR=/tmp/aeld-data username=$(cat conf/username.txt) -if [ $# -lt 2 ] +if [ $# -lt 3 ] then echo "Using default value ${WRITESTR} for string to write" if [ $# -lt 1 ] @@ -22,6 +22,7 @@ then else NUMFILES=$1 WRITESTR=$2 + WRITEDIR=/tmp/aeld-data/$3 fi MATCHSTR="The number of files are ${NUMFILES} and the number of matching lines are ${NUMFILES}" @@ -29,18 +30,24 @@ MATCHSTR="The number of files are ${NUMFILES} and the number of matching lines a echo "Writing ${NUMFILES} files containing string ${WRITESTR} to ${WRITEDIR}" rm -rf "${WRITEDIR}" -mkdir -p "$WRITEDIR" -#The WRITEDIR is in quotes because if the directory path consists of spaces, then variable substitution will consider it as multiple argument. -#The quotes signify that the entire string in WRITEDIR is a single string. -#This issue can also be resolved by using double square brackets i.e [[ ]] instead of using quotes. -if [ -d "$WRITEDIR" ] +# create $WRITEDIR if not assignment1 +assignment=`cat ../conf/assignment.txt` + +if [ $assignment != 'assignment1' ] then - echo "$WRITEDIR created" -else - exit 1 -fi + mkdir -p "$WRITEDIR" + #The WRITEDIR is in quotes because if the directory path consists of spaces, then variable substitution will consider it as multiple argument. + #The quotes signify that the entire string in WRITEDIR is a single string. + #This issue can also be resolved by using double square brackets i.e [[ ]] instead of using quotes. + if [ -d "$WRITEDIR" ] + then + echo "$WRITEDIR created" + else + exit 1 + fi +fi #echo "Removing the old writer utility and compiling as a native application" #make clean #make @@ -52,6 +59,9 @@ done OUTPUTSTRING=$(./finder.sh "$WRITEDIR" "$WRITESTR") +# remove temporary directories +rm -rf /tmp/aeld-data + set +e echo ${OUTPUTSTRING} | grep "${MATCHSTR}" if [ $? -eq 0 ]; then From e34c0d0216c736a5270e0ed86348eeb560ff384e Mon Sep 17 00:00:00 2001 From: Hemanth Nandish Date: Sat, 8 Oct 2022 13:04:13 -0600 Subject: [PATCH 02/10] yaml fix for a2 --- .github/workflows/github-actions.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml index e5339c2..c4b1095 100644 --- a/.github/workflows/github-actions.yml +++ b/.github/workflows/github-actions.yml @@ -1,5 +1,10 @@ name: assignment-test -on: [push] +on: + push: + tags-ignore: + - '*' + branches: + - '*' jobs: unit-test: container: cuaesd/aesd-autotest:unit-test From 81484b9f1281310618f3ed776f0e367a3181e25b Mon Sep 17 00:00:00 2001 From: Hemanth Nandish Date: Sat, 8 Oct 2022 13:12:34 -0600 Subject: [PATCH 03/10] Revert "yaml fix for a2" This reverts commit e34c0d0216c736a5270e0ed86348eeb560ff384e. --- .github/workflows/github-actions.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml index c4b1095..e5339c2 100644 --- a/.github/workflows/github-actions.yml +++ b/.github/workflows/github-actions.yml @@ -1,10 +1,5 @@ name: assignment-test -on: - push: - tags-ignore: - - '*' - branches: - - '*' +on: [push] jobs: unit-test: container: cuaesd/aesd-autotest:unit-test From 3bf587a7305adae4ed8144fd274c425531a2617d Mon Sep 17 00:00:00 2001 From: Hemanth Nandish Date: Sat, 8 Oct 2022 23:17:13 -0600 Subject: [PATCH 04/10] yaml changes for a3p1 --- .github/workflows/github-actions.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml index 94a5373..1d4d860 100644 --- a/.github/workflows/github-actions.yml +++ b/.github/workflows/github-actions.yml @@ -1,5 +1,10 @@ name: assignment-test -on: [push] +on: + push: + tags-ignore: + - '*' + branches: + - '*' jobs: unit-test: container: cuaesd/aesd-autotest:unit-test From c5419eddd81b3ca90308d2b5c7452dfda625b2cd Mon Sep 17 00:00:00 2001 From: Hemanth Nandish Date: Sat, 8 Oct 2022 23:17:59 -0600 Subject: [PATCH 05/10] Revert "yaml changes for a3p1" This reverts commit 3bf587a7305adae4ed8144fd274c425531a2617d. --- .github/workflows/github-actions.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml index 1d4d860..94a5373 100644 --- a/.github/workflows/github-actions.yml +++ b/.github/workflows/github-actions.yml @@ -1,10 +1,5 @@ name: assignment-test -on: - push: - tags-ignore: - - '*' - branches: - - '*' +on: [push] jobs: unit-test: container: cuaesd/aesd-autotest:unit-test From 27c17d44b2700bb5e0cdecb455f8c5d8560112c9 Mon Sep 17 00:00:00 2001 From: Hemanth Nandish Date: Sun, 2 Oct 2022 21:06:39 -0600 Subject: [PATCH 06/10] github-actions: Don't re-run on tags Support running github actions on any branch but do not run if the tag changes or is added to a specific commit. This prevents extra actions from being run when a branch is created from an existing commit and only results in a new actions run if/when a new commit is pushed on the resulting branch. --- .github/workflows/github-actions.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml index 3c746c1..a7da1d5 100644 --- a/.github/workflows/github-actions.yml +++ b/.github/workflows/github-actions.yml @@ -1,5 +1,10 @@ name: assignment-test -on: [push] +on: + push: + tags-ignore: + - '*' + branches: + - '*' jobs: unit-test: container: cuaesd/aesd-autotest:unit-test From 8de9c85cb76ab03f864ffc87fe3baf6a37ea1014 Mon Sep 17 00:00:00 2001 From: Dan Walkes Date: Sat, 14 Jan 2023 18:16:00 -0700 Subject: [PATCH 07/10] assignment-autotest: Go to latest automated tests Including fixes for assignment 1, assignment 3, assignments 8 and 9, and assignment 6. --- assignment-autotest | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assignment-autotest b/assignment-autotest index 3d8e246..83e5dfa 160000 --- a/assignment-autotest +++ b/assignment-autotest @@ -1 +1 @@ -Subproject commit 3d8e2463334d7cd004a8f558a0846969689a3ba8 +Subproject commit 83e5dfa52a482c76980e69e1f231c32a03c68910 From eed71d775b9cde0224f323858062cf4af028a6c0 Mon Sep 17 00:00:00 2001 From: Amy Liffey Date: Fri, 23 Jun 2023 14:52:35 +0200 Subject: [PATCH 08/10] fix git command in README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 7bbfc39..e4217ff 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ The basis of the automated test implementation for this repository comes from [h The assignment-autotest directory contains scripts useful for automated testing Use ``` -git submodule init update --recursive +git submodule update --init --recursive ``` to synchronize after cloning and before starting each assignment, as discussed in the assignment instructions. From f0c7a24c232fcf664ebf5387e3f6b5cd306ef308 Mon Sep 17 00:00:00 2001 From: Dan Walkes Date: Sun, 25 Aug 2024 15:21:59 -0600 Subject: [PATCH 09/10] Update container for F24 Update to Ubuntu 22.04 containers --- .github/workflows/github-actions.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml index a7da1d5..da82dd8 100644 --- a/.github/workflows/github-actions.yml +++ b/.github/workflows/github-actions.yml @@ -1,5 +1,5 @@ name: assignment-test -on: +on: push: tags-ignore: - '*' @@ -7,7 +7,7 @@ on: - '*' jobs: unit-test: - container: cuaesd/aesd-autotest:unit-test + container: cuaesd/aesd-autotest:24-unit-test runs-on: self-hosted steps: - uses: actions/checkout@v2 @@ -16,7 +16,7 @@ jobs: - name: Run unit test run: ./unit-test.sh full-test: - container: cuaesd/aesd-autotest:assignment1 + container: cuaesd/aesd-autotest:24-assignment1 runs-on: self-hosted steps: - uses: actions/checkout@v2 From 21f5f747b806cd6f6b2a74fb07085a5f95e53405 Mon Sep 17 00:00:00 2001 From: Dan Walkes Date: Wed, 28 Aug 2024 10:38:59 -0600 Subject: [PATCH 10/10] Update linux version to 5.15 To work with latest gcc --- finder-app/manual-linux.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/finder-app/manual-linux.sh b/finder-app/manual-linux.sh index a2dd5ee..8dcd3f0 100755 --- a/finder-app/manual-linux.sh +++ b/finder-app/manual-linux.sh @@ -7,7 +7,7 @@ set -u OUTDIR=/tmp/aeld KERNEL_REPO=git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git -KERNEL_VERSION=v5.1.10 +KERNEL_VERSION=v5.15.163 BUSYBOX_VERSION=1_33_1 FINDER_APP_DIR=$(realpath $(dirname $0)) ARCH=arm64