Sponsored Content
Full Discussion: Test for file
Top Forums UNIX for Dummies Questions & Answers Test for file Post 97941 by BCarlson on Friday 3rd of February 2006 11:29:14 AM
Old 02-03-2006
Do this

if [ ! -s $DATA_DIR/test.das ]
then
 

6 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Test on string containing spacewhile test 1 -eq 1 do read a $a if test $a = quitC then break fi d

This is the code: while test 1 -eq 1 do read a $a if test $a = stop then break fi done I read a command on every loop an execute it. I check if the string equals the word stop to end the loop,but it say that I gave too many arguments to test. For example echo hello. Now the... (1 Reply)
Discussion started by: Max89
1 Replies

2. Shell Programming and Scripting

How to check weather a string is like test* or test* ot *test* in if condition

How to check weather a string is like test* or test* ot *test* in if condition (5 Replies)
Discussion started by: johnjerome
5 Replies

3. Shell Programming and Scripting

Problem in test file operator on a ufsdump archive file mount nfs

Hi, I would like to ask if someone know how to test a files if exist the file is a nfs mount ufsdump archive file.. i used the test operator -f -a h almost all test operator but i failed file1=ufs_root_image.dump || echo "files doesn't exist && exit 1 the false file1 is working but... (0 Replies)
Discussion started by: jao_madn
0 Replies

4. Shell Programming and Scripting

Prefixing test case methods with letter 'test'

Hi, I have a Python unit test cases source code file which contains more than a hundred test case methods. In that, some of the test case methods already have prefix 'test' where as some of them do not have. Now, I need to add the string 'test' (case-sensitive) as a prefix to those of the... (5 Replies)
Discussion started by: royalibrahim
5 Replies

5. Shell Programming and Scripting

Hit multiple URL from a text file and store result in other test file

Hi, I have a problem where i have to hit multiple URL that are stored in a text file (input.txt) and save their output in different text file (output.txt) somewhat like : cat input.txt http://192.168.21.20:8080/PPUPS/international?NUmber=917875446856... (3 Replies)
Discussion started by: mukulverma2408
3 Replies

6. Shell Programming and Scripting

Test file

Hi, I try to test 3 files, #!/bin/bash if ; then echo "ok" else echo "ko" It works partially, but I want that the output tell me "ok" only if the three files doesn't exist. :b: (9 Replies)
Discussion started by: Arnaudh78
9 Replies
Test::InDistDir(3pm)					User Contributed Perl Documentation				      Test::InDistDir(3pm)

NAME
Test::InDistDir - test environment setup for development with IDE VERSION
version 1.112071 SYNOPSIS
use Test::More; use Test::InDistDir; # when this is run from inside t/ with a default @INC, it will now be in the # dist dir and include ./lib in @INC DESCRIPTION
This module helps run test scripts in IDEs like Komodo. When running test scripts in an IDE i have to set up a project file defining the dist dir to run tests in and a lib dir to load additional modules from. Often I didn't feel like doing that, especially when i only wanted to do a small patch to a dist. In those cases i added a BEGIN block to mangle the environment for me. This module basically is that BEGIN block. It automatically moves up one directory when it cannot see the test script in "t/$scriptname" and includes 'lib' in @INC when there's no blib present. That way the test ends up with almost the same environment it'd get from EUMM/prove/etc., even when it's actually run inside the t/ directory. At the same time it will still function correctly when called by EUMM/prove/etc., since it does not change the environment in those cases. SUPPORT
Bugs / Feature Requests Please report any bugs or feature requests by email to "bug-test-indistdir at rt.cpan.org", or through the web interface at http://rt.cpan.org/Public/Dist/Display.html?Name=Test-InDistDir <http://rt.cpan.org/Public/Dist/Display.html?Name=Test-InDistDir>. You will be automatically notified of any progress on the request by the system. Source Code This is open source software. The code repository is available for public review and contribution under the terms of the license. https://github.com/wchristian/Test-InDistDir <https://github.com/wchristian/Test-InDistDir> git clone https://github.com/wchristian/Test-InDistDir AUTHOR
Christian Walde <walde.christian@googlemail.com> COPYRIGHT AND LICENSE
This software is Copyright (c) 2011 by Christian Walde. This is free software, licensed under: DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE, Version 2, December 2004 perl v5.12.4 2011-07-26 Test::InDistDir(3pm)
All times are GMT -4. The time now is 03:48 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy