On Fri, May 30, 2014 at 12:06:19PM -0700, Gurucharan Shetty wrote:
> file_name.at tests dirname(), basename() and symlinks tests
> that are POSIX related.
> 
> Though we run the unit tests on msys, msys
> automatically converts '/' to a Windows equivalent 'C:/foo/bar'
> So, dirname() and basename() wouldn't really work.
> 
> Also, Windows does not have a one-one symlink functionality when
> compared with POSIX.
> 
> Signed-off-by: Gurucharan Shetty <gshe...@nicira.com>

It makes sense to me to skip the symlink functionality.

I was confused about why we should not test dir_name() and base_name()
on Windows, because it seems like we would probably use them on
Windows.  However, looking at the source tree it seems that currently
we use these functions only from Unix-specific bits of code.  If that
is the case, then I would want to only prototype and define these
function "#ifndef _WIN32", to prevent generic code from accidentally
starting to use code that will not work on Windows.

I see that that would leave tests/test-file_name.c entirely unused on
Windows.  It might make sense to move it into tests/test-util.c.

Thanks,

Ben.
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to