Search Results

Search found 65503 results on 2621 pages for 'real application testing'.

Page 81/2621 | < Previous Page | 77 78 79 80 81 82 83 84 85 86 87 88  | Next Page >

  • Bidirectional real-time sync of large file tree between two distant linux servers

    - by dlo
    By large file tree I mean about 200k files, and growing all the time. A relatively small number of files are being changed in any given hour though. By bidirectional I mean that changes may occur on either server and need to be pushed to the other, so rsync doesn't seem appropriate. By distant I mean that the servers are both in data centers, but geographically remote from each other. Currently there are only 2 servers, but that may expand over time. By real-time, it's ok for there to be a little latency between syncing, but running a cron every 1-2 minutes doesn't seem right, since a very small fraction of files may change in any given hour, let alone minute. EDIT: This is running on VPS's so I might be limited on the kinds of kernel-level stuff I can do. Also, the VPS's are not resource-rich, so I'd shy away from solutions that require lots of ram (like Gluster?). What's the best / most "accepted" approach to get this done? This seems like it would be a common need, but I haven't been able to find a generally accepted approach yet, which was surprising. (I'm seeking the safety of the masses. :) I've come across lsyncd to trigger a sync at the filesystem change level. That seems clever though not super common, and I'm a bit confused by the various lsyncd approaches. There's just using lsyncd with rsync, but it seems this could be fragile for bidirectionality since rsync doesn't have a notion of memory (eg- to know whether a deleted file on A should be deleted on B or whether it's a new file on B that should be copied to A). lipsync appears to be just a lsyncd+rsync implementation, right? Then there's using lsyncd with csync2, like this: http://www.axivo.com/community/threads/lightning-fast-synchronization-with-csync2-and-lsyncd.121/ ... I'm leaning towards this approach, but csync2 is a little quirky, though I did do a successful test of it. I'm mostly concerned that I haven't been able to find a lot of community confirmation of this method. People on here seem to like Unison a lot, but it seems that it is no longer under active development and it's not clear that it has an automatic trigger like lsyncd. I've seen Gluster mentioned, but maybe overkill for what I need? UPDATE: fyi- I ended up going with the original solution I mentioned: lsyncd+csync2. It seems to work quite well, and I like the architectural approach of having the servers be very loosely joined, so that each server can operate indefinitely on its own regardless of the link quality between them.

    Read the article

  • GWT: Best practice for unit testing / mocking JSNI methods?

    - by Epaga
    I have a class which uses JSNI to retrieve JSON data stored in the host page: protected native JsArray<JsonModel> getModels() /*-{ return $wnd.jsonData; }-*/; This method is called, and the data is then translated and process in a different method. How should I unit test this class, since I'm not able to instantiate (or seemingly mock?) JsArray? What is the best way to unit test JSNI methods at all?

    Read the article

  • When creating a new IIS web site, how can I add it to an existing application pool?

    - by Ian Robinson
    I have successfully automated the process of creating a new IIS website, however the code I've written doesn't care about application pools, it just gets added to DefaultAppPool. However I'd like to add this newly created site to an existing application pool. Here is the code I'm using to create the new website. var w3Svc = new DirectoryEntry(string.Format("IIS://{0}/w3svc", webserver)); var newsite = new object[] { serverComment, new object[] { serverBindings }, homeDirectory }; var websiteId = w3Svc.Invoke("CreateNewSite", newsite); site.Invoke("Start", null); site.CommitChanges(); <update Although this is not directly related to the question, here are some sample values being used above. This might help someone understand exactly what the code above is doing more easily. webServer: "localhost" serverComment: "testing.dev" serverBindings: ":80:testing.dev" homeDirectory: "c:\inetpub\wwwroot\testing\" </update If I know the name of the application pool that I'd like this web site to be in, how can I find it and add this site to it?

    Read the article

  • Using reflection to change static final File.separatorChar for unit testing?

    - by Stefan Kendall
    Specifically, I'm trying to create a unit test for a method which requires uses File.separatorChar to build paths on windows and unix. The code must run on both platforms, and yet I get errors with JUnit when I attempt to change this static final field. Anyone have any idea what's going on? Field field = java.io.File.class.getDeclaredField( "separatorChar" ); field.setAccessible(true); field.setChar(java.io.File.class,'/'); When I do this, I get IllegalAccessException: Can not set static final char field java.io.File.separatorChar to java.lang.Character Thoughts?

    Read the article

  • MonoRail: Testing, Route Extensions, Folder Structures

    - by Kezzer
    I've got a few questions related to the use of MonoRail Testing Does everyone tend to use NUnit for their testing? I haven't worked enough with testing to know if this is a good testing framework to use. I'm just looking to get more into testing my applications a lot more than before and wanted to know if there's any general guidelines. Are you supposed to copy the controller over to a test area and just rename it with test in the name and re-run it? How do you ensure your test project and main project coincide with one another? Is it just a case of copying everything over again or are there tools available to do it for you? Route Extensions MonoRail tends to use <action>.rails, can you omit the .rails part if you configure your routing correctly? Why does this seem to be the standard? Folder Structures I haven't found anywhere which really points out your standard folder structure. Sure, you have Controllers, Models, and Views. But your Models folder should contain your data access objects as well. I've seen some have something like -> Models -> DaoClasses -> Entities But what about custom structures used to get data out of views? And if you're using NHibernate, where's a good place to stick the mappings? I know it's entirely dependent on the developer, but I haven't really seen any standard approach. Cheers

    Read the article

  • How to get Eclipse + PyDev + App Engine + Unit testing to work?

    - by PEZ
    I want to run my unit tests for a Python Google App Engine project using Run As = Python unit-test But when I try that all my Model tests bail with the error message: BadArgumentError: app must not be empty. Anyone got this to work? NB: The tests runs fine using Nose --with-gae. But I want the PyDev integration with hyperlinking of resources and such.

    Read the article

  • How do you set a custom session when unit testing with wicket?

    - by vagabond
    I'm trying to run some unit tests on a wicket page that only allows access after you've logged in. In my JUnit test I cannot start the page or render it without setting the session. How do you set the session? I'm having problems finding any documentation on how to do this. WicketTester tester = new WicketTester(new MyApp()); ((MyCustomSession)tester.getWicketSession()).setItem(MyFactory.getItem("abc")); //Fails to start below, no session seems to be set tester.startPage(General.class); tester.assertRenderedPage(General.class);

    Read the article

  • Unit Testing Error - The unit test adapter failed to connect to the data source or to read the data

    - by michael.lukatchik
    I'm using VSTS 2K8 and I've set up a Unit Test Project. In it, I have a test class with a method that does a simple assertion. I'm using an Excel 2007 spreadsheet as my data source. My test method looks like this: [DataSource("System.Data.Odbc", "Dsn=Excel Files;dbq=|DataDirectory|\\MyTestData.xlsx;defaultdir=C:\\TestData;driverid=1046;maxbuffersize=2048;pagetimeout=5", "Sheet1", DataAccessMethod.Sequential)] [DeploymentItem("MyTestData.xlsx")] [TestMethod()] public void State_Value_Is_Set() { string expected = "MD"; string actual = TestContext.DataRow["State"] as string; Assert.AreEqual(expected, actual); } As indicated in the method decoration attributes, my Excel spreadsheet is on my local C:/ Drive. In it, the sheet where all of my data is located is named "Sheet1". I've copied the Excel spreadsheet into my project and I've set its Build Action = "Content" and I've set its Copy to Output Directory = "Copy if Newer". When trying to run this simple unit test, I receive the following error: The unit test adapter failed to connect to the data source or to read the data. For more information on troubleshooting this error, see "Troubleshooting Data-Driven Unit Tests" (http://go.microsoft.com/fwlink/?LinkId=62412) in the MSDN Library. Error details: ERROR [42S02] [Microsoft][ODBC Excel Driver] The Microsoft Office Access database engine could not find the object 'Sheet1'. Make sure the object exists and that you spell its name and the path name correctly. I've verified that the sheet name is spelled correctly (i.e. Sheet1) and I've verified that my data sources are set correctly. Web searches haven't turned up much at all. And I'm totally stumped. All help or input is appreciated!!!!

    Read the article

  • Disable "System Memory Testing" via OMSA 6.4.0

    - by EGr
    Is it possible to disable system memory testing via OMSA 6.4.0? I can only find ways to do it using newer versions of OMSA; and I can't even see the setting in 6.4.0. I have quite a few machines that I want to disable this (BIOS) setting on, but I don't want to have to install the new OMSA and reboot. My intentions are to disable the setting so that when the systems are rebooted in the future, they don't need to go through the system memory testing. If it is possible to disable this another way, without OMSA or manually changing the BIOS settings, I would be open to that as well.

    Read the article

  • Use cellular emulator with a REAL WinMo device?

    - by Ranhiru
    I don't whether this is even possible which is obviously why I am asking this question :) Is it in any way possible to leverage functionality the Cellular Emulator on a REAL PHYSICAL device?? :) So when I test it on my device, I really do not have to send real SMS(s) to test my MessageInteceptor. On a sidenote, why does MessageInteceptor fails after several messages to intercept messages?? :( Thanx a lot in advance :)

    Read the article

  • How to fake Azure Table Storage in .NET for Unit Testing?

    - by Erick T
    I am working on a system that uses Azure Table Storage. In other systems (e.g., SQL, File based, etc), I can write a fake that allows me to test my data persistence logic. However, I can't see an easy way to create a fake for the Azure Table Service. I could create a new IIS project that behaves the same way, but that isn't a good way to write a unit test, it is more of an integration test. Any thoughts on how to unit test data access code that uses the Azure Table Storage client? Thanks, Erick

    Read the article

  • Rolling Back Microsoft CRM during testing

    - by npeterson
    Process related question: Currently we have a multi-tenant installation of MS CRM 4.0 on three servers, Dev, Test, and Live. We are actively working on customizing one of the tenants, but the others are static. During user testing, we often find it necessary to 'start fresh' in one of the tenants. Is it better to try and delete out the changes from the tenant (created accounts, leads, etc), or just revert the database to a backup from before the testing started? Is there compelling reasons why bulk delete is not advisable for MSCRM or that reverting the database frequently could cause issue?

    Read the article

  • Is unit testing the definition of an interface necessary?

    - by HackedByChinese
    I have occasionally heard or read about people asserting their interfaces in a unit test. I don't mean mocking an interface for use in another type's test, but specifically creating a test to accompany the interface. Consider this ultra-lame and off-the-cuff example: public interface IDoSomething { string DoSomething(); } and the test: [TestFixture] public class IDoSomethingTests { [Test] public void DoSomething_Should_Return_Value() { var mock = new Mock<IDoSomething>(); var actualValue = mock.Expect(m => m.DoSomething()).Returns("value"); mock.Object.DoSomething(); mock.Verify(m => DoSomething()); Assert.AreEqual("value", actualValue); } } I suppose the idea is to use the test to drive the design of the interface and also to provide guidance for implementors on what's expected so they can draw good tests of their own. Is this a common (recommended) practice?

    Read the article

  • Watir question regarding exist on a class for testing purposes.

    - by AJ
    I have a button on my page that changes depending on what radio button is clicked. The button has the same text on it with the same id, but different classes. How do I test if the two different buttons exist depending on the radio. <a id="submit" class="on" href="javascript:submit();">Submit</a> <a id="submit" class="off" href="javascript:submit();">Submit</a> How do i test if the second button appears instead of the first one. I used something like, browser.link(:text, 'Submit').exist? but this doesn't work cause it will return true no matter what. thanks

    Read the article

  • Unit testing - how do I test a function that returns random output?

    - by Extrakun
    I have a function which takes in two parameters, and returns one or the other 50% of the time. The unit test for this should determine that both parameters could be returned. Luckily, I don't need to prove that the probability for each is 50% but I do need to show that both parameters are possible to be returned. How do I write a test case for this function?

    Read the article

  • Using Python, what's the best way to create a set of files on disk for testing?

    - by Chris R
    I'm looking for a way to create a tree of test files to unit test a packaging tool. Basically, I want to create some common file system structures -- directories, nested directories, symlinks within the selected tree, symlinks outside the tree, &c. Ideally I want to do this with as little boilerplate as possible. Of course, I could hand-write the set of files I want to see, but I'm thinking that somebody has to have automated this for a test suite somewhere. Any suggestions?

    Read the article

  • Debian Testing installs Iceweasel ESR (severely outdated)?

    - by Lucas Phillips
    I just reinstalled Debian Testing, and for some reason, instead of Iceweasel 25, I have 17. The installed and candidate versions are both 17.0.9esr-1~deb7u1. apt-get update && apt-get upgrade does nothing, and it seems that version 17 is the latest for this install. I was on Debian Testing before, and Iceweasel was at the latest version. Even Debian Stable had an Iceweasel version 20. Why would it be trying to install ESR now?

    Read the article

  • Determining which classes would benefit most from unit testing?

    - by benoit
    I am working on a project where we have only 13% of code coverage with our unit tests. I would like to come up with a plan to improve that but by focusing first on the areas where increasing coverage would bring the greatest value. This project is in C#, we're using VS 2008 and TFS 2008 and out unit tests are written using MSTest. What methodology should I use to determine which classes we should tackle first? Which metrics (code or usage) should I be looking at (and how can I get those metrics if this is not obvious)?

    Read the article

  • Mod_Rewrite: Testing URL got indexed in Google - How do I create a proper 301 redirect?

    - by Jonathan Wold
    I worked on a website for which I had a "development URL" that looked something like this: www.domainname.com.php5-9.dfw1-2.websitetestlink.com/ Now, several weeks after the website launch, there is at least one page of content indexed on Google with that URL. Question: How do I redirect all requests from that test URL to reroute to the actual domain? So, for instance, I would want: www.domainname.com.php5-9.dfw1-2.websitetestlink.com/page-name To go to: www.domainname.com/page-name The website is powered by WordPress and hosted on a PHP server. I've experimented with .htaccess without much success.

    Read the article

< Previous Page | 77 78 79 80 81 82 83 84 85 86 87 88  | Next Page >