Skip to content
Myr

[Tests] add unit tests for `nvm_version_greater_than_or_equal_to`

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Hridhin Varkey Joseph · committed by Jordan Harband · parent cb96d2a · Browse files · 1 file+20 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+20 added−0 removed

  • tests:+20 added−0 removed

1 file+20 added−0 removed

added:test/fast/Unit tests/nvm_version_greater_than_or_equal_to+20 added
1#!/bin/sh23die () { echo "$@" ; exit 1; }45: nvm.sh6\. ../../../nvm.sh78nvm_version_greater_than_or_equal_to 0.10.0 0.2.12 || die '"nvm_version_greater_than_or_equal_to 0.10.0 0.2.12" did not return true'910nvm_version_greater_than_or_equal_to 0.10.0 0.10.0 || die '"nvm_version_greater_than_or_equal_to" did not return true for the same two versions'1112nvm_version_greater_than_or_equal_to v0.10.0 0.10.0 || die '"nvm_version_greater_than_or_equal_to v0.10.0 0.10.0" did not return true'1314if nvm_version_greater_than_or_equal_to 0.10.0 0.20.12; then15 die '"nvm_version_greater_than_or_equal_to 0.10.0 0.20.12" returned true'16fi1718if nvm_version_greater_than_or_equal_to 0.10.0 ''; then19 die '"nvm_version_greater_than_or_equal_to" returned true with an empty argument'20fi