aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.test
diff options
context:
space:
mode:
authorRoberto Tyley <roberto.tyley@gmail.com>2013-05-18 22:52:55 +0100
committerRobin Stocker <robin@nibor.org>2013-05-19 13:20:47 +0200
commitb4b3999f8221c4c5885aef541abb4a411a9fdcbe (patch)
tree3eb99bdd9bbbc73b6b5924b5926de476dc00be11 /org.eclipse.jgit.test
parent84ad4957c6a1479032ad24a216904f87f1e02f40 (diff)
downloadjgit-b4b3999f8221c4c5885aef541abb4a411a9fdcbe.tar.gz
jgit-b4b3999f8221c4c5885aef541abb4a411a9fdcbe.zip
Fix BatchRefUpdate progress-monitoring so it doesn't count twice
I was seeing output like this while running The BFG: Updating references: 200% (374/187) ...issue sneaked in with 5cf53fda I think. The update call is also moved to the end of the loop, as update() is only supposed to be called after work has been done ("Denote that some work units have been completed"). Change-Id: I1620fa75be16dc80df44745d0e123ea512762e31 Signed-off-by: Robin Stocker <robin@nibor.org>
Diffstat (limited to 'org.eclipse.jgit.test')
-rw-r--r--org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java37
1 files changed, 30 insertions, 7 deletions
diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java
index 9bf3b94c43..a821e948e7 100644
--- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java
+++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2010, Google Inc.
+ * Copyright (C) 2010, 2013 Google Inc.
* and other copyright owners as documented in the project's IP log.
*
* This program and the accompanying materials are made available
@@ -73,6 +73,7 @@ import org.eclipse.jgit.junit.LocalDiskRepositoryTestCase;
import org.eclipse.jgit.junit.TestRepository;
import org.eclipse.jgit.lib.AnyObjectId;
import org.eclipse.jgit.lib.BatchRefUpdate;
+import org.eclipse.jgit.lib.ProgressMonitor;
import org.eclipse.jgit.lib.NullProgressMonitor;
import org.eclipse.jgit.lib.Ref;
import org.eclipse.jgit.lib.Ref.Storage;
@@ -1191,8 +1192,7 @@ public class RefDirectoryTest extends LocalDiskRepositoryTestCase {
ReceiveCommand.Type.UPDATE_NONFASTFORWARD));
BatchRefUpdate batchUpdate = refdir.newBatchUpdate();
batchUpdate.addCommand(commands);
- batchUpdate
- .execute(new RevWalk(diskRepo), NullProgressMonitor.INSTANCE);
+ batchUpdate.execute(new RevWalk(diskRepo), new StrictWorkMonitor());
Map<String, Ref> refs = refdir.getRefs(RefDatabase.ALL);
assertEquals(ReceiveCommand.Result.OK, commands.get(0).getResult());
assertEquals(ReceiveCommand.Result.REJECTED_NONFASTFORWARD, commands
@@ -1215,8 +1215,7 @@ public class RefDirectoryTest extends LocalDiskRepositoryTestCase {
BatchRefUpdate batchUpdate = refdir.newBatchUpdate();
batchUpdate.setAllowNonFastForwards(true);
batchUpdate.addCommand(commands);
- batchUpdate
- .execute(new RevWalk(diskRepo), NullProgressMonitor.INSTANCE);
+ batchUpdate.execute(new RevWalk(diskRepo), new StrictWorkMonitor());
Map<String, Ref> refs = refdir.getRefs(RefDatabase.ALL);
assertEquals(ReceiveCommand.Result.OK, commands.get(0).getResult());
assertEquals(ReceiveCommand.Result.OK, commands.get(1).getResult());
@@ -1267,8 +1266,7 @@ public class RefDirectoryTest extends LocalDiskRepositoryTestCase {
BatchRefUpdate batchUpdate = refdir.newBatchUpdate();
batchUpdate.setAllowNonFastForwards(true);
batchUpdate.addCommand(commands);
- batchUpdate
- .execute(new RevWalk(diskRepo), NullProgressMonitor.INSTANCE);
+ batchUpdate.execute(new RevWalk(diskRepo), new StrictWorkMonitor());
Map<String, Ref> refs = refdir.getRefs(RefDatabase.ALL);
assertEquals(ReceiveCommand.Result.OK, commands.get(0).getResult());
assertEquals(ReceiveCommand.Result.OK, commands.get(1).getResult());
@@ -1311,4 +1309,29 @@ public class RefDirectoryTest extends LocalDiskRepositoryTestCase {
File path = new File(diskRepo.getDirectory(), name);
assertTrue("deleted " + name, path.delete());
}
+
+ private static final class StrictWorkMonitor implements ProgressMonitor {
+ private int lastWork, totalWork;
+
+ public void start(int totalTasks) {
+ // empty
+ }
+
+ public void beginTask(String title, int totalWork) {
+ this.totalWork = totalWork;
+ lastWork = 0;
+ }
+
+ public void update(int completed) {
+ lastWork += completed;
+ }
+
+ public void endTask() {
+ assertEquals("Units of work recorded", totalWork, lastWork);
+ }
+
+ public boolean isCancelled() {
+ return false;
+ }
+ }
}
47649/stable29 Nextcloud server, a safe home for all your data: https://github.com/nextcloud/serverwww-data
summaryrefslogtreecommitdiffstats
path: root/apps/workflowengine/l10n/sk.js
blob: 981f014620cb51c36eaf9dd19b5ccc400a9363b3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
OC.L10N.register(
    "workflowengine",
    {
    "File MIME type" : "MIME typ súboru",
    "is" : "je",
    "is not" : "nie je",
    "matches" : "súhlasí",
    "does not match" : "nesúhlasí",
    "Example: {placeholder}" : "Napríklad: {placeholder}",
    "File name" : "Názov súboru",
    "File size (upload)" : "Veľkosť súboru (upload)",
    "less" : "menej",
    "less or equals" : "menej alebo rovné",
    "greater or equals" : "viac alebo rovné",
    "greater" : "viac",
    "File system tag" : "Štítok súborového systému",
    "is tagged with" : "je označený",
    "is not tagged with" : "nie je označený",
    "Select tag…" : "Vyber štítok...",
    "Request remote address" : "Vyžiadať vzdialenú adresu",
    "matches IPv4" : "súhlasí s IPv4",
    "does not match IPv4" : "nesúhlasí s IPv4",
    "matches IPv6" : "súhlasí s IPv6",
    "does not match IPv6" : "nesúhlasí s IPv6",
    "Request time" : "Čas požiadavky",
    "between" : "medzi",
    "not between" : "nie je medzi",
    "Start" : "Začiatok",
    "End" : "Koniec",
    "Select timezone…" : "Vybrať časové pásmo...",
    "Request URL" : "Vyžiadať URL",
    "Predefined URLs" : "Preddefinované URL",
    "Files WebDAV" : "WebDAV súbory",
    "Request user agent" : "User agent požiadavky",
    "Sync clients" : "Synchronizovať klientov",
    "Android client" : "Android klient",
    "iOS client" : "iOS klient",
    "Desktop client" : "Desktopový klient",
    "Thunderbird & Outlook addons" : "Doplnky pre Thunderbird a Outlook",
    "User group membership" : "Členstvo v skupine používateľov",
    "is member of" : "Je členom",
    "is not member of" : "Nie je členom",
    "Short rule description" : "Zobraziť popis pravidla",
    "Add rule" : "Pridať pravidlo",
    "Reset" : "Vynulovať",
    "Save" : "Uložiť",
    "Saving…" : "Ukladá sa...",
    "Group list is empty" : "Zoznam skupín je prázdny",
    "Unable to retrieve the group list" : "Nie je možné načítať zoznam skupín",
    "Saved" : "Uložené",
    "Saving failed:" : "Ukladanie neúspešné:",
    "Add rule group" : "Pridať skupinu pravidiel",
    "The given operator is invalid" : "Zadaný operátor je neplatný",
    "The given regular expression is invalid" : "Zadaný regulárny výraz je neplatný",
    "The given file size is invalid" : "Zadaná veľkosť súboru je neplatná",
    "The given tag id is invalid" : "Zadaný identifikátor štítku je neplatný",
    "The given IP range is invalid" : "Zadaný rozsah IP je neplatný",
    "The given IP range is not valid for IPv4" : "Zadaný IP rozsah nie je platný pre IPv4",
    "The given IP range is not valid for IPv6" : "Zadaný IP rozsah nie je platný pre IPv6",
    "The given time span is invalid" : "Zadané časové rozpätie nie je platné",
    "The given start time is invalid" : "Zadaný čas začatia nie je platný",
    "The given end time is invalid" : "Zadaný čas ukončenia nie je platný",
    "The given group does not exist" : "Zadaná skupina neexistuje",
    "Check %s is invalid or does not exist" : "Kontrola %s je neplatná alebo neexistuje",
    "Operation #%s does not exist" : "Operácia #%s neexistuje",
    "Operation %s does not exist" : "Operácia %s neexistuje",
    "Operation %s is invalid" : "Operácia #%s nie je platná",
    "Check %s does not exist" : "Kontrola %s neexistuje",
    "Check %s is invalid" : "Kontrola %s je neplatná",
    "Check #%s does not exist" : "Kontrola #%s neexistuje",
    "Tag management" : "Správa štítkov",
    "Files workflow engine" : "Typ spôsobu práce súborov",
    "Open documentation" : "Otvoriť dokumentáciu",
    "Loading…" : "Načítava sa...",
    "Workflow" : "Systém práce"
},
"nplurals=4; plural=(n % 1 == 0 && n == 1 ? 0 : n % 1 == 0 && n >= 2 && n <= 4 ? 1 : n % 1 != 0 ? 2: 3);");