diff options
Diffstat (limited to 'src/fs/test_fs_publish.c')
-rw-r--r-- | src/fs/test_fs_publish.c | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/src/fs/test_fs_publish.c b/src/fs/test_fs_publish.c index 99d4b6710..b206fb415 100644 --- a/src/fs/test_fs_publish.c +++ b/src/fs/test_fs_publish.c | |||
@@ -225,6 +225,7 @@ run (void *cls, | |||
225 | struct GNUNET_FS_FileInformation *fi2; | 225 | struct GNUNET_FS_FileInformation *fi2; |
226 | struct GNUNET_FS_FileInformation *fidir; | 226 | struct GNUNET_FS_FileInformation *fidir; |
227 | size_t i; | 227 | size_t i; |
228 | struct GNUNET_FS_BlockOptions bo; | ||
228 | 229 | ||
229 | setup_peer (&p1, "test_fs_publish_data.conf"); | 230 | setup_peer (&p1, "test_fs_publish_data.conf"); |
230 | fs = GNUNET_FS_start (cfg, | 231 | fs = GNUNET_FS_start (cfg, |
@@ -258,33 +259,35 @@ run (void *cls, | |||
258 | 259 | ||
259 | meta = GNUNET_CONTAINER_meta_data_create (); | 260 | meta = GNUNET_CONTAINER_meta_data_create (); |
260 | kuri = GNUNET_FS_uri_ksk_create_from_args (2, keywords); | 261 | kuri = GNUNET_FS_uri_ksk_create_from_args (2, keywords); |
262 | bo.content_priority = 42; | ||
263 | bo.anonymity_level = 1; | ||
264 | bo.replication_level = 0; | ||
265 | bo.expiration_time = GNUNET_TIME_relative_to_absolute (LIFETIME); | ||
266 | |||
261 | fi1 = GNUNET_FS_file_information_create_from_file (fs, | 267 | fi1 = GNUNET_FS_file_information_create_from_file (fs, |
262 | "publish-context1", | 268 | "publish-context1", |
263 | fn1, | 269 | fn1, |
264 | kuri, | 270 | kuri, |
265 | meta, | 271 | meta, |
266 | GNUNET_YES, | 272 | GNUNET_YES, |
267 | 1, | 273 | &bo); |
268 | 42, | 274 | |
269 | GNUNET_TIME_relative_to_absolute (LIFETIME)); | ||
270 | GNUNET_assert (NULL != fi1); | 275 | GNUNET_assert (NULL != fi1); |
276 | bo.anonymity_level = 2; | ||
271 | fi2 = GNUNET_FS_file_information_create_from_file (fs, | 277 | fi2 = GNUNET_FS_file_information_create_from_file (fs, |
272 | "publish-context2", | 278 | "publish-context2", |
273 | fn2, | 279 | fn2, |
274 | kuri, | 280 | kuri, |
275 | meta, | 281 | meta, |
276 | GNUNET_YES, | 282 | GNUNET_YES, |
277 | 2, | 283 | &bo); |
278 | 42, | ||
279 | GNUNET_TIME_relative_to_absolute (LIFETIME)); | ||
280 | GNUNET_assert (NULL != fi2); | 284 | GNUNET_assert (NULL != fi2); |
285 | bo.anonymity_level = 3; | ||
281 | fidir = GNUNET_FS_file_information_create_empty_directory (fs, | 286 | fidir = GNUNET_FS_file_information_create_empty_directory (fs, |
282 | "publish-context-dir", | 287 | "publish-context-dir", |
283 | kuri, | 288 | kuri, |
284 | meta, | 289 | meta, |
285 | 3, | 290 | &bo); |
286 | 42, | ||
287 | GNUNET_TIME_relative_to_absolute (LIFETIME)); | ||
288 | GNUNET_assert (GNUNET_OK == GNUNET_FS_file_information_add (fidir, fi1)); | 291 | GNUNET_assert (GNUNET_OK == GNUNET_FS_file_information_add (fidir, fi1)); |
289 | GNUNET_assert (GNUNET_OK == GNUNET_FS_file_information_add (fidir, fi2)); | 292 | GNUNET_assert (GNUNET_OK == GNUNET_FS_file_information_add (fidir, fi2)); |
290 | GNUNET_FS_uri_destroy (kuri); | 293 | GNUNET_FS_uri_destroy (kuri); |