Home
Products
FAQ
WordPress
Contact Us
Home
Products
FAQ
WordPress
Contact Us
menu
Search
Search Keyword:
Search
All words
Any words
Exact Phrase
Ordering:
Newest First
Oldest First
Most Popular
Alphabetical
Section/Category
Search Keyword
loader
Total: 50 results found.
Display #
5
10
15
20
25
30
50
100
All
Page 2 of 3
21.
Can I use Mockito to test retry mechanisms in my code
(Knowledge base/Global)
... FileService { private final FileDown
loader
down
loader
; public FileService(FileDown
loader
down
loader
) { this.down
loader
= down
loader
; } public File getFile(int retryCount) ...
22.
Can you provide an example of using PowerMockito with Hamcrest
(Knowledge base/Global)
... and Hamcrest for assertions. ### Step 3: Writing the Test ```java import org.junit.Test; import org.junit.runner.RunWith; import org.powermock.api.mockito.PowerMockito; import org.powermock.core.class
loader
.annotations.PrepareForTest; import ...
23.
How does the dependency on PowerMock affect the overall test architecture compared to using Mockito alone
(Knowledge base/Global)
... class
loader
s, which can complicate test setup and require more configuration[2][6]. PowerMock is generally used for more complex scenarios or legacy codebases where Mockito's limitations are a barrier[4][5]. ### ...
24.
Can I use PowerMock and Mockito together in the same test class
(Knowledge base/Global)
... org.powermock.core.class
loader
.annotations.PrepareForTest; import org.powermock.modules.junit4.PowerMockRunner; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import ...
25.
How do I integrate PowerMock with JUnit 4 to use Mockito's mock-maker-inline
(Knowledge base/Global)
... and specify the classes you want to mock using `@PrepareForTest`. Here's an example: ```java import org.junit.runner.RunWith; import org.powermock.api.mockito.PowerMockito; import org.powermock.core.class
loader
.annotations.PrepareForTest; import ...
26.
Can you provide an example of mocking a static method with PowerMock and Mockito
(Knowledge base/Global)
... org.powermock.core.class
loader
.annotations.PrepareForTest; import org.powermock.modules.junit4.PowerMockRunner; @RunWith(PowerMockRunner.class) @PrepareForTest(IdGenerator.class) public class ServiceRegistratorTest ...
27.
How do you configure PowerMock and Mockito in a Maven project
(Knowledge base/Global)
... org.powermock.api.mockito.PowerMockito; import org.powermock.core.class
loader
.annotations.PrepareForTest; import org.powermock.modules.junit4.PowerMockRunner; @RunWith(PowerMockRunner.class) @PrepareForTest(Utils.class) public ...
28.
Can PowerMock and Mockito be used together in the same project
(Knowledge base/Global)
... org.powermock.api.mockito.PowerMockito; import org.powermock.core.class
loader
.annotations.PrepareForTest; import org.powermock.modules.junit4.PowerMockRunner; import static org.mockito.Mockito.when; @RunWith(PowerMockRunner.class) @PrepareForTest(Utils.class) public ...
29.
How does PowerMock's MockMaker differ from Mockito's mock-maker-inline
(Knowledge base/Global)
... PowerMock's MockMaker PowerMock extends other mock libraries like EasyMock and Mockito by providing more powerful capabilities. It uses a custom class
loader
and bytecode manipulation to enable mocking ...
30.
How does PowerMock handle final methods in Mockito 5
(Knowledge base/Global)
... org.powermock.core.class
loader
.annotations.PrepareForTest; import org.powermock.modules.junit4.PowerMockRunner; @RunWith(PowerMockRunner.class) @PrepareForTest(ClassWithFinalMethod.class) public ...
31.
How do I configure PowerMock to use Mockito's mock-maker-inline feature
(Knowledge base/Global)
... org.junit.Test; import org.junit.runner.RunWith; import org.powermock.api.mockito.PowerMockito; import org.powermock.core.class
loader
.annotations.PrepareForTest; import org.powermock.modules.junit4.PowerMockRunner; import ...
32.
How do I configure PowerMock to work with Mockito 2
(Knowledge base/Global)
... for testing using `@PrepareForTest`. This annotation is necessary for mocking static methods or classes. ```java import org.junit.runner.RunWith; import org.powermock.core.class
loader
.annotations.PrepareForTest; import ...
33.
How does PowerMock integrate with Mockito and Hamcrest
(Knowledge base/Global)
... org.powermock.api.mockito.PowerMockito; import org.powermock.core.class
loader
.annotations.PrepareForTest; import org.powermock.modules.junit4.PowerMockRunner; @RunWith(PowerMockRunner.class) @PrepareForTest(MyStaticClass.class) public ...
34.
How can I ensure my plugin is properly loaded in different MvvmCross versions
(Knowledge base/Global)
... `T` is your plugin
loader
. This approach required manually specifying which plugins to load. ```csharp using MvvmCross.Platform.Plugins; namespace MyNamespace { public class MyPluginBootstrap ...
35.
How do you integrate the Infinite Scroll Plugin with MvvmCross
(Knowledge base/Global)
... a class that inherits from `MvxPluginBootstrapAction` where `T` is the plugin
loader
type[8]. ```csharp using MvvmCross.Platform.Plugins; using Sequence.Plugins.InfiniteScroll; namespace ...
36.
How do I install and configure the MvvmCross.Plugin.Email plugin
(Knowledge base/Global)
... https://stackoverflow.com/questions/18291513/mvvmcross-passing-configuration-to-configurable-plugin-
loader
[7] https://mantisbt.org/forums/viewtopic.php?t=20630 [8] https://www.mvvmcross.com/documentation/plugins/plugins-development [9] ...
37.
How does the JsonLocalization plugin interact with custom JSON converters in MvvmCross
(Knowledge base/Global)
The JsonLocalization plugin in MvvmCross is designed to handle internationalization by loading JSON language text files. It relies on the Resource
Loader
and Json plugins to load these files from the application ...
38.
How do I increase the shared memory segment size for multi-threaded data loaders
(Knowledge base/Global)
To increase the shared memory segment size for multi-threaded data
loader
s, you can follow these steps: 1. Edit System Configuration: - Become the superuser. - Open the `/etc/system` file (on ...
39.
How can I optimize the build speed for PyTorch and PyTorch/XLA
(Knowledge base/Global)
... operation[4][6]. 2. Preload Data: Use `MPDevice
Loader
` to preload data onto XLA devices, reducing communication overhead between the host CPU and the device[8]. 3. Minimize CPU-Device Communication: ...
40.
Can you provide examples of batch size mismatches in PyTorch
(Knowledge base/Global)
... in a way that its first dimension (batch size) is altered, this can lead to a mismatch when computing loss functions that expect the batch sizes of input and target to match[5]. 3. Data
loader
Behavior: ...
<<
Start
<
Prev
1
2
3
Next
>
End
>>