-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ff3ae16
commit 2807905
Showing
1 changed file
with
26 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
// This file is Free Software under the MIT License | ||
// without warranty, see README.md and LICENSES/MIT.txt for details. | ||
// | ||
// SPDX-License-Identifier: MIT | ||
// | ||
// SPDX-FileCopyrightText: 2023 German Federal Office for Information Security (BSI) <https://www.bsi.bund.de> | ||
// Software-Engineering: 2023 Intevation GmbH <https://intevation.de> | ||
|
||
package main | ||
|
||
import "testing" | ||
|
||
func TestValidationStatusUpdate(t *testing.T) { | ||
sv := validValidationStatus | ||
sv.update(invalidValidationStatus) | ||
sv.update(validValidationStatus) | ||
if sv != invalidValidationStatus { | ||
t.Fatalf("got %q expected %q", sv, invalidValidationStatus) | ||
} | ||
sv = notValidatedValidationStatus | ||
sv.update(validValidationStatus) | ||
sv.update(notValidatedValidationStatus) | ||
if sv != notValidatedValidationStatus { | ||
t.Fatalf("got %q expected %q", sv, notValidatedValidationStatus) | ||
} | ||
} |