aboutsummaryrefslogtreecommitdiff
path: root/test/dotnet
diff options
context:
space:
mode:
Diffstat (limited to 'test/dotnet')
-rw-r--r--test/dotnet/install_additional_dotnet.sh13
-rw-r--r--test/dotnet/install_dotnet_3.sh13
-rw-r--r--test/dotnet/install_dotnet_5.sh14
-rw-r--r--test/dotnet/scenarios.json27
4 files changed, 67 insertions, 0 deletions
diff --git a/test/dotnet/install_additional_dotnet.sh b/test/dotnet/install_additional_dotnet.sh
new file mode 100644
index 0000000..fdb2da7
--- /dev/null
+++ b/test/dotnet/install_additional_dotnet.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+set -e
+
+# Optional: Import test library
+source dev-container-features-test-lib
+
+check "dotnet version 6.0.301 installed as default" dotnet --version | grep 6.0.301
+check "dotnet version 5.0 installed" ls -l /usr/local/dotnet | grep 5.0
+check "dotnet version 3.1.420 installed" ls -l /usr/local/dotnet | grep 3.1.420
+
+# Report result
+reportResults
diff --git a/test/dotnet/install_dotnet_3.sh b/test/dotnet/install_dotnet_3.sh
new file mode 100644
index 0000000..0d05215
--- /dev/null
+++ b/test/dotnet/install_dotnet_3.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+set -e
+
+# Optional: Import test library
+source dev-container-features-test-lib
+
+check "dotnet sdks" dotnet --list-sdks
+check "some major version of dotnet 3 is installed" dotnet --list-sdks | grep '3\.[0-9]*\.[0-9]*'
+check "dotnet version 3 installed" ls -l /usr/share/dotnet/sdk | grep '3\.[0-9]*\.[0-9]*'
+
+# Report result
+reportResults
diff --git a/test/dotnet/install_dotnet_5.sh b/test/dotnet/install_dotnet_5.sh
new file mode 100644
index 0000000..5f48eb1
--- /dev/null
+++ b/test/dotnet/install_dotnet_5.sh
@@ -0,0 +1,14 @@
+#!/bin/bash
+
+set -e
+
+# Optional: Import test library
+source dev-container-features-test-lib
+
+check "dotnet sdks" dotnet --list-sdks
+check "some major version of dotnet 5 is installed" dotnet --list-sdks | grep '5\.[0-9]*\.[0-9]*'
+check "dotnet version 5 installed" ls -l /usr/share/dotnet/sdk | grep '5\.[0-9]*\.[0-9]*'
+
+
+# Report result
+reportResults
diff --git a/test/dotnet/scenarios.json b/test/dotnet/scenarios.json
new file mode 100644
index 0000000..edf4a75
--- /dev/null
+++ b/test/dotnet/scenarios.json
@@ -0,0 +1,27 @@
+{
+ "install_additional_dotnet": {
+ "image": "ubuntu:focal",
+ "features": {
+ "dotnet": {
+ "version": "6.0.301",
+ "additionalVersions": "5.0,3.1.420"
+ }
+ }
+ },
+ "install_dotnet_3": {
+ "image": "ubuntu:focal",
+ "features": {
+ "dotnet": {
+ "version": "3"
+ }
+ }
+ },
+ "install_dotnet_5": {
+ "image": "ubuntu:focal",
+ "features": {
+ "dotnet": {
+ "version": "5"
+ }
+ }
+ }
+} \ No newline at end of file