Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(358)

Unified Diff: tests/test-lib.sh

Issue 122040: Refactor the unit tests. (Closed)
Patch Set: even more cleanup Created 11 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/revert_unittest.py ('k') | tests/trychange_unittest.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/test-lib.sh
diff --git a/tests/test-lib.sh b/tests/test-lib.sh
deleted file mode 100755
index f4954bef151a0dc463fba5f48df05a73c6e255f4..0000000000000000000000000000000000000000
--- a/tests/test-lib.sh
+++ /dev/null
@@ -1,50 +0,0 @@
-#!/bin/bash
-
-# Abort on error.
-set -e
-
-PWD=`pwd`
-REPO_URL=file://$PWD/svnrepo
-GIT_CL=$PWD/../git-cl
-
-# Set up an SVN repo that has a few commits to trunk.
-setup_initsvn() {
- echo "Setting up test SVN repo..."
- rm -rf svnrepo
- svnadmin create svnrepo
-
- rm -rf svn
- svn co -q $REPO_URL svn
- (
- cd svn
- echo "test" > test
- svn add -q test
- svn commit -q -m "initial commit"
- echo "test2" >> test
- svn commit -q -m "second commit"
- )
-}
-
-# Set up a git-svn checkout of the repo.
-setup_gitsvn() {
- echo "Setting up test git-svn repo..."
- rm -rf git-svn
- # There appears to be no way to make git-svn completely shut up, so we
- # redirect its output.
- git svn -q clone $REPO_URL git-svn >/dev/null 2>&1
-}
-
-cleanup() {
- rm -rf svnrepo svn git-svn
-}
-
-# Usage: test_expect_success "description of test" "test code".
-test_expect_success() {
- echo "TESTING: $1"
- exit_code=0
- sh -c "$2" || exit_code=$?
- if [ $exit_code != 0 ]; then
- echo "FAILURE: $1"
- return $exit_code
- fi
-}
« no previous file with comments | « tests/revert_unittest.py ('k') | tests/trychange_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698